Get Accumulated Balances

get

/accumulatedBalance

Gets accumulated balances that match the query criteria.

Request

Query Parameters
  • The type of object to return. Use @type=AccumulatedBalance for a base object, or @type=AccumulatedBalanceOracle for an extended object.
  • Specifies the bill structure's ID to filter accumulated balances. Use @type=AccumulatedBalanceOracle for the extended response. When the request filters by billStructure.id, the response includes billStructure and sets billingCycleSpecification to null.
    Examples

  • Specifies the billing cycle specification's POID to filter accumulated balances. Use @type=AccumulatedBalanceOracle for the extended response.
    Example:
    0.0.0.1+-billinfo+174685
  • The list of comma-separated fields to return in the response.
    Examples

  • The internal account ID or external account ID.
    Examples

  • The maximum number of results to return.
    Examples

  • Retrieves accumulated balances associated with the specified login ID or device ID.
    Example:
    710-20211115-091333-0-27507--147359168-phx-111
  • The number of results to offset the response by.
    Examples

  • Retrieves the accumulated balance associated with the account external ID or account POID.
    Examples

  • Retrieves the accumulated balances associated with the specified service POID, login ID or alias name.
    Examples

There's no request body for this operation.

Back to Top

Response

Supported Media Types

200 Response

The accumulated balances were retrieved successfully.
Headers
Body ()
Root Schema : schema
Type: array
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

The following examples show how to get accumulated balances by submitting a GET request on the REST resource using cURL. For more information about cURL, see Use cURL.

The first example uses query parameters to show a single accumulated balance object and only displays specific fields.

curl -X GET 'http://host:port/brm/prepayBalanceManagement/version/accumulatedBalance?fields=bucket,partyAccount,product,totalBalance&limit=1'

Response Body

The following example shows the contents of the response body in JSON format. Because the request included only bucket, partyAccount, product, and totalBalance in the fields query parameter, these are the only details shown, other than id and href.

[
  {
    "id": "0.0.0.1+-account+140598+840",
    "href": "http://host:port/brm/prepayBalanceManagement/version/accumulatedBalance/0.0.0.1+-account+140598+840",
    "bucket": [
      {
        "id": "0.0.0.1+-balance_group+141494+840+0",
        "href": "http://host:port/brm/prepayBalanceManagement/version/bucket/0.0.0.1+-balance_group+141494+840+0",
        "name": "Balance Group<Account>",
        "@baseType": "BucketRef",
        "@schemaLocation": null,
        "@type": "BucketRef",
        "@referredType": null
      }
    ],
    "partyAccount": {
      "id": "test_account_140598",
      "href": null,
      "description": null,
      "name": "Venkateswari Moorthy",
      "status": "active",
      "@baseType": "PartyAccountRef",
      "@schemaLocation": null,
      "@type": "PartyAccountRef",
      "@referredType": null
    },
    "product": [
      {
        "id": "0.0.0.1+-service-telco-gsm-telephony+143030",
        "href": null,
        "name": "ServiceTelcoGsmTelephony",
        "@baseType": "ProductRef",
        "@schemaLocation": null,
        "@type": "ProductRef",
        "@referredType": null
      }
    ],
    "totalBalance": {
      "amount": 176.21,
      "units": "USD",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": "Quantity"
    }
  }
]

Get Accumulated Balances by External Account ID

The following example filters by the account's external ID. External ID searches require the custom mapper flag described in the release changes.

curl -X GET 'http://host:port/brm/prepayBalanceManagement/version/accumulatedBalance?@type=AccumulatedBalance&partyAccount.id=test_account_140598'

Response Body

[
  {
    "id": "0.0.0.1+-account+140598+840",
    "href": "http://host:port/brm/prepayBalanceManagement/version/accumulatedBalance/0.0.0.1+-account+140598+840",
    "description": "",
    "name": "Venkateswari Moorthy",
    "bucket": [
      {
        "id": "0.0.0.1+-balance_group+141494+840+0",
        "href": "http://host:port/brm/prepayBalanceManagement/version/bucket/0.0.0.1+-balance_group+141494+840+0",
        "name": "Balance Group<Account>",
        "@baseType": "BucketRef",
        "@schemaLocation": null,
        "@type": "BucketRef",
        "@referredType": null
      }
    ],
    "logicalResource": {
      "@baseType": "LogicalResourceRef",
      "@referredType": null,
      "@schemaLocation": null,
      "@type": "LogicalResourceRef",
      "href": null,
      "id": null,
      "name": null,
      "value": "472-20260410-072856-0-245742-906351744-cagbu-phx-1038"
    },
    "partyAccount": {
      "id": "test_account_140598",
      "href": null,
      "description": null,
      "name": "Venkateswari Moorthy",
      "status": "active",
      "@baseType": "PartyAccountRef",
      "@schemaLocation": null,
      "@type": "PartyAccountRef",
      "@referredType": null
    },
    "product": [
      {
        "id": "0.0.0.1+-service-telco-gsm-telephony+143030",
        "href": null,
        "name": "ServiceTelcoGsmTelephony",
        "@baseType": "ProductRef",
        "@schemaLocation": null,
        "@type": "ProductRef",
        "@referredType": null
      }
    ],
    "relatedParty": [],
    "totalBalance": {
      "amount": 176.21,
      "units": "USD",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": "Quantity"
    },
    "@baseType": "AccumulatedBalance",
    "@schemaLocation": "",
    "@type": "AccumulatedBalance"
  }
]

