v48

latestOpenAPI 3.1.0raw.githubusercontent.com2026-05-275867561.6 MB
gateway-policies

List gateway policies

Returns every gateway policy in the current organization. The response includes both admin-created policies and runtime-materialized children of default_spend_cap policies (children carry parent_policy_id).

Spend tracking: each spend-cap policy carries current_spend_usd — the spend accumulated in the policy's active window.

get/v1/platform/gateway-policies

Response

OK

actionstring
configobject
created_atstring
created_bystring
current_spend_usdnumber

CurrentSpendUSD is the spend in the policy's current window. Set for any spend_cap policy regardless of enabled state — disabled policies still surface usage so users can see what would have been counted. Nil for non-spend_cap policies or when the spend lookup failed.

descriptionstring
enabledboolean
idstring
is_system_generatedboolean
namestring
organization_idstring
parent_policy_idstring

ParentPolicyID is set on materialized children of a default_spend_cap to the default's id, and cleared (NULL) only when an admin Create with the same matchers takes over the materialized row. Update on a child preserves the link; Delete on the parent cascade-soft-deletes every child rather than detaching them.

policy_typestring
priorityinteger
updated_atstring