Deploy to Vercel
The scaffolded app is already shaped for Vercel. Deployment mainly means linking the project, setting env vars, enabling snapshot warmup support, and pointing Slack at the production URL.
Link the project
Section titled “Link the project”Authenticate and link the local app to a Vercel project:
pnpm dlx vercel@latest loginpnpm dlx vercel@latest linkIf your account requires a team scope, pass the same --scope <team-slug> value to Vercel commands.
Configure build command
Section titled “Configure build command”The scaffolded package.json includes the production build script:
{ "scripts": { "check": "junior check", "dev": "vite dev", "build": "junior snapshot create && vite build" }}Keep the Vercel build command as pnpm build. junior snapshot create prepares sandbox runtime dependencies declared by enabled plugins before request handling starts.
Configure production environment
Section titled “Configure production environment”Set the core runtime variables in Vercel:
| Variable | Required | Purpose |
|---|---|---|
SLACK_SIGNING_SECRET | Yes | Verifies Slack requests. |
SLACK_BOT_TOKEN or SLACK_BOT_USER_TOKEN | Yes | Posts replies and calls Slack APIs. |
REDIS_URL | Yes | Queue and runtime state storage. |
JUNIOR_SECRET | Yes | Signs internal callbacks and sandbox requester context. |
JUNIOR_BASE_URL | Conditional | Canonical URL for OAuth and callback URLs when Vercel URL envs are not enough. |
AI_GATEWAY_API_KEY | Optional | AI Gateway auth when your setup requires it. |
Use one stable JUNIOR_SECRET per deployment:
node -e "console.log(require('node:crypto').randomBytes(32).toString('base64url'))"Plugin pages list provider-specific env vars such as GitHub App settings or Datadog keys.
Enable snapshot warmup credentials
Section titled “Enable snapshot warmup credentials”If enabled plugins need sandbox runtime dependencies, junior snapshot create runs during build. In Vercel, enable OIDC so VERCEL_OIDC_TOKEN is available during the build.
Snapshot warmup also needs REDIS_URL during build because the snapshot registry is Redis-backed.
Point Slack at production
Section titled “Point Slack at production”Update these Slack URLs to your production domain:
https://<your-domain>/api/webhooks/slackApply the URL to:
- Event Subscriptions
- Interactivity
/jrslash command
Reinstall the Slack app if scopes changed.
Verify production
Section titled “Verify production”Run these checks after deployment:
GET https://<your-domain>/healthreturnsstatus: "ok".- A Slack mention produces a thread reply in the expected workspace.
- App Home opens without an error.
- Queue callback and turn logs show successful processing.
- One enabled plugin workflow succeeds end to end.
Next step
Section titled “Next step”Use Verify & Troubleshoot for first-response checks, then monitor production with Observability.