figpea-mcp
v2.15.0MCP server for AI agents to open, inspect, and export PSD, Adobe XD, Figma, SVG & PDF files in a live Figpea editor — runs locally over stdio, files never…
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
open_editor
Opens a Figpea editor tab wired to connect back to this bridge. Returns {port, token, url} -- open `url` in a browser to connect an editor tab; the returned port/token also let a caller compose its own URL.
| Parameter | Type | Description |
|---|---|---|
editorBaseUrl | string | Overrides the editor origin for this call only. |
file | string | Optional design-file URL to load via the ?loader=http seam. |
status
Reports the bridge's port, whether an editor tab is connected, the connected tab's contract version (null if none), and how many contract tools are currently registered. Also returns token and url so an LLM can construct the paste-ready pairing string without re-launching (REQ-1035). Returns a `connection` block naming WHY a tab is not connected — `lastEvent` (no_attempt, transport_only, hello_timeout, hello_rejected, hello_accepted, slot_refused, tab_superseded, disconnected) with the `nextStep` it implies, plus per-process counters and the run's `startedAt`; read it instead of re-trying a…
figpea_skill
Returns Figpea's agent skill reference -- the craft guidance for using window.figpea well (the authoring loop, recreating a reference faithfully, wiring interactions, the screenshot feedback loop, undo etiquette, entitlement boundaries, and the canonical Tier-1 recipe). Sourced from the editor origin's /agent/skill.md at startup, and the answer NAMES that origin: the body is that origin's own build, so if a tab is paired from a different origin or build, get the tab's skill with figpea.SKILL() in the tab or GET <the tab's origin>/agent/skill.md.
figpea_describe
Returns the agent contract surface for a group or method — the same doc/params/result the editor's own describe() returns, served from the manifest this server already holds in memory (no round trip to the tab). Call it with no arguments for the group index, {group} for one group's methods, or {group, method} for one method's wire shape. In compact mode this is how you learn a method's argument shape instead of probing: e.g. figpea_describe({group:'layer', method:'batch'}) returns the ops shape, whose args is a POSITIONAL array of {method, args} ops. A per-method response also carries string…
| Parameter | Type | Description |
|---|---|---|
group | string | Contract group name (e.g. layer, canvas, session, export). Omit for the index of all groups. |
method | string | Method name within the group (e.g. create, batch). Requires group. |
figpea_call
Universal dispatcher — calls any group.method on the paired editor tab via bridge.callTab(group, method, args, _timeoutMs?). In compact mode this is the only way to reach contract methods; in full mode the individual tools are also available. group/method are the describe() surface names, and args is the POSITIONAL argument array for that method, in that method's own parameter order. FLAT example: ["rect", {rwidth:100}] for layer.create. NESTED example — when a parameter is itself an array (e.g. layer.batch's ops), that parameter is passed as ONE element of args, so the element is an array…
| Parameter | Type | Description |
|---|---|---|
group * | string | Contract group name (e.g. layer, canvas, session, export) |
method * | string | Method name within the group (e.g. create, screenshot) |
_opsFile | Reserved, for a method whose top-level payload is an array (e.g. layer.batch's ops). Optional. Absolute path to a JSON file whose content is this parameter's array — read by this server and substitu… | |
_rawJson | Set _rawJson:true on your figpea_call when your harness STRINGIFIED an object or array argument AND this server cannot tell what that position expects — the method is unknown, the parameter is not d… | |
_timeoutMs | number | Optional per-call timeout override in ms. The default can be too low during a burst of mutations, where the editor is still settling after the relay has already given up — pass _timeoutMs deliberate… |
args | array | Positional argument array, in the method's own parameter order. An array-typed parameter (e.g. layer.batch's ops) is passed as ONE element of args, and that element is itself an array of {method, args… |
returnAs | Reserved: "inline" (default) or "path" — "path" writes a binary result to a session file and returns {ok, path, mime, width, height, bytes, filename?, url} as text, so a non-image export (e.g. a nat… |