The CLI publishes as
@craveup/cli. The older unscoped craveup package
on npm is unmaintained and stops at 1.0.3 — install the scoped name. The
installed command is still craveup, so craveup login and the rest are
unchanged.Install & run
Run the CLI anywhere you want to create the project directory:- Choosing a template (
storefront-default, Tomodachi Sushi, or Xichuan Noodles) - Selecting the published organization and location
- Naming the project directory
- Installing dependencies with your detected package manager
- Optionally starting
pnpm devso you can preview immediately
Sign in
Sign in before scaffolding so the CLI can discover the organizations and locations your account can manage:~/.config/craveup/credentials.json, and is shared with the CraveUp MCP server — signing in through either one satisfies the other. On a headless or remote machine, use craveup login --device to pair with a code you open on any other device.
Non-interactive usage
Prefer automation or CI pipelines? Use flags to skip prompts.
Example:
Environment variables
The CLI creates.env.local with placeholders. Update them before running the app:
Tip:The merchant and location variables are standalone/local overrides. A hostedCRAVEUP_DASHBOARD_URL,CRAVEUP_PARTNER_API_URL, and a privateCRAVEUP_API_KEYare CLI/server concerns. They are never written to a public storefront environment variable.
cravejs-storefront-template resolves the merchant from its controlled
host/subdomain and the location from the [locationId] route instead of
duplicating tenant selection in production environment variables. The CLI does
not write NEXT_PUBLIC_STOREFRONT_URL; the template derives its canonical
metadata origin from the request host. Add that optional override manually only
when the deployed metadata origin must differ from the request host.
Project anatomy
Every template ships with:- Next.js 16.3 + App Router for modern server-first rendering
@craveup/storefront-sdk@2.0.1pinned and preconfigured insrc/lib/storefront-client.ts- Typed API helpers co-located with app routes
- Component library for menu browsing, cart management, and checkout