Policies

Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

List compliance policies

GET/v1/policies

Lists active compliance policies for SOC 2, ISO 27001, HIPAA, and GDPR programs by default. Use includeArchived=true to include archived rows and excludeContent=true when you only need policy metadata.

Query parameters

excludeContentboolean

When true, omits `content` and `draftContent` from each policy in the response. Use this when listing policies to find one by name/ID — fetch the full content via GET /v1/policies/{id} after.

includeArchivedboolean

When true, includes user-archived and framework-sync-archived policies in the response. Defaults to false.

Header parameters

X-Organization-Idstring

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

Responses

200Policies retrieved successfully
dataobject[]required

Array of policies

Show child attributes
idstringrequired

The policy ID

namestringrequired

Name of the policy

descriptionstringrequired

Description of the policy

statusenumrequired

Status of the policy

One of: draft published needs_review

contentobject[]required

Content of the policy as TipTap JSON (array of nodes)

frequencyenumrequired

Review frequency of the policy

One of: monthly quarterly yearly

departmentstringrequired

Department this policy applies to. May be one of the built-in values (none, admin, gov, hr, it, itsm, qms) or a custom department name.

isRequiredToSignbooleanrequired

Whether this policy requires a signature

signedBystring[]required

List of user IDs who have signed this policy

reviewDatestringrequired

Review date for the policy

isArchivedbooleanrequired

Whether this policy is archived

archivedAtstringrequired

When the policy was archived by framework sync

createdAtstringrequired

When the policy was created

updatedAtstringrequired

When the policy was last updated

lastArchivedAtstringrequired

When the policy was last archived

lastPublishedAtstringrequired

When the policy was last published

organizationIdstringrequired

Organization ID this policy belongs to

assigneeIdstringrequired

ID of the user assigned to this policy

approverIdstringrequired

ID of the user who approved this policy

policyTemplateIdstringrequired

ID of the policy template this policy is based on

authTypeenumrequired

How the request was authenticated

One of: api-key session

authenticatedUserobject

Authenticated user information (only present for session auth)

Show child attributes
idstring

User ID

emailstring

User email

{
  "data": [
    {
      "id": "pol_abc123def456",
      "name": "Data Privacy Policy",
      "description": "This policy outlines how we handle and protect personal data",
      "status": "draft",
      "content": [
        {
          "type": "heading",
          "attrs": {
            "level": 2,
            "textAlign": null
          },
          "content": [
            {
              "type": "text",
              "text": "Purpose"
            }
          ]
        },
        {
          "type": "paragraph",
          "attrs": {
            "textAlign": null
          },
          "content": [
            {
              "type": "text",
              "text": "Verify workforce integrity and grant the right access at start, revoke at end."
            }
          ]
        }
      ],
      "frequency": "yearly",
      "department": "it",
      "isRequiredToSign": true,
      "signedBy": [
        "usr_123",
        "usr_456"
      ],
      "reviewDate": "2024-12-31T00:00:00.000Z",
      "isArchived": false,
      "archivedAt": "2024-02-01T00:00:00.000Z",
      "createdAt": "2024-01-01T00:00:00.000Z",
      "updatedAt": "2024-01-15T00:00:00.000Z",
      "lastArchivedAt": "2024-02-01T00:00:00.000Z",
      "lastPublishedAt": "2024-01-10T00:00:00.000Z",
      "organizationId": "org_abc123def456",
      "assigneeId": "usr_abc123def456",
      "approverId": "usr_xyz789abc123",
      "policyTemplateId": "plt_template123"
    }
  ],
  "authType": "api-key",
  "authenticatedUser": {
    "id": "usr_abc123def456",
    "email": "user@company.com"
  }
}
401Unauthorized - Invalid authentication or insufficient permissions
messagestring
{
  "message": "Unauthorized"
}
curl --request GET \
  --url https://api.complianz.ai/v1/policies \
  --header 'X-API-Key: <api-key>'

