MCP

MCP (Model Context Protocol)

Anything that speaks MCP can be gated by Eda. If your agents run through Claude Desktop, Claude Code, Cursor, or any MCP client, you can put Eda in front of their tool calls without touching the tools.

There are three ways to use Eda with MCP:

  1. Proxy an existing MCP server — wrap any server so every tools/call is checked. Zero code changes to the underlying tools.
  2. Eda’s own MCP server — exposes eda_check and eda_wait_approval tools so an agent can self-gate.
  3. In-code handler wrappergateMcpHandler from the SDK, for servers you build yourself.

However you connect, every gated call flows through the same policies and lands in the same audit log.

1. Proxy any MCP server

The proxy sits between the MCP client and your existing server. Each tools/call is turned into an eda.check(); blocked calls never reach the tool, and require_approval pauses until a human decides.

claude_desktop_config.json
{
  "mcpServers": {
    "payments": {
      "command": "npx",
      "args": [
        "@eda-holding-inc/cli", "mcp", "proxy",
        "--agent", "payments-agent",
        "--", "node", "./my-payments-mcp-server.js"
      ],
      "env": { "EDA_API_KEY": "eda_live_…" }
    }
  }
}

Everything the wrapped server exposes still works — Eda only inserts the check. The client sees the same tools; you get policy enforcement and an audit trail for free.

2. Eda’s MCP server (self-gating tools)

Add Eda as an MCP server and your agent gets two tools it can call itself:

  • eda_check{ agent, action, params } → a decision. The agent asks before it acts.
  • eda_wait_approval{ actionId } → blocks until a human approves/denies.
claude_desktop_config.json
{
  "mcpServers": {
    "eda": {
      "command": "npx",
      "args": ["@eda-holding-inc/cli", "mcp", "serve"],
      "env": { "EDA_API_KEY": "eda_live_…" }
    }
  }
}

Then, in your system prompt, instruct the agent: “Before any consequential action, call eda_check. If it returns pending, call eda_wait_approval and only proceed when approved.”

3. Wrap a handler in code

If you build your own MCP server with the official SDK, gate it inline:

import { Eda, gateMcpHandler } from "@eda-holding-inc/sdk";
import { CallToolRequestSchema } from "@modelcontextprotocol/sdk/types.js";
 
const eda = new Eda({ apiKey: process.env.EDA_API_KEY! });
 
server.setRequestHandler(
  CallToolRequestSchema,
  gateMcpHandler(async (req) => runTool(req), {
    eda,
    agent: "mcp-tools",
    // map an MCP request → an Eda action; defaults to the tool name + arguments
    action: (req) => req.params.name,
    params: (req) => req.params.arguments,
  }),
);

mcpCheckRequest(req, { eda }) is also exported if you want to run the check yourself and decide how to shape the MCP error response.

Connect from the dashboard

Open Integrations → MCP

In the dashboard, go to Integrations → MCP.

Register an endpoint

Give your MCP server a name and its command/URL, choose the agent name it should report as, and Eda generates the proxy config to paste into your MCP client.

Watch calls flow

Every tools/call that passes through appears in the activity feed, with the tool, arguments, decision, and matched policy.