All the usage data will be returned for the accounts under the organization. The data is aggregated by month for each product. A 403 error is returned if the specified accounts are not under the organization performing the call. The results are paged.
If you're a reseller, please check how to get entitled to this API here.
Scope
express-accounts-usage:read
Body Response - Schema
200 OK
| Parameter | Type | Description |
|---|---|---|
| first | object | "first" subdivides into: 1 - "href" (string) - The link to the first page. |
| last | object | "last" subdivides into: 1 - "href" (string) - The link to the last page. |
| next | object | "next" subdivides into: 1 - "href" (string) - The link to the next page. |
| prev | object | "prev" subdivides into: 1 - "href" (string) - The link to the previous page. |
| self | object | "self" subdivides into: 1 - "href" (string) - The link to the current page. |
| show | object | "show" subdivides into: 1 - "href" (string) - The current link. |
| _embedded | object | "_embedded" subdivides into: 1 - "usage" (array[object]). 1.2 - "account ID"(string) - The ID of the account. 1.3 - "product_id"(string) - The ID of the product. 1.4 - "aggr_product_id"(string) - Aggregated product ID. 1.5 - month"(string) - The year and month of the usage aggregate. 1.6 - "type"(string) - The type of usage. Allowed values: Example: 1.7 - "description"(string) - A description of the usage type. 1.8 - "currency (string) - The 3 chars ISO code of the currency for the invoice according to ISO-4217 (https://www.iso.org/iso-4217-currency-codes.html ). 1.9 - "direction"(string) - The direction of the interaction, when applicable, NULL otherwise. Allowed values: Example: 1.10 - "resolution"(string) - The type of interaction resolution or NULL if not applicable. Example: 1.11 - "unit"(string) - The unit of measure. Allowed values: Example: 1.12 - price"(number<double>) - The price of each unit. 1.13 - "wallet_name (string) 1.14 - "number_of_units"(number<double>) - The number of units in the aggregate. 1.15 - "total_amount"(number<double>) - The total amount in the usage aggregate in the currency specified in the currency field. |
| _links | object | "_links" subdivides into: 1 - "first" (object)
5 - "self" (object) |
400 (bad request), 401 (unauthorized), 403 (This caller is not authorized to query the given accounts. The accounts specified are not under the organization owning the current authentication token.)
| Parameter | Type | Description | Required |
|---|---|---|---|
| code | string | n/a | yes |
| message | string | n/a | yes |
| description | string | n/a | no |
| fields | array[object] | "fields" subdivides into: "name" (string) "description" (string) | yes (name and description) |
API AvailabilityThe Billing Insights API becomes available on January 31st, 2024.
TroubleshootingIf you have any questions regarding the usage of this API, or if you’re having any technical issues, please open a ticket using this form.