Create compliance policy

POST/v1/policies

Create a policy record that can be reviewed, versioned, published, linked to controls, and used as source evidence for questionnaires.

Header parameters

X-Organization-Idstring

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

Request body

namestringrequired

Name of the policy

descriptionstring

Description of the policy

statusenum

Status of the policy

One of: draft published needs_review

contentobject[]required

Content of the policy as TipTap JSON (array of nodes)

frequencyenum

Review frequency of the policy

One of: monthly quarterly yearly

departmentstring

Department this policy applies to. Built-in values: none, admin, gov, hr, it, itsm, qms. Custom department names are also accepted.

isRequiredToSignboolean

Whether this policy requires a signature

reviewDatestring

Review date for the policy

assigneeIdstring

ID of the user assigned to this policy

approverIdstring

ID of the user who approved this policy

policyTemplateIdstring

ID of the policy template this policy is based on

signedBystring[]

List of user IDs who have signed this policy

Responses

201Policy created successfully
idstringrequired

The policy ID

namestringrequired

Name of the policy

descriptionstringrequired

Description of the policy

statusenumrequired

Status of the policy

One of: draft published needs_review

contentobject[]required

Content of the policy as TipTap JSON (array of nodes)

frequencyenumrequired

Review frequency of the policy

One of: monthly quarterly yearly

departmentstringrequired

Department this policy applies to. May be one of the built-in values (none, admin, gov, hr, it, itsm, qms) or a custom department name.

isRequiredToSignbooleanrequired

Whether this policy requires a signature

signedBystring[]required

List of user IDs who have signed this policy

reviewDatestringrequired

Review date for the policy

isArchivedbooleanrequired

Whether this policy is archived

archivedAtstringrequired

When the policy was archived by framework sync

createdAtstringrequired

When the policy was created

updatedAtstringrequired

When the policy was last updated

lastArchivedAtstringrequired

When the policy was last archived

lastPublishedAtstringrequired

When the policy was last published

organizationIdstringrequired

Organization ID this policy belongs to

assigneeIdstringrequired

ID of the user assigned to this policy

approverIdstringrequired

ID of the user who approved this policy

policyTemplateIdstringrequired

ID of the policy template this policy is based on

{
  "id": "pol_abc123def456",
  "name": "Data Privacy Policy",
  "description": "This policy outlines how we handle and protect personal data",
  "status": "draft",
  "content": [
    {
      "type": "heading",
      "attrs": {
        "level": 2,
        "textAlign": null
      },
      "content": [
        {
          "type": "text",
          "text": "Purpose"
        }
      ]
    },
    {
      "type": "paragraph",
      "attrs": {
        "textAlign": null
      },
      "content": [
        {
          "type": "text",
          "text": "Verify workforce integrity and grant the right access at start, revoke at end."
        }
      ]
    }
  ],
  "frequency": "yearly",
  "department": "it",
  "isRequiredToSign": true,
  "signedBy": [
    "usr_123",
    "usr_456"
  ],
  "reviewDate": "2024-12-31T00:00:00.000Z",
  "isArchived": false,
  "archivedAt": "2024-02-01T00:00:00.000Z",
  "createdAt": "2024-01-01T00:00:00.000Z",
  "updatedAt": "2024-01-15T00:00:00.000Z",
  "lastArchivedAt": "2024-02-01T00:00:00.000Z",
  "lastPublishedAt": "2024-01-10T00:00:00.000Z",
  "organizationId": "org_abc123def456",
  "assigneeId": "usr_abc123def456",
  "approverId": "usr_xyz789abc123",
  "policyTemplateId": "plt_template123"
}
400Bad Request - Invalid policy data
messagestring
{
  "message": "Invalid policy content format"
}
401Unauthorized - Invalid authentication or insufficient permissions
messagestring
{
  "message": "Unauthorized"
}
curl --request POST \
  --url https://api.complianz.ai/v1/policies \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "name": "Data Privacy Policy",
    "description": "This policy outlines how we handle and protect personal data",
    "status": "draft",
    "content": [
      {
        "type": "heading",
        "attrs": {
          "level": 2,
          "textAlign": null
        },
        "content": [
          {
            "type": "text",
            "text": "Purpose"
          }
        ]
      },
      {
        "type": "paragraph",
        "attrs": {
          "textAlign": null
        },
        "content": [
          {
            "type": "text",
            "text": "Verify workforce integrity and grant the right access at start, revoke at end."
          }
        ]
      }
    ],
    "frequency": "yearly",
    "department": "it",
    "isRequiredToSign": true,
    "reviewDate": "2024-12-31T00:00:00.000Z",
    "assigneeId": "usr_abc123def456",
    "approverId": "usr_xyz789abc123",
    "policyTemplateId": "plt_template123",
    "signedBy": [
      "usr_123",
      "usr_456"
    ]
  }'

