Skip to main content

Automatic MCP Setup

The fastest way to configure vai as an MCP server for your AI tools.

Prerequisites

  • vai installed globally: npm install -g voyageai-cli
  • Voyage AI API key configured: vai config set api-key YOUR_KEY
  • (Optional) MongoDB URI configured: vai config set mongodb-uri YOUR_URI

Install

# Install into all supported tools at once
vai mcp install all

# Or install into specific tools
vai mcp install claude cursor

Supported Targets

TargetToolConfig Path
claudeClaude Desktop~/.config/claude/claude_desktop_config.json
claude-codeClaude Code CLIClaude Code MCP config
cursorCursor IDE~/.cursor/mcp.json
windsurfWindsurf IDE~/.windsurf/mcp.json
vscodeVS Code~/.vscode/mcp.json

Verify

vai mcp status

Embed API Key in Config

To include your Voyage API key directly in the MCP config (so the server doesn't need environment variables):

vai mcp install all --api-key YOUR_VOYAGE_API_KEY

Restart Your AI Tool

Most AI tools discover MCP servers on startup. After installation, restart Claude Desktop, Cursor, or your IDE.

Test

Ask your AI tool something like:

"Use vai to search for documents about vector search"

If the tool calls vai_query, the setup is working.

Troubleshooting

If the MCP server isn't detected:

  1. Check vai mcp status
  2. Reinstall with vai mcp install claude --force
  3. Restart the AI tool
  4. See MCP Troubleshooting