The Cloudflare Agents SDK lets you build stateful, long-running AI agents on Cloudflare Workers with built-in MCP server support. Connect to the Apideck MCP Server and give your edge-deployed agents access to accounting, HRIS, and file storage data across 200+ SaaS apps.
Connect Cloudflare Agents SDK to the Apideck MCP Server with a few lines of code.
import { MCPClientManager } from "agents/mcp/client";
const mcpManager = new MCPClientManager("my-agent", "1.0.0");
await mcpManager.connect(
"apideck",
{
url: "https://mcp.apideck.dev/mcp",
headers: {
"x-apideck-api-key": "YOUR_API_KEY",
"x-apideck-app-id": "YOUR_APP_ID",
"x-apideck-consumer-id": "YOUR_CONSUMER_ID",
},
}
);
const tools = mcpManager.listTools();Every resource below is accessible as a set of MCP tools (list, get, create, update, delete) through Cloudflare Agents SDK.