{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://docs.demiton.io/registers/dropbox_document_routing/v1.json",
  "title": "dropbox_document_routing contract v1",
  "type": "object",
  "required": [
    "default_action",
    "dropbox_prefix",
    "rules",
    "scope",
    "subject_entity_id"
  ],
  "properties": {
    "rules": {
      "type": "array",
      "description": "The ordered rule set, one element per routing rule; the shelf's entire payload",
      "x-demiton-requiredness": "required"
    },
    "scope": {
      "type": "string",
      "description": "The functional label a rule belongs to; the write path filters rules by it",
      "x-demiton-requiredness": "required"
    },
    "sp_library": {
      "type": "string",
      "description": "The document library inside that site",
      "x-demiton-requiredness": "optional"
    },
    "blob_prefix": {
      "type": "string",
      "description": "The container-relative prefix placed in front of the source path's remainder, mirroring the Dropbox layout so a file is findable from its Dropbox path alone",
      "x-demiton-requiredness": "optional"
    },
    "sp_site_path": {
      "type": "string",
      "description": "The SharePoint site the rule delivers into",
      "x-demiton-requiredness": "optional"
    },
    "strip_prefix": {
      "type": "boolean",
      "description": "Whether the matched `dropbox_prefix` is removed before the destination folder is built",
      "x-demiton-requiredness": "optional"
    },
    "default_action": {
      "type": "string",
      "description": "What happens to a file matching no rule; the only value observed in the live ruleset is `skip`",
      "x-demiton-requiredness": "required"
    },
    "dropbox_prefix": {
      "type": "string",
      "description": "The Dropbox path prefix this rule claims; it is simultaneously the literal `list_folder` path, the `startswith()` needle, and the delta-cursor scope key",
      "x-demiton-requiredness": "required"
    },
    "always_full_scan": {
      "type": "boolean",
      "description": "Whether this prefix bypasses the delta cursor and the modified_after cutoff on every dispatch",
      "x-demiton-requiredness": "optional"
    },
    "destination_kind": {
      "type": "string",
      "description": "Which class of destination the rule targets; absent means SharePoint",
      "x-demiton-requiredness": "optional"
    },
    "sp_folder_prefix": {
      "type": "string",
      "description": "The library-relative folder the rule's files land under, before the stripped remainder of the source path is re-appended",
      "x-demiton-requiredness": "optional"
    },
    "subject_entity_id": {
      "type": "integer",
      "description": "The entity the ruleset is about: the tenant organisation itself",
      "x-demiton-requiredness": "required"
    },
    "sp_connector_alias": {
      "type": "string",
      "description": "The logical alias of the connector that reaches the SharePoint destination",
      "x-demiton-requiredness": "optional"
    },
    "blob_connector_alias": {
      "type": "string",
      "description": "The logical alias of the connector that reaches the blob destination",
      "x-demiton-requiredness": "optional"
    }
  },
  "x-demiton-register-type": "dropbox_document_routing",
  "x-demiton-contract-version": "1.0.2",
  "x-demiton-store": "tenant",
  "x-demiton-axes": [],
  "x-demiton-measures": [],
  "x-demiton-provenance": {
    "standards": []
  },
  "description": "Your rules for routing an incoming Dropbox document to the right folder.",
  "x-demiton-contract-url": "https://docs.demiton.io/registers/dropbox_document_routing/",
  "x-demiton-register-catalog": "https://docs.demiton.io/concepts/register-catalog"
}