affinity

Installation
SKILL.md

Affinity Control

Affinity (/Applications/Affinity.app, the unified Canva-era app) has no AppleScript dictionary, CLI, or URL scheme, and its file formats are proprietary. Its only automation surface is the AI connector: when enabled, the app serves its JavaScript scripting SDK on http://localhost:6767/sse. The endpoint speaks the MCP protocol, but this skill drives it directly over HTTP/SSE with a zero-dependency Node CLI — no MCP client configuration, no tool schemas loaded into context. Verified end-to-end against Affinity 3.2.3.

  • scripts/affinity-cli.mjs — the CLI (Node ≥ 18, no npm install needed).
  • references/api-reference.md — verified endpoint tool contracts + SDK preamble digest. Read it before writing scripts.
  • references/sdk-map.md — curated SDK digest: module map, node model, creation recipes (text, image, adjustments), gotchas. Read it when writing anything beyond the basic drawing recipe.
  • references/sdk-docs/ — the complete vendored SDK documentation (109 topics, ~1.3 MB). Grep it for exact signatures only after sdk-map.md; never read the big files whole (nodes.js is 180 KB).

The control loop

  1. Preflight — the endpoint cannot be enabled remotely:
Installs
31
GitHub Stars
1
First Seen
Jul 31, 2026
affinity — jablonkai/skills