Visual node canvas for chaining LLM, image, and video models via OpenRouter. Wire nodes, run pipelines—no glue code.
Independent project — not affiliated with OpenRouter unless agreed in writing. See License & IP.
GitHub
·
OpenRouter
·
| Canvas | Drag nodes from a palette, connect outputs to inputs, run one node or Run all in dependency order. |
| Models | Anything OpenRouter exposes—chat, vision-capable models, image generators, video jobs (including alpha APIs where applicable). |
| Your key | Bring your own OpenRouter API key; usage is billed by OpenRouter. The app proxies requests through your server so the key is not sent straight from the browser to openrouter.ai. |
| Accounts | Sign up to sync encrypted API key (with AUTH_SECRET), canvas, saved workflows, theme, and video job metadata in SQLite—resume on another device. |
| Self-host | Run locally or in Docker; export/import workflows as JSON for backups. |
npm install
cp .env.example .env
# Set AUTH_SECRET (e.g. openssl rand -base64 32) and NEXTAUTH_URL in .env
npx prisma migrate dev # creates SQLite DB for auth
npm run devWith the example .env, the dev server uses port 3080 (see PORT and NEXTAUTH_URL). Open http://localhost:3080, register or sign in, then paste your OpenRouter API key in the studio when prompted (keys are not required in .env for local dev).
npm run build
npm startSet NEXTAUTH_URL and AUTH_SECRET to match your public URL and a long random secret. AUTH_SECRET also encrypts stored OpenRouter keys in the database.
Images use Next.js standalone. Each container start runs prisma migrate deploy (docker-entrypoint.sh) so the schema exists before node server.js. The process runs as nextjs with a writable /app for SQLite.
1. Environment
cp .env.example .envMinimum in .env: AUTH_SECRET, and usually NEXTAUTH_URL only when you need a fixed canonical URL. Compose sets DATABASE_URL=file:/app/data/studio.db and mounts a named volume on /app/data, so the SQLite database and accounts persist across image rebuilds and container recreation. To wipe data, run docker compose down -v.
2. Build and run
docker compose up --build -dDifferent host port? Set APP_PORT (and matching NEXTAUTH_URL) in .env, for example:
APP_PORT=3000 NEXTAUTH_URL=http://localhost:3000 docker compose up --build -dOr edit .env before docker compose up. NextAuth must use the same origin you open in the browser.
Compose may load .env; it sets AUTH_TRUST_HOST=true for port mapping and reverse proxies.
nginx on the same host: The app listens on 127.0.0.1:${APP_PORT:-3080} on the host (mapped to port 3000 inside the container). Point your server / location at that upstream, for example proxy_pass http://127.0.0.1:3080;. Set NEXTAUTH_URL to your public https://your.domain (no trailing slash). The hostname in container logs (e.g. f5030adb7722) is only valid inside Docker—not the URL you use in nginx or a browser.
| Area | Choice |
|---|---|
| Framework | Next.js 16 (App Router) |
| UI | React 19, Tailwind CSS v4, Base UI / shadcn-style components |
| Canvas | @xyflow/react (React Flow v12) |
| State | Zustand (graph + UI; theme + sync via /api/settings/studio when signed in) |
| Auth | NextAuth.js v5, @auth/prisma-adapter |
| Database | Prisma 7, SQLite, better-sqlite3 adapter |
| Language | TypeScript |
- After sign-in, the studio loads your saved state from the server; edits debounce and sync automatically.
- Add Prompt, LLM, Image, Video, input nodes, Notes, and Output; connect compatible handles.
- Choose models and parameters per node; run steps individually or use Run all where supported.
- Server route handlers call OpenRouter with your key; video flows use polling and proxied downloads.
For payload details and model notes, see openrouter-studio-prompt.md and app/api/openrouter/.
This repository is licensed under the Apache License 2.0. You may use, modify, and distribute the software for commercial and non-commercial purposes, subject to the terms of that license (including the patent grant where applicable). See the license text for full conditions.
- Copyright: NOTICE states project copyright and trademark notices required or recommended when redistributing under Apache 2.0. If you are the sole copyright holder preparing a sale or exclusive license, replace OpenRouter Studio authors in
LICENSE,NOTICE, and this file with your legal name or entity so counterparties can identify assignable rights. - Trademarks: OpenRouter and related marks belong to their respective owners. This studio is a separate product; the name refers to API compatibility only unless you have a separate trademark agreement.
- Dependencies: Third-party packages remain under their own licenses.
The maintainers welcome good-faith conversations about acquisition, exclusive or enterprise licensing, official product or hosting integration, or partnership with OpenRouter or other organizations. Nothing in the Apache license obliges the authors to grant additional rights beyond that license; anything beyond the public license is subject to a separate written agreement.
How to reach out: use GitHub Discussions or Issues on this repository, or your usual business development channel, and reference “OpenRouter Studio / licensing or partnership.”