Get Balance Actions

get

/balanceAction

Gets balance actions that match the query criteria.

Request

Query Parameters
  • The type of object to return. Can be one of the following: TransferBalance, TopupBalance, AdjustBalance, or AdjustBalanceOracle for an extended object.
    Example:
    TransferBalance
  • The list of comma-separated fields to return in the response.
    Example:
    impactedBucket,usageType
  • The maximum number of results to return. For example, use limit=10 to return the first 10 results only.
    Example:
    10
  • The number of results to offset the response by. For example, use offset=10 to return results 10 and higher.
    Example:
    10

There's no request body for this operation.

Back to Top

Response

Supported Media Types

200 Response

Success
Headers
Body ()
Root Schema : schema
Type: array
Show Source
Nested Schema : BalanceAction
Type: object
An abstract resource for an action, such as adjusting or topping up a balance.
Show Source
Nested Schema : Quantity
Type: object
An amount in a given unit.
Show Source
Nested Schema : Bucket Ref
Type: object
Title: Bucket Ref
A reference to a bucket.
Show Source
Nested Schema : Channel Ref
Type: object
Title: Channel Ref
A reference to a channel.
Show Source
Nested Schema : impactedBucket
Type: array
Buckets impacted by the request.
Show Source
Nested Schema : Logical Resource Ref
Type: object
Title: Logical Resource Ref
A reference to a logical resource.
Show Source
Nested Schema : Party Account Ref
Type: object
Title: Party Account Ref
A reference to a party account.
Show Source
Nested Schema : Product Ref
Type: object
Title: Product Ref
A reference to a product.
Show Source
Nested Schema : relatedParty
Type: array
Parties related to the action. to the operation
Show Source
Nested Schema : Related Party
Type: object
Title: Related Party
A party related to another object.
Show Source
Nested Schema : ImpactedBucket
Type: object
A bucket impacted by a balance top-up, adjustment, transfer, or reservation.
Show Source
Nested Schema : item
Type: array
Minimum Number of Items: 1
The impacted bucket items.
Show Source
Nested Schema : ImpactedBucketItem
Type: object
An impact item that affects an ImpactedBucket object.
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 get balance actions by submitting a GET request on the REST resource using cURL. For more information about cURL, see Use cURL.

The request uses query parameters to show two balance adjustments. You can use different values for the @type parameter to show different types of action, such as balance transfers or top-ups.

curl -X GET 'http://host:port/brm/prepayBalanceManagement/version/balanceAction?@type=AdjustBalance&limit=2'

Example of the Response Body

The following example shows the contents of the response body in JSON format.

[
    {
        "id": "0.0.0.1+-item-adjustment+54349",
        "href": "http://host:port/brm/prepayBalanceManagement/v4/adjustBalance/0.0.0.1+-item-adjustment+54349",
        "confirmationDate": "2021-02-05T11:59:08+05:30",
        "description": "",
        "reason": "0",
        "requestedDate": "2021-02-05T11:59:08+05:30",
        "adjustType": null,
        "amount": {
            "amount": 2.0,
            "units": "USD",
            "@baseType": null,
            "@schemaLocation": null,
            "@type": null
        },
        "bucket": null,
        "channel": null,
        "logicalResource": null,
        "partyAccount": {
            "id": "0.0.0.1+-account+57645",
            "href": null,
            "description": null,
            "name": "John Doe",
            "status": "active",
            "@baseType": null,
            "@schemaLocation": null,
            "@type": null,
            "@referredType": null
        },
        "product": null,
        "relatedParty": null,
        "requestor": {
            "id": null,
            "href": null,
            "name": "brm-rest-services-manager",
            "role": null,
            "@baseType": null,
            "@schemaLocation": null,
            "@type": null,
            "@referredType": null
        },
        "status": "CREATED",
        "usageType": "MONETARY",
        "validFor": null,
        "@baseType": "AdjustBalance",
        "@schemaLocation": null,
        "@type": "AdjustBalance"
    },
    {
        "id": "0.0.0.1+-item-adjustment+56717",
        "href": "http://host:port/brm/prepayBalanceManagement/v4/adjustBalance/0.0.0.1+-item-adjustment+56717",
        "confirmationDate": "2021-02-05T11:52:35+05:30",
        "description": "",
        "reason": "0",
        "requestedDate": "2021-02-05T11:52:35+05:30",
        "adjustType": null,
        "amount": {
            "amount": 2.0,
            "units": "USD",
            "@baseType": null,
            "@schemaLocation": null,
            "@type": null
        },
        "bucket": null,
        "channel": null,
        "logicalResource": null,
        "partyAccount": {
            "id": "0.0.0.1+-account+57645",
            "href": null,
            "description": null,
            "name": "John Doe",
            "status": "active",
            "@baseType": null,
            "@schemaLocation": null,
            "@type": null,
            "@referredType": null
        },
        "product": null,
        "relatedParty": null,
        "requestor": {
            "id": null,
            "href": null,
            "name": "brm-rest-services-manager",
            "role": null,
            "@baseType": null,
            "@schemaLocation": null,
            "@type": null,
            "@referredType": null
        },
        "status": "CREATED",
        "usageType": "MONETARY",
        "validFor": null,
        "@baseType": "AdjustBalance",
        "@schemaLocation": null,
        "@type": "AdjustBalance"
    }
]
Back to Top