Modify Customer Billing Cycle Definition

The Modify Customer Billing Cycle Definition (BCD) API is used to replace a particular Billing Cycle Definition of a given sub-account with other BCD which is listed in the eligible BCDs.

The customer is not allowed to top-up a plan of the RATE type.

HTTP URL

 

PUT

api/v2/customer/{id}/bcd

Customer {id} is the requestor’s customer ID.

Eligibility

The Requestor is eligible to change BCD that is assigned to his sub-accounts, only from its own eligible BCD list.

API Request

Parameter Type M/O/CM Description
id UUID M New billing cycle definition universal unique identity which will replace the existing one for the given customer ID (sub account)

API Response

Response Structure

Parameter Type M/O/CM Description
errorCode String O Failure code. See list below, under ‘Error Codes’ section
errorMessage String O Failure detailed description. See list below, under ‘Error Codes’ section
content Object O Array of main response body object. Displayed when an API call was successful. For a failure it will be empty.
pageable Object O Paging information object. Displayed when an API call was successful. For a failure it will be empty.

Content

Parameter Type M/O/CM Description
requestId UUID M Request instance ID. To be used by external systems to query the call (operation) status, whether in progress, successful or failed.

Error Codes

In addition to the general success and failure codes, thefollowing error codes are possible.

Code Message
GLOBAL_1001 Service unavailable. Please try again
CUSTOMER_1002 Customer does not exist
CUSTOMER_1006 Failed to retrieve customer details.
CUSTOMER_1039 Requested BCD is not eligible for the customer

Examples

Request Body

Copy

  "id": "fe84aea1-5e3f-4f45-b32c-03562913c350"
}
            

Response Body: Success (ACK)

Copy
{
  "errorCode": "",
  "errorMessage": "",
  "content": [
    {
      "requestId": "ff74dca6-8e7f-4b85-a42b-13860913b370"
    }
  ],
  "pageable": null
}

Response Body: Failure(s) (NAK)

Copy
  "errorCode": "CUSTOMER_1039",
  "errorMessage": "Requested BCD is not eligible for the customer",
  "content": "",
  "pageable": ""
}