Skip to main content
This page brings up bap-engine on your laptop, registers a product, provisions an Engine for a user, and admits a request. By the end you’ll have a working orchestrator + Engine pair you can hit with curl.

Prerequisites

  • Docker with Compose v2.
  • Git.
  • An Anthropic API key and an OpenAI API key (the orchestrator forwards these to engine containers).
  • A GitHub PAT with read access to septemberai/engine (only needed at image build time).

Step 1 — Clone and configure

Create .env from the template:
Open .env and set, at minimum:
For the full list of variables see Environment variables.

Step 2 — Build the engine image

The orchestrator launches engine containers from a local image. Build it once:
Your local Docker now has september-engine:2.3.0, which matches ORCH_ENGINE_IMAGE above.

Step 3 — Start the orchestrator

From the bap-engine repo root:
The first run pulls Postgres, builds the orchestrator image, applies migrations, and starts both. You’ll see:
Leave it running. Open a second terminal.

Step 4 — Confirm the orchestrator is up

You should see:
/health is the only endpoint that doesn’t require auth.

Step 5 — Register a product

The orchestrator is multi-product. Before you can provision engines, register a product. This call requires X-Admin-Key (the ORCH_ADMIN_KEY you set in step 1).
Response:
Save the platform_api_key. It’s the only time the orchestrator returns it. Set it as an env var for convenience:

Step 6 — Admit a user

POST /engines/{user_id}/admit is the primary entry point. It checks policy, auto-provisions if allowed, and returns the engine URL + key.
Response:
The orchestrator just spun up a fresh Engine container, applied migrations to its brain, generated an API key, and returned the endpoint. All in a few seconds.

Step 7 — Talk to the Engine

The product (you, in this example) calls the Engine directly. The orchestrator stays out of the data path.
You should see the SSE stream from the Engine. It worked. If the engine container is bound to 127.0.0.1:9001 only (the default in docker-compose.yml), the URL above works from your host machine. From other containers in the same Docker network, use the engine’s container hostname.

Step 8 — Observe the fleet

Lists the user’s engine.

Step 9 — Shut it down

To wipe the Postgres state too:

What you’ve just done

You’ve run the full path a real product takes. The orchestrator stood up a fresh Engine, gave you a URL + key, and watched its health. The Engine ran an SSE turn against the LLM. When you were done, you tore it down cleanly. Everything that lives in production lives in this loop. Production deploys add: TLS upstream of the orchestrator, a real secret manager, a backup strategy for the Postgres + brain volumes, and observability.

Where to go next