Existing App
Use this path when you already have a Hono or Nitro app and want Junior to own the Slack runtime routes inside it.
The safest integration is still the scaffolded shape: a dedicated server entrypoint that exports the Hono app returned by createApp(), plus juniorNitro() in Nitro config.
Add the server entrypoint
Section titled “Add the server entrypoint”Create a Junior server module:
import { initSentry } from "@sentry/junior/instrumentation";initSentry();
import { createApp } from "@sentry/junior";import { plugins } from "./plugins.ts";
const app = await createApp({ plugins,});
export default app;createApp() mounts the supported Junior routes listed in Route & Handler Surface.
Add Nitro wiring
Section titled “Add Nitro wiring”Create a runtime-safe plugin set and point juniorNitro() at it so app files
and declared plugin packages are copied into the deployment bundle:
import { defineJuniorPlugins } from "@sentry/junior";
export const plugins = defineJuniorPlugins(["@sentry/junior-sentry"]);import { defineConfig } from "nitro";import { juniorNitro } from "@sentry/junior/nitro";
export default defineConfig({ modules: [ juniorNitro({ plugins: "./plugins", }), ], routes: { "/**": { handler: "./server.ts" }, },});If your existing app already owns routes, make sure the Junior Hono app still receives the paths under /api/webhooks, /api/oauth/callback, /api/internal/agent-dispatch, /api/internal/agent/continue, /api/internal/plugin/tasks, /api/internal/heartbeat, and /health. Do not split those routes across independent runtime instances. When mounted, @sentry/junior-dashboard owns /, /conversations, /plugins, /_junior/dashboard/client.js, /auth/login, /api/auth/*, and the authenticated product API routes /api/health, /api/runtime, /api/plugins, /api/plugins/*, /api/plugin-reports, /api/skills, /api/conversations, /api/conversations/*, /api/config, and /api/me.
Some packages export runtime hooks instead of plugin.yaml. Add those
plugin factories to the same plugins.ts set. For example, see
Scheduler Plugin for scheduled tasks and
GitHub Plugin for the githubPlugin() setup.
Add app files
Section titled “Add app files”Junior expects app context and local extension files under app/:
app/├── SOUL.md├── WORLD.md├── DESCRIPTION.md├── skills/└── plugins/Keep provider setup in plugin manifests and env vars, not in skill prose.
Verify integration
Section titled “Verify integration”Run the same checks as a scaffolded app:
pnpm exec junior checkpnpm devcurl http://localhost:3000/healthThen complete Slack App Setup and verify one real Slack mention.
Next step
Section titled “Next step”Review Config & Environment before deploying, then follow Deploy to Vercel.