Skip to main content
GET
/
v1
/
policies
Get all policies
curl --request GET \
  --url http://localhost:3333/v1/policies \
  --header 'X-API-Key: <api-key>'
{
  "data": [
    {
      "id": "pol_abc123def456",
      "name": "Data Privacy Policy",
      "description": "This policy outlines how we handle and protect personal data",
      "status": "draft",
      "content": [
        {
          "type": "paragraph",
          "attrs": {
            "textAlign": null
          },
          "content": [
            {
              "type": "text",
              "text": "This policy outlines our commitment to protecting personal data."
            }
          ]
        }
      ],
      "frequency": "yearly",
      "department": "IT",
      "isRequiredToSign": true,
      "signedBy": [],
      "reviewDate": "2024-12-31T00:00:00.000Z",
      "isArchived": false,
      "createdAt": "2024-01-01T00:00:00.000Z",
      "updatedAt": "2024-01-15T00:00:00.000Z",
      "lastArchivedAt": null,
      "lastPublishedAt": "2024-01-10T00:00:00.000Z",
      "organizationId": "org_abc123def456",
      "assigneeId": "usr_abc123def456",
      "approverId": "usr_xyz789abc123",
      "policyTemplateId": null
    }
  ],
  "authType": "session",
  "authenticatedUser": {
    "id": "usr_abc123def456",
    "email": "user@company.com"
  }
}

Authorizations

X-API-Key
string
header
required

API key for authentication

Headers

X-Organization-Id
string

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

Response

Policies retrieved successfully

data
object[]
required

Array of policies

authType
enum<string>
required

How the request was authenticated

Available options:
api-key,
session
authenticatedUser
object

Authenticated user information (only present for session auth)