Docs

Start the gateway and dashboard, open /docs, and make a real chat call.

Run locally

Services

bash
# Terminal 1 — API gateway bun --filter @opendoor/gateway dev # Terminal 2 — dashboard bun --filter @opendoor/dashboard dev # Docs are at http://localhost:3010/docs while the dashboard is running

Access points

ServiceURLWhat it is
Dashboardhttp://localhost:3010Console (session cookie)
Gatewayhttp://localhost:3001OpenAI-compatible API
Gateway healthhttp://localhost:3001/healthProbe
Gateway statushttp://localhost:3001/statusPostgres, Redis, providers
Site statushttp://localhost:3010/statusSame checks in the UI
Docshttp://localhost:3010/docsGuides and API reference

First call

  1. Seed and ingest so the catalog is not empty: bun --env-file=.env run scripts/seed.ts then bun run ingest:open-models
  2. Sign in on the dashboard, create an API key, copy a live model id from Models
  3. Call the gateway:
bash
curl http://localhost:3001/v1/chat/completions \ -H "Authorization: Bearer YOUR_OPENDOOR_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "YOUR_MODEL_ID", "messages": [{"role": "user", "content": "Hello!"}], "max_tokens": 50 }'

Or open Playground — it creates a Playground key and uses the live catalog.

The TypeScript SDK and CLI talk to the same gateway:

bash
export OPENDOOR_API_KEY=YOUR_OPENDOOR_KEY export OPENDOOR_BASE_URL=http://localhost:3001 bun run od -- chat --model YOUR_MODEL_ID --message "Hello"

See TypeScript SDK and CLI.

bash
curl http://localhost:3001/v1/models \ -H "Authorization: Bearer YOUR_OPENDOOR_KEY"

Database

bash
bun run db:studio

Studio images

Studio (/dashboard/studio) talks only to OpenDoor APIs (/api/studio/* → gateway POST /v1/images/generations). The browser never calls a local image UI.

If PRIVATE_IMAGE_GEN_URL is set, the gateway posts to {url}/v1/images/generations. Otherwise it uses OpenAI / Azure keys, then Vertex when ADC is configured. If nothing is configured, Studio is offline and generate returns 503 Studio GPU offline.

bash
curl http://localhost:3001/v1/images/generations \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{"prompt":"A red door on a white wall","n":1,"size":"1024x1024","response_format":"b64_json"}'

Ports in use

Dashboard is 3010, gateway 3001. Docs no longer bind 3002.

Workflow code_execution on this machine uses a local execFile subprocess unless CODE_SANDBOX_URL points at Cloud Run opendoor-sandbox (gVisor). Firecracker is not available on macOS. See Code execution jail.

bash
lsof -ti:3010 | xargs kill -9 lsof -ti:3001 | xargs kill -9