{
  "openapi": "3.1.0",
  "info": {
    "title": "Ocho public site API",
    "version": "1.0.0",
    "summary": "Read-only content, search, and contact endpoints for ocho.bot.",
    "description": "Ocho is an AI knowledge orchestration platform for enterprise teams — it turns sprawling documents, meeting transcripts, and app content into a single, cited knowledge base (chat, search, knowledge graph, and workflows).\n\nThis spec covers the **public website API**: blog posts, documentation pages, site search, machine-readable discovery files, and the demo-request endpoint. All content endpoints are read-only and require no authentication; only published documents are returned.\n\n**Rate limits.** REST content reads have no hard per-client limit today — be a good citizen (≤ 2 req/s sustained). `POST /api/graphql` is limited to 120 requests per IP per 60 s and `POST /api/contact` to 5 per IP per 60 s; both return standard `RateLimit-*` headers plus `Retry-After` on 429.\n\n**Markdown negotiation.** Every public HTML page also serves a Markdown variant via `Accept: text/markdown` (responses vary on Accept).\n\n**Product access for agents.** To operate Ocho itself (datasets, chat, workflows), use the MCP server at https://mcp.ocho.bot (OAuth 2.1, Streamable HTTP). This website API does not expose product data.",
    "contact": {
      "name": "Ocho",
      "email": "hello@ocho.bot",
      "url": "https://ocho.bot/contact"
    }
  },
  "servers": [
    {
      "url": "https://ocho.bot",
      "description": "Production"
    }
  ],
  "externalDocs": {
    "description": "Ocho developer resources",
    "url": "https://ocho.bot/developers"
  },
  "tags": [
    {
      "name": "content",
      "description": "Read-only published content (Payload CMS REST)."
    },
    {
      "name": "search",
      "description": "Site-wide content search index."
    },
    {
      "name": "leads",
      "description": "Demo requests and contact."
    },
    {
      "name": "graphql",
      "description": "GraphQL access to the same content collections."
    },
    {
      "name": "discovery",
      "description": "Machine-readable discovery documents for crawlers and agents."
    }
  ],
  "paths": {
    "/api/posts": {
      "get": {
        "operationId": "listPosts",
        "tags": [
          "content"
        ],
        "summary": "List published blog posts",
        "description": "Returns published blog posts, newest first when sorted by `-publishedAt`. Rendered pages live under https://ocho.bot/blog/{slug}.",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "description": "Number of posts per page (default 10).",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 10
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, starting at 1.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "default": 1
            }
          },
          {
            "name": "depth",
            "in": "query",
            "description": "Relationship population depth. 0 returns IDs only; 1–2 embed related documents (categories, media…).",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "maximum": 2,
              "default": 1
            }
          },
          {
            "name": "sort",
            "in": "query",
            "description": "Field to sort by; prefix with \"-\" for descending (e.g. \"-publishedAt\").",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "where",
            "in": "query",
            "style": "deepObject",
            "explode": true,
            "description": "Payload CMS query filter, bracket-encoded. Example: `where[slug][equals]=what-is-agentic-ingestion`. Operators include equals, not_equals, in, contains, like, greater_than, less_than. Only published documents are visible without authentication.",
            "schema": {
              "type": "object",
              "additionalProperties": true
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Paginated blog posts.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "description": "Payload CMS paginated result set.",
                  "required": [
                    "docs",
                    "totalDocs",
                    "page",
                    "totalPages"
                  ],
                  "properties": {
                    "docs": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Post"
                      }
                    },
                    "totalDocs": {
                      "type": "integer"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "totalPages": {
                      "type": "integer"
                    },
                    "page": {
                      "type": "integer"
                    },
                    "pagingCounter": {
                      "type": "integer"
                    },
                    "hasPrevPage": {
                      "type": "boolean"
                    },
                    "hasNextPage": {
                      "type": "boolean"
                    },
                    "prevPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    },
                    "nextPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/posts/{id}": {
      "get": {
        "operationId": "getPostById",
        "tags": [
          "content"
        ],
        "summary": "Get one blog post by ID",
        "description": "Fetch a single published post by numeric ID. To fetch by slug, use `GET /api/posts?where[slug][equals]={slug}` instead.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "Numeric post ID.",
            "schema": {
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The blog post.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Post"
                }
              }
            }
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/api/docs": {
      "get": {
        "operationId": "listDocs",
        "tags": [
          "content"
        ],
        "summary": "List published documentation pages",
        "description": "Returns published product documentation. Rendered pages live under https://ocho.bot/docs/{category}/{slug}; a full link index is at /llms.txt.",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "description": "Number of documentation pages per page (default 10).",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 10
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, starting at 1.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "default": 1
            }
          },
          {
            "name": "depth",
            "in": "query",
            "description": "Relationship population depth. 0 returns IDs only; 1–2 embed related documents (categories, media…).",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "maximum": 2,
              "default": 1
            }
          },
          {
            "name": "sort",
            "in": "query",
            "description": "Field to sort by; prefix with \"-\" for descending (e.g. \"-publishedAt\").",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "where",
            "in": "query",
            "style": "deepObject",
            "explode": true,
            "description": "Payload CMS query filter, bracket-encoded. Example: `where[slug][equals]=what-is-agentic-ingestion`. Operators include equals, not_equals, in, contains, like, greater_than, less_than. Only published documents are visible without authentication.",
            "schema": {
              "type": "object",
              "additionalProperties": true
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Paginated documentation pages.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "description": "Payload CMS paginated result set.",
                  "required": [
                    "docs",
                    "totalDocs",
                    "page",
                    "totalPages"
                  ],
                  "properties": {
                    "docs": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Doc"
                      }
                    },
                    "totalDocs": {
                      "type": "integer"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "totalPages": {
                      "type": "integer"
                    },
                    "page": {
                      "type": "integer"
                    },
                    "pagingCounter": {
                      "type": "integer"
                    },
                    "hasPrevPage": {
                      "type": "boolean"
                    },
                    "hasNextPage": {
                      "type": "boolean"
                    },
                    "prevPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    },
                    "nextPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/pages": {
      "get": {
        "operationId": "listPages",
        "tags": [
          "content"
        ],
        "summary": "List published CMS pages",
        "description": "Returns published layout-builder pages (marketing pages managed in the CMS).",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "description": "Number of pages per page (default 10).",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 10
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, starting at 1.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "default": 1
            }
          },
          {
            "name": "depth",
            "in": "query",
            "description": "Relationship population depth. 0 returns IDs only; 1–2 embed related documents (categories, media…).",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "maximum": 2,
              "default": 1
            }
          },
          {
            "name": "sort",
            "in": "query",
            "description": "Field to sort by; prefix with \"-\" for descending (e.g. \"-publishedAt\").",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "where",
            "in": "query",
            "style": "deepObject",
            "explode": true,
            "description": "Payload CMS query filter, bracket-encoded. Example: `where[slug][equals]=what-is-agentic-ingestion`. Operators include equals, not_equals, in, contains, like, greater_than, less_than. Only published documents are visible without authentication.",
            "schema": {
              "type": "object",
              "additionalProperties": true
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Paginated CMS pages.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "description": "Payload CMS paginated result set.",
                  "required": [
                    "docs",
                    "totalDocs",
                    "page",
                    "totalPages"
                  ],
                  "properties": {
                    "docs": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Page"
                      }
                    },
                    "totalDocs": {
                      "type": "integer"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "totalPages": {
                      "type": "integer"
                    },
                    "page": {
                      "type": "integer"
                    },
                    "pagingCounter": {
                      "type": "integer"
                    },
                    "hasPrevPage": {
                      "type": "boolean"
                    },
                    "hasNextPage": {
                      "type": "boolean"
                    },
                    "prevPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    },
                    "nextPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/categories": {
      "get": {
        "operationId": "listCategories",
        "tags": [
          "content"
        ],
        "summary": "List content categories",
        "description": "Categories used to group blog posts and documentation sections.",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "description": "Number of categories per page (default 10).",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 10
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, starting at 1.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "default": 1
            }
          },
          {
            "name": "depth",
            "in": "query",
            "description": "Relationship population depth. 0 returns IDs only; 1–2 embed related documents (categories, media…).",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "maximum": 2,
              "default": 1
            }
          },
          {
            "name": "sort",
            "in": "query",
            "description": "Field to sort by; prefix with \"-\" for descending (e.g. \"-publishedAt\").",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "where",
            "in": "query",
            "style": "deepObject",
            "explode": true,
            "description": "Payload CMS query filter, bracket-encoded. Example: `where[slug][equals]=what-is-agentic-ingestion`. Operators include equals, not_equals, in, contains, like, greater_than, less_than. Only published documents are visible without authentication.",
            "schema": {
              "type": "object",
              "additionalProperties": true
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Paginated categories.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "description": "Payload CMS paginated result set.",
                  "required": [
                    "docs",
                    "totalDocs",
                    "page",
                    "totalPages"
                  ],
                  "properties": {
                    "docs": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Category"
                      }
                    },
                    "totalDocs": {
                      "type": "integer"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "totalPages": {
                      "type": "integer"
                    },
                    "page": {
                      "type": "integer"
                    },
                    "pagingCounter": {
                      "type": "integer"
                    },
                    "hasPrevPage": {
                      "type": "boolean"
                    },
                    "hasNextPage": {
                      "type": "boolean"
                    },
                    "prevPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    },
                    "nextPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/search": {
      "get": {
        "operationId": "searchContent",
        "tags": [
          "search"
        ],
        "summary": "Search indexed site content",
        "description": "Queries the site search index (titles + metadata of published posts and pages). Filter with `where[title][like]={term}`.",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "description": "Number of search results per page (default 10).",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 10
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, starting at 1.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "default": 1
            }
          },
          {
            "name": "depth",
            "in": "query",
            "description": "Relationship population depth. 0 returns IDs only; 1–2 embed related documents (categories, media…).",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "maximum": 2,
              "default": 1
            }
          },
          {
            "name": "sort",
            "in": "query",
            "description": "Field to sort by; prefix with \"-\" for descending (e.g. \"-publishedAt\").",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "where",
            "in": "query",
            "style": "deepObject",
            "explode": true,
            "description": "Payload CMS query filter, bracket-encoded. Example: `where[slug][equals]=what-is-agentic-ingestion`. Operators include equals, not_equals, in, contains, like, greater_than, less_than. Only published documents are visible without authentication.",
            "schema": {
              "type": "object",
              "additionalProperties": true
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Paginated search results.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "description": "Payload CMS paginated result set.",
                  "required": [
                    "docs",
                    "totalDocs",
                    "page",
                    "totalPages"
                  ],
                  "properties": {
                    "docs": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/SearchResult"
                      }
                    },
                    "totalDocs": {
                      "type": "integer"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "totalPages": {
                      "type": "integer"
                    },
                    "page": {
                      "type": "integer"
                    },
                    "pagingCounter": {
                      "type": "integer"
                    },
                    "hasPrevPage": {
                      "type": "boolean"
                    },
                    "hasNextPage": {
                      "type": "boolean"
                    },
                    "prevPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    },
                    "nextPage": {
                      "type": [
                        "integer",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/contact": {
      "post": {
        "operationId": "submitContactLead",
        "tags": [
          "leads"
        ],
        "summary": "Request a demo / contact the Ocho team",
        "description": "Submits a demo request to the Ocho team (the same endpoint the /contact form uses). Rate limit: 5 requests per IP per 60 s, advertised via RateLimit-* response headers. A human follows up by email — this endpoint does not create product accounts.",
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional client-supplied key. Retrying with the same key within an hour replays the original success instead of creating a duplicate lead.",
            "schema": {
              "type": "string",
              "maxLength": 200
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ContactSubmission"
              },
              "example": {
                "fullName": "Dana Smith",
                "workEmail": "dana@example.com",
                "company": "Example Corp",
                "teamSize": "51-200",
                "automationTarget": "Turn our SharePoint policy library into a cited knowledge base."
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Submission accepted.",
            "headers": {
              "RateLimit-Limit": {
                "$ref": "#/components/headers/RateLimitLimit"
              },
              "RateLimit-Remaining": {
                "$ref": "#/components/headers/RateLimitRemaining"
              },
              "RateLimit-Reset": {
                "$ref": "#/components/headers/RateLimitReset"
              },
              "RateLimit-Policy": {
                "$ref": "#/components/headers/RateLimitPolicy"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ContactResponse"
                }
              }
            }
          },
          "400": {
            "description": "Validation failed (missing name, invalid email…).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ContactResponse"
                }
              }
            }
          },
          "429": {
            "description": "Rate limit exceeded. Honor Retry-After before retrying.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              },
              "RateLimit-Limit": {
                "$ref": "#/components/headers/RateLimitLimit"
              },
              "RateLimit-Remaining": {
                "$ref": "#/components/headers/RateLimitRemaining"
              },
              "RateLimit-Reset": {
                "$ref": "#/components/headers/RateLimitReset"
              },
              "RateLimit-Policy": {
                "$ref": "#/components/headers/RateLimitPolicy"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ContactResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/graphql": {
      "post": {
        "operationId": "graphqlQuery",
        "tags": [
          "graphql"
        ],
        "summary": "GraphQL endpoint for the content collections",
        "description": "GraphQL access to the same published content as the REST endpoints (Posts, Docs, Pages, Categories). Introspection is enabled — type your queries against the live schema. Conventions: fully typed schema; errors return an errors array with message and location; page-based pagination via limit/page arguments with totalPages and hasNextPage in every result set; fields are deprecated with @deprecated before removal; all operations are synchronous. Rate limit: 120 requests per IP per 60 s, advertised via RateLimit-* response headers with Retry-After on 429; no authentication required for published content.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "query"
                ],
                "properties": {
                  "query": {
                    "type": "string",
                    "description": "GraphQL query string."
                  },
                  "variables": {
                    "type": "object",
                    "additionalProperties": true
                  },
                  "operationName": {
                    "type": "string"
                  }
                }
              },
              "example": {
                "query": "{ Posts(limit: 5, sort: \"-publishedAt\") { docs { title slug publishedAt } } }"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "GraphQL result (may contain an errors array).",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": [
                        "object",
                        "null"
                      ],
                      "additionalProperties": true
                    },
                    "errors": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "additionalProperties": true
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/openapi.json": {
      "get": {
        "operationId": "getOpenApiSpec",
        "tags": [
          "discovery"
        ],
        "summary": "This OpenAPI document",
        "description": "The machine-readable description of the public ocho.bot HTTP surface.",
        "responses": {
          "200": {
            "description": "OpenAPI 3.1 JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/llms.txt": {
      "get": {
        "operationId": "getLlmsIndex",
        "tags": [
          "discovery"
        ],
        "summary": "llms.txt index for AI agents",
        "description": "Product summary, when-to-use guidance for agents, and a curated link index (llmstxt.org format).",
        "responses": {
          "200": {
            "description": "llms.txt markdown.",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/llms-full.txt": {
      "get": {
        "operationId": "getLlmsFullContent",
        "tags": [
          "discovery"
        ],
        "summary": "Full documentation corpus as plain text",
        "description": "Every published documentation page concatenated for LLM consumption.",
        "responses": {
          "200": {
            "description": "Full docs corpus.",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/sitemap.xml": {
      "get": {
        "operationId": "getSitemap",
        "tags": [
          "discovery"
        ],
        "summary": "XML sitemap",
        "description": "All indexable public URLs, regenerated at request time from the CMS.",
        "responses": {
          "200": {
            "description": "Sitemap XML.",
            "content": {
              "application/xml": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/blog/rss.xml": {
      "get": {
        "operationId": "getBlogFeed",
        "tags": [
          "discovery"
        ],
        "summary": "Blog RSS feed",
        "description": "RSS 2.0 feed of the Ocho blog.",
        "responses": {
          "200": {
            "description": "RSS XML.",
            "content": {
              "application/rss+xml": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "LexicalContent": {
        "type": "object",
        "description": "Rich text as Payload Lexical JSON (root node tree). For a plain-text rendition, request the rendered page with `Accept: text/markdown` instead.",
        "properties": {
          "root": {
            "type": "object",
            "additionalProperties": true
          }
        },
        "additionalProperties": true
      },
      "Meta": {
        "type": "object",
        "description": "SEO metadata for a document.",
        "properties": {
          "title": {
            "type": [
              "string",
              "null"
            ]
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "image": {
            "oneOf": [
              {
                "type": "integer"
              },
              {
                "type": "object",
                "additionalProperties": true
              },
              {
                "type": "null"
              }
            ]
          }
        }
      },
      "Post": {
        "type": "object",
        "description": "A blog post. Rendered at /blog/{slug}.",
        "required": [
          "id",
          "title",
          "slug"
        ],
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "content": {
            "$ref": "#/components/schemas/LexicalContent"
          },
          "meta": {
            "$ref": "#/components/schemas/Meta"
          },
          "categories": {
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "type": "integer"
                },
                {
                  "$ref": "#/components/schemas/Category"
                }
              ]
            }
          },
          "publishedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "additionalProperties": true
      },
      "Doc": {
        "type": "object",
        "description": "A documentation page. Rendered under /docs/{category}/{slug}.",
        "required": [
          "id",
          "title",
          "slug"
        ],
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "category": {
            "oneOf": [
              {
                "type": "integer"
              },
              {
                "$ref": "#/components/schemas/Category"
              },
              {
                "type": "null"
              }
            ]
          },
          "parent": {
            "oneOf": [
              {
                "type": "integer"
              },
              {
                "type": "object",
                "additionalProperties": true
              },
              {
                "type": "null"
              }
            ]
          },
          "order": {
            "type": [
              "integer",
              "null"
            ]
          },
          "content": {
            "$ref": "#/components/schemas/LexicalContent"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "additionalProperties": true
      },
      "Page": {
        "type": "object",
        "description": "A layout-builder CMS page.",
        "required": [
          "id",
          "title"
        ],
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": [
              "string",
              "null"
            ]
          },
          "layout": {
            "type": "array",
            "description": "Ordered content blocks.",
            "items": {
              "type": "object",
              "additionalProperties": true
            }
          },
          "meta": {
            "$ref": "#/components/schemas/Meta"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "additionalProperties": true
      },
      "Category": {
        "type": "object",
        "description": "A content category.",
        "required": [
          "id",
          "title"
        ],
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": "string"
          },
          "slug": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "additionalProperties": true
      },
      "SearchResult": {
        "type": "object",
        "description": "A site search index entry pointing at the underlying document.",
        "properties": {
          "id": {
            "type": "integer"
          },
          "title": {
            "type": [
              "string",
              "null"
            ]
          },
          "priority": {
            "type": [
              "number",
              "null"
            ]
          },
          "doc": {
            "type": "object",
            "description": "Polymorphic reference to the indexed document.",
            "properties": {
              "relationTo": {
                "type": "string",
                "enum": [
                  "posts",
                  "pages"
                ]
              },
              "value": {
                "oneOf": [
                  {
                    "type": "integer"
                  },
                  {
                    "type": "object",
                    "additionalProperties": true
                  }
                ]
              }
            }
          },
          "meta": {
            "$ref": "#/components/schemas/Meta"
          }
        },
        "additionalProperties": true
      },
      "ContactSubmission": {
        "type": "object",
        "description": "A demo request from a prospective customer.",
        "required": [
          "fullName",
          "workEmail",
          "company"
        ],
        "properties": {
          "fullName": {
            "type": "string",
            "maxLength": 200,
            "description": "Your full name."
          },
          "workEmail": {
            "type": "string",
            "format": "email",
            "maxLength": 200,
            "description": "Work email address the team should reply to."
          },
          "company": {
            "type": "string",
            "maxLength": 200,
            "description": "Company or organization name."
          },
          "teamSize": {
            "type": "string",
            "enum": [
              "1-10",
              "11-50",
              "51-200",
              "201-1000",
              "1000+"
            ],
            "description": "Approximate team size."
          },
          "automationTarget": {
            "type": "string",
            "maxLength": 2000,
            "description": "Optional: what you want Ocho to take over — sources, use case, outcome."
          },
          "phone": {
            "type": "string",
            "maxLength": 50,
            "description": "Optional phone number."
          }
        },
        "additionalProperties": false
      },
      "ContactResponse": {
        "type": "object",
        "required": [
          "ok"
        ],
        "properties": {
          "ok": {
            "type": "boolean"
          },
          "error": {
            "type": "string",
            "description": "Top-level error message, when ok is false."
          },
          "errors": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "Per-field validation messages, when validation failed."
          }
        }
      },
      "Error": {
        "type": "object",
        "properties": {
          "errors": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "message": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "headers": {
      "RateLimitLimit": {
        "description": "Requests allowed in the current window.",
        "schema": {
          "type": "integer"
        }
      },
      "RateLimitRemaining": {
        "description": "Requests remaining in the current window.",
        "schema": {
          "type": "integer"
        }
      },
      "RateLimitReset": {
        "description": "Seconds until the current window resets.",
        "schema": {
          "type": "integer"
        }
      },
      "RateLimitPolicy": {
        "description": "Quota policy, e.g. \"5;w=60\" (5 requests per 60-second window).",
        "schema": {
          "type": "string"
        }
      }
    },
    "responses": {
      "NotFound": {
        "description": "Document not found or not published.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      }
    }
  }
}