{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/clarify/json-schema/clarify-object-record-access-list-response-schema.json",
  "title": "ObjectRecordAccessListResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/clarify-recordaccess-api-openapi.yml#/components/schemas/ObjectRecordAccessListResponse",
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "object-record-access"
            ]
          },
          "id": {
            "type": "string"
          },
          "attributes": {
            "type": "object",
            "properties": {
              "_id": {
                "type": "string",
                "description": "The unique ID of the grant."
              },
              "object_id": {
                "type": "string",
                "description": "The unique ID of the shared record."
              },
              "grantee_type": {
                "type": "string",
                "enum": [
                  "user",
                  "workspace",
                  "group",
                  "email",
                  "public"
                ],
                "description": "Who the grant is for: `user` for a single workspace member, `workspace` for everyone in the workspace."
              },
              "grantee_id": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The unique ID of the grantee. Set to the user’s ID for `user` grants; `null` for `workspace` grants."
              },
              "access_level": {
                "type": "string",
                "enum": [
                  "view",
                  "edit",
                  "manage",
                  "owner"
                ],
                "description": "The level of access the grant confers: `view` read-only, `edit` read-write. `owner` marks the record’s owner — returned read-only to identify the owner; it cannot be granted, changed, or revoked through this API (use the reassign-owner endpoint)."
              },
              "source": {
                "type": "string",
                "enum": [
                  "share",
                  "field",
                  "delegated_send"
                ],
                "description": "Why the grant exists: `share` for a direct grant, `field` for a grant from a user field on the record, such as a deal’s owner, `delegated_send` for an email a delegate sent from the owner’s account, or a reply in a thread they started. Field grants follow the field and delegated-send grants follow the delegation; neither can be changed or revoked through this API. A user can hold a direct grant beside either one on the same record."
              },
              "_created_at": {
                "type": "string",
                "format": "date-time",
                "description": "When the grant was created."
              },
              "_created_by": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The unique ID of the user who created the grant."
              },
              "_updated_at": {
                "type": [
                  "string",
                  "null"
                ],
                "format": "date-time",
                "description": "When the grant was last updated."
              },
              "_updated_by": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The unique ID of the user who last updated the grant."
              }
            },
            "required": [
              "_id",
              "object_id",
              "grantee_type",
              "grantee_id",
              "access_level",
              "source",
              "_created_at",
              "_created_by",
              "_updated_at",
              "_updated_by"
            ]
          }
        },
        "required": [
          "type",
          "id",
          "attributes"
        ]
      }
    },
    "meta": {
      "type": "object",
      "properties": {
        "viewerAccess": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "public-link",
                  "workspace-public",
                  "legacy-delegate",
                  "entity-wide-delegate"
                ],
                "description": "How the viewer reaches the record. `workspace-public` is deprecated and never returned."
              },
              "grantee_id": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "access_level": {
                "type": [
                  "string",
                  "null"
                ],
                "enum": [
                  "view",
                  "edit",
                  "manage",
                  "owner"
                ]
              },
              "owners": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "owner_id": {
                      "type": "string"
                    },
                    "access_level": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "enum": [
                        "view",
                        "edit",
                        "manage",
                        "owner"
                      ]
                    }
                  },
                  "required": [
                    "owner_id",
                    "access_level"
                  ]
                },
                "description": "The record owners whose delegation grants this viewer access, each with the access level that owner granted. Empty for paths with no delegating owner, such as public-link sharing."
              }
            },
            "required": [
              "kind",
              "grantee_id",
              "access_level",
              "owners"
            ]
          }
        }
      },
      "required": [
        "viewerAccess"
      ]
    }
  },
  "required": [
    "data",
    "meta"
  ]
}