Skip to main content
POST
Create Policy

Authorizations

Authorization
string
header
required

A control-plane management key using the sk-cp- prefix. Inference keys are not accepted by control-plane endpoints.

Path Parameters

workspace_ref
string
required

Workspace ID or slug

org_id
string
required

Organization ID or slug

Body

application/json
name
string
required

Display name for the workspace policy

Required string length: 1 - 200
definition
PolicyDefinition · object
required

Workspace, user, or inference key target and inline rules

enabled
boolean
default:true

Whether gateways apply this policy after receiving the updated configuration

Response

Successful Response

data
PolicyOut · object
required