Pragmatic Figma CLI for macOS — REST API + figma-mcp-go plugin + Hermes-Agent bridge. MIT.
For Figma Professional / Organization / Enterprise users.
A lean macOS CLI that turns your design-token source of truth into real
Figma Variables, launches thefigma-mcp-goplugin for you without
hunting through menus, and streams every step into Hermes-Agent.
Built because shipping a token update shouldn't cost you fifteen
clicks every time.
You already pay for a plan that unlocks multi-mode Variables, code
connect, and libraries. What you don't have is a clean way to keep them
in lockstep with your codebase — Figma's own CLI offering is minimal,
Tokens Studio still needs a wizard, and figma-mcp-go needs a plugin
window that never quite stays open. figx stitches all three into a
single hybrid pipeline that:
Plugins → 개발 → Figma MCP Go through a locale-independent AppleScript menuDrop-in editable diagram atassets/diagrams/figx-architecture.excalidraw
or open the live link above.
Each block below is actual output from this machine. They're what you
get.
figx doctor — checks everything before you start→ figma-cli doctor
✓ curl
✓ jq
✓ security
✓ gh
✓ Keychain PAT
✓ config: /Users/yu/.config/figma/cli.toml
✓ hermes Hermes Agent v0.8.0 (2026.4.8)figx auth status — PAT lives in Keychain, not in your shell history✓ PAT present in Keychain (service=figma-cli)figx files current — your working file, rememberedkzHqIqhzl3xJ5GqE0N2aMlfigx plugin status — WebSocket + manifest check in one✓ figma-mcp-go WS up on 127.0.0.1:1994
✓ manifest: /Users/yu/Projects/figma-mcp-learning/plugins/figma-mcp-go/plugin/manifest.jsonfigx plugin open — the move that replaces 5 clicks✓ Figma MCP Go dispatched
✓ WS 1994 listeningUnder the hood: AppleScript clicks Plugins → 개발 → Figma MCP Go —
deterministic, locale-independent, works in both Design Mode and Dev
Mode.
figx hermes check — observability on✓ Hermes Agent v0.8.0 (2026.4.8)
✓ Up to dateThe efficient path on a paid plan isn't REST or plugin — it's both at
the same time. figx makes that trivial.
Your codebase Figma Desktop
───────────── ─────────────
design tokens in code (1) extract │
(e.g. pdp_pipeline/make_pdp.py) ─────────► tokens.studio.json
tokens.dtcg.json
tokens.css
│
(2) push via ▼
Tokens Studio Variables
plugin (Pep / Cer modes)
│
(3) figma-mcp-go ▼
figx plugin open ──────────► plugin Styles
Components
Frames
(4) figx publish ▼
Library published
figx hermes notify ──────────► Hermes ──► Telegram / Slack / Discord| Step | Tool | What you type |
|---|---|---|
| Extract tokens from code | figx / tools/extract_from_py.py | figx export tokens --fmt dtcg |
| Push to Variables (Pep/Cer) | Tokens Studio for Figma | plugin UI, once |
| Create Styles / Components | figma-mcp-go via MCP | agent calls after figx plugin open |
| Publish library | manual + polled | figx publish |
| Notify / audit | Hermes webhook | automatic |
Enterprise users can substitute step 2 with figx vars apply (Variables
REST). Everyone else goes through Tokens Studio — same end state.
curl -fsSL https://raw.githubusercontent.com/MadKangYu/figx/main/bootstrap.sh | bashThe script installs figx, pulls the latest figma-mcp-go plugin
release, warms the MCP server, checks Accessibility permission, and
registers a Hermes webhook if Hermes is present.
git clone https://github.com/MadKangYu/figx.git ~/scripts/figma-cli
ln -sf ~/scripts/figma-cli/figma ~/.local/bin/figx
figx doctorNaming note — the binary is
figx, notfigma. npm'sfigma
binary would shadow us on most Node setups; this way you stay out of
that fight.
figx auth login # paste PAT once
figx files find "https://www.figma.com/design/XXXXX/..."
figx plugin open # launches Figma MCP Go
figx export tokens --fmt css --out src/tokens.css
figx export tokens --fmt dtcg --out design/tokens.dtcg.json
# Tokens Studio plugin → Load from file system → tokens.studio.json → Push
figx publish # guided manual publishFirst-time users: figx onboarding walks the 7 preconditions
(account → app → PAT → file → plugin → apply → verify) one at a time.
| Command | Purpose |
|---|---|
figx version / figx doctor / figx onboarding | environment + guided setup |
figx auth {login,status,logout} | Keychain-backed PAT management |
figx files {current,set,find,list} | file-key discovery |
figx vars {get,dump,apply} | Variables read / write (write = Enterprise only) |
figx publish | guided manual publish, polls /variables/published up to 20 min |
figx devmode | file metadata + Dev Resources |
figx export tokens --fmt {dtcg,css} | W3C DTCG / CSS custom properties |
figx plugin {install,open,run,status} | figma-mcp-go plugin management |
figx hermes {check,notify} | Hermes version + ad-hoc webhook push |
Deeper reference: docs/CLI.md.
figx (this CLI)
├── REST API ────────────► Figma cloud (read everywhere, write on Enterprise)
├── AppleScript menu click ► Figma Desktop (deterministic plugin launch)
├── npx @vkhanhqui/figma-mcp-go ► MCP server on ws://127.0.0.1:1994
│ └── figma-mcp-go Figma plugin connects here
└── hermes webhook ──────► Hermes Agent ── delivery (log | Telegram | Slack)/v1/me before storing.ERR trap into both the local auditfigx is designed around figma-mcp-go + Tokens Studio for Figma.
For related projects and IDE integrations — figma-mcp-bridge, figma
copilot, vscode-figma-mcp-helper, and more — seedocs/ESSENTIAL-PLUGINS.md.
MIT © 2026 KangYu (MadKangYu) · [email protected]
MadKangYu/figx
April 13, 2026
April 13, 2026
Shell