Update a Customer Bill

patch

/customerBill/{id}

Updates a customer bill. You can update the value of the bill's state property from InProgress to OnHold, or from OnHold to InProgress.

Request

Path Parameters
Supported Media Types
Request Body - application/json;charset=utf-8 ()
Root Schema : Customer Bill Update
Type: object
Title: Customer Bill Update
A customer bill, used in the bill update request when changing the bill's state.
Show Source
  • Title: Base Type
    The object's superclass.
  • Title: Schema Location
    A URI to a JSON schema file that defines additional attributes and relationships.
  • Title: Type
    The object's subclass.
  • Title: State Value
    Allowed Values: [ "new", "partiallyPaid", "settled", "onHold", "inProgress" ]
    The possible values for a bill's state: new, partiallyPaid, settled, onHold, and inProgress.
Back to Top

Response

Supported Media Types

200 Response

The customer bill was updated successfully.
Body ()
Root Schema : Customer Bill
Type: object
Title: Customer Bill
A customer bill, also called an invoice.
Show Source
Nested Schema : Money
Type: object
Represents a monetary amount.
Show Source
Nested Schema : appliedPayment
Type: array
The payments applied to the bill.
Show Source
Nested Schema : billDocument
Type: array
A document attached to the bill.
Show Source
  • Discriminator: @type
    Discriminator: { "propertyName":"@type", "mapping":{ "Attachment":"#/components/schemas/Attachment", "AttachmentRef":"#/components/schemas/AttachmentRef" } }
    The Attachment entity, not the AttachmentRefOrValue class, uses the polymorphic @type, @schemaLocation, and @referredType attributes.
Nested Schema : Discriminator: @type
Type: object
Discriminator: @type

Discriminator Values

Match All
Refers to the billing account. The billing account describes the bill structure.
Show Source
Nested Schema : TimePeriod
Type: object
Represents a time period with a start date, an end date, or both.
Show Source
Nested Schema : Financial Account Ref
Type: object
Title: Financial Account Ref
A financial account reference.
Show Source
Nested Schema : PaymentMethodRef
Type: object
PaymentMethod reference. A payment method defines a specific mean of payment (e.g direct debit).
Match All
PaymentMethod reference. A payment method defines a specific mean of payment (e.g direct debit).
Show Source
Nested Schema : relatedParty
Type: array
The parties related to the bill.
Show Source
Nested Schema : taxItem
Type: array
The taxes on the bill.
Show Source
Nested Schema : Applied Payment
Type: object
Title: Applied Payment
A payment that can be assigned to a bill.
Show Source
Nested Schema : PaymentRef
Type: object
A payment received at order time.
Show Source
Nested Schema : Discriminator: @type
Type: object
Discriminator: @type

Discriminator Values

The Attachment entity, not the AttachmentRefOrValue class, uses the polymorphic @type, @schemaLocation, and @referredType attributes.
Match One Schema
Show Source
Nested Schema : Attachment
Match All
Represents an attachment that complements an element's description, such as a product description, through videos or pictures.
Show Source
Nested Schema : AttachmentRef
Match All
Represents an attachment reference. An attachment complements an element's description, such as a product description, through videos or pictures.
Show Source
Nested Schema : Entity
Type: object
Represents a base entity schema for TM Forum Open APIs.
Match All
Represents a base entity schema for TM Forum Open APIs.
Represents a base entity schema for TM Forum Open APIs.
Show Source
Nested Schema : Extensible
Type: object
Represents a base extensible schema for TM Forum Open APIs. The entity must include @type.
Show Source
Nested Schema : Addressable
Type: object
Defines a base schema for addressable entities.
Show Source
Nested Schema : Attachment-allOf[1]
Type: object
Represents an attachment that complements an element's description, such as a product description, through videos or pictures.
Show Source
Nested Schema : Quantity
Type: object
Represents an amount in a specified unit.
Show Source
Nested Schema : EntityRef
Match All
Represents an entity reference schema for EntityRef classes.
Show Source
Nested Schema : EntityRef-allOf[2]
Type: object
Represents an entity reference schema for EntityRef classes.
Show Source
Nested Schema : AttachmentRef-allOf[1]
Type: object
Represents an attachment reference. An attachment complements an element's description, such as a product description, through videos or pictures.
Show Source
Nested Schema : Discriminator: @type-allOf[2]
Type: object
Refers to the billing account. The billing account describes the bill structure.
Show Source
  • Indicates if the account follows a specific payment option such as prepaid or postpaid.
