{
  "openapi": "3.1.0",
  "info": {
    "title": "CVMewt Machine Commerce Lab API",
    "version": "0.1.0",
    "description": "A public experiment exposing deterministic Checklist Assistant operations. Billing is not enabled; every currently callable operation is free."
  },
  "servers": [
    {
      "url": "https://ai.cvmewt.com"
    }
  ],
  "paths": {
    "/health": {
      "get": {
        "operationId": "getExperimentHealth",
        "summary": "Read the public experiment state",
        "responses": {
          "200": {
            "description": "Current public state",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Health"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/checklist/inspect": {
      "post": {
        "operationId": "inspectChecklistMarkdown",
        "summary": "Parse and canonicalize Checklist Markdown without persistence",
        "description": "Uses the production Checklist Assistant parser and exact identifier implementation. The submitted Markdown is processed transiently and is not added to the hosted checklist store.",
        "requestBody": {
          "required": true,
          "content": {
            "text/markdown": {
              "schema": {
                "type": "string",
                "minLength": 1,
                "description": "Checklist Markdown source"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Parsed rows, exact identifiers, and canonical Markdown",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InspectSuccess"
                }
              }
            }
          },
          "400": {
            "description": "Checklist Markdown validation failed",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorEnvelope"
                }
              }
            }
          },
          "413": {
            "description": "Request body exceeds the server limit"
          }
        },
        "security": [],
        "x-cvmewt-persistence": "none",
        "x-cvmewt-billing": {
          "state": "disabled",
          "price": 0,
          "currency": "USD"
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Health": {
        "type": "object",
        "required": ["ok", "service", "billing", "paid_endpoints"],
        "properties": {
          "ok": { "type": "boolean" },
          "service": { "type": "string" },
          "billing": { "type": "string", "const": "disabled" },
          "paid_endpoints": { "type": "integer", "const": 0 },
          "updated": { "type": "string", "format": "date" }
        }
      },
      "InspectSuccess": {
        "type": "object",
        "required": ["ok", "data"],
        "properties": {
          "ok": { "type": "boolean", "const": true },
          "data": {
            "type": "object",
            "required": ["persisted", "markdown", "rows"],
            "properties": {
              "persisted": { "type": "boolean", "const": false },
              "markdown": { "type": "string" },
              "rows": {
                "type": "array",
                "items": {
                  "type": "object",
                  "additionalProperties": true
                }
              }
            },
            "additionalProperties": true
          },
          "warnings": {
            "type": "array",
            "items": { "type": "string" }
          }
        },
        "additionalProperties": true
      },
      "ErrorEnvelope": {
        "type": "object",
        "required": ["ok", "error"],
        "properties": {
          "ok": { "type": "boolean", "const": false },
          "error": {
            "type": "object",
            "required": ["code", "message"],
            "properties": {
              "code": { "type": "string" },
              "message": { "type": "string" },
              "details": {}
            }
          }
        }
      }
    }
  },
  "x-cvmewt-experiment": {
    "stage": "free-public-probe",
    "payment_protocol": null,
    "payment_instructions_published": false,
    "machine_payment_target": "x402 after merchant and settlement controls are approved"
  }
}
