{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/tryorcha-com/json-schema/tryorcha-com-file-schema.json",
  "title": "File",
  "description": "A workspace file. List responses omit `content`; single-file responses include it.",
  "x-generated": "2026-11-27",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/tryorcha-com-openapi.json#/components/schemas/File",
  "type": "object",
  "required": [
    "id",
    "name",
    "fileType",
    "workspaceId"
  ],
  "properties": {
    "id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "content": {
      "type": "string"
    },
    "fileType": {
      "type": "string",
      "enum": [
        "markdown",
        "json",
        "yaml",
        "text"
      ]
    },
    "folderId": {
      "type": [
        "string",
        "null"
      ]
    },
    "workspaceId": {
      "type": "string"
    },
    "tags": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "string"
      }
    },
    "createdAt": {
      "type": "string",
      "format": "date-time"
    },
    "updatedAt": {
      "type": "string",
      "format": "date-time"
    },
    "commentCount": {
      "type": "integer",
      "description": "Unresolved comments on the file. Returned by `GET /api/v1/files/{id}` only; read them with `GET /api/v1/files/{id}/comments`."
    }
  },
  "additionalProperties": true
}