affinity-mcp-proxy
Allows interaction with Affinity's local MCP server, providing tools for executing scripts, rendering document spreads, and searching SDK hints.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@affinity-mcp-proxysearch for SDK hints about text styles"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
affinity-mcp-proxy
affinity-mcp-proxy exposes the local Affinity MCP server as an MCP server over stdio.
It is designed for tools that know how to launch MCP servers as local commands, for example:
{
"mcpServers": {
"affinity": {
"command": "pnpm",
"args": ["dlx", "affinity-mcp-proxy"]
}
}
}What it does
connects to the local Affinity MCP server over HTTP/SSE
re-exposes
tools/listandtools/calloverstdioprimes
execute_scriptwithread_preamblein the same upstream sessionships a small CLI for diagnostics and direct tool calls
Related MCP server: affinity-mcp-bridge
Status
first-class target: macOS
runtime: Node.js 22+
package manager:
pnpm
Other platforms may work, but this package is only validated on macOS in the first release.
Install and run
Preferred ephemeral usage:
pnpm dlx affinity-mcp-proxyDirect CLI usage:
pnpm dlx --package affinity-mcp-proxy affinity-mcp-proxy-cli list-tools
pnpm dlx --package affinity-mcp-proxy affinity-mcp-proxy-cli call-tool search_sdk_hints '{"query":"text style"}'Local development:
pnpm install
pnpm test
pnpm dlx . --help
node ./affinity_mcp_proxy.mjs --helpRequirements
Affinity must be open
the local Affinity MCP server must be enabled and listening
Node.js 22 or newer
By default the proxy tries these upstream URLs:
http://127.0.0.1:6767/ssehttp://127.0.0.1:6767http://[::1]:6767/ssehttp://[::1]:6767
Environment variables
AFFINITY_MCP_URLforce a specific upstream MCP URL
AFFINITY_MCP_CONNECT_TIMEOUT_MSoverride the connection timeout
AFFINITY_MCP_DEBUGenable proxy debug logs on
stderr
The proxy requires the SDK to be installed through the package dependencies. There is no alternate local SDK fallback.
Commands
Proxy server:
pnpm dlx affinity-mcp-proxy
pnpm dlx affinity-mcp-proxy --help
pnpm dlx affinity-mcp-proxy --versionDiagnostic CLI:
pnpm dlx --package affinity-mcp-proxy affinity-mcp-proxy-cli list-tools
pnpm dlx --package affinity-mcp-proxy affinity-mcp-proxy-cli execute-script-file ./script.js
pnpm dlx --package affinity-mcp-proxy affinity-mcp-proxy-cli render-spread-file DOCUMENT_SESSION_UUID '{"spread_index":2,"out":"/tmp/spread-2.jpg"}'Troubleshooting
If the proxy exits immediately:
confirm Affinity is open
confirm the local MCP endpoint is enabled
set
AFFINITY_MCP_DEBUG=1to see connection attemptsif your environment prefers a specific interface, set
AFFINITY_MCP_URLexplicitly
If text formatting scripts fail inside Affinity with COMMAND_FAILED, make sure the script sets the current spread to the target text node spread before calling doc.formatText(...).
This server cannot be deployed
Maintenance
Related MCP Connectors
MCP server (stdio): validate JSON against JSON Schema (draft-07 / 2020-12) via the AgentForge API
Stateless MCP gateway and OTel span-streaming bridge for hosted MCP servers.
- QuallaaOAuthcom.quallaa
Talk to your public-facing AI from any MCP client — Claude, ChatGPT, Cursor, Cline, Windsurf.
MCP server (stdio): check if URLs are alive (status, redirects, latency) via the AgentForge API
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceProxies remote HTTP/HTTPS MCP servers over stdio, allowing stdio-based MCP clients to connect to remote servers via Streamable HTTP or SSE transports.MIT
- AlicenseAqualityCmaintenanceBridges MCP clients to Affinity by Canva's local MCP server, exposing tools for script execution, rendering, and SDK documentation.21120 npm7MIT
- AlicenseNot gradedqualityDmaintenanceProxies STDIO-based MCP clients to streaming HTTP MCP servers, enabling local clients to connect to remote servers.8 npm3MIT
- AlicenseNot gradedqualityCmaintenanceActs as a stdio-to-HTTP proxy for the 1C runtime-MCP service, enabling MCP clients like Claude Desktop to interact with 1C tools.MIT