Get Bucket Balances
get
/bucket
Gets the bucket balances that match the specified query criteria.
Request
Query Parameters
-
@type: string
The type of object to return.Example:
Use @type=Bucket for a base object or @type=BucketOracle for an extended object.
-
fields: string
The list of comma-separated fields to return in the response.Example:
<b>fields=name,partyAccount,product</b>.
-
limit: integer
The maximum number of results to return.Example:
Use limit=10 to return the first 10 results only.
-
offset: integer
The number of results to offset the response by.Example:
Use offset=10 to return results 10 and higher.
-
product.id: string
Retrieves the buckets for the product with the specified ID.Example:
product.id=0.0.0.1+-service-telco-gsm+67479
There's no request body for this operation.
Back to TopResponse
Supported Media Types
- application/json;charset=utf-8
200 Response
Success
Headers
-
X-Result-Count:
The number of items returned in the response body.
-
X-Total-Count:
The total number of items that matched the criteria.
Root Schema : schema
Type:
Show Source
array
-
Array of:
object Bucket
Title:
Bucket
A bucket that tracks a quantity of usage (remaining or consumed) for currency or non-currency resources (such as messages, minutes, data).
Nested Schema : Bucket
Type:
object
Title:
Bucket
A bucket that tracks a quantity of usage (remaining or consumed) for currency or non-currency resources (such as messages, minutes, data).
Show Source
-
@baseType: string
Title:
Base Type
The object's superclass. -
@schemaLocation: string
(uri)
Title:
Schema Location
A URI to a JSON-Schema file that defines additional attributes and relationships. -
@type: string
Title:
Type
The object's subclass. -
confirmationDate: string
(date-time)
Title:
Confirmation Date
The date that an action on the bucket was confirmed. -
description: string
Title:
Description
The bucket's description. -
href(required): string
Title:
Bucket Href
The bucket's href. -
id(required): string
Title:
Bucket ID
The bucket's ID. - isShared: boolean
-
logicalResource: array
logicalResource
Logical resources associated with the bucket.
-
name: string
Title:
Bucket Name
The bucket's name. -
partyAccount: object
Party Account Ref
Title:
Party Account Ref
A reference to a party account. -
product: array
product
Products associated with the bucket.
- relatedParty: array relatedParty
-
remainingValue: object
Quantity
An amount in a given unit.
-
remainingValueName: string
Title:
Remaining Value
A string, including value and unit, representing the remaining amount in the bucket, used for display purposes. For example, 1.9 GB. -
requestedDate: string
(date-time)
Title:
Requested Date
The date that a request about the bucket was made. -
reservedValue: object
Quantity
An amount in a given unit.
-
status(required): string
Title:
Bucket Status Type
Allowed Values:[ "active", "suspended", "expired" ]
A bucket's status. -
usageType: string
Title:
Usage Type
Allowed Values:[ "monetary", "voice", "data", "sms", "other" ]
The type of usage. For BRM REST Services Manager, only monetary and other are supported. -
validFor(required): object
TimePeriod
A period of time.
Nested Schema : logicalResource
Type:
array
Logical resources associated with the bucket.
Show Source
-
Array of:
object Logical Resource Ref
Title:
Logical Resource Ref
A reference to a logical resource.
Nested Schema : Party Account Ref
Type:
object
Title:
Party Account Ref
A reference to a party account.
Show Source
-
@baseType: string
Title:
Base Type
The object's superclass. -
@referredType: string
Title:
Referred Type
The object's type in the target system, if baseType and type need further disambiguation. -
@schemaLocation: string
(uri)
Title:
Schema Location
A URI to a JSON-Schema file that defines additional attributes and relationships. -
@type: string
Title:
Type
The object's subclass. -
description: string
Title:
Description
The party account's description. -
href: string
Title:
Href
The party account's href. -
id(required): string
Title:
Account ID
The party account's ID. -
name: string
Title:
Name
The party account's name. -
status: string
Title:
Status
The overall status of the account. For example, due, paid, or in arrears.
Nested Schema : product
Type:
array
Products associated with the bucket.
Show Source
-
Array of:
object Product Ref
Title:
Product Ref
A reference to a product.
Nested Schema : Quantity
Type:
object
An amount in a given unit.
Show Source
-
amount: number
(float)
Default Value:
1
Numeric value in a given unit. -
units: string
Unit
Nested Schema : TimePeriod
Type:
object
A period of time.
Show Source
-
endDateTime: string
(date-time)
Title:
End Time Period
The end of the time period in IETC-RFC-3339 format. -
startDateTime: string
(date-time)
Title:
Start Time Period
The start of the time period in IETC-RFC-3339 format.
Nested Schema : Logical Resource Ref
Type:
object
Title:
Logical Resource Ref
A reference to a logical resource.
Show Source
-
@baseType: string
Title:
Base Type
The object's superclass. -
@referredType: string
Title:
Referred Type
The object's type in the target system, if baseType and type need further disambiguation. -
@schemaLocation: string
(uri)
Title:
Schema Location
A URI to a JSON-Schema file that defines additional attributes and relationships. -
@type: string
Title:
Type
The object's subclass. -
href: string
Title:
Href
The resource's href. -
id(required): string
Title:
ID
The resource's ID. -
name: string
Title:
Name
The resource's name.
Nested Schema : Product Ref
Type:
object
Title:
Product Ref
A reference to a product.
Show Source
-
@baseType: string
Title:
Base Type
The object's superclass. -
@referredType: string
Title:
Referred Type
The object's type in the target system, if baseType and type need further disambiguation. -
@schemaLocation: string
(uri)
Title:
Schema Location
A URI to a JSON-Schema file that defines additional attributes and relationships. -
@type: string
Title:
Type
The object's subclass. -
href: string
Title:
Product Href
The product's href. -
id(required): string
Title:
Product ID
The product's ID. -
name: string
Title:
Product Name
The product's name.
Nested Schema : Related Party
Type:
object
Title:
Related Party
A party related to another object.
Show Source
-
@baseType: string
Title:
Base Type
The object's superclass. -
@referredType(required): string
Title:
Referred Type
The object's type in the target system, if baseType and type need further disambiguation. -
@schemaLocation: string
(uri)
Title:
Schema Location
A URI to a JSON-Schema file that defines additional attributes and relationships. -
@type: string
Title:
Type
The object's subclass. -
href: string
Title:
Href
The party's href. -
id(required): string
Title:
Party ID
The party's ID. -
name: string
Title:
Party Name
The party's name. -
role: string
Title:
Party Role
The party's role.
400 Response
Bad Request
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
-
@baseType: string
This defines the super-class when sub-classing.
-
@schemaLocation: string
(uri)
A URI to a JSON-schema file that defines additional attributes and relationships.
-
@type: string
This defines the sub-class entity name when sub-classing.
-
code(required): string
Refers to application relevant detail, defined in the API or a common list.
-
message: string
More details and corrective actions related to the error which can be shown to a client user.
-
reason(required): string
Explanation of the reason for the error which can be shown to a client user.
-
referenceError: string
(uri)
URI of documentation describing the error.
-
status: string
Displays the HTTP error code extension.
401 Response
Unauthorized
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
-
@baseType: string
This defines the super-class when sub-classing.
-
@schemaLocation: string
(uri)
A URI to a JSON-schema file that defines additional attributes and relationships.
-
@type: string
This defines the sub-class entity name when sub-classing.
-
code(required): string
Refers to application relevant detail, defined in the API or a common list.
-
message: string
More details and corrective actions related to the error which can be shown to a client user.
-
reason(required): string
Explanation of the reason for the error which can be shown to a client user.
-
referenceError: string
(uri)
URI of documentation describing the error.
-
status: string
Displays the HTTP error code extension.
403 Response
Forbidden
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
-
@baseType: string
This defines the super-class when sub-classing.
-
@schemaLocation: string
(uri)
A URI to a JSON-schema file that defines additional attributes and relationships.
-
@type: string
This defines the sub-class entity name when sub-classing.
-
code(required): string
Refers to application relevant detail, defined in the API or a common list.
-
message: string
More details and corrective actions related to the error which can be shown to a client user.
-
reason(required): string
Explanation of the reason for the error which can be shown to a client user.
-
referenceError: string
(uri)
URI of documentation describing the error.
-
status: string
Displays the HTTP error code extension.
404 Response
Not Found
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
-
@baseType: string
This defines the super-class when sub-classing.
-
@schemaLocation: string
(uri)
A URI to a JSON-schema file that defines additional attributes and relationships.
-
@type: string
This defines the sub-class entity name when sub-classing.
-
code(required): string
Refers to application relevant detail, defined in the API or a common list.
-
message: string
More details and corrective actions related to the error which can be shown to a client user.
-
reason(required): string
Explanation of the reason for the error which can be shown to a client user.
-
referenceError: string
(uri)
URI of documentation describing the error.
-
status: string
Displays the HTTP error code extension.
405 Response
Method Not allowed
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
-
@baseType: string
This defines the super-class when sub-classing.
-
@schemaLocation: string
(uri)
A URI to a JSON-schema file that defines additional attributes and relationships.
-
@type: string
This defines the sub-class entity name when sub-classing.
-
code(required): string
Refers to application relevant detail, defined in the API or a common list.
-
message: string
More details and corrective actions related to the error which can be shown to a client user.
-
reason(required): string
Explanation of the reason for the error which can be shown to a client user.
-
referenceError: string
(uri)
URI of documentation describing the error.
-
status: string
Displays the HTTP error code extension.
409 Response
Conflict
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
-
@baseType: string
This defines the super-class when sub-classing.
-
@schemaLocation: string
(uri)
A URI to a JSON-schema file that defines additional attributes and relationships.
-
@type: string
This defines the sub-class entity name when sub-classing.
-
code(required): string
Refers to application relevant detail, defined in the API or a common list.
-
message: string
More details and corrective actions related to the error which can be shown to a client user.
-
reason(required): string
Explanation of the reason for the error which can be shown to a client user.
-
referenceError: string
(uri)
URI of documentation describing the error.
-
status: string
Displays the HTTP error code extension.
500 Response
Internal Server Error
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
-
@baseType: string
This defines the super-class when sub-classing.
-
@schemaLocation: string
(uri)
A URI to a JSON-schema file that defines additional attributes and relationships.
-
@type: string
This defines the sub-class entity name when sub-classing.
-
code(required): string
Refers to application relevant detail, defined in the API or a common list.
-
message: string
More details and corrective actions related to the error which can be shown to a client user.
-
reason(required): string
Explanation of the reason for the error which can be shown to a client user.
-
referenceError: string
(uri)
URI of documentation describing the error.
-
status: string
Displays the HTTP error code extension.
Examples
The following example shows how to get bucket balances by submitting a GET request on the REST resource using cURL. For more information about cURL, see Use cURL.
The request uses the product.id query parameters to restrict the results.
curl -X GET 'http://host:port/brm/prepayBalanceManagement/version/bucket?&product.id=0.0.0.1+-service-telco-gsm-sms+102975'
Example of the Response Body
The following example shows the contents of the response body in JSON format.
[ { "id": "0.0.0.1+-balance_group+106463", "href": "http://host:port/brm/prepayBalanceManagement/version/bucket/0.0.0.1+-balance_group+106463", "confirmationDate": null, "description": null, "isShared": null, "name": "Account Balance Group", "remainingValueName": null, "requestedDate": null, "logicalResource": null, "partyAccount": { "id": "0.0.0.1+-account+102879", "href": null, "description": null, "name": "James Kurup", "status": "active", "@baseType": null, "@schemaLocation": null, "@type": "PartyAccountRef", "@referredType": null }, "product": [ { "id": "0.0.0.1+-service-telco-gsm-sms+102975", "href": null, "name": "ServiceTelcoGsmSms", "@baseType": null, "@schemaLocation": null, "@type": "ProductRef", "@referredType": null }, { "id": "0.0.0.1+-service-telco-gsm-telephony+104255", "href": null, "name": "ServiceTelcoGsmTelephony", "@baseType": null, "@schemaLocation": null, "@type": "ProductRef", "@referredType": null } ], "relatedParty": null, "remainingValue": { "amount": 45.0, "units": "EUR", "@baseType": null, "@schemaLocation": null, "@type": "Quantity" }, "reservedValue": { "amount": 0.0, "units": "EUR", "@baseType": null, "@schemaLocation": null, "@type": "Quantity" }, "status": "ACTIVE", "usageType": null, "validFor": { "endDateTime": null, "startDateTime": "2020-05-02T00:00:00-07:00" }, "@baseType": "Bucket", "@schemaLocation": null, "@type": "Bucket" } ]