Get Budgets and Access Policy
/v1/workspaces/{workspace_id}/guardrailsOverview
Daily, weekly and monthly budgets with this period's spend and when each period resets, and the access policy. Any member's dashboard session can read them. Periods are UTC calendar days, weeks starting Monday, and months.
Parameters
workspace_idpath · stringRequiredWorkspace id.
Responses
200Budgets, spend and access policy.
workspace_idstringRequiredbudgetsobjectRequiredSpend limits in USD per UTC calendar period. null means no limit.
Show nested fields
dailynumber | nullRequiredMinimum 0
weeklynumber | nullRequiredWeeks start on Monday.
Minimum 0
monthlynumber | nullRequiredMinimum 0
usageobjectRequiredUSD spent in the current UTC day, week and month, and in total, including holds for requests in progress. Spend counts in the period its request started.
Show nested fields
dailynumberRequiredweeklynumberRequiredmonthlynumberRequiredtotalnumberRequiredresets_atobjectRequiredWhen the current day, week and month end, in UTC.
Show nested fields
dailystringRequiredweeklystringRequiredmonthlystringRequiredaccess_policyobject | nullRequiredShow nested fields
Option 1: object
allowed_modelsstring[]Show nested fields
See the OpenAPI schema for this nested object.
blocked_modelsstring[]Show nested fields
See the OpenAPI schema for this nested object.
allowed_providersstring[]Show nested fields
See the OpenAPI schema for this nested object.
blocked_providersstring[]Show nested fields
See the OpenAPI schema for this nested object.
allowed_productsstring[]Show nested fields
See the OpenAPI schema for this nested object.
blocked_productsstring[]Show nested fields
See the OpenAPI schema for this nested object.
Option 2: null
null
401Authentication is missing or invalid.
errorobjectRequiredShow nested fields
codestringRequiredmessagestringRequiredparamstring | nullrequest_idstring | nullmetadataobjectTyped detail for some refusals. budget_exceeded (402): limit (key_budget or workspace_budget) and budget with scope, period, limit, usage and resets_at. key_limit_exceeded (402): limit key_spend_limit. access_denied (403): policy (workspace or key), rule (models, providers or products), product, provider and model.
403Authenticated principal lacks permission.
errorobjectRequiredShow nested fields
codestringRequiredmessagestringRequiredparamstring | nullrequest_idstring | nullmetadataobjectTyped detail for some refusals. budget_exceeded (402): limit (key_budget or workspace_budget) and budget with scope, period, limit, usage and resets_at. key_limit_exceeded (402): limit key_spend_limit. access_denied (403): policy (workspace or key), rule (models, providers or products), product, provider and model.