Skip to content

Guides

Features

Switch built-in features off, or package your own routes, services, tools and tables as a feature.

Turn off optional server features you do not use. Keep identity and workspaces enabled; they are required. Define a custom feature when you want to register related routes, services, tools, or tables together.

FeatureAdds
integrationsThe integration catalog, connections, OAuth and webhooks
mcpThe hosted MCP endpoint at /api/agentic/mcp
localRuntimesAgents on your local Codex CLI or Claude Code, in dev only
promptThe dashboard prompt
agentsAgents, runs and approvals for tool calls
automationsAutomations, triggers, outcomes and run history

Switch features off

export default defineNuxtConfig({
  extends: ['@nuxtagentic-pro/nuxt'],
  agentic: {
    features: { prompt: false, localRuntimes: false },
  },
})

In Nuxt, the dashboard hides the pages of switched-off features.

Write a feature

A feature bundles routes, services, tools, models, integrations, tables, maintenance jobs, and event handlers under one ID. The built-in features use the same pattern.

server/features/notes.ts
import { defineFeature, defineRoute } from '@nuxtagentic-pro/server'
import { desc, eq } from 'drizzle-orm'
import { z } from 'zod'
import { notes } from '../database/notes'

export const notesFeature = defineFeature({
  id: 'notes',
  requires: ['workspaces'],
  schema: { notes },
  routes: [
    defineRoute({
      id: 'notes.create',
      method: 'POST',
      path: '/notes',
      access: 'member',
      summary: 'Add a note to the workspace',
      input: { body: z.object({ text: z.string().min(1).max(2000) }) },
      async handler({ database, actor }, { body }) {
        const [note] = await database
          .insert(notes)
          .values({ text: body.text, workspace: actor!.workspace, ownerId: actor!.user.id })
          .returning()
        return note
      },
    }),
  ],
  services: ({ database, actor }) => ({
    notes: {
      latest: () =>
        database
          .select()
          .from(notes)
          .where(eq(notes.workspace, actor!.workspace))
          .orderBy(desc(notes.id))
          .limit(20),
    },
  }),
})
  • Routes are mounted under the base path, validated with Zod, listed in the OpenAPI document and checked for access before the handler runs. member, admin and owner routes always have an actor.
  • Services appear on useAgentic(event) and agentic.services(...).
  • Schema tables belong to you: export them from your Drizzle schema so pnpm db:generate creates their migrations.
  • Tools, models and integrations register exactly like their file-based versions.
  • Jobs run in the maintenance cron. Events observe runs, tool calls and approvals.

Register the feature:

import { notesFeature } from './features/notes'

export default defineNuxtAgentic({ features: [notesFeature] })

Feature ids are lowercase. requires lists features that must be present; startup fails with a clear message otherwise.