{"openapi":"3.1.0","info":{"title":"UML Diagram Generator","description":"API for generating UML and other diagrams; MCP at /mcp (Streamable HTTP — use an MCP client). [Swagger UI](/docs) · [ReDoc](/redoc) · [OpenAPI JSON](/openapi.json)","version":"1.3.0"},"paths":{"/":{"get":{"tags":["rest"],"summary":"Root","description":"Root: JSON by default; ``Accept: text/html`` or ``text/markdown`` for agents.","operationId":"root__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health":{"get":{"tags":["rest"],"summary":"Health Check","description":"Health check endpoint","operationId":"health_check_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/generate_diagram":{"post":{"tags":["rest"],"summary":"Generate Diagram Endpoint","description":"Generate a diagram from text","operationId":"generate_diagram_endpoint_generate_diagram_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiagramRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiagramResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/kroki_encode":{"post":{"tags":["rest"],"summary":"Kroki Encode Endpoint","description":"Return the Kroki-encoded URL for a diagram (no file write). Use when running on a read-only filesystem (e.g. serverless).","operationId":"kroki_encode_endpoint_kroki_encode_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/KrokiEncodeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/KrokiEncodeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/logo.png":{"get":{"tags":["well-known"],"summary":"Get Logo","description":"Return the logo for the plugin (used by Smithery and AI plugin manifests).","operationId":"get_logo_logo_png_get","responses":{"200":{"description":"Plugin logo (ICO format, used by Smithery and AI plugin manifests).","content":{"application/json":{"schema":{}},"image/x-icon":{"schema":{"type":"string","format":"binary"}}}}}}},"/.well-known/ai-plugin.json":{"get":{"tags":["well-known"],"summary":"Get Plugin Manifest","description":"Return the plugin manifest for OpenAI plugins and Smithery (base URL from request).","operationId":"get_plugin_manifest__well_known_ai_plugin_json_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/.well-known/mcp/server-card.json":{"get":{"tags":["well-known"],"summary":"Get Mcp Server Card","description":"MCP server metadata for Smithery and other registries (SEP-1649 server card).","operationId":"get_mcp_server_card__well_known_mcp_server_card_json_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/.well-known/privacy.txt":{"get":{"tags":["well-known"],"summary":"Get Privacy Policy","description":"Return the privacy policy for the plugin","operationId":"get_privacy_policy__well_known_privacy_txt_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/supported_formats":{"get":{"tags":["rest"],"summary":"Get Supported Formats","description":"Return the supported diagram formats","operationId":"get_supported_formats_supported_formats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/openapi.yaml":{"get":{"tags":["openapi"],"summary":"Get Openapi Yaml","description":"Return the OpenAPI specification in YAML format (for AI tools and ReDoc).","operationId":"get_openapi_yaml_openapi_yaml_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}}},"components":{"schemas":{"DiagramRequest":{"properties":{"lang":{"type":"string","title":"Lang","description":"The language of the diagram like plantuml, mermaid, etc."},"type":{"type":"string","title":"Type","description":"The type of the diagram like class, sequence, etc."},"code":{"type":"string","minLength":1,"title":"Code","description":"The code of the diagram."},"theme":{"type":"string","title":"Theme","description":"Optional theme for the diagram.","default":""},"output_format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output Format","description":"Output format for the diagram (svg, png, etc.)","default":"svg"}},"type":"object","required":["lang","type","code"],"title":"DiagramRequest","example":{"code":"@startuml\nclass Demo {\n  +name : String\n}\n@enduml","lang":"plantuml","output_format":"svg","theme":"","type":"class"}},"DiagramResponse":{"properties":{"url":{"type":"string","title":"Url","description":"URL to the generated diagram."},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"A message about the diagram generation."},"playground":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Playground","description":"URL to an interactive playground."},"local_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Local Path","description":"Local path to the diagram file."}},"type":"object","required":["url"],"title":"DiagramResponse"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"KrokiEncodeRequest":{"properties":{"type":{"type":"string","title":"Type","description":"Diagram type (class, sequence, mermaid, d2, etc.)."},"code":{"type":"string","title":"Code","description":"Diagram source code."},"output_format":{"type":"string","title":"Output Format","description":"Output format: svg, png, or pdf.","default":"svg"},"theme":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Theme","description":"PlantUML theme (e.g. cerulean). Ignored for non-PlantUML backends."}},"type":"object","required":["type","code"],"title":"KrokiEncodeRequest","description":"Request body for /kroki_encode: returns Kroki URL without writing to disk.","example":{"code":"@startuml\nclass A\n@enduml","output_format":"svg","type":"class"}},"KrokiEncodeResponse":{"properties":{"url":{"type":"string","title":"Url","description":"Kroki URL for the rendered diagram."},"playground":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Playground","description":"Optional URL to an interactive editor when available."}},"type":"object","required":["url"],"title":"KrokiEncodeResponse"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}},"tags":[{"name":"rest","description":"Diagram generation, encoding, and health endpoints."},{"name":"well-known","description":"Machine-readable manifests, MCP server card, and plugin metadata."},{"name":"openapi","description":"OpenAPI specification exports (JSON is also served by FastAPI at /openapi.json)."}]}