Skip to content

Run a Solution Locally

Develop a Solution's app and workflows on one local origin with bifrost solution start — hot reload, no deploy.

bifrost solution start runs your Solution’s app dev server and its local workflows behind a single origin, proxying everything else to your dev instance. It deploys nothing — edit, save, refresh.

  • A Solution workspace (a directory containing bifrost.solution.yaml). Create one with bifrost solution init.
  • At least one standalone_v2 app in the workspace. Scaffold one with bifrost solution scaffold-app <slug>.
  • You are logged in (bifrost login) and Node.js (npm) is on your PATH.
  1. From the solution root (the directory holding bifrost.solution.yaml), run:

    Terminal window
    bifrost solution start

    With more than one app in the workspace, name the one to serve:

    Terminal window
    bifrost solution start my-app
  2. On first run, the CLI installs the app’s npm dependencies, discovers your local workflow functions, and starts Vite. Watch for:

    Discovered 1 local function(s).
    Bifrost solution dev server → http://localhost:3000
  3. Open http://localhost:3000. The app loads already authenticated as your CLI user, with its “Run workflow” button wired to your local functions.

start runs a proxy on --port (default 3000) and Vite on --port + 1 (so 3000 → Vite 3001). You only ever open the proxy port. Behind it:

  • App requests are served by Vite (HMR).
  • Workflow calls (useWorkflowQuery / useWorkflowMutation with a path::function ref) run in-process against your local source — no deploy, no DB row needed.
  • Everything else (auth, tables, configs, integrations) is proxied to your dev instance.
Terminal window
bifrost solution start my-app --port 4000

The dev origin is then http://localhost:4000 (Vite runs on 4001).

  • App code (.tsx, .css, …) reloads instantly via Vite HMR.
  • Workflow code (the .py functions under your solution root) is re-discovered on save by the file watcher — the next workflow call runs the updated source. No restart.

By default the app runs under your own org context. To exercise the app as another org or globally:

Terminal window
# A specific org (id or name)
bifrost solution start my-app --org "Contoso"
# Global / org-null context
bifrost solution start my-app --global

--org / --global require superuser privileges; without them the CLI exits with a permissions error.

Press Ctrl-C. The CLI tears down both the proxy and the Vite process group.