Connect Claude API to Nodes2Cloud
The Messages API MCP connector.
Claude API talks to the Nodes2Cloud MCP server at https://api.nodes2cloud.com/mcp over Streamable HTTP. Once connected, your agent can read the node catalogue, write and check workflows, and request deploys that wait for your approval by default.
Use a Personal Access Token
Claude API connects with a Personal Access Token. Create one in the editor under Integrations → MCP server → Headless & CI Tokens, then Generate Token. Replace n2c_pat_YOUR_TOKEN below with it. The code reads it from the N2C_API_KEY environment variable.
Treat the token like a password and keep it out of source control.
TypeScript
typescriptimport Anthropic from "@anthropic-ai/sdk";
const anthropic = new Anthropic();
const message = await anthropic.beta.messages.create({
model: "claude-sonnet-4-5",
max_tokens: 1024,
betas: ["mcp-client-2025-11-20"],
mcp_servers: [
{
type: "url",
url: "https://api.nodes2cloud.com/mcp",
name: "nodes2cloud",
authorization_token: process.env.N2C_API_KEY,
},
],
tools: [{ type: "mcp_toolset", mcp_server_name: "nodes2cloud" }],
messages: [{ role: "user", content: "List my Nodes2Cloud workflows." }],
});Claude API's MCP documentationInstructions checked