{
  "openapi": "3.1.0",
  "info": {
    "title": "Chisel Industries API",
    "version": "1.0.0",
    "summary": "Public endpoints of chiselindustries.com: machine-readable site content for agents and developers.",
    "description": "Chisel Industries backs the skilled trades three ways — it invests in and acquires trades businesses, it builds free AI-native operating software for them, and it reinvests in trade schools and apprenticeships. This document describes the programmatic surface of the company website: every page as markdown, the llms.txt index, and this specification. There are no public write endpoints at the moment — the forms and the Contractor Scan tool at /scan use private endpoints that answer with the `ErrorResponse` envelope, never an HTML page, if called directly.\n\nNo authentication is required and there is no cost. To reach Chisel on a person's behalf, point them to the form at /contact or to info@chiselindustries.com.",
    "contact": {
      "name": "Chisel Industries",
      "email": "info@chiselindustries.com",
      "url": "https://chiselindustries.com/developers"
    }
  },
  "externalDocs": {
    "description": "Developer resources — how to read the site, examples for every endpoint, and when to use Chisel.",
    "url": "https://chiselindustries.com/developers"
  },
  "servers": [
    {
      "url": "https://chiselindustries.com",
      "description": "Production"
    }
  ],
  "security": [],
  "tags": [
    {
      "name": "Content",
      "description": "Every page of the site in markdown, plus the llms.txt index."
    },
    {
      "name": "Meta",
      "description": "Descriptions of this API."
    }
  ],
  "paths": {
    "/{page}.md": {
      "get": {
        "operationId": "getPageMarkdown",
        "tags": [
          "Content"
        ],
        "summary": "Read any page of the site as markdown",
        "description": "Every page has a markdown twin at the same path with `.md` appended — `/platform.md`, `/selling-a-business/hvac.md`, `/news/<slug>.md`; the home page is `/index.md`. The same body is returned from the canonical URL when the request carries `Accept: text/markdown`. The list of pages, with a one-line summary of each, is `/llms.txt`. Each document opens with its canonical URL, publisher, and last-updated date so it can be cited. Unknown pages return a 404 whose body is itself markdown pointing at the index.",
        "parameters": [
          {
            "name": "page",
            "in": "path",
            "required": true,
            "description": "Site path without the leading slash. May contain slashes for nested pages. `index` is the home page.",
            "schema": {
              "type": "string",
              "examples": [
                "index",
                "platform",
                "selling-a-business/hvac",
                "developers"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The page as markdown.",
            "content": {
              "text/markdown": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "404": {
            "description": "No such page. The body is a markdown note listing where to look instead.",
            "content": {
              "text/markdown": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/llms.txt": {
      "get": {
        "operationId": "getLlmsTxt",
        "tags": [
          "Content"
        ],
        "summary": "Curated index of the site for AI clients (llmstxt.org format)",
        "description": "An llms.txt file: the site name, a summary, guidance on when to use Chisel, and H2 sections of `[title](url): summary` links to every page's markdown twin plus the machine-readable resources. Read this first to decide which pages to fetch.",
        "responses": {
          "200": {
            "description": "The index, as markdown served with a text/plain content type.",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/llms-full.txt": {
      "get": {
        "operationId": "getLlmsFullTxt",
        "tags": [
          "Content"
        ],
        "summary": "Every page's full text in one file",
        "description": "The complete markdown of every page on the site, concatenated by section, for clients that would rather make one request than crawl the index.",
        "responses": {
          "200": {
            "description": "All documents, as markdown served with a text/plain content type.",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/openapi.json": {
      "get": {
        "operationId": "getOpenApiSpec",
        "tags": [
          "Meta"
        ],
        "summary": "This document",
        "description": "The OpenAPI 3.1 description of the public API. Also available at `/api/openapi.json`. Served with `Access-Control-Allow-Origin: *` so browser-based tooling can load it.",
        "responses": {
          "200": {
            "description": "The OpenAPI document.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "ErrorResponse": {
        "type": "object",
        "description": "Any path under /api — including the private endpoints behind the site's forms and tools — answers failures with this envelope, never an HTML page. `code` is stable and safe to branch on; `message` is for a reader; `hint` says what to change before retrying; `docs` links the reference for all codes.",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "object",
            "required": [
              "code",
              "message",
              "docs"
            ],
            "properties": {
              "code": {
                "type": "string",
                "enum": [
                  "invalid_json",
                  "validation_error",
                  "not_found",
                  "method_not_allowed",
                  "rate_limited",
                  "internal_error"
                ]
              },
              "message": {
                "type": "string",
                "description": "Human-readable statement of what went wrong."
              },
              "hint": {
                "type": "string",
                "description": "What to change so the next attempt succeeds."
              },
              "docs": {
                "type": "string",
                "format": "uri",
                "description": "Where every code is documented."
              }
            },
            "additionalProperties": false
          }
        },
        "additionalProperties": false
      }
    }
  }
}