> **Version 10.3** — **React** / **TypeScript**
> Also available:
- `?language=js` for JavaScript
- `?codeOnly=true` for code snippets only
- other versions: Version 9 (`/docs/9/ai/mcp/api.md`), Version 8 (`/docs/8/ai/mcp/api.md`)

# MCP server API

While they are in [preview](../../releases/features.mdx#preview), Storybook's AI capabilities (specifically, the [manifests](../manifests.mdx) and MCP server) are currently only supported for [React](?renderer=react) projects.

  Additionally, the API may change in future releases. We welcome feedback and contributions to help improve this feature.

## `@storybook/addon-mcp` options

The MCP server addon accepts the following options to configure the tools provided by the MCP server. You can provide these options when registering the addon in your `main.js|ts` file:

```ts
// .storybook/main.ts — CSF 3
// Replace your-framework with the framework you are using (e.g., react-vite, vue3-vite, angular, etc.)

const config: StorybookConfig = {
  framework: '@storybook/your-framework',
  stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
  addons: [
    // ... your existing addons
    {
      name: '@storybook/addon-mcp',
      options: {
        toolsets: {
          dev: false,
        },
      },
    },
  ],
};

export default config;
```

```ts
// .storybook/main.ts — CSF Next 🧪
// Replace your-framework with the framework you are using (e.g., react-vite, nextjs, nextjs-vite)

export default defineMain({
  framework: '@storybook/your-framework',
  stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
  addons: [
    // ... your existing addons
    {
      name: '@storybook/addon-mcp',
      options: {
        toolsets: {
          dev: false,
        },
      },
    },
  ],
});
```

### `toolsets`

Type:

```ts
{
  dev?: boolean;
  docs?: boolean;
  test?: boolean;
}
```

Default: 

```ts
{
  dev: true,
  docs: true,
  test: true,
}
```

Configuration object to toggle which toolsets are enabled in the MCP server. By default, all toolsets are enabled.

#### `dev`

Type: `boolean`

Default: `true`

The development toolset includes the [`get-storybook-story-instructions`](./overview.mdx#get-storybook-story-instructions) and [`preview-stories`](./overview.mdx#preview-stories) tools.

#### `docs`

Type: `boolean`

Default: `true`

The docs toolset includes the [`get-documentation`](./overview.mdx#get-documentation), [`get-documentation-for-story`](./overview.mdx#get-documentation-for-story), and [`list-all-documentation`](./overview.mdx#list-all-documentation) tools.

#### `test`

Type: `boolean`

Default: `true`

The testing toolset includes the [`run-story-tests`](./overview.mdx#run-story-tests) tool.

**More AI resources**

- [MCP server overview](./overview.mdx)
- [Sharing your MCP server](./sharing.mdx)
- [Best practices for using Storybook with AI](../best-practices.mdx)
- [Manifests](../manifests.mdx)