Skip to main content
PATCH
Update policy

Authorizations

Authorization
string
header
required

MeshQu API key passed as a bearer token: Authorization: Bearer mqu_…. Mint one in the console (Settings → API keys).

X-MeshQu-Tenant-Id
string
header
required

Tenant UUID for multi-tenant isolation. Required on all authenticated routes — validated before authentication (middleware/tenant.ts), so a missing or non-UUID header returns 400 (MISSING_TENANT_ID / INVALID_TENANT_ID) before the API key is checked.

Path Parameters

id
string<uuid>
required

Body

application/json
name
string
Required string length: 1 - 200
description
string
Maximum string length: 2000
is_active
boolean
shadow_mode
boolean

When true, violations are logged but DENY becomes ALERT. Enables A/B testing.

policy_group_id
string<uuid> | null

Assign to a policy group (null to remove from group)

regulatory_refs
string[] | null

Regulatory references (null to clear)

Maximum array length: 50
Maximum string length: 200

Response

Default Response

id
string<uuid>
required
tenant_id
string<uuid>
required
code
string
required
name
string
required
description
string | null
required
decision_type
string
required
current_version
integer
required
is_active
boolean
required
shadow_mode
boolean
required

When true, violations are logged but DENY becomes ALERT

policy_group_id
string<uuid> | null
required

Policy group this policy belongs to

created_at
string<date-time>
required
created_by
string | null
required
updated_at
string<date-time>
required
regulatory_refs
string[] | null

Regulatory references this policy implements

regulatory_refs_warnings
object[]

Warnings for regulatory_refs entries not found in the clause registry. Informational only — the save proceeded.

version
object
versionState

Lifecycle state of the selected version. "submitted" is reserved for PV2-020; today the server only emits active | draft | historical.

Available options:
active
selectedVersion
integer
permissions
object

Convenience permission flags. Clients MUST use actions[] as the source of truth for availability; permissions are for disable-state/tooltip hints only.

actions
object[]