v56

latestOpenAPI 3.0.0raw.githubusercontent.com2026-08-014121451.1 MB
Policies

Publish policy version

Publishes a draft policy version, making it the active/current version of the policy. Pass the versionId of the draft you want to publish — for example one created via create-policy-version and then edited.

post/v1/policies/{id}/versions/publish

Path parameters

idstring required
Example:pol_abc123def456

Policy ID

Headers

X-Organization-Idstring

Organization ID (required for session auth, optional for API key auth)

Request body

versionIdstring

Version ID to publish. PASS THIS after update-version to publish your edits — omitting it publishes stale draftContent (loses your changes).

setAsActiveboolean

Whether to set this version as the active version

changelogstring

Optional changelog to associate with the published version

Example request

{
  "versionId": "pv_abc123def456",
  "setAsActive": true,
  "changelog": "Updated access controls section"
}

Response

Version published

versionIdstring
versionnumber