Quickstart
Go from nothing to a deployed Sproutboat app in four commands.
Prerequisites
- A package manager.
npm install -g sproutboat,npx sproutboat,bunx sproutboatandpnpm dlx sproutboatall resolve a self-contained native binary for your platform. - An account on a platform you or your admin run. See Install the platform to run one, or Get access to join one. For a standalone binary you need neither.
The CLI compiles with the local C toolchain when there is one, and falls back to its own Zig otherwise, so a C compiler is optional.
Zero to deployed
Sign in once, from a browser
bunx sproutboat login --api-url https://control.example.comnpx sproutboat login --api-url https://control.example.comThis is the only step that needs a browser tab where you are signed in to the dashboard. It writes a long-lived token to ~/.config/sproutboat/credentials.json.
Scaffold a project
bunx sproutboat init hello
cd hellonpx sproutboat init hello
cd helloWrites sproutboat.jsonc and src/index.js under ./hello.
Edit the handler
Open src/index.js and make your changes. See The handler for the contract. sproutboat dev runs it on this machine with real bindings and rebuilds on save.
Deploy
bunx sproutboat deploynpx sproutboat deploydeploy prints the URL and waits until it serves. Deploying an unchanged artifact is a no-op.
Use TypeScript
The starter creates JavaScript. To use TypeScript, rename src/index.js to src/index.ts and set main in sproutboat.jsonc to "src/index.ts". The same dev, build and deploy commands work. Sproutboat bundles the file and removes TypeScript syntax before native compilation.
Run sproutboat types to generate binding types for your editor. To make type errors fail a build, add a tsconfig.json and run your own type check; sproutboat check checks runtime compatibility, not types. See Generated types.