Skip to the documentation
API

Read pay as you go

Whether usage past the allowances is billed, and what it costs so far.

GET/billing/pay-as-you-go

Runs the real call on your workspace.

GET /billing/pay-as-you-go

Whether usage past the allowances is billed, and what it costs so far.

Example

Needs billing:read. Amounts are in US cents. limits are the monthly limits that can be chosen, prices what extras cost, and period the current billing period of pay as you go, null until it is set up.

curl
curl "$OE/billing/pay-as-you-go" -H "$AUTH"
Response
{  "object": "pay_as_you_go",  "available": true,  "enabled": true,  "suspended": false,  "enrolled": true,  "switchedOn": true,  "coversSends": true,  "coversAiActions": true,  "limitCents": 5000,  "spentCents": 120,  "extraSends": 3000,  "extraAiActions": 0,  "estimatedCents": 120,  "limits": [1000, 2500, 5000, 10000, 25000, 50000, 100000, 250000, 500000],  "prices": {    "sends": { "unit": 1000, "priceCents": 40 },    "aiActions": { "unit": 100, "priceCents": 25 }  },  "period": {    "endsAt": "2026-11-01T09:00:00.000Z",    "sends": 3000,    "aiActions": 0,    "estimatedCents": 120  }}

enabled is true while extras are billed: switched on and not paused. suspended means the last payment failed, and the card is updated on the billing portal.

Only the owner of the workspace reaches billing: an API key, or an access token the owner connected with every address. A member’s token is a 403 owner_only, and a key or token limited to particular addresses or domains is a 422 capability_unsupported.

Reference