Billing & Usage

Manage billing and usage.

Find every run operation under Runs: lifecycle, events, input requests, children, the runs that triggers start, and the runtime callbacks workers use. Configure schedules and webhooks to trigger runs automatically.

Assign access through account and project roles. Private resources may require additional permissions.

Inspect usage by account, project, member, or API key. Use budgets to cap monthly AI spend.

Subscriptions · Billing · Credits · Feature gates · Budgets · Usage · Analytics

Subscriptions

Read usage, activity and financial records owned by the selected account.

Read owner-wide collaboration entitlements and seat usage. The project reference selects its owner; can_invite does not grant requester invitation permission.

EndpointMethodsDescription
/accounts/{account_id}/subscriptionGET, PATCHGet subscription; Update subscription
/accounts/{account_id}/subscription/cancelPOSTCancel subscription
/accounts/{account_id}/billing-portal-sessionsPOSTCreate billing portal session
/projects/{project_reference}/collaborationGETGet available seats

Billing

Read usage, activity and financial records owned by the selected account.

EndpointMethodsDescription
/accounts/{account_id}/billing-detailsGET, PATCHGet billing details; Update billing details
/accounts/{account_id}/invoicesGETList invoices
/accounts/{account_id}/paymentsGETList payments
/accounts/{account_id}/payment-methodsGETList payment methods

Credits

Read usage, activity and financial records owned by the selected account.

EndpointMethodsDescription
/accounts/{account_id}/credits/balanceGETGet credit balance
/accounts/{account_id}/credits/transactionsGETList credit transactions
/accounts/{account_id}/credits/packagesGETList credit packages
/accounts/{account_id}/credits/checkoutsPOSTCreate credit checkout
/accounts/{account_id}/credits/coupons/redeemPOSTRedeem credit coupon

Feature gates

Check access to a named plan or feature gate. Individual endpoints still enforce their resource permissions.

EndpointMethodsDescription
/feature-gates/{gate}GETCheck feature gate

Budgets

Set monthly AI spending caps by project, person, API key, or a combination of these fields. New budgets count spending already incurred that month; use PATCH /budgets/{budget_id} to change an existing cap.

EndpointMethodsDescription
/budgetsGET, POSTList budgets; Create budget
/budgets/{budget_id}GET, PATCH, DELETEGet budget; Update budget; Delete budget

Usage

Read usage, activity and financial records owned by the selected account.

Use member usage for project AI spend by person and automation. AI usage analytics adds daily project or member consumption and customer charges.

List usage across API keys or inspect one key. Manage the keys themselves through API key endpoints. Manage inference limits for project-bound keys.

EndpointMethodsDescription
/api-keys/usageGETList API key usage
/api-keys/{id}/limitsGET, PUT, DELETEGet API key inference limits; Replace API key inference limits; Clear API key inference limits
/api-keys/{id}/usageGETGet API key usage
/accounts/{account_id}/usageGETGet usage
/accounts/{account_id}/usage/seriesGETGet usage series
/accounts/{account_id}/usage/creditsGETGet credit usage
/projects/{project_reference}/analytics/ai-usageGETGet AI usage analytics
/projects/{project_reference}/members/usageGETGet member usage

Analytics

Start, list, inspect, cancel, and resume agent, task, and workflow runs, follow their events, answer their input requests, and find the runs that schedules, webhooks, and evaluations start.

Read usage, activity and financial records owned by the selected account.

EndpointMethodsDescription
/accounts/{account_id}/analytics/conversationsGETGet conversation analytics
/accounts/{account_id}/analytics/runsGETGet account run analytics
/account/analytics/runsGETGet run analytics

Back to REST API reference