{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/namirial/json-schema/namirial-envelope-find-request-schema.json",
  "title": "EnvelopeFindRequest",
  "description": "The request model for searching envelopes.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/namirial-envelope-api-openapi.yml#/components/schemas/EnvelopeFindRequest",
  "type": "object",
  "properties": {
    "StartDate": {
      "format": "date-time",
      "description": "If set, filter for envelopes which were sent after the start date.\nA datetime in the format RFC 3339, section 5.6, 'date-Time' (e.g. 2017-07-21T17:32:28Z).",
      "maxLength": 30,
      "minLength": 20,
      "type": "string"
    },
    "EndDate": {
      "format": "date-time",
      "description": "If set, filter for envelopes which were sent before the end date.\nA datetime in the format RFC 3339, section 5.6, 'date-Time' (e.g. 2017-07-21T17:32:28Z).",
      "maxLength": 30,
      "minLength": 20,
      "type": "string"
    },
    "SearchText": {
      "description": "If set, the given text is searched in following fields:\nenvelope name and description\nnotification subject and message \nsender email address, given name and surname  \nrecipient email address, given name and surname\nNote: Using this search option is very resource intensive! It might take very long.",
      "maxLength": 500,
      "minLength": 0,
      "type": "string"
    },
    "Status": {
      "description": "If set, envelopes in the given status are matched.",
      "enum": [
        "Canceled",
        "Completed",
        "Expired",
        "Rejected",
        "ActionRequired",
        "WaitingForOthers",
        "ExpiringSoon",
        "Active"
      ],
      "type": "string"
    },
    "InStatusSinceDays": {
      "description": "If set, envelopes having the given status for the specified days are matched.\nIt must be combined with Status.",
      "type": "integer"
    },
    "SenderEmail": {
      "description": "If set, envelopes sent by the user with the given email address are matched.",
      "maxLength": 250,
      "minLength": 0,
      "type": "string"
    },
    "CompletedByRecipientWithEmail": {
      "description": "If set, envelopes containing a completed activity, belonging to a recipient with the given email address, are matched.",
      "maxLength": 250,
      "minLength": 0,
      "type": "string"
    },
    "RecipientEmail": {
      "description": "If set, envelopes containing a recipient with the given email address are matched.",
      "maxLength": 250,
      "minLength": 0,
      "type": "string"
    },
    "WaitingForRecipientWithEmail": {
      "description": "If set, envelopes waiting for the recipient with the given email address are matched.",
      "maxLength": 250,
      "minLength": 0,
      "type": "string"
    },
    "EnvelopeBulkParentId": {
      "description": "If set, envelopes belonging to the given BulkParent envelope are matched.",
      "maxLength": 36,
      "minLength": 36,
      "type": "string"
    }
  }
}