Get workspace usage
Return today's workspace cost, daily limit, and remaining allowance.
Endpoint
GET
/api/v1/workspaces/{workspace_id}/usageAuthentication
| Operation class | Authentication | Minimum role | API key |
|---|---|---|---|
| dashboard-session-api | Dashboard session cookie; mutations also require X-CX-Request: 1. | admin | Not allowed |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
workspace_id | path | string | Yes | — |
Request body
This operation has no request body.
Example
curl --request GET 'https://operade.ai/api/v1/workspaces/ws_demo/usage' \ --cookie 'cx_session=YOUR_SESSION_COOKIE'
Responses
| Status | Description | Content |
|---|---|---|
4XX | Handled client error | application/json: ErrorResponse |
200 | Successful Response | application/json: WorkspaceUsageResponse |
4XX application/json response schema
| Field path | Type | Reference | Format | Nullable | Required | Enum | Description |
|---|---|---|---|---|---|---|---|
$ | object | ErrorResponse | — | No | Yes | — | — |
error | object | ErrorItem | — | No | Yes | — | — |
error.code | string | — | — | No | Yes | — | — |
error.details | object | — | — | No | No | — | — |
error.message | string | — | — | No | Yes | — | — |
200 application/json response schema
| Field path | Type | Reference | Format | Nullable | Required | Enum | Description |
|---|---|---|---|---|---|---|---|
$ | object | WorkspaceUsageResponse | — | No | Yes | — | — |
cost_usd_today | string | — | — | No | Yes | — | — |
daily_cost_limit_usd | string | — | — | No | Yes | — | — |
remaining_usd | string | — | — | No | Yes | — | — |
resets_at | string | — | date-time | No | Yes | — | — |
Response example
{
"cost_usd_today": "string",
"daily_cost_limit_usd": "string",
"remaining_usd": "string",
"resets_at": "2026-01-01T00:00:00Z"
}Errors
Reviewed common and route-declared errors are summarized here; the list is not exhaustive. Start with the distributed error index to find each code's canonical domain page.
| Status | Code | Description |
|---|---|---|
401 | unauthenticated | Authentication is missing, invalid, or revoked. |
403 | forbidden | The authenticated caller does not have access to this operation. |
404 | not_found | The requested workspace resource was not found. |
