{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/cotal-ai/json-schema/cotal-ai-feedback-schema.json",
  "title": "Feedback",
  "description": "Strings are trimmed before length checks. Empty or null optional strings are omitted. Unknown properties are discarded. client and diagnostics accept arbitrary JSON.",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/cotal-ai-feedback-intake-openapi.yml#/components/schemas/Feedback",
  "type": "object",
  "properties": {
    "origin": {
      "type": "string",
      "enum": [
        "human",
        "agent"
      ]
    },
    "type": {
      "type": "string",
      "enum": [
        "bug",
        "idea",
        "friction",
        "praise",
        "other"
      ]
    },
    "summary": {
      "type": "string",
      "minLength": 1,
      "maxLength": 300
    },
    "severity": {
      "type": "string",
      "enum": [
        "low",
        "medium",
        "high"
      ]
    },
    "client": {},
    "diagnostics": {},
    "details": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 10000
    },
    "area": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 120
    },
    "repro": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 10000
    },
    "expected": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 5000
    },
    "actual": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 5000
    },
    "source": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 40
    }
  },
  "required": [
    "origin",
    "type",
    "summary"
  ]
}