Publish all draft policies

POST/v1/policies/publish-all

Publish draft policies in bulk so approved policy content can power Trust Center sharing, questionnaire answers, and audit evidence.

Header parameters

X-Organization-Idstring

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

Responses

201
curl --request POST \
  --url https://api.complianz.ai/v1/policies/publish-all \
  --header 'X-API-Key: <api-key>'

Download all published policies

GET/v1/policies/download-all

Generate a single PDF bundle of published compliance policies for auditors, customer security reviews, and Trust Center workflows.

Header parameters

X-Organization-Idstring

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

Responses

200Signed URL for PDF bundle returned
404No published policies found
curl --request GET \
  --url https://api.complianz.ai/v1/policies/download-all \
  --header 'X-API-Key: <api-key>'

Get mapped and all controls for a policy

GET/v1/policies/{id}/controls

Get mapped and all controls for a policy in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Responses

200
curl --request GET \
  --url https://api.complianz.ai/v1/policies/<id>/controls \
  --header 'X-API-Key: <api-key>'

Map controls to a policy

POST/v1/policies/{id}/controls

Map controls to a policy in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Responses

201
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/controls \
  --header 'X-API-Key: <api-key>'

Get tasks that serve as evidence for a policy, grouped by control

GET/v1/policies/{id}/evidence-tasks

Get tasks that serve as evidence for a policy, grouped by control in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Responses

200
curl --request GET \
  --url https://api.complianz.ai/v1/policies/<id>/evidence-tasks \
  --header 'X-API-Key: <api-key>'

Regenerate policy with AI

POST/v1/policies/{id}/regenerate

Regenerate policy content using Complianz while keeping the result reviewable before it is published or used as compliance evidence.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Responses

201
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/regenerate \
  --header 'X-API-Key: <api-key>'

Get a signed URL for the policy PDF

GET/v1/policies/{id}/pdf/signed-url

Get a signed URL for the policy PDF in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

Query parameters

versionIdstring

Header parameters

X-Organization-Idstring

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

Responses

200
curl --request GET \
  --url https://api.complianz.ai/v1/policies/<id>/pdf/signed-url \
  --header 'X-API-Key: <api-key>'

Upload a PDF to a policy version (UI-only)

POST/v1/policies/{id}/pdf

Uploads a PDF via multipart `file` or base64 `fileData` JSON. Defaults to the latest draft if no `versionId`; 400 if no draft is available. UI-only — AI clients should use the presigned `/pdf/upload-url` + `/pdf/confirm` flow.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Request body

Responses

201
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/pdf \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "file": "string",
    "versionId": "string"
  }'

Delete a policy version PDF

DELETE/v1/policies/{id}/pdf

Deletes the PDF from a specific policy version. If no versionId is provided, deletes from the latest draft version. Cannot delete PDFs from published or pending-approval versions.

Path parameters

idstringrequired

Policy ID

Query parameters

versionIdstring

Target version ID. If omitted, targets the latest draft version.

Header parameters

X-Organization-Idstring

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

