Skip to content
Reference

Templates

5 source starter configurations. Template init writes split config and attempts provider setup by default; use --noProvision to inspect config first.

How templates work

A template is just a .stack.toml checked in under templates/<name>/stack.toml in the monorepo. It declares the services you want wired and the secrets each should expect. Applying a template runs stack add for each service in order; skipped services (provider not registered, already in stack) are reported cleanly at the end.

Two commands, two workflows:

  • stack init --template <name> — writes the .stack.toml and local instance file, then attempts provider setup by default. Add --noProvision to write config without running the provider setup loop.
  • stack templates apply <name> — actually runs through the setup loop for eligible entries. Needs the installed Phantom setup and provider access; inspect reported skips, failures and partial writes.
Continue on error: By default stack templates apply keeps going when a single service fails (e.g. a provider refuses setup). Review stack templates apply --help for your installed interface and inspect every reported result.

The five starters

Next.js · Supabase · PostHog

Postgres + auth + product analytics.

Starter definitions for Supabase data/auth and PostHog analytics. Available MCP entries depend on provider setup and separately configured client credentials.

2 services 5 declared slots 2 MCP declarations envs: dev, prod

What you get

Service Provider Secrets MCP
supabase supabase
SUPABASE_URL SUPABASE_ANON_KEY SUPABASE_SERVICE_ROLE_KEY
supabase
posthog posthog
POSTHOG_PROJECT_API_KEY POSTHOG_PERSONAL_API_KEY
posthog

Good for: Teams planning a data, auth and analytics stack with provider-specific setup.

Apply it

# inside a fresh project directory
stack templates apply nextjs-supabase-posthog

# or: write split config without provider setup, then inspect it
stack init --template nextjs-supabase-posthog --noProvision

Next.js · Neon · Vercel · Sentry

Serverless Postgres, deploy, error tracking.

Starter definitions for Neon, Vercel and Sentry. Sentry setup selects an existing project; available MCP configuration still needs usable client credentials.

3 services 7 declared slots 1 MCP declaration envs: dev, prod

What you get

Service Provider Secrets MCP
neon neon
NEON_API_KEY DATABASE_URL
—
vercel vercel
VERCEL_TOKEN
—
sentry sentry
SENTRY_AUTH_TOKEN SENTRY_DSN SENTRY_ORG SENTRY_PROJECT
sentry

Good for: Next.js apps on Vercel that need a real Postgres + production error tracking.

Apply it

# inside a fresh project directory
stack templates apply nextjs-neon-vercel-sentry

# or: write split config without provider setup, then inspect it
stack init --template nextjs-neon-vercel-sentry --noProvision

Supabase · PostHog · Sentry · Resend · Stripe

The "SaaS in a box" template.

Starter definitions for data/auth, analytics, errors, email and payments. Each service needs its supported setup; listed MCP entries do not establish running clients or working credentials.

5 services 10 declared slots 3 MCP declarations envs: dev, prod

What you get

Service Provider Secrets MCP
supabase supabase
SUPABASE_URL SUPABASE_ANON_KEY SUPABASE_SERVICE_ROLE_KEY
supabase
posthog posthog
POSTHOG_PERSONAL_API_KEY
posthog
sentry sentry
SENTRY_AUTH_TOKEN SENTRY_DSN SENTRY_ORG SENTRY_PROJECT
sentry
resend resend
RESEND_API_KEY
—
stripe stripe
STRIPE_SECRET_KEY
—

Good for: SaaS projects planning payment and error-monitoring integrations to configure and verify.

Apply it

# inside a fresh project directory
stack templates apply supabase-posthog-sentry-resend

# or: write split config without provider setup, then inspect it
stack init --template supabase-posthog-sentry-resend --noProvision

Cloudflare · Turso · Clerk · Sentry

Edge deployment, database and auth definitions.

Service definitions for Turso, Cloudflare, Clerk and Sentry. Available MCP configuration depends on adapter results and client setup.

4 services 10 declared slots 1 MCP declaration envs: dev, prod

What you get

Service Provider Secrets MCP
cloudflare cloudflare
CLOUDFLARE_API_TOKEN CLOUDFLARE_ACCOUNT_ID
—
turso turso
TURSO_DATABASE_URL TURSO_AUTH_TOKEN TURSO_PLATFORM_TOKEN
—
clerk clerk
CLERK_SECRET_KEY
—
sentry sentry
SENTRY_AUTH_TOKEN SENTRY_DSN SENTRY_ORG SENTRY_PROJECT
sentry

Good for: Edge apps planning database, deployment, auth and error-monitoring integrations.

Apply it

# inside a fresh project directory
stack templates apply cloudflare-turso-clerk

# or: write split config without provider setup, then inspect it
stack init --template cloudflare-turso-clerk --noProvision

Claude agent (OpenAI · Anthropic · xAI · DeepSeek · GitHub)

Multi-model agent project.

Provider slots for OpenAI, Anthropic, xAI, DeepSeek and GitHub. Supply supported account credentials; available GitHub MCP configuration needs separate client setup.

5 services 5 declared slots 1 MCP declaration envs: dev

What you get

Service Provider Secrets MCP
openai openai
OPENAI_API_KEY
—
anthropic anthropic
ANTHROPIC_API_KEY
—
xai xai
XAI_API_KEY
—
deepseek deepseek
DEEPSEEK_API_KEY
—
github github
GITHUB_TOKEN
github

Good for: Agent projects planning model API access and a GitHub integration.

Apply it

# inside a fresh project directory
stack templates apply claude-agent-openai-anthropic

# or: write split config without provider setup, then inspect it
stack init --template claude-agent-openai-anthropic --noProvision

Build your own

A template is just a TOML file with a [stack] block, one [services.<name>] per service, and optional [[environments]]. See config reference for the full schema. Drop it into templates/<your-name>/stack.toml, open a PR, and we'll add it to the curated list.

# templates/my-edge-starter/stack.toml

[stack]
version = "1"
template = "my-edge-starter"

[services.cloudflare]
provider = "cloudflare"
secrets = ["CLOUDFLARE_API_TOKEN", "CLOUDFLARE_ACCOUNT_ID"]

[services.turso]
provider = "turso"
secrets = ["TURSO_DATABASE_URL", "TURSO_AUTH_TOKEN", "TURSO_PLATFORM_TOKEN"]

[[environments]]
name = "dev"
default = true

[[environments]]
name = "prod"