Nested Schema : accountBalance
Type: array
The account's balances.
Show Source
Nested Schema : AccountBalance
Match All
Represents balances linked to an account.
Show Source
Nested Schema : AccountBalance-allOf[1]
Type: object
Represents balances linked to an account.
Show Source
Nested Schema : Related Party Ref
Type: object
Title: Related Party Ref
A reference to the party related to an object.
Show Source
Nested Schema : State Values
Type: object
Title: State Values
A tax item.
Show Source

400 Response

The request isn't valid.
Body ()
Root Schema : Error
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Match All
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Show Source
Nested Schema : Extensible
Type: object
Represents a base extensible schema for TM Forum Open APIs. The entity must include @type.
Show Source
Nested Schema : Error-allOf[1]
Type: object
Show Source

401 Response

The client doesn't have the correct privileges.
Body ()
Root Schema : Error
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Match All
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Show Source
Nested Schema : Extensible
Type: object
Represents a base extensible schema for TM Forum Open APIs. The entity must include @type.
Show Source
Nested Schema : Error-allOf[1]
Type: object
Show Source

403 Response

The request wasn't authorized.
Body ()
Root Schema : Error
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Match All
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Show Source
Nested Schema : Extensible
Type: object
Represents a base extensible schema for TM Forum Open APIs. The entity must include @type.
Show Source
Nested Schema : Error-allOf[1]
Type: object
Show Source

404 Response

The requested resource couldn't be found.
Body ()
Root Schema : Error
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Match All
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Show Source
Nested Schema : Extensible
Type: object
Represents a base extensible schema for TM Forum Open APIs. The entity must include @type.
Show Source
Nested Schema : Error-allOf[1]
Type: object
Show Source

405 Response

This method is not allowed.
Body ()
Root Schema : Error
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Match All
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Show Source
Nested Schema : Extensible
Type: object
Represents a base extensible schema for TM Forum Open APIs. The entity must include @type.
Show Source
Nested Schema : Error-allOf[1]
Type: object
Show Source

409 Response

The request could not be processed due to the conflict with the existing state of the resource.
Body ()
Root Schema : Error
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Match All
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Show Source
Nested Schema : Extensible
Type: object
Represents a base extensible schema for TM Forum Open APIs. The entity must include @type.
Show Source
Nested Schema : Error-allOf[1]
Type: object
Show Source

500 Response

The system encountered an internal error.
Body ()
Root Schema : Error
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Match All
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Represents an error returned by an API, typically with an HTTP 3xx, 4xx, or 5xx response code.
Show Source
Nested Schema : Extensible
Type: object
Represents a base extensible schema for TM Forum Open APIs. The entity must include @type.
Show Source
Nested Schema : Error-allOf[1]
Type: object
Show Source
Back to Top

Examples

Example 1: Update a Customer Bill by Billing POID

The following example shows how to update the state of a customer bill by submitting a PATCH request on the REST resource using cURL. For more information about cURL, see Use cURL.

The -d option specifies the file to attach as the request body.

curl -X PATCH 'http://host:port/brm/customerBillManagement/version/customerBill/0.0.0.1+-bill+106861' -d @billUpdate.json

Request Body

The following is an example of the contents of the billUpdate.json file sent as the request body. You can only use the PATCH method to update the bill state from InProgress to OnHold, or from OnHold to InProgress.

{    
   "state": "OnHold",
   "@baseType": "CustomerBill",
    "@schemaLocation": null,
    "@type": "CustomerBill"
}

Response Body

The following is an example of the response body in JSON format.

