affinity-mcp
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| AFFINITY_MCP_URL | No | Affinity SSE endpoint. Default: http://localhost:6767/sse. | http://localhost:6767/sse |
| AFFINITY_BUNDLE_ID | No | macOS bundle identifier affinity_open launches. Default: com.canva.affinity. | com.canva.affinity |
| AFFINITY_LAUNCH_TIMEOUT_MS | No | How long affinity_open waits for the connector after launching. Default: 120000. | 120000 |
| AFFINITY_SCRIPT_TIMEOUT_MS | No | Upstream call timeout in milliseconds. Default: 300000. | 300000 |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| affinity_statusA | Report whether the adapter is connected to Affinity's local MCP connector. Does not launch Affinity. |
| affinity_openA | Launch Affinity if it is not running, wait for its local MCP connector, and connect. Other tools do this automatically; use this to warm Affinity up ahead of time. |
| affinity_list_documentsA | List the documents currently open in Affinity with their session UUIDs, titles, paths, and dirty state. |
| affinity_new_documentA | Create a new Affinity document, either from a named preset (for example 'A4', 'IG Post', 'Icon') or from explicit width, height, and units. Optionally save it straight to save_as. Returns the document's session UUID for later tools. |
| affinity_open_documentA | Open an existing document from an absolute path (or return it if it is already open). Affinity's filesystem setting limits which folders are readable; the Desktop is allowed by default. |
| affinity_get_document_settingsA | Read a document's setup: pixel dimensions, dpi, units, colour format and profile, layer and artboard counts, fonts, and dirty/undo state. Defaults to the current document; pass session_uuid to target a specific one. |
| affinity_set_document_settingsA | Change a document's setup and return the updated settings. Supports units, dpi, pixel width/height, and transparent_background. Changing dpi, size, or transparency rewrites document setup; other settings are preserved, but background transparency resets to opaque unless transparent_background is given. Defaults to the current document; pass session_uuid to target a specific one. |
| affinity_exportA | Export a document to an absolute path as png, jpeg, tiff, pdf, svg, webp, or gif. area is whole_document (default), current_spread, current_page, or selection. Affinity's filesystem setting limits where files can be written; the Desktop is allowed by default. Defaults to the current document. |
| affinity_add_shapeA | Add a rectangle or ellipse at pixel coordinates (x, y, width, height) with an optional #RRGGBB or #RRGGBBAA fill. Defaults to the current document; pass session_uuid to target another. |
| affinity_add_textA | Add a text frame containing text at pixel coordinates (x, y, width, height), using the document's default text style. Defaults to the current document; pass session_uuid to target another. |
| affinity_place_imageA | Place an image file into the document. Give x, y, width, height to fit it to a rectangle, or omit them for the image's natural size. Affinity's filesystem setting limits which folders are readable; the Desktop is allowed by default. Defaults to the current document. |
| affinity_add_sdk_hintC | Add a verified SDK hint to Affinity's preamble for future sessions. |
| affinity_execute_scriptC | Execute JavaScript in Affinity. This can modify documents and access capabilities allowed by Affinity settings. |
| affinity_list_library_scriptsB | List scripts in Affinity's script library. |
| affinity_list_sdk_documentationB | List available Affinity SDK documentation topics. |
| affinity_read_library_scriptC | Read a named script from Affinity's script library. |
| affinity_read_sdk_documentation_topicC | Read an Affinity SDK documentation topic by filename. |
| affinity_render_selectionC | Render the selected nodes in a document session as a JPEG. |
| affinity_render_spreadC | Render a zero-based spread in a document session as a JPEG. |
| affinity_report_sdk_issueB | Report a confirmed Affinity SDK issue with optional reproduction code. |
| affinity_save_script_to_libraryC | Save a completed JavaScript script to Affinity's script library. |
| affinity_search_sdk_hintsC | Search shared Affinity SDK hints for an existing solution. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 22 tools
Most tools have clearly distinct resource/action targets, such as document lifecycle, settings, export, and rendering. The main overlap is in the SDK/scripting cluster, where add_sdk_hint, search_sdk_hints, read_sdk_documentation_topic, report_sdk_issue, save_script_to_library, and execute_script require careful reading to distinguish.
All tools use the affinity_ prefix with snake_case, giving a predictable namespace and mostly verb_noun naming. A few standalone operations like affinity_status and affinity_open are minor deviations but remain readable.
The 22-tool surface is broad but feels heavy for the core purpose. While each tool has a plausible role, the scripting and SDK documentation tools push the count into a crowded range.
The set covers connection, document creation/open/listing, settings, export, basic shape/text/image insertion, rendering, and scripting/SDK support. Gaps remain around closing/deleting documents and deeper layer/selection editing, but execute_script provides a workaround.