Update a Customer Bill

patch

/customerBill/{id}

Updates a customer bill. You can update the value of the state property of the bill 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
Back to Top

Response

Supported Media Types

200 Response

Updated
Body ()
Root Schema : Customer Bill
Type: object
Title: Customer Bill
A customer bill, also called an invoice.
Show Source
Nested Schema : Money
Type: object
A base / value business entity used to represent money.
Show Source
Nested Schema : appliedPayment
Type: array
Payments applied to the bill.
Show Source
Nested Schema : billDocument
Type: array
A document attached to the bill.
Show Source
  • Attachment Ref Or Value
    Title: Attachment Ref Or Value
    An attachment reference or value. The baseType, type, schemaLocation and referredType properties are related to the contained object, not the AttchmentRefOrValue.
Nested Schema : Billing Account Ref
Type: object
Title: Billing Account Ref
A billing account is a detailed description of a bill structure.
Show Source
Nested Schema : TimePeriod
Type: object
A period of time.
Show Source
Nested Schema : Financial Account Ref
Type: object
Title: Financial Account Ref
A financial account reference.
Show Source
Nested Schema : Payment Method Ref
Type: object
Title: Payment Method Ref
A reference to a payment method.
Show Source
Nested Schema : relatedParty
Type: array
The parties related to the bill.
Show Source
Nested Schema : taxItem
Type: array
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 : Payment Ref
Type: object
Title: Payment Ref
A payment captured as a reference on an order. Used when a payment is made immediately on an order rather than at a later billing date.
Show Source
Nested Schema : Attachment Ref Or Value
Type: object
Title: Attachment Ref Or Value
An attachment reference or value. The baseType, type, schemaLocation and referredType properties are related to the contained object, not the AttchmentRefOrValue.
Show Source
Nested Schema : Quantity
Type: object
An amount in a given unit.
Show Source
Nested Schema : accountBalance
Type: array
The account's balances.
Show Source
Nested Schema : Account Balance
Type: object
Title: Account Balance
A balance associated with 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

Bad Request
Body ()
Root Schema : Error
Type: object
This is used when an API throws an error, typically with a HTTP error response-code (3xx, 4xx, 5xx).
Show Source

401 Response

Unauthorized
Body ()
Root Schema : Error
Type: object
This is used when an API throws an error, typically with a HTTP error response-code (3xx, 4xx, 5xx).
Show Source

403 Response

Forbidden
Body ()
Root Schema : Error
Type: object
This is used when an API throws an error, typically with a HTTP error response-code (3xx, 4xx, 5xx).
Show Source

404 Response

Not Found
Body ()
Root Schema : Error
Type: object
This is used when an API throws an error, typically with a HTTP error response-code (3xx, 4xx, 5xx).
Show Source

405 Response

Method Not Allowed
Body ()
Root Schema : Error
Type: object
This is used when an API throws an error, typically with a HTTP error response-code (3xx, 4xx, 5xx).
Show Source

409 Response

Conflict
Body ()
Root Schema : Error
Type: object
This is used when an API throws an error, typically with a HTTP error response-code (3xx, 4xx, 5xx).
Show Source

500 Response

Internal Server Error
Body ()
Root Schema : Error
Type: object
This is used when an API throws an error, typically with a HTTP error response-code (3xx, 4xx, 5xx).
Show Source
Back to Top

Examples

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. You can use either a bill ID POID, as in the example, or a bill number.

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

Example of 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": "OnHold",
      "@baseType": "CustomerBill",
       "@schemaLocation": null,
       "@type": "CustomerBill"

}

Example of 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": "2021-05-02T01:14:13-07:00",
        "nextBillDate": "2021-06-13T00:00:00-07:00",
        "paymentDueDate": "2021-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": "2020-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"
}
Back to Top