Skip to content

Get usage for the authenticated account's organization (new billing model).

GET
/organization/usage
curl --request GET \
--url https://api.pingram.io/organization/usage \
--header 'Authorization: Bearer <token>'

Successful response

Media type application/json

Response for GET /account/organization/usage

object
messageUsage
required

Total message usage (EMAIL + INAPP_WEB + WEB_PUSH + PUSH + SLACK)

number
budgetUsage
required

Total budget usage in USD (cost_SMS + cost_CALL + cost_NUMBER)

number
costSms
required

SMS cost in USD

number
costCall
required

Call cost in USD

number
costNumber
required

Phone number rent in USD

number
channelUsages
required

Per-channel usage breakdown

object
key
additional properties
number
billingCycleStart
required

Billing cycle start date (ISO string)

string
billingCycleEnd
required

Billing cycle end date (ISO string)

string
Example generated
{
"messageUsage": 1,
"budgetUsage": 1,
"costSms": 1,
"costCall": 1,
"costNumber": 1,
"channelUsages": {
"additionalProperty": 1
},
"billingCycleStart": "example",
"billingCycleEnd": "example"
}

Bad Request - validation errors, invalid input

Media type application/json

Standard error response for API errors.

object
trackingId
required

Unique tracking ID for the request.

string
error
required

Structured error details for API error responses.

object
code
required

Machine-readable error code.

string
message
required

Human-readable error message.

string
fix

Actionable hint for fixing the error.

string
Example generated
{
"trackingId": "example",
"error": {
"code": "example",
"message": "example",
"fix": "example"
}
}

Unauthorized

Payment Required - usage limits exceeded

Media type application/json

Standard error response for API errors.

object
trackingId
required

Unique tracking ID for the request.

string
error
required

Structured error details for API error responses.

object
code
required

Machine-readable error code.

string
message
required

Human-readable error message.

string
fix

Actionable hint for fixing the error.

string
Example generated
{
"trackingId": "example",
"error": {
"code": "example",
"message": "example",
"fix": "example"
}
}

Internal Server Error

Bad Gateway - provider error

Media type application/json

Standard error response for API errors.

object
trackingId
required

Unique tracking ID for the request.

string
error
required

Structured error details for API error responses.

object
code
required

Machine-readable error code.

string
message
required

Human-readable error message.

string
fix

Actionable hint for fixing the error.

string
Example generated
{
"trackingId": "example",
"error": {
"code": "example",
"message": "example",
"fix": "example"
}
}