Delete Dynamic Charges for a Purchased Product
/bcws/webresources/v1.0/subscriptions/offer/{id}/overridecharges
Request
-
id(required): string
The ID of the purchased product or discount to delete dynamic charges from. For example: 0.0.0.1+-purchased_product+123123
- application/xml
- application/json
- event
- charges
object
-
charges(required): array
charges
The charge details.
-
event(required): string
The event associated with the overridden charges.
array
-
Array of:
object Charges
The charge details.
object
-
charge(required): array
charge
The charges.
-
endDate: string
(date-time)
The date and time the charge's validity ends.
-
startDate(required): string
(date-time)
The date and time the charge's validity starts.
object
-
amount(required): number
The charge amount.
-
priceTag(required): string
The charge's price tag.
-
type(required): string
The charge type.
- event
- charges
object
-
charges(required): array
charges
The charge details.
-
event(required): string
The event associated with the overridden charges.
array
-
Array of:
object Charges
The charge details.
object
-
charge(required): array
charge
The charges.
-
endDate: string
(date-time)
The date and time the charge's validity ends.
-
startDate(required): string
(date-time)
The date and time the charge's validity starts.
object
-
amount(required): number
The charge amount.
-
priceTag(required): string
The charge's price tag.
-
type(required): string
The charge type.
Response
200 Response
400 Response
500 Response
Examples
This example shows how delete dynamic charges for a purchased product by submitting DELETE requests on the REST resource using cURL. For more information about cURL, see "Use cURL".
cURL Commands
The following command shows how to delete all dynamic charges for the product:curl -X DELETE 'http://hostname:port/bcws/webresources/version/subscriptions/offer/0.0.0.1+-purchased_product+2832219/overridecharges' -H 'content-type: application/json'
The following command shows how to specify a request body to delete only the dynamic charges specified:
curl -X DELETE 'http://hostname:port/bcws/webresources/version/subscriptions/offer/0.0.0.1+-purchased_product+2832219/overridecharges' -H 'content-type: application/json' -d @deleteCharges.json
where:
- hostname is the URL for the Billing Care REST server.
- port is the port for the Billing Care REST server.
- version is the version of the API you're using, such as v1.0.
- deleteCharges.json is the JSON file that specifies the loan to create.
Example of Request Body for Deleting Charges by Date Range
This example shows the contents of the deleteCharges.json file sent as the request body. It deletes only the charges that fall within the specified date range.
[
{
"event":"/event/billing/product/fee/cycle/cycle_forward_arrear",
"charges":[
{
"startDate":"2021-10-19",
"endDate":"2021-11-19",
}
]
}
]
Example of Request Body for Deleting Charges by Price Tag
This example shows the contents of the deleteCharges.json file sent as the request body. It deletes only the charges with the specified price tag.
[
{
"event":"/event/billing/product/fee/cycle/cycle_forward_arrear",
"charges":[
{
"startDate":"2021-10-19",
"endDate":"2021-11-19",
"charge":[
{
"priceTag":"USD",
},
{
"priceTag":"Free Minutes",
}
]
}
]
}
]
Example of Response Body
If successful, the response code 200 is returned with Ok in the response body.