Skip to content

Get the organization billing dashboard

GET
/v2/organizations/{org_id}/billing
curl --request GET \
--url https://api.runta.com/v2/organizations/example/billing \
--header 'Authorization: Bearer <token>'
org_id
required
string

Stable Portal organization UUID.

Response envelope.

Media typeapplication/json
object
data
required
object
credit_balance
required
One of: discriminator: freshness
object
freshness
required
string
Allowed values: fresh
amount_minor
required
integer format: int64
as_of_unix_seconds
required
integer format: int64
rated_cost
required
One of: discriminator: freshness
object
freshness
required
string
Allowed values: fresh
amount_minor
required
integer format: int64
as_of_unix_seconds
required
integer format: int64
quantities
required
Array<object>
object
metric
required
string
quantity_decimal
required
string
billing_revision
required
integer format: uint64
Example
{
"data": {
"credit_balance": {
"freshness": "fresh"
},
"rated_cost": {
"freshness": "fresh"
}
}
}

Missing, malformed, or rejected bearer token

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}

The bearer token is not allowed to perform this action

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}

The requested resource was not found

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}

The request conflicts with current resource state

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}

Validation or application error

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}

Rate limit exceeded

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}

Operation is not implemented

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}

Upstream service is unavailable

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}

Upstream request timed out

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}

Error response

Media typeapplication/json
object
error
required
object
authorization_reason

Authorization refusal reason. Only required_scope_missing permits an OAuth scope challenge.

string
code
required
string
Allowed values: already_exists command_failed deadline_exceeded failed_precondition FEATURE_TEMPORARILY_DISABLED internal invalid_argument not_found permission_denied tenant_blocked rate_limited unauthenticated unavailable unimplemented
message
required
string
request_id
required

UUID v7 correlation ID shared with the X-Request-Id response header.

string
Example
{
"error": {
"code": "already_exists"
}
}