Backend API¶
The Phytograph backend is a single FastAPI application that serves all
compute-heavy operations to the renderer over HTTP. It lives in
backend-api/main.py (~23,000 lines, single file by design).
- Base URL:
http://127.0.0.1:<backend-port>. The port is chosen dynamically per app instance; the renderer resolves it over thebackend.getInfoIPC.8008is only a standalone-launch fallback. - All routes are prefixed with
/api/except/,/health,/version. - Versioning:
/versionreturnsBACKEND_VERSION. The supervisor refuses to run a backend whose version doesn't match the renderer'sEXPECTED_BACKEND_VERSION— see Version Lock.
Read on:
- HTTP Endpoints — grouped list of every route.
- Python Reference — auto-generated from docstrings via
mkdocstrings.