{
  "type": "object",
  "properties": {
    "filename": {
      "type": "string",
      "minLength": 1,
      "maxLength": 512,
      "description": "Original filename including extension \u2014 the extension drives type detection. Example: \"vendor-contract-2026.pdf\"."
    },
    "contentBase64": {
      "type": "string",
      "minLength": 1,
      "description": "The file's raw bytes, base64-encoded (standard alphabet, no data: URI prefix). For a plain-text or markdown document, base64-encode the UTF-8 text."
    },
    "mimeType": {
      "type": "string",
      "maxLength": 255,
      "description": "MIME type, e.g. \"application/pdf\". Optional \u2014 the backend verifies the real type from the file's magic bytes regardless."
    },
    "projectId": {
      "type": "string",
      "description": "Council project workspace to file the document under. Omit for the general library."
    },
    "tags": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Free-form tags to attach to the document, e.g. [\"contracts\", \"2026\"]."
    }
  },
  "required": [
    "filename",
    "contentBase64"
  ],
  "additionalProperties": false,
  "$schema": "http://json-schema.org/draft-07/schema#"
}