{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/pdfbetter-com/json-schema/pdfbetter-com-signature-request-detail-schema.json",
  "title": "SignatureRequestDetail",
  "x-generated": "2026-11-20",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/pdfbetter-com-openapi.json#/components/schemas/SignatureRequestDetail",
  "type": "object",
  "properties": {
    "object": {
      "type": "string",
      "const": "signature_request"
    },
    "id": {
      "type": "string"
    },
    "documentId": {
      "type": "string"
    },
    "title": {
      "type": "string"
    },
    "message": {
      "type": [
        "string",
        "null"
      ]
    },
    "status": {
      "type": "string",
      "enum": [
        "draft",
        "sent",
        "completed",
        "declined",
        "canceled",
        "expired"
      ]
    },
    "routing": {
      "type": "string",
      "enum": [
        "sequential",
        "parallel"
      ]
    },
    "reminderEveryDays": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": -9007199254740991,
          "maximum": 9007199254740991
        },
        {
          "type": "null"
        }
      ]
    },
    "expiresAt": {
      "anyOf": [
        {
          "type": "string",
          "description": "ISO 8601 timestamp (UTC)"
        },
        {
          "type": "null"
        }
      ]
    },
    "sentAt": {
      "anyOf": [
        {
          "type": "string",
          "description": "ISO 8601 timestamp (UTC)"
        },
        {
          "type": "null"
        }
      ]
    },
    "completedAt": {
      "anyOf": [
        {
          "type": "string",
          "description": "ISO 8601 timestamp (UTC)"
        },
        {
          "type": "null"
        }
      ]
    },
    "createdAt": {
      "type": "string",
      "description": "ISO 8601 timestamp (UTC)"
    },
    "fieldCount": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    },
    "hasCompletedFile": {
      "type": "boolean"
    },
    "hasCertificate": {
      "type": "boolean"
    },
    "recipients": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "role": {
            "type": "string",
            "enum": [
              "signer",
              "approver",
              "cc"
            ]
          },
          "order": {
            "type": "integer",
            "minimum": -9007199254740991,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "sent",
              "viewed",
              "signed",
              "declined"
            ]
          },
          "authMethod": {
            "type": "string"
          },
          "sentAt": {
            "anyOf": [
              {
                "type": "string",
                "description": "ISO 8601 timestamp (UTC)"
              },
              {
                "type": "null"
              }
            ]
          },
          "viewedAt": {
            "anyOf": [
              {
                "type": "string",
                "description": "ISO 8601 timestamp (UTC)"
              },
              {
                "type": "null"
              }
            ]
          },
          "signedAt": {
            "anyOf": [
              {
                "type": "string",
                "description": "ISO 8601 timestamp (UTC)"
              },
              {
                "type": "null"
              }
            ]
          },
          "declinedAt": {
            "anyOf": [
              {
                "type": "string",
                "description": "ISO 8601 timestamp (UTC)"
              },
              {
                "type": "null"
              }
            ]
          },
          "declineReason": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "required": [
          "id",
          "name",
          "email",
          "role",
          "order",
          "status",
          "authMethod",
          "sentAt",
          "viewedAt",
          "signedAt",
          "declinedAt",
          "declineReason"
        ],
        "additionalProperties": false
      }
    },
    "timeline": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "seq": {
            "type": "integer",
            "minimum": -9007199254740991,
            "maximum": 9007199254740991
          },
          "event": {
            "type": "string",
            "description": "created, sent, delivered, viewed, consented, signed, approved, declined, completed, canceled, expired, reminded, …"
          },
          "actorType": {
            "type": "string"
          },
          "actorEmail": {
            "type": [
              "string",
              "null"
            ]
          },
          "createdAt": {
            "type": "string",
            "description": "ISO 8601 timestamp (UTC)"
          },
          "data": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {}
          }
        },
        "required": [
          "seq",
          "event",
          "actorType",
          "actorEmail",
          "createdAt",
          "data"
        ],
        "additionalProperties": false
      }
    }
  },
  "required": [
    "object",
    "id",
    "documentId",
    "title",
    "message",
    "status",
    "routing",
    "reminderEveryDays",
    "expiresAt",
    "sentAt",
    "completedAt",
    "createdAt",
    "fieldCount",
    "hasCompletedFile",
    "hasCertificate",
    "recipients",
    "timeline"
  ],
  "additionalProperties": false
}