eavz

MCP Servers

Expose integrations as tools for AI agents via the Model Context Protocol.

MCP Servers

MCP (Model Context Protocol) servers expose your integrations as tools that AI agents can discover and use. Create an MCP server, add integration tools, and connect it to Claude Desktop, Cursor, or any MCP-compatible client.

Server Modes

MCP servers operate in one of two modes:

TOOLS Mode

Each integration action is exposed as a separate tool. The AI agent sees a flat list of tools like slack__send_channel_message, github__create_issue, etc. Best for focused servers with a small number of integrations.

CODE Mode

Instead of individual tools, the server exposes three meta-tools:

ToolPurpose
weavz_searchSearch available integrations, actions, and their schemas
weavz_read_apiRead detailed API documentation for a specific action
weavz_executeExecute code that calls integration actions

CODE mode dramatically reduces context usage (80-98% less) by letting the AI agent discover and call actions dynamically through code, rather than loading all tool schemas upfront. Best for servers with many integrations.

Creating an MCP Server

bash
curl -X POST https://api.weavz.io/api/v1/mcp/servers \
  -H "Authorization: Bearer wvz_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "My AI Tools",
    "workspaceId": "proj_abc123",
    "mode": "TOOLS"
  }'

The response includes the server's SSE endpoint and bearer token:

json
{
  "id": "mcp_abc123",
  "name": "My AI Tools",
  "mode": "TOOLS",
  "endpoint": "https://api.weavz.io/api/v1/mcp/servers/mcp_abc123/protocol",
  "bearerToken": "mcp_xxxxxxxxxxxxxxxx"
}

Adding Tools

Add integration actions as tools on your MCP server:

bash
curl -X POST https://api.weavz.io/api/v1/mcp/servers/{serverId}/tools \
  -H "Authorization: Bearer wvz_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "integrationName": "slack",
    "actionName": "send_channel_message",
    "connectionId": "conn_abc123"
  }'

Each API call adds one tool. To add multiple tools, make separate requests for each action.

Tool Naming

In TOOLS mode, tools are named using the pattern {integrationName}__{actionName}:

  • slack__send_channel_message
  • github__create_issue
  • google_sheets__read_rows

Integration Aliases

You can register the same integration multiple times under different aliases. This is useful when you need separate connections for the same service (e.g., a bot Slack connection and a user Slack connection):

bash
curl -X POST https://api.weavz.io/api/v1/mcp/servers/{serverId}/tools \
  -H "Authorization: Bearer wvz_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "integrationName": "slack",
    "integrationAlias": "slack_bot",
    "actionName": "send_channel_message",
    "connectionId": "conn_bot"
  }'

This creates tools named slack_bot__send_channel_message instead of slack__send_channel_message. Each alias can have its own connection and action subset.

Alias format: lowercase letters, numbers, hyphens, and underscores. Must start with a letter, max 64 characters.

Helper Tools

For actions with select inputs (e.g., selecting a Slack channel), MCP servers auto-generate companion tools so the AI agent can discover valid values:

slack__list_channels   →  companion tool for the "channel" select input

Helper tool naming: {integrationAlias}__list_{propertyName}s

Input Partials

Input partials let you assign saved parameter presets to MCP tools. When a partial is assigned, its values are merged into the tool's input at execution time. Enforced keys are locked and cannot be overridden by the AI agent — they are also stripped from the tool's schema so the agent never sees them.

bash
curl -X POST https://api.weavz.io/api/v1/mcp/servers/{serverId}/tools \
  -H "Authorization: Bearer wvz_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "integrationName": "slack",
    "actionName": "send_channel_message",
    "connectionId": "conn_abc123",
    "partialIds": ["partial_001", "partial_002"]
  }'

Connecting AI Clients

Claude Desktop

Add to your claude_desktop_config.json:

json
{
  "mcpServers": {
    "weavz": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://api.weavz.io/api/v1/mcp/servers/{serverId}/protocol",
        "--header",
        "Authorization: Bearer mcp_your_bearer_token"
      ]
    }
  }
}

Cursor

Add to your Cursor MCP settings:

json
{
  "mcpServers": {
    "weavz": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://api.weavz.io/api/v1/mcp/servers/{serverId}/protocol",
        "--header",
        "Authorization: Bearer mcp_your_bearer_token"
      ]
    }
  }
}

Any MCP Client

The MCP server endpoint supports Server-Sent Events (SSE) transport. Connect using:

  • Endpoint: https://api.weavz.io/api/v1/mcp/servers/{serverId}/protocol
  • Auth: Authorization: Bearer mcp_your_bearer_token

Managing Tools

List tools on a server

bash
curl https://api.weavz.io/api/v1/mcp/servers/{serverId}/tools \
  -H "Authorization: Bearer wvz_your_api_key"

Remove a tool

bash
curl -X DELETE https://api.weavz.io/api/v1/mcp/servers/{serverId}/tools/{toolId} \
  -H "Authorization: Bearer wvz_your_api_key"

End-User MCP Servers

SaaS developers can create MCP servers scoped to a specific end user. The server resolves connections belonging to that end user, so an AI agent operating on their behalf automatically uses their connected accounts.

Pass endUserId when creating the server:

bash
curl -X POST https://api.weavz.io/api/v1/mcp/servers \
  -H "Authorization: Bearer wvz_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "User Agent",
    "workspaceId": "proj_abc123",
    "endUserId": "user_123",
    "mode": "TOOLS"
  }'

When a tool call fails because the end user hasn't connected the required integration, the error response includes a setup URL. Share this URL with the end user so they can connect their account and retry.

Next Steps

Create your first MCP server in the dashboard or follow the MCP Tool Mode guide.