{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/trackmcp/main/json-schema/trackmcp-post-api-v1-ingest-request-schema.json",
  "title": "PostApiV1IngestRequest",
  "x-generated": "2026-10-19",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/_ae-authored/trackmcp-openapi-generated.yml#/components/schemas/PostApiV1IngestRequest",
  "type": "object",
  "properties": {
    "events": {
      "type": "array",
      "description": "Array of event objects"
    },
    "schema_version": {
      "type": "string",
      "description": "Version of the event schema"
    },
    "event_id": {
      "type": "string",
      "description": "Unique identifier for the event"
    },
    "event_type": {
      "type": "string",
      "description": "Type of the event (e.g., tool_call)"
    },
    "observation_source": {
      "type": "string",
      "description": "Source of observation (server or client)"
    },
    "service": {
      "type": "string",
      "description": "Name of the MCP service"
    },
    "environment": {
      "type": "string",
      "description": "Deployment environment"
    },
    "tool_name": {
      "type": "string",
      "description": "Name of the tool invoked"
    },
    "started_at": {
      "type": "string",
      "description": "ISO‑8601 timestamp when the event started"
    },
    "duration_ms": {
      "type": "integer",
      "description": "Duration of the event in milliseconds"
    },
    "success": {
      "type": "boolean",
      "description": "Whether the event succeeded"
    },
    "is_error": {
      "type": "boolean",
      "description": "Whether the event resulted in an error"
    },
    "payload_policy": {
      "type": "string",
      "description": "Policy for payload redaction"
    },
    "payload": {
      "type": "object",
      "description": "Event payload (example shows empty args object)"
    }
  },
  "required": [
    "events",
    "schema_version",
    "event_id",
    "event_type",
    "observation_source",
    "service",
    "environment",
    "tool_name",
    "started_at",
    "duration_ms",
    "success",
    "is_error",
    "payload_policy",
    "payload"
  ]
}