{
   "id": "0.0.0.1+-bill+106861",
   "href": "http://host:port/brm/customerBillManagement/version/customerBill/0.0.0.1+-bill+106861",
   "billDate": null,
   "billNo": "bill in progress",
   "category": "0",
   "lastUpdate": "2025-05-02T01:14:13-07:00",
   "nextBillDate": "2025-06-13T00:00:00-07:00",
   "paymentDueDate": "2025-08-01T01:05:29-07:00",
   "runType": "onCycle",
   "amountDue": {
      "unit": "EUR",
      "value": 90.0
   },
   "appliedPayment": null,
   "billDocument": null,
   "billingAccount": {
      "id": "0.0.0.1+-account+107117",
      "href": null,
      "name": "Tanya Levy",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": null,
      "@referredType": "billingAccount"
   },
   "billingPeriod": {
      "endDateTime": null,
      "startDateTime": "2024-05-02T00:00:00-07:00"
   },
   "financialAccount": {
      "id": "0.0.0.1+-account+107117",
      "href": null,
      "name": "Tanya Levy",
      "accountBalance": null,
      "@baseType": null,
      "@schemaLocation": null,
      "@type": null,
      "@referredType": "financialAccount"
   },
   "paymentMethod": {
      "id": "0.0.0.1+-payinfo-invoice+109165",
      "href": null,
      "name": "4243324",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": null,
      "@referredType": null
   },
   "relatedParty": null,
   "remainingAmount": {
      "unit": "EUR",
      "value": 90.0
   },
   "state": "OnHold",
   "taxExcludedAmount": {
      "unit": "EUR",
      "value": 86.0
   },
   "taxIncludedAmount": {
      "unit": "EUR",
      "value": 90.0
   },
   "taxItem": null,
   "@baseType": "CustomerBill",
   "@schemaLocation": null,
   "@type": "CustomerBill"
}

Example 2: Update a Customer Bill by Bill Number

The following example shows how to update the state of a customer bill by submitting a PATCH request on the REST resource using cURL. For more information about cURL, see Use cURL.

The -d option specifies the file to attach as the request body.

curl -X PATCH 'http://host:port/brm/customerBillManagement/version/customerBill/Bill-123' -d @billUpdate.json

Request Body

The following is an example of the contents of the billUpdate.json file sent as the request body. You can only use the PATCH method to update the bill state from InProgress to OnHold, and from OnHold to InProgress.

{    
   "state": "InProgress",
   "@baseType": "CustomerBill",
    "@schemaLocation": null,
    "@type": "CustomerBill"
}

Response Body

The following is an example of the response body in JSON format.

{
   "id": "Bill-123",
   "href": "http://host:port/brm/customerBillManagement/version/customerBill/Bill-123",
   "billDate": null,
   "billNo": "Bill-123",
   "category": "0",
   "lastUpdate": "2025-05-02T01:14:13-07:00",
   "nextBillDate": "2025-06-13T00:00:00-07:00",
   "paymentDueDate": "2025-08-01T01:05:29-07:00",
   "runType": "onCycle",
   "amountDue": {
      "unit": "USD",
      "value": 146.0
   },
   "appliedPayment": null,
   "billDocument": null,
   "billingAccount": {
      "id": "0.0.0.1+-account+107117",
      "href": null,
      "name": "Mary Carter",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": null,
      "@referredType": "billingAccount"
   },
   "billingPeriod": {
      "endDateTime": null,
      "startDateTime": "2024-05-02T00:00:00-07:00"
   },
   "financialAccount": {
      "id": "0.0.0.1+-account+107117",
      "href": null,
      "name": "Mary Carter",
      "accountBalance": null,
      "@baseType": null,
      "@schemaLocation": null,
      "@type": null,
      "@referredType": "financialAccount"
   },
   "paymentMethod": {
      "id": "0.0.0.1+-payinfo-invoice+109165",
      "href": null,
      "name": "4243324",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": null,
      "@referredType": null
   },
   "relatedParty": null,
   "remainingAmount": {
      "unit": "USD",
      "value": 50.0
   },
   "state": "InProgress",
   "taxExcludedAmount": {
      "unit": "USD",
      "value": 15.0
   },
   "taxIncludedAmount": {
      "unit": "USD",
      "value": 12.0
   },
   "taxItem": null,
   "@baseType": "CustomerBill",
   "@schemaLocation": null,
   "@type": "CustomerBill"
}
Back to Top