Responses

200
curl --request DELETE \
  --url https://api.complianz.ai/v1/policies/<id>/pdf \
  --header 'X-API-Key: <api-key>'

Request a presigned URL to upload a policy PDF

POST/v1/policies/{id}/pdf/upload-url

Generates a presigned S3 URL for uploading a policy PDF directly to storage. Use this when attaching a PDF to a compliance policy — the file bytes are uploaded straight to S3 without passing through the API. Requires the policy ID; if you only know the policy name, look it up first via the list-compliance-policies tool. After uploading the file to the returned URL, finalize the attachment by calling confirm-policy-pdf-uploaded with the same s3Key.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Request body

versionIdstring

Optional version ID to attach the PDF to. Omit to attach the PDF at the policy level (legacy path).

fileNamestringrequired

Filename of the PDF (e.g., "policy-v1.pdf"). Non-alphanumeric characters will be replaced with underscores when storing in S3.

fileTypestringrequired

MIME type of the file. Must be "application/pdf" — the presigned URL enforces this at upload time.

Responses

201
uploadUrlstringrequired

Presigned S3 URL. PUT the raw file bytes to this URL with header `Content-Type: application/pdf`. No auth headers required — the signature is in the URL.

s3Keystringrequired

The S3 key the file will land at. Pass this back to the confirm endpoint after a successful upload.

expiresInnumberrequired

Seconds until the presigned URL expires.

{
  "uploadUrl": "https://bucket.s3.us-east-1.amazonaws.com/org_xxx/policies/pol_xxx/...?X-Amz-Signature=...",
  "s3Key": "org_abc/policies/pol_xyz/1735000000-acceptable-use-v1.pdf",
  "expiresIn": 900
}
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/pdf/upload-url \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "versionId": "pv_abc123def456",
    "fileName": "acceptable-use-v1.pdf",
    "fileType": "application/pdf"
  }'

Confirm a policy PDF upload completed

POST/v1/policies/{id}/pdf/confirm

Links an uploaded PDF to a compliance policy after the file has been PUT to a presigned S3 URL. Call this after request-policy-pdf-upload-url returned an s3Key and you successfully uploaded the file bytes to that URL. The endpoint verifies the file exists in S3 before linking it to the policy or version.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Request body

s3Keystringrequired

The exact s3Key returned by the upload-url endpoint.

versionIdstring

Optional version ID — must match the versionId passed to the upload-url endpoint. Omit if attaching at the policy level.

Responses

201
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/pdf/confirm \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "s3Key": "org_abc/policies/pol_xyz/1735000000-acceptable-use-v1.pdf",
    "versionId": "pv_abc123def456"
  }'

Get signed URL for policy PDF (alternate path)

GET/v1/policies/{id}/pdf-url

Get signed URL for policy PDF (alternate path) in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

Query parameters

versionIdstring

Header parameters

X-Organization-Idstring

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

Responses

200
curl --request GET \
  --url https://api.complianz.ai/v1/policies/<id>/pdf-url \
  --header 'X-API-Key: <api-key>'

Remove a control mapping from a policy

DELETE/v1/policies/{id}/controls/{controlId}

Remove a control mapping from a policy in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

controlIdstringrequired

Header parameters

X-Organization-Idstring

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

Responses

200
curl --request DELETE \
  --url https://api.complianz.ai/v1/policies/<id>/controls/<controlId> \
  --header 'X-API-Key: <api-key>'

Get compliance policy

GET/v1/policies/{id}

Retrieve a single compliance policy by its ID, including current content, draft content, review status, framework links, and audit metadata. Use this to read or inspect one policy in detail. If you only have a policy name, find its ID first by listing compliance policies.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Responses

200Policy retrieved successfully
idstringrequired

The policy ID

namestringrequired

Name of the policy

descriptionstringrequired

Description of the policy

statusenumrequired

Status of the policy

One of: draft published needs_review

contentobject[]required

