Skip to main content
POST
/
v1
/
policies
/
{id}
/
versions
/
publish
Publish new policy version
curl --request POST \
  --url http://localhost:3333/v1/policies/{id}/versions/publish \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "setAsActive": true,
  "changelog": "Updated access controls section"
}
'
{
  "versionId": "<string>",
  "version": 123
}

Authorizations

X-API-Key
string
header
required

API key for authentication

Path Parameters

id
string
required

Policy ID

Example:

"pol_abc123def456"

Body

application/json

Publish a new policy version

setAsActive
boolean

Whether to set this version as the active version

Example:

true

changelog
string

Optional changelog to associate with the published version

Example:

"Updated access controls section"

Response

Version published

versionId
string
version
number