Skip to content

Set or clear the paid overage limit (OWNER only)

PATCH
/organizations/current/overage-limit
curl --request PATCH \
--url https://api.invogi.com/v1/organizations/current/overage-limit \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "limit_units": 1 }'

By default a paid plan’s overage is automatic: invoices above the included volume keep being analyzed and are billed after the period closes. Set limit_units to cap it at that many invoice units above the included volume per billing period (annual plans use the pooled annual period); 0 never goes over the included volume. Once the limit is reached, new invoices are refused with USAGE_LIMIT_EXCEEDED (429) until an owner raises it or the period renews. null removes the limit.

Media typeapplication/json
object
limit_units
required
integer | null
<= 1000000

Example generated

{
"limit_units": 1
}

Setting updated and audit event recorded

Media typeapplication/json
object
overage_limit_units
required
integer | null

Example generated

{
"overage_limit_units": 1
}

Invalid request

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: NOT_FOUND UNAUTHORIZED FORBIDDEN INVALID_REQUEST CONFLICT RATE_LIMITED USAGE_LIMIT_EXCEEDED PROCESSING_FAILED
message
required
string
request_id
required
string

Example

{
"error": {
"code": "NOT_FOUND"
}
}

Missing or invalid API key

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: NOT_FOUND UNAUTHORIZED FORBIDDEN INVALID_REQUEST CONFLICT RATE_LIMITED USAGE_LIMIT_EXCEEDED PROCESSING_FAILED
message
required
string
request_id
required
string

Example

{
"error": {
"code": "NOT_FOUND"
}
}

API key lacks required scope/role

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: NOT_FOUND UNAUTHORIZED FORBIDDEN INVALID_REQUEST CONFLICT RATE_LIMITED USAGE_LIMIT_EXCEEDED PROCESSING_FAILED
message
required
string
request_id
required
string

Example

{
"error": {
"code": "NOT_FOUND"
}
}