Content of the policy as TipTap JSON (array of nodes)

frequencyenumrequired

Review frequency of the policy

One of: monthly quarterly yearly

departmentstringrequired

Department this policy applies to. May be one of the built-in values (none, admin, gov, hr, it, itsm, qms) or a custom department name.

isRequiredToSignbooleanrequired

Whether this policy requires a signature

signedBystring[]required

List of user IDs who have signed this policy

reviewDatestringrequired

Review date for the policy

isArchivedbooleanrequired

Whether this policy is archived

archivedAtstringrequired

When the policy was archived by framework sync

createdAtstringrequired

When the policy was created

updatedAtstringrequired

When the policy was last updated

lastArchivedAtstringrequired

When the policy was last archived

lastPublishedAtstringrequired

When the policy was last published

organizationIdstringrequired

Organization ID this policy belongs to

assigneeIdstringrequired

ID of the user assigned to this policy

approverIdstringrequired

ID of the user who approved this policy

policyTemplateIdstringrequired

ID of the policy template this policy is based on

{
  "id": "pol_abc123def456",
  "name": "Data Privacy Policy",
  "description": "This policy outlines how we handle and protect personal data",
  "status": "draft",
  "content": [
    {
      "type": "heading",
      "attrs": {
        "level": 2,
        "textAlign": null
      },
      "content": [
        {
          "type": "text",
          "text": "Purpose"
        }
      ]
    },
    {
      "type": "paragraph",
      "attrs": {
        "textAlign": null
      },
      "content": [
        {
          "type": "text",
          "text": "Verify workforce integrity and grant the right access at start, revoke at end."
        }
      ]
    }
  ],
  "frequency": "yearly",
  "department": "it",
  "isRequiredToSign": true,
  "signedBy": [
    "usr_123",
    "usr_456"
  ],
  "reviewDate": "2024-12-31T00:00:00.000Z",
  "isArchived": false,
  "archivedAt": "2024-02-01T00:00:00.000Z",
  "createdAt": "2024-01-01T00:00:00.000Z",
  "updatedAt": "2024-01-15T00:00:00.000Z",
  "lastArchivedAt": "2024-02-01T00:00:00.000Z",
  "lastPublishedAt": "2024-01-10T00:00:00.000Z",
  "organizationId": "org_abc123def456",
  "assigneeId": "usr_abc123def456",
  "approverId": "usr_xyz789abc123",
  "policyTemplateId": "plt_template123"
}
401Unauthorized - Invalid authentication or insufficient permissions
messagestring
{
  "message": "Unauthorized"
}
404Policy not found
messagestring
{
  "message": "Policy with ID pol_abc123def456 not found"
}
curl --request GET \
  --url https://api.complianz.ai/v1/policies/<id> \
  --header 'X-API-Key: <api-key>'

Update compliance policy

PATCH/v1/policies/{id}

Update compliance policy details or content while keeping policy workflows connected to controls, tasks, and approvals.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Request body

namestring

Name of the policy

descriptionstring

Description of the policy

statusenum

Status of the policy

One of: draft published needs_review

contentobject[]

Content of the policy as TipTap JSON (array of nodes)

frequencyenum

Review frequency of the policy

One of: monthly quarterly yearly

departmentstring

Department this policy applies to. Built-in values: none, admin, gov, hr, it, itsm, qms. Custom department names are also accepted.

isRequiredToSignboolean

Whether this policy requires a signature

reviewDatestring

Review date for the policy

assigneeIdstring

ID of the user assigned to this policy

approverIdstring

ID of the user who approved this policy

policyTemplateIdstring

ID of the policy template this policy is based on

signedBystring[]

List of user IDs who have signed this policy

isArchivedboolean

Whether to archive this policy

displayFormatenum

Display format for this policy

One of: EDITOR PDF

Responses

200Policy updated successfully
idstringrequired

The policy ID

namestringrequired

Name of the policy

descriptionstringrequired

Description of the policy

