Skip to main content

UIGraph API (uigraph-api)

uigraph-api is the core backend. It owns the database, authentication, asset storage, the screenshot worker, and every REST endpoint the UI and MCP server call. It is the first service to start, and everything else depends on it.

Core

The essentials: where the API listens, and how it reaches its database, cache, and the domain it is served on.

VariableRequiredDefaultDescription
POSTGRES_URLYesDatabase DSN. Points at the bundled Postgres; repoint at a managed database to use your own.
UIGRAPH_SECRET_KEYYesAES-256-GCM master key (32 bytes) used to encrypt sensitive database values, including OIDC client secrets and SAML SP private keys. Generate with openssl rand -hex 32. Existing encrypted values cannot be read after changing or losing it.
HOSTNoWhich network interface to listen on. Leave empty to accept connections on all of them.
PORTNo8080Port the API listens on.
REDIS_URLNoredis://redis:6379Redis URL. Points at the bundled Redis.
UIGRAPH_DOMAINNolocalhostPublic domain UIGraph is served on.
UIGRAPH_COOKIE_DOMAINNoSet this to .example.com if you want one sign-in to work across subdomains. Leave it empty and a session is only valid on the exact host it was issued from, which is what you want when UIGraph is served from a single URL. See SSO Security & Operations.
UIGRAPH_LICENSE_KEYNoLicense key. Not required for self-hosted use.

URLs

VariableRequiredDefaultDescription
UIGRAPH_PUBLIC_URLNohttp://localhost:3000Externally reachable base URL. UIGraph derives OIDC callbacks, SAML ACS/entity ID/metadata URLs, and secure-cookie behavior from it.
UIGRAPH_FRONTEND_URLNohttp://localhost:3000Where the backend redirects the browser after OIDC or SAML login, and where the screenshot worker navigates to capture frames.
UIGRAPH_INTERNAL_FRONTEND_URLNohttp://uigraph-uiIn-network address of the UI container, used for server-to-UI requests inside the Docker network.

Bootstrap admin

VariableRequiredDefaultDescription
UIGRAPH_ADMIN_EMAILNoadmin@uigraph.appEmail of the admin user seeded on first boot (empty database).
UIGRAPH_ADMIN_PASSWORDNoadminInitial admin password. Leaving it as admin forces a password change at first login.

Object storage

The API signs and stores assets here. The same STORAGE_* values must be set on UIGraph Gateway; they must agree. The bundled deploy uses MinIO; the s3 backend is S3-compatible, so the same keys point UIGraph at AWS S3, Cloudflare R2, or any S3-compatible provider.

VariableRequiredDefaultDescription
STORAGE_BACKENDNominiominio (bundled) | s3 | gcs.
STORAGE_ENDPOINTNoIn-network storage endpoint the service signs against (e.g. http://minio:9000).
STORAGE_PUBLIC_ENDPOINTNoBrowser-reachable storage host used for presigned asset URLs (e.g. http://localhost:9000). Must resolve from the user's browser. Falls back to STORAGE_ENDPOINT.
STORAGE_BUCKETNouigraphBucket name.
STORAGE_ACCESS_KEYNoAccess key. For bundled MinIO this is also the root user.
STORAGE_SECRET_KEYNoSecret key / MinIO root password.
STORAGE_REGIONNous-east-1Region for the s3 backend. Use auto for Cloudflare R2.
STORAGE_FORCE_PATH_STYLENotrue when STORAGE_ENDPOINT is setPath-style addressing, required by MinIO and R2; set false for AWS S3.

The bundled MinIO container's root credentials (MINIO_ROOT_USER / MINIO_ROOT_PASSWORD) must match STORAGE_ACCESS_KEY / STORAGE_SECRET_KEY; see Storage (MinIO).

Vector store and embeddings

Search in UIGraph understands meaning, not just keywords, which is what these settings power. The bundled deploy runs everything it needs, so a standard install sets none of them. Change them to use a managed vector store or a hosted embedding provider instead.

VariableRequiredDefaultDescription
VECTOR_BACKENDNoqdrantqdrant | s3vectors.
QDRANT_URLNohttp://qdrant:6333Where to reach Qdrant, when VECTOR_BACKEND is qdrant.
EMBEDDING_BACKENDNoollamaollama | bedrock | openai.
EMBEDDING_MODELNonomic-embed-textWhich embedding model to use, named as your chosen backend names it.
EMBEDDING_URLNohttp://ollama:11434Where to reach the embedding service.
Changing the embedding model

Search results from one model cannot be compared with results from another. If you change EMBEDDING_MODEL or EMBEDDING_BACKEND once you already have data, everything indexed before the change has to be re-indexed before search works properly again.

Screenshots

UIGraph captures screenshots of your UI with a headless browser.

VariableRequiredDefaultDescription
UIGRAPH_CHROMIUM_PATHNo/usr/bin/chromium in the official imageWhere Chromium or Chrome is installed. Set this if you build your own image and screenshots stop working; leave it empty to let UIGraph find the browser itself.

Figma integration

The Figma OAuth app powers importing designs directly from Figma. Leave blank to disable. Create the app at figma.com/developers.

VariableRequiredDefaultDescription
FIGMA_CLIENT_IDNoOAuth client ID of your Figma app.
FIGMA_CLIENT_SECRETNoOAuth client secret of your Figma app.

Register this redirect URL in your Figma app: UIGRAPH_PUBLIC_URL + /api/v1/figma/callback (for example http://localhost:3000/api/v1/figma/callback).

Authentication references