Use the PlantUML CLI from KosmoKrator to call PlantUML tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.
PlantUML can be configured headlessly with `kosmokrator integrations:configure plantuml`.
# Install KosmoKrator first if it is not available on PATH.curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash# Configure and verify this integration.kosmokrator integrations:configure plantuml --enable --read allow --write ask --jsonkosmokrator integrations:doctor plantuml --jsonkosmokrator integrations:status --json
Runtime Requirements
Install these host dependencies before calling PlantUML locally.
Name
Type
Description
java
binary
Java is required to run PlantUML.
Credentials
Authentication type: No credentialsnone. Configure credentials once, then use the same stored profile from
scripts, coding CLIs, Lua code mode, and the MCP gateway.
No credentials are required.
Call PlantUML Headlessly
Use the generic call form when another coding CLI or script needs a stable universal interface.
Every function below can be called headlessly. The generic form is stable across all integrations;
the provider shortcut is shorter but specific to PlantUML.
plantuml.render_plantuml
Write write
Render a PlantUML diagram to a PNG image. Pass valid PlantUML syntax and get back a markdown image embed.
Supported diagram types: class, sequence, activity, component, state, use case, object, deployment, timing, network (nwdiag), wireframe (salt), Gantt, mindmap, WBS, JSON, YAML, ERD.
Example syntax:
```
@startuml
Alice -> Bob: Authentication Request
Bob --> Alice: Authentication Response
Alice -> Bob: Another request
Bob --> Alice: Another response
@enduml
```
Tips:
- Always wrap syntax in @startuml / @enduml
- Use `->` for solid arrows, `-->` for dashed arrows
- Use `class ClassName { }` blocks for class diagrams
- Use `(*) -->` for activity diagram start
- Use `[Component]` for component diagrams
- Use `state "Name" as s1` for state diagrams
Use these parameter tables when building CLI payloads without calling integrations:schema first.
plantuml.render_plantuml
Render a PlantUML diagram to a PNG image. Pass valid PlantUML syntax and get back a markdown image embed.
Supported diagram types: class, sequence, activity, component, state, use case, object, deployment, timing, network (nwdiag), wireframe (salt), Gantt, mindmap, WBS, JSON, YAML, ERD.
Example syntax:
```
@startuml
Alice -> Bob: Authentication Request
Bob --> Alice: Authentication Response
Alice -> Bob: Another request
Bob --> Alice: Another response
@enduml
```
Tips:
- Always wrap syntax in @startuml / @enduml
- Use `->` for solid arrows, `-->` for dashed arrows
- Use `class ClassName { }` blocks for class diagrams
- Use `(*) -->` for activity diagram start
- Use `[Component]` for component diagrams
- Use `state "Name" as s1` for state diagrams
PlantUML diagram syntax. Should be wrapped in @startuml/@enduml (auto-wrapped if missing).
title
string
no
Diagram title used as alt text (default: "Diagram").
Permissions
Headless calls still follow the integration read/write permission policy. Configure read/write defaults
with integrations:configure. Add --force only for trusted automation that should bypass that policy.