statusenumrequired

Status of the policy

One of: draft published needs_review

contentobject[]required

Content of the policy as TipTap JSON (array of nodes)

frequencyenumrequired

Review frequency of the policy

One of: monthly quarterly yearly

departmentstringrequired

Department this policy applies to. May be one of the built-in values (none, admin, gov, hr, it, itsm, qms) or a custom department name.

isRequiredToSignbooleanrequired

Whether this policy requires a signature

signedBystring[]required

List of user IDs who have signed this policy

reviewDatestringrequired

Review date for the policy

isArchivedbooleanrequired

Whether this policy is archived

archivedAtstringrequired

When the policy was archived by framework sync

createdAtstringrequired

When the policy was created

updatedAtstringrequired

When the policy was last updated

lastArchivedAtstringrequired

When the policy was last archived

lastPublishedAtstringrequired

When the policy was last published

organizationIdstringrequired

Organization ID this policy belongs to

assigneeIdstringrequired

ID of the user assigned to this policy

approverIdstringrequired

ID of the user who approved this policy

policyTemplateIdstringrequired

ID of the policy template this policy is based on

{
  "id": "pol_abc123def456",
  "name": "Data Privacy Policy",
  "description": "This policy outlines how we handle and protect personal data",
  "status": "draft",
  "content": [
    {
      "type": "heading",
      "attrs": {
        "level": 2,
        "textAlign": null
      },
      "content": [
        {
          "type": "text",
          "text": "Purpose"
        }
      ]
    },
    {
      "type": "paragraph",
      "attrs": {
        "textAlign": null
      },
      "content": [
        {
          "type": "text",
          "text": "Verify workforce integrity and grant the right access at start, revoke at end."
        }
      ]
    }
  ],
  "frequency": "yearly",
  "department": "it",
  "isRequiredToSign": true,
  "signedBy": [
    "usr_123",
    "usr_456"
  ],
  "reviewDate": "2024-12-31T00:00:00.000Z",
  "isArchived": false,
  "archivedAt": "2024-02-01T00:00:00.000Z",
  "createdAt": "2024-01-01T00:00:00.000Z",
  "updatedAt": "2024-01-15T00:00:00.000Z",
  "lastArchivedAt": "2024-02-01T00:00:00.000Z",
  "lastPublishedAt": "2024-01-10T00:00:00.000Z",
  "organizationId": "org_abc123def456",
  "assigneeId": "usr_abc123def456",
  "approverId": "usr_xyz789abc123",
  "policyTemplateId": "plt_template123"
}
400Bad Request - Invalid update data
messagestring
{
  "message": "Validation failed"
}
401Unauthorized - Invalid authentication or insufficient permissions
messagestring
{
  "message": "Unauthorized"
}
404Policy not found
messagestring
{
  "message": "Policy with ID pol_abc123def456 not found"
}
curl --request PATCH \
  --url https://api.complianz.ai/v1/policies/<id> \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "name": "Data Privacy Policy",
    "description": "This policy outlines how we handle and protect personal data",
    "status": "draft",
    "content": [
      {
        "type": "heading",
        "attrs": {
          "level": 2,
          "textAlign": null
        },
        "content": [
          {
            "type": "text",
            "text": "Purpose"
          }
        ]
      },
      {
        "type": "paragraph",
        "attrs": {
          "textAlign": null
        },
        "content": [
          {
            "type": "text",
            "text": "Verify workforce integrity and grant the right access at start, revoke at end."
          }
        ]
      }
    ],
    "frequency": "yearly",
    "department": "it",
    "isRequiredToSign": true,
    "reviewDate": "2024-12-31T00:00:00.000Z",
    "assigneeId": "usr_abc123def456",
    "approverId": "usr_xyz789abc123",
    "policyTemplateId": "plt_template123",
    "signedBy": [
      "usr_123",
      "usr_456"
    ],
    "isArchived": false,
    "displayFormat": "EDITOR"
  }'

