{"openapi":"3.1.1","jsonSchemaDialect":"https://json-schema.org/draft/2020-12/schema","info":{"title":"Darkroom Engineering Public Content API","version":"1.0.0","description":"Read-only access to public darkroom.engineering page content for agents, search tools, and developer integrations.","license":{"name":"MIT","identifier":"MIT"}},"servers":[{"url":"https://darkroom.engineering"}],"paths":{"/api/content":{"get":{"operationId":"getSiteContent","summary":"Get public site content as Markdown","description":"Returns the Markdown representation of a public darkroom.engineering page. Omit path to retrieve the homepage. This operation is public, read-only, and requires no authentication.","security":[],"parameters":[{"name":"path","in":"query","required":false,"description":"A same-origin site path beginning with '/'. Defaults to the homepage. Use paths published in the sitemap.","schema":{"type":"string","minLength":1,"maxLength":2048,"default":"/","examples":["/","/about","/work"]}}],"responses":{"200":{"description":"The requested public page represented as Markdown with its canonical URL.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContentResponse"},"examples":{"homepage":{"summary":"Homepage content","value":{"data":{"path":"/","canonical":"https://darkroom.engineering/","contentType":"text/markdown","body":"# Darkroom Engineering\n\nDarkroom is a development studio..."},"error":null}}}}}},"400":{"description":"The query contains an invalid, duplicated, external, or unsafe path value.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"examples":{"invalidPath":{"value":{"data":null,"error":{"code":"INVALID_CONTENT_PATH","message":"The path query parameter must be one safe, same-origin site path.","resolution":"Provide one path value beginning with '/', such as '/about'."}}}}}}},"404":{"description":"No public content is registered for the requested path.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"examples":{"notFound":{"value":{"data":null,"error":{"code":"CONTENT_NOT_FOUND","message":"No public content is available for \"/missing\".","resolution":"Use '/' or a path listed in https://darkroom.engineering/sitemap.xml."}}}}}}},"405":{"description":"The operation was requested with an unsupported HTTP method.","headers":{"Allow":{"description":"Methods supported by this operation.","schema":{"type":"string","const":"GET, HEAD"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"examples":{"methodNotAllowed":{"value":{"data":null,"error":{"code":"METHOD_NOT_ALLOWED","message":"Method not allowed","resolution":"Use GET for this operation."}}}}}}},"429":{"description":"The per-client request budget is exhausted. Retry after the number of seconds in Retry-After.","headers":{"Retry-After":{"description":"Seconds to wait before retrying.","schema":{"type":"integer","minimum":1}},"X-RateLimit-Limit":{"description":"Maximum requests allowed in the current window.","schema":{"type":"integer","minimum":1}},"X-RateLimit-Remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer","minimum":0}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"examples":{"rateLimited":{"value":{"data":null,"error":{"code":"RATE_LIMIT_EXCEEDED","message":"Too many requests","resolution":"Wait until the rate limit resets, then retry."}}}}}}}}}}},"components":{"schemas":{"ApiError":{"type":"object","additionalProperties":false,"required":["code","message","resolution"],"properties":{"code":{"type":"string","description":"Stable machine-readable error code."},"message":{"type":"string","description":"Human-readable explanation of the failure."},"resolution":{"type":"string","description":"Actionable guidance for resolving the failure."}}},"ErrorResponse":{"type":"object","additionalProperties":false,"required":["data","error"],"properties":{"data":{"type":"null"},"error":{"$ref":"#/components/schemas/ApiError"}}},"ContentResponse":{"type":"object","additionalProperties":false,"required":["data","error"],"properties":{"data":{"type":"object","additionalProperties":false,"required":["path","canonical","contentType","body"],"properties":{"path":{"type":"string","description":"Normalized site path used to resolve the content."},"canonical":{"type":"string","format":"uri","description":"Canonical production URL for the page."},"contentType":{"type":"string","const":"text/markdown","description":"Media type of the body field."},"body":{"type":"string","description":"Complete public page content in Markdown."}}},"error":{"type":"null"}}}}}}