TraceDB Docs

OpenAPI v1

Source: tracedb-protocol/docs/api/v1-openapi.json

{
  "components": {
    "schemas": {
      "AccessPathExplain": {
        "additionalProperties": false,
        "description": "Access path explain entry.",
        "properties": {
          "access_path_id": {
            "type": "string"
          },
          "candidates": {
            "type": "integer"
          },
          "opened": {
            "type": "boolean"
          },
          "visibility_checked_before_open": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "AccessPathTiming": {
        "additionalProperties": false,
        "description": "Access path timing entry.",
        "properties": {
          "access_path_id": {
            "type": "string"
          },
          "build_ms": {
            "type": "number"
          },
          "open_ms": {
            "type": "number"
          }
        },
        "type": "object"
      },
      "AdminJob": {
        "additionalProperties": false,
        "description": "Admin job queue entry.",
        "properties": {
          "queue": {
            "type": "string"
          },
          "state": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "BranchSummary": {
        "additionalProperties": false,
        "description": "Branch catalog entry.",
        "properties": {
          "branch_id": {
            "type": "string"
          },
          "database_id": {
            "type": "string"
          },
          "endpoint": {
            "type": "string"
          },
          "latest_epoch": {
            "type": "integer"
          },
          "parent_branch_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "state": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "BranchesResponse": {
        "additionalProperties": false,
        "description": "Branch catalog response.",
        "properties": {
          "branches": {
            "items": {
              "$ref": "#/components/schemas/BranchSummary"
            },
            "type": "array"
          },
          "gateway": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "Candidate": {
        "additionalProperties": false,
        "description": "Planner candidate explain row.",
        "properties": {
          "freshness": {
            "type": "string"
          },
          "record_id": {
            "type": "string"
          },
          "score_components": {
            "$ref": "#/components/schemas/HybridScoreComponents"
          },
          "score_upper_bound": {
            "type": [
              "number",
              "null"
            ]
          },
          "source": {
            "type": "string"
          },
          "version_id": {
            "type": "integer"
          },
          "visibility_checked": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "CompactResponse": {
        "additionalProperties": false,
        "description": "Compact response.",
        "properties": {
          "compacted": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "DatabaseSummary": {
        "additionalProperties": false,
        "description": "Database catalog entry.",
        "properties": {
          "database_id": {
            "type": "string"
          },
          "endpoint": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "org_id": {
            "type": "string"
          },
          "project_id": {
            "type": "string"
          },
          "region": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "DatabasesResponse": {
        "additionalProperties": false,
        "description": "Database catalog response.",
        "properties": {
          "databases": {
            "items": {
              "$ref": "#/components/schemas/DatabaseSummary"
            },
            "type": "array"
          },
          "gateway": {
            "type": "boolean"
          },
          "mode": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "DeleteResponse": {
        "additionalProperties": false,
        "description": "Delete response.",
        "properties": {
          "deleted": {
            "type": "boolean"
          },
          "epoch": {
            "type": "integer"
          }
        },
        "type": "object"
      },
      "EmptyObject": {
        "additionalProperties": true,
        "description": "Empty JSON object.",
        "type": "object"
      },
      "EpochResponse": {
        "additionalProperties": false,
        "description": "Epoch allocation response.",
        "properties": {
          "epoch": {
            "type": "integer"
          }
        },
        "type": "object"
      },
      "ErrorResponse": {
        "additionalProperties": false,
        "description": "Error response.",
        "properties": {
          "code": {
            "description": "Stable machine-readable error code when available; existing clients can continue to read error.",
            "type": "string"
          },
          "error": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "GetRecordResponse": {
        "additionalProperties": false,
        "description": "Get record response.",
        "properties": {
          "record": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/RecordOutput"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "type": "object"
      },
      "GraphQlError": {
        "additionalProperties": false,
        "description": "GraphQL error entry.",
        "properties": {
          "extensions": {
            "additionalProperties": true,
            "description": "GraphQL error extensions.",
            "properties": {
              "code": {
                "type": "string"
              }
            },
            "type": "object"
          },
          "message": {
            "type": "string"
          },
          "path": {
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "GraphQlQueryRequest": {
        "additionalProperties": true,
        "description": "GraphQL request body. Native operations accept an input JSON string argument and standard variables/operationName fields.",
        "properties": {
          "operationName": {
            "type": "string"
          },
          "operation_name": {
            "type": "string"
          },
          "query": {
            "type": "string"
          },
          "variables": {
            "additionalProperties": true,
            "description": "GraphQL variables map.",
            "type": "object"
          }
        },
        "type": "object"
      },
      "GraphQlResponse": {
        "additionalProperties": false,
        "description": "Native GraphQL response envelope.",
        "properties": {
          "data": {
            "additionalProperties": true,
            "description": "GraphQL data object.",
            "type": "object"
          },
          "errors": {
            "items": {
              "$ref": "#/components/schemas/GraphQlError"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "GraphQlSchemaResponse": {
        "additionalProperties": false,
        "description": "Bounded GraphQL adapter schema response.",
        "properties": {
          "adapter": {
            "type": "string"
          },
          "execution": {
            "type": "string"
          },
          "schema": {
            "type": "string"
          },
          "tables": {
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "HealthResponse": {
        "additionalProperties": false,
        "description": "Health response.",
        "properties": {
          "catalog_databases": {
            "type": "integer"
          },
          "engine_url": {
            "type": "string"
          },
          "metered_requests": {
            "type": "integer"
          },
          "ok": {
            "type": "boolean"
          },
          "service": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "HybridExplain": {
        "additionalProperties": false,
        "description": "Explain response.",
        "properties": {
          "access_path_timings": {
            "items": {
              "$ref": "#/components/schemas/AccessPathTiming"
            },
            "type": "array"
          },
          "access_paths": {
            "items": {
              "$ref": "#/components/schemas/AccessPathExplain"
            },
            "type": "array"
          },
          "candidate_budget": {
            "type": "integer"
          },
          "deduped_candidate_count": {
            "type": "integer"
          },
          "dirty_feature_count": {
            "type": "integer"
          },
          "early_stop_reason": {
            "type": [
              "string",
              "null"
            ]
          },
          "exact_fallback_triggered": {
            "type": "boolean"
          },
          "failed_feature_count": {
            "type": "integer"
          },
          "final_visibility_guard_count": {
            "type": "integer"
          },
          "final_visibility_guard_removed": {
            "type": "integer"
          },
          "freshness_mode": {
            "type": "string"
          },
          "fusion_method": {
            "type": "string"
          },
          "hot_overlay_searched": {
            "type": "boolean"
          },
          "lexical_cache_hits": {
            "type": "integer"
          },
          "lexical_cache_misses": {
            "type": "integer"
          },
          "lexical_indexed_documents": {
            "type": "integer"
          },
          "lexical_scored_documents": {
            "type": "integer"
          },
          "materialized_count": {
            "type": "integer"
          },
          "missing_feature_count": {
            "type": "integer"
          },
          "module_versions": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "opened_candidate_streams": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "pending_feature_count": {
            "type": "integer"
          },
          "phase_timings": {
            "items": {
              "$ref": "#/components/schemas/QueryPhaseTiming"
            },
            "type": "array"
          },
          "planner_candidates": {
            "items": {
              "$ref": "#/components/schemas/Candidate"
            },
            "type": "array"
          },
          "policy_epoch": {
            "type": "integer"
          },
          "read_epoch": {
            "type": "integer"
          },
          "returned_count": {
            "type": "integer"
          },
          "scalar_filter_applied": {
            "type": "boolean"
          },
          "scalar_filter_predicates": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "scalar_filter_removed_records": {
            "type": "integer"
          },
          "scalar_filter_visible_records": {
            "type": "integer"
          },
          "schema_epoch": {
            "type": "integer"
          },
          "segments_scanned": {
            "type": "integer"
          },
          "selected_strategy": {
            "type": [
              "string",
              "null"
            ]
          },
          "skipped_access_paths": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "tenant_mask_visible_records": {
            "type": "integer"
          },
          "text_candidates": {
            "type": "integer"
          },
          "vector_candidates": {
            "type": "integer"
          }
        },
        "type": "object"
      },
      "HybridQuery": {
        "additionalProperties": true,
        "description": "Hybrid lexical/vector/scalar query.",
        "properties": {
          "cursor": {
            "description": "Opaque cursor returned by the previous query page.",
            "type": [
              "string",
              "null"
            ]
          },
          "explain": {
            "type": "boolean"
          },
          "freshness": {
            "type": "string"
          },
          "graph_seed": {
            "type": [
              "string",
              "null"
            ]
          },
          "scalar_eq": {
            "additionalProperties": true,
            "description": "Scalar equality predicates keyed by schema scalar column.",
            "type": "object"
          },
          "table": {
            "type": "string"
          },
          "temporal_as_of": {
            "type": [
              "integer",
              "null"
            ]
          },
          "tenant_id": {
            "type": "string"
          },
          "text": {
            "type": [
              "string",
              "null"
            ]
          },
          "text_field": {
            "description": "Optional schema text-indexed column to search. When omitted, TraceDB searches all text-indexed columns for backwards-compatible fieldless queries.",
            "type": [
              "string",
              "null"
            ]
          },
          "top_k": {
            "minimum": 0,
            "type": "integer"
          },
          "vector": {
            "items": {
              "type": "number"
            },
            "type": [
              "array",
              "null"
            ]
          },
          "vector_field": {
            "description": "Optional schema vector column to score. When omitted, TraceDB uses the first vector column for backwards-compatible fieldless queries.",
            "type": [
              "string",
              "null"
            ]
          }
        },
        "type": "object"
      },
      "HybridQueryRow": {
        "additionalProperties": false,
        "description": "Hybrid query result row.",
        "properties": {
          "fields": {
            "additionalProperties": true,
            "description": "Record field map.",
            "type": "object"
          },
          "record_id": {
            "type": "string"
          },
          "score": {
            "$ref": "#/components/schemas/HybridScoreComponents"
          },
          "tenant_id": {
            "type": "string"
          },
          "version_id": {
            "type": "integer"
          }
        },
        "type": "object"
      },
      "HybridScoreComponents": {
        "additionalProperties": false,
        "description": "Hybrid query score components.",
        "properties": {
          "final_score": {
            "type": "number"
          },
          "freshness_penalty": {
            "type": [
              "number",
              "null"
            ]
          },
          "lexical": {
            "type": [
              "number",
              "null"
            ]
          },
          "relational": {
            "type": [
              "number",
              "null"
            ]
          },
          "vector": {
            "type": [
              "number",
              "null"
            ]
          }
        },
        "type": "object"
      },
      "JobsResponse": {
        "additionalProperties": false,
        "description": "Admin job queue response.",
        "properties": {
          "jobs": {
            "items": {
              "$ref": "#/components/schemas/AdminJob"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "MetricsResponse": {
        "additionalProperties": false,
        "description": "Public-safe metrics response.",
        "properties": {
          "durable_epoch": {
            "type": "integer"
          },
          "gateway": {
            "type": "boolean"
          },
          "index_count": {
            "type": "integer"
          },
          "latest_epoch": {
            "type": "integer"
          },
          "module_count": {
            "type": "integer"
          },
          "rate_limit_enabled": {
            "type": "boolean"
          },
          "rate_limit_requests": {
            "type": "integer"
          },
          "recovery_state": {
            "type": "string"
          },
          "requests": {
            "type": "integer"
          },
          "schema_count": {
            "type": "integer"
          },
          "segment_count": {
            "type": "integer"
          },
          "service": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "PutBatchResponse": {
        "additionalProperties": false,
        "description": "Batch write response.",
        "properties": {
          "epoch": {
            "type": "integer"
          },
          "record_count": {
            "type": "integer"
          },
          "write_timing": {
            "additionalProperties": {
              "type": "number"
            },
            "description": "Optional write timing attribution.",
            "type": "object"
          }
        },
        "type": "object"
      },
      "QueryPhaseTiming": {
        "additionalProperties": false,
        "description": "Query phase timing entry.",
        "properties": {
          "elapsed_ms": {
            "type": "number"
          },
          "phase": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "QueryResponse": {
        "additionalProperties": false,
        "description": "Query response.",
        "properties": {
          "explain": {
            "$ref": "#/components/schemas/HybridExplain"
          },
          "next_cursor": {
            "type": [
              "string",
              "null"
            ]
          },
          "results": {
            "items": {
              "$ref": "#/components/schemas/HybridQueryRow"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "ReadyResponse": {
        "additionalProperties": false,
        "description": "Readiness response.",
        "properties": {
          "catalog_databases": {
            "type": "integer"
          },
          "durable_epoch": {
            "type": "integer"
          },
          "engine_health_checked": {
            "type": "boolean"
          },
          "engine_status_code": {
            "type": "integer"
          },
          "engine_url": {
            "type": "string"
          },
          "error": {
            "type": "string"
          },
          "latest_epoch": {
            "type": "integer"
          },
          "metered_requests": {
            "type": "integer"
          },
          "ok": {
            "type": "boolean"
          },
          "ready": {
            "type": "boolean"
          },
          "recovery_state": {
            "type": "string"
          },
          "service": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "RecordDeleteRequest": {
        "additionalProperties": true,
        "description": "Delete/tombstone record request.",
        "properties": {
          "id": {
            "type": "string"
          },
          "table": {
            "type": "string"
          },
          "tenant_id": {
            "type": "string"
          },
          "tombstone": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "RecordGetRequest": {
        "additionalProperties": true,
        "description": "Get record request.",
        "properties": {
          "id": {
            "type": "string"
          },
          "table": {
            "type": "string"
          },
          "tenant_id": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "RecordInput": {
        "additionalProperties": true,
        "description": "TraceDB record input.",
        "properties": {
          "fields": {
            "additionalProperties": true,
            "description": "Record field map.",
            "type": "object"
          },
          "id": {
            "type": "string"
          },
          "table": {
            "type": "string"
          },
          "tenant_id": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "RecordOutput": {
        "additionalProperties": false,
        "description": "TraceDB visible record output.",
        "properties": {
          "fields": {
            "additionalProperties": true,
            "description": "Record field map.",
            "type": "object"
          },
          "id": {
            "type": "string"
          },
          "table": {
            "type": "string"
          },
          "tenant_id": {
            "type": "string"
          },
          "version_id": {
            "type": "integer"
          }
        },
        "type": "object"
      },
      "RecordPatchRequest": {
        "additionalProperties": true,
        "description": "Patch record request.",
        "properties": {
          "fields": {
            "additionalProperties": true,
            "description": "Patch field map.",
            "type": "object"
          },
          "id": {
            "type": "string"
          },
          "table": {
            "type": "string"
          },
          "tenant_id": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "RecordPutBatchRequest": {
        "additionalProperties": true,
        "description": "Batch record write.",
        "properties": {
          "include_write_timing": {
            "type": "boolean"
          },
          "records": {
            "items": {
              "$ref": "#/components/schemas/RecordInput"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "RecordPutBody": {
        "description": "Full replacement record write body. The server accepts either RecordInput directly or a wrapper with record.",
        "oneOf": [
          {
            "$ref": "#/components/schemas/RecordInput"
          },
          {
            "$ref": "#/components/schemas/RecordPutRequest"
          }
        ]
      },
      "RecordPutRequest": {
        "additionalProperties": true,
        "description": "Full replacement record write. The server also accepts RecordInput directly.",
        "properties": {
          "record": {
            "$ref": "#/components/schemas/RecordInput"
          }
        },
        "type": "object"
      },
      "RecordScanOutput": {
        "additionalProperties": false,
        "description": "Scan output.",
        "properties": {
          "next_cursor": {
            "type": [
              "string",
              "null"
            ]
          },
          "records": {
            "items": {
              "$ref": "#/components/schemas/RecordOutput"
            },
            "type": "array"
          },
          "returned_count": {
            "type": "integer"
          }
        },
        "type": "object"
      },
      "RecordScanRequest": {
        "additionalProperties": true,
        "description": "Scan records request.",
        "properties": {
          "cursor": {
            "description": "Opaque cursor returned by the previous scan page.",
            "type": [
              "string",
              "null"
            ]
          },
          "limit": {
            "minimum": 0,
            "type": "integer"
          },
          "table": {
            "type": "string"
          },
          "tenant_id": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "RestoreRequest": {
        "additionalProperties": true,
        "description": "Snapshot restore request.",
        "properties": {
          "source": {
            "type": "string"
          },
          "target": {
            "type": "string"
          },
          "verify_record": {
            "$ref": "#/components/schemas/RecordGetRequest"
          }
        },
        "type": "object"
      },
      "RestoreResponse": {
        "additionalProperties": false,
        "description": "Restore response.",
        "properties": {
          "restored": {
            "type": "boolean"
          },
          "source": {
            "type": "string"
          },
          "target": {
            "type": "string"
          },
          "verification": {
            "$ref": "#/components/schemas/RestoreVerification"
          }
        },
        "type": "object"
      },
      "RestoreVerification": {
        "additionalProperties": false,
        "description": "Optional restored-target record verification.",
        "properties": {
          "record": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/RecordOutput"
              },
              {
                "type": "null"
              }
            ]
          },
          "record_visible": {
            "type": "boolean"
          },
          "request": {
            "$ref": "#/components/schemas/RecordGetRequest"
          },
          "status": {
            "enum": [
              "passed",
              "failed"
            ],
            "type": "string"
          }
        },
        "type": "object"
      },
      "SnapshotRequest": {
        "additionalProperties": true,
        "description": "Snapshot creation request.",
        "properties": {
          "target": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "SnapshotResponse": {
        "additionalProperties": false,
        "description": "Snapshot response.",
        "properties": {
          "snapshot": {
            "type": "boolean"
          },
          "target": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "TableSchema": {
        "additionalProperties": true,
        "description": "TraceDB table schema. Names must use GraphQL-safe identifiers; schema apply rejects duplicate columns, overlapping scalar/text/vector columns, reserved TraceDB result metadata fields, and undeclared vector source columns before WAL append.",
        "properties": {
          "name": {
            "type": "string"
          },
          "primary_id_column": {
            "type": "string"
          },
          "scalar_columns": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "tenant_id_column": {
            "type": "string"
          },
          "text_indexed_columns": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "vector_columns": {
            "items": {
              "additionalProperties": true,
              "description": "Vector column schema.",
              "type": "object"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "TraceQlQueryRequest": {
        "additionalProperties": true,
        "description": "Native TraceQL query request.",
        "properties": {
          "query": {
            "type": "string"
          }
        },
        "type": "object"
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "description": "Required by gateway-managed routes; direct local engine development can use any token.",
        "scheme": "bearer",
        "type": "http"
      }
    }
  },
  "info": {
    "description": "SQL compatibility is not implemented.\nInternal TraceDB-only runs are development evidence; exported performance claims require an external control and a number to beat.\nIdempotency-Key supports local data-dir replay from WAL/checkpoint-backed idempotency receipts for mutation and admin routes, plus polymorphic native operation routes; SDK idempotent retries are opt-in and require an Idempotency-Key; cross-replica, managed-cloud exactly-once, and crash-atomic exactly-once idempotency remain future work.",
    "title": "TraceDB v1 HTTP API",
    "version": "0.1.0-development"
  },
  "openapi": "3.1.0",
  "paths": {
    "/v1/admin/compact": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postAdminCompact",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EmptyObject"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CompactResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Compact local engine state",
        "tags": [
          "admin"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Mutating/admin route: SDK safe retries are disabled; retry transient failures only when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "mutates"
      }
    },
    "/v1/admin/jobs": {
      "get": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "getAdminJobs",
        "parameters": [
          {
            "description": "Canonical managed-routing database identifier for bodyless routes. SDKs must use this parameter name (not db_id, databaseId, or similar variants) so all SDKs target the same gateway routing key.",
            "in": "query",
            "name": "database_id",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Canonical managed-routing branch identifier for bodyless routes. SDKs must use this parameter name (not br_id, branchId, or similar variants) so all SDKs target the same gateway routing key.",
            "in": "query",
            "name": "branch_id",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/JobsResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "List admin jobs",
        "tags": [
          "admin"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "SDK safe retries are disabled for this route.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/admin/restore": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postAdminRestore",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RestoreRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RestoreResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Restore snapshot",
        "tags": [
          "admin"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Mutating/admin route: SDK safe retries are disabled; retry transient failures only when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "mutates"
      }
    },
    "/v1/admin/snapshot": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postAdminSnapshot",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SnapshotRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SnapshotResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Create snapshot",
        "tags": [
          "admin"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Mutating/admin route: SDK safe retries are disabled; retry transient failures only when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "mutates"
      }
    },
    "/v1/branches": {
      "get": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "getBranches",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BranchesResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "List branches",
        "tags": [
          "catalog"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "SDK safe retries are disabled for this route.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/databases": {
      "get": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "getDatabases",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DatabasesResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "List databases",
        "tags": [
          "catalog"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "SDK safe retries are disabled for this route.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/explain": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postExplain",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/HybridQuery"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HybridExplain"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Explain hybrid query",
        "tags": [
          "query"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": true,
        "x-tracedb-sdk-safe-retry-policy": "Read-only route: SDK safe retries may retry transient failures.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/graphql": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postGraphql",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GraphQlQueryRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GraphQlResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Run native GraphQL query, mutation, or admin operation",
        "tags": [
          "query"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": true,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Polymorphic operation route: SDK safe retries are not blanket-enabled. Retry only when the payload is provably read-only, or when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "polymorphic-read-or-mutate"
      }
    },
    "/v1/graphql/bounded": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postGraphqlBounded",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GraphQlQueryRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QueryResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Run bounded GraphQL compatibility query adapter",
        "tags": [
          "query"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": true,
        "x-tracedb-sdk-safe-retry-policy": "Read-only route: SDK safe retries may retry transient failures.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/graphql/schema": {
      "get": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "getGraphqlSchema",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GraphQlSchemaResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Export bounded GraphQL schema",
        "tags": [
          "query"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": true,
        "x-tracedb-sdk-safe-retry-policy": "Read-only route: SDK safe retries may retry transient failures.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/health": {
      "get": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "getHealth",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HealthResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Health check",
        "tags": [
          "health"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": true,
        "x-tracedb-sdk-safe-retry-policy": "Read-only route: SDK safe retries may retry transient failures.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/insert": {
      "post": {
        "deprecated": true,
        "description": "Deprecated. Use POST /v1/records/put instead. This route remains for backwards compatibility and will be removed in a future release.",
        "operationId": "postInsert",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RecordInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EpochResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Insert record compatibility route",
        "tags": [
          "records"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Mutating/admin route: SDK safe retries are disabled; retry transient failures only when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "mutates"
      }
    },
    "/v1/metrics/public-safe": {
      "get": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "getMetricsPublicSafe",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MetricsResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Read public-safe metrics",
        "tags": [
          "metrics"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "SDK safe retries are disabled for this route.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/query": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postQuery",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/HybridQuery"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QueryResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Run hybrid query",
        "tags": [
          "query"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": true,
        "x-tracedb-sdk-safe-retry-policy": "Read-only route: SDK safe retries may retry transient failures.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/ready": {
      "get": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "getReady",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReadyResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Readiness check",
        "tags": [
          "readiness"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": true,
        "x-tracedb-sdk-safe-retry-policy": "Read-only route: SDK safe retries may retry transient failures.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/records/delete": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postRecordsDelete",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RecordDeleteRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DeleteResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Delete record",
        "tags": [
          "records"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Mutating/admin route: SDK safe retries are disabled; retry transient failures only when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "mutates"
      }
    },
    "/v1/records/get": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postRecordsGet",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RecordGetRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetRecordResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Get record",
        "tags": [
          "records"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": true,
        "x-tracedb-sdk-safe-retry-policy": "Read-only route: SDK safe retries may retry transient failures.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/records/patch": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postRecordsPatch",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RecordPatchRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EpochResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Patch record",
        "tags": [
          "records"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Mutating/admin route: SDK safe retries are disabled; retry transient failures only when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "mutates"
      }
    },
    "/v1/records/put": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postRecordsPut",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RecordPutBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EpochResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Put record",
        "tags": [
          "records"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Mutating/admin route: SDK safe retries are disabled; retry transient failures only when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "mutates"
      }
    },
    "/v1/records/put-batch": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postRecordsPutBatch",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RecordPutBatchRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PutBatchResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Put record batch",
        "tags": [
          "records"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Mutating/admin route: SDK safe retries are disabled; retry transient failures only when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "mutates"
      }
    },
    "/v1/records/scan": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postRecordsScan",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RecordScanRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RecordScanOutput"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Scan records",
        "tags": [
          "records"
        ],
        "x-tracedb-idempotency-key-supported": false,
        "x-tracedb-mutates-state": false,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": false,
        "x-tracedb-sdk-safe-retry": true,
        "x-tracedb-sdk-safe-retry-policy": "Read-only route: SDK safe retries may retry transient failures.",
        "x-tracedb-state-effect": "read-only"
      }
    },
    "/v1/schema/apply": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postSchemaApply",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TableSchema"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EpochResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Apply table schema",
        "tags": [
          "schema"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": false,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Mutating/admin route: SDK safe retries are disabled; retry transient failures only when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "mutates"
      }
    },
    "/v1/traceql": {
      "post": {
        "description": "Current TraceDB v1 product route. This OpenAPI artifact is generated from the checked-in route manifest.",
        "operationId": "postTraceql",
        "parameters": [
          {
            "description": "Optional local data-dir replay key scoped by method and path. Receipts are WAL/checkpoint-backed in the local engine. same key plus same raw request body replays the first successful response; same key with a different body returns 409 Conflict.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TraceQlQueryRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QueryResponse"
                }
              }
            },
            "description": "Successful TraceDB response."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Bad request or validation failure."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Unauthorized gateway request."
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Route not found."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Idempotency key was reused with a different request body."
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway rate limit exceeded."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Engine or gateway failure."
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Gateway upstream failure."
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            },
            "description": "Service unavailable."
          }
        },
        "summary": "Run native TraceQL query or command",
        "tags": [
          "query"
        ],
        "x-tracedb-idempotency-durability": "local-data-dir-reopen",
        "x-tracedb-idempotency-key-supported": true,
        "x-tracedb-mutates-state": true,
        "x-tracedb-polymorphic-operation-route": true,
        "x-tracedb-sdk-idempotency-retry-supported": true,
        "x-tracedb-sdk-safe-retry": false,
        "x-tracedb-sdk-safe-retry-policy": "Polymorphic operation route: SDK safe retries are not blanket-enabled. Retry only when the payload is provably read-only, or when the caller supplies Idempotency-Key and idempotency retry is enabled.",
        "x-tracedb-state-effect": "polymorphic-read-or-mutate"
      }
    }
  },
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "servers": [
    {
      "description": "Local tracedb-server",
      "url": "http://127.0.0.1:8090"
    },
    {
      "description": "Current Railway alpha engine",
      "url": "https://tracedb-engine-production.up.railway.app"
    }
  ],
  "tags": [
    {
      "name": "health"
    },
    {
      "name": "readiness"
    },
    {
      "name": "catalog"
    },
    {
      "name": "metrics"
    },
    {
      "name": "schema"
    },
    {
      "name": "records"
    },
    {
      "name": "query"
    },
    {
      "name": "admin"
    }
  ],
  "x-tracedb-generated-by": "scripts/generate_openapi_v1.py"
}