Delete compliance policy

DELETE/v1/policies/{id}

Delete a compliance policy that is no longer part of the organization evidence library or control program.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Responses

200Policy deleted successfully
successboolean

Indicates successful deletion

deletedPolicyobject
Show child attributes
idstring

The deleted policy ID

namestring

The deleted policy name

authTypeenum

How the request was authenticated

One of: api-key session

{
  "success": true,
  "deletedPolicy": {
    "id": "pol_abc123def456",
    "name": "Data Privacy Policy"
  },
  "authType": "api-key"
}
401Unauthorized - Invalid authentication or insufficient permissions
messagestring
{
  "message": "Unauthorized"
}
404Policy not found
messagestring
{
  "message": "Policy with ID pol_abc123def456 not found"
}
curl --request DELETE \
  --url https://api.complianz.ai/v1/policies/<id> \
  --header 'X-API-Key: <api-key>'

Get policy versions

GET/v1/policies/{id}/versions

Get policy versions in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Responses

200Policy versions retrieved successfully
versionsobject[]
currentVersionIdstring
pendingVersionIdstring
{
  "versions": [
    {}
  ],
  "currentVersionId": "string",
  "pendingVersionId": "string"
}
401Unauthorized
messagestring
{
  "message": "Unauthorized"
}
404Resource not found
messagestring
{
  "message": "Resource not found"
}
curl --request GET \
  --url https://api.complianz.ai/v1/policies/<id>/versions \
  --header 'X-API-Key: <api-key>'

Create policy version

POST/v1/policies/{id}/versions

Creates a new draft version of a policy, cloned from the current published version (or a specified source version). Use this when you need to make any change to a published policy — content edits, PDF attachments, anything. Published.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Request body

sourceVersionIdstring

Optional version ID to base the new version on

changelogstring

Optional changelog to associate with the new version

Responses

201Policy version created
versionIdstring
versionnumber
{
  "versionId": "string",
  "version": 0
}
400Invalid request
messagestring
{
  "message": "Invalid request"
}
401Unauthorized
messagestring
{
  "message": "Unauthorized"
}
404Resource not found
messagestring
{
  "message": "Resource not found"
}
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/versions \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "sourceVersionId": "pv_abc123def456",
    "changelog": "Initial draft for quarterly updates"
  }'

Get policy version by ID

GET/v1/policies/{id}/versions/{versionId}

Get policy version by ID in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

versionIdstringrequired

Policy version ID

Header parameters

X-Organization-Idstring

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

Responses

200Policy version retrieved successfully
versionobject
currentVersionIdstring
pendingVersionIdstring
{
  "version": {},
  "currentVersionId": "string",
  "pendingVersionId": "string"
}
401Unauthorized
messagestring
{
  "message": "Unauthorized"
}
404Resource not found
messagestring
{
  "message": "Resource not found"
}
curl --request GET \
  --url https://api.complianz.ai/v1/policies/<id>/versions/<versionId> \
  --header 'X-API-Key: <api-key>'

Update version content

PATCH/v1/policies/{id}/versions/{versionId}

Update version content in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

versionIdstringrequired

Policy version ID

Header parameters

X-Organization-Idstring

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

Request body

contentobject[]required

Content of the policy version as TipTap JSON (array of nodes)

Responses

200Version content updated
versionIdstring
{
  "versionId": "string"
}
400Invalid request
messagestring
{
  "message": "Invalid request"
}
401Unauthorized
messagestring
{
  "message": "Unauthorized"
}
404Resource not found
messagestring
{
  "message": "Resource not found"
}
curl --request PATCH \
  --url https://api.complianz.ai/v1/policies/<id>/versions/<versionId> \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "content": [
      {
        "type": "heading",
        "attrs": {
          "level": 2,
          "textAlign": null
        },
        "content": [
          {
            "type": "text",
            "text": "Purpose"
          }
        ]
      }
    ]
  }'

Delete policy version

DELETE/v1/policies/{id}/versions/{versionId}

Delete policy version in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

versionIdstringrequired

Policy version ID

Header parameters

X-Organization-Idstring

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

Responses

200Version deleted
deletedVersionnumber
{
  "deletedVersion": 0
}
400Invalid request
messagestring
{
  "message": "Invalid request"
}
401Unauthorized
messagestring
{
  "message": "Unauthorized"
}
404Resource not found
messagestring
{
  "message": "Resource not found"
}
curl --request DELETE \
  --url https://api.complianz.ai/v1/policies/<id>/versions/<versionId> \
  --header 'X-API-Key: <api-key>'

Publish policy version

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

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.

Path parameters

idstringrequired

Policy ID

Header parameters

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

Responses

200Version published
versionIdstring
versionnumber
{
  "versionId": "string",
  "version": 0
}
400Invalid request
messagestring
{
  "message": "Invalid request"
}
401Unauthorized
messagestring
{
  "message": "Unauthorized"
}
404Resource not found
messagestring
{
  "message": "Resource not found"
}
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/versions/publish \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "versionId": "pv_abc123def456",
    "setAsActive": true,
    "changelog": "Updated access controls section"
  }'

Set active policy version

POST/v1/policies/{id}/versions/{versionId}/activate

Set active policy version in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

versionIdstringrequired

Policy version ID

Header parameters

X-Organization-Idstring

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

Responses

200Active version updated
versionIdstring
versionnumber
{
  "versionId": "string",
  "version": 0
}
400Invalid request
messagestring
{
  "message": "Invalid request"
}
401Unauthorized
messagestring
{
  "message": "Unauthorized"
}
404Resource not found
messagestring
{
  "message": "Resource not found"
}
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/versions/<versionId>/activate \
  --header 'X-API-Key: <api-key>'

Submit version for approval

POST/v1/policies/{id}/versions/{versionId}/submit-for-approval

Submit version for approval in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

versionIdstringrequired

Policy version ID

Header parameters

X-Organization-Idstring

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

Request body

approverIdstringrequired

Member ID of the approver

Responses

200Version submitted for approval
versionIdstring
versionnumber
{
  "versionId": "string",
  "version": 0
}
400Invalid request
messagestring
{
  "message": "Invalid request"
}
401Unauthorized
messagestring
{
  "message": "Unauthorized"
}
404Resource not found
messagestring
{
  "message": "Resource not found"
}
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/versions/<versionId>/submit-for-approval \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "approverId": "mem_abc123def456"
  }'

Accept pending policy changes and publish the version

POST/v1/policies/{id}/accept-changes

Accept pending policy changes and publish the version in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Responses

201
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/accept-changes \
  --header 'X-API-Key: <api-key>'

Deny pending policy changes

POST/v1/policies/{id}/deny-changes

Deny pending policy changes in Complianz. Create, version, publish, export, map, and improve compliance policies with AI-assisted drafting and approval workflows.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Responses

201
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/deny-changes \
  --header 'X-API-Key: <api-key>'

Chat with AI about a policy

POST/v1/policies/{id}/ai-chat

Ask policy-specific questions and request draft improvements while preserving human review before policy changes are applied.

Path parameters

idstringrequired

Policy ID

Header parameters

X-Organization-Idstring

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

Request body

instructionsstringrequired

User instructions about what changes to make to the policy

chatHistoryobject[]

Chat history for context (array of messages with role and content)

Show child attributes
roleenum

One of: user assistant

contentstring

Responses

200Streaming AI response
401Unauthorized
404Policy not found
curl --request POST \
  --url https://api.complianz.ai/v1/policies/<id>/ai-chat \
  --header 'X-API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
    "instructions": "Update the data retention section to specify a 7-year retention period",
    "chatHistory": [
      {
        "role": "user",
        "content": "Update the data retention policy"
      },
      {
        "role": "assistant",
        "content": "I can help with that..."
      }
    ]
  }'