Get Accumulated Balances by Bill Structure ID

The following example filters by billStructure.id. The response includes billStructure and sets billingCycleSpecification to null.

curl -X GET 'http://host:port/brm/prepayBalanceManagement/version/accumulatedBalance?@type=AccumulatedBalanceOracle&billStructure.id=test_bill_structure_174268'

Response Body

[
  {
    "id": "0.0.0.1+-account+173981+840",
    "href": "http://host:port/brm/prepayBalanceManagement/version/accumulatedBalance/0.0.0.1+-account+173981+840",
    "description": "",
    "name": "Rachel Douglas",
    "bucket": [
      {
        "id": "0.0.0.1+-balance_group+175837+840+0",
        "href": "http://host:port/brm/prepayBalanceManagement/version/bucket/0.0.0.1+-balance_group+175837+840+0",
        "name": "",
        "@baseType": "BucketRef",
        "@schemaLocation": null,
        "@type": "BucketRef",
        "@referredType": null
      }
    ],
    "logicalResource": {
      "@baseType": "LogicalResourceRef",
      "@referredType": null,
      "@schemaLocation": null,
      "@type": "LogicalResourceRef",
      "href": null,
      "id": null,
      "name": null,
      "value": ""
    },
    "partyAccount": {
      "id": "0.0.0.1+-account+173981",
      "href": null,
      "description": null,
      "name": "Rachel Douglas",
      "status": "active",
      "@baseType": "PartyAccountRef",
      "@schemaLocation": null,
      "@type": "PartyAccountRef",
      "@referredType": null
    },
    "product": [
      {
        "id": "0.0.0.1+-service-telco-gsm-telephony+247218",
        "href": null,
        "name": "ServiceTelcoGsmTelephony",
        "@baseType": "ProductRef",
        "@schemaLocation": null,
        "@type": "ProductRef",
        "@referredType": null
      }
    ],
    "relatedParty": [],
    "totalBalance": {
      "amount": 270.0,
      "units": "USD",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": "Quantity"
    },
    "@baseType": "AccumulatedBalance",
    "@schemaLocation": "",
    "@type": "AccumulatedBalanceOracle",
    "billingCycleSpecification": null,
    "billStructure": {
      "id": "test_bill_structure_174268",
      "href": "http://host:port/brm/accountManagement/v5/billingAccount?billStructure.id=test_bill_structure_174268",
      "name": "Default BillStructure"
    },
    "unbilledBalance": {
      "amount": 270.0,
      "units": "USD",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": "Quantity"
    },
    "originalBalance": {
      "amount": null,
      "units": null,
      "@baseType": null,
      "@schemaLocation": null,
      "@type": "Quantity"
    }
  }
]

Get Accumulated Balances by Service Alias

The following example shows the request and response for this filter.

curl -X GET 'http://host:port/brm/prepayBalanceManagement/version/accumulatedBalance?@type=AccumulatedBalanceOracle&product.id=aliasIMEIBase_0010'

Response Body

[
  {
    "id": "0.0.0.1+-account+173981+840",
    "href": "http://host:port/brm/prepayBalanceManagement/version/accumulatedBalance/0.0.0.1+-account+173981+840",
    "description": "",
    "name": "Rachel Douglas",
    "bucket": [
      {
        "id": "0.0.0.1+-balance_group+175837+840+0",
        "href": "http://host:port/brm/prepayBalanceManagement/version/bucket/0.0.0.1+-balance_group+175837+840+0",
        "name": "",
        "@baseType": "BucketRef",
        "@schemaLocation": null,
        "@type": "BucketRef",
        "@referredType": null
      }
    ],
    "logicalResource": {
      "@baseType": "LogicalResourceRef",
      "@referredType": null,
      "@schemaLocation": null,
      "@type": "LogicalResourceRef",
      "href": null,
      "id": null,
      "name": null,
      "value": ""
    },
    "partyAccount": {
      "id": "0.0.0.1+-account+173981",
      "href": null,
      "description": null,
      "name": "Rachel Douglas",
      "status": "active",
      "@baseType": "PartyAccountRef",
      "@schemaLocation": null,
      "@type": "PartyAccountRef",
      "@referredType": null
    },
    "product": [
      {
        "id": "aliasIMEIBase_0010",
        "href": null,
        "name": "ServiceTelcoGsmTelephony",
        "@baseType": "ProductRef",
        "@schemaLocation": null,
        "@type": "ProductRef",
        "@referredType": null
      }
    ],
    "relatedParty": [],
    "totalBalance": {
      "amount": 260.0,
      "units": "USD",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": "Quantity"
    },
    "@baseType": "AccumulatedBalance",
    "@schemaLocation": "",
    "@type": "AccumulatedBalanceOracle",
    "billingCycleSpecification": [
      {
        "id": "0.0.0.1+-billinfo+174685",
        "href": "http://host:port/brm/accountManagement/v4/billingCycleSpecification/0.0.0.1+-billinfo+174685",
        "name": null
      }
    ],
    "unbilledBalance": {
      "amount": 260.0,
      "units": "USD",
      "@baseType": null,
      "@schemaLocation": null,
      "@type": "Quantity"
    },
    "originalBalance": {
      "amount": null,
      "units": null,
      "@baseType": null,
      "@schemaLocation": null,
      "@type": "Quantity"
    }
  }
]
Back to Top