Sidekick for InDesign
v1.0.39Lets Claude (or any other AI assistant) work in your open Adobe InDesign documents.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
execute
Use this when the user wants to create, inspect or change anything in their open Adobe InDesign documents (Sidekick for InDesign). Execute JavaScript code in InDesign via UXP (NOT ExtendScript). The code has access to the full InDesign DOM via require('indesign'). The 'app' object is NOT a global — you must import it: const { app } = require('indesign'). Use 'return' to return values. Capabilities: - Full InDesign DOM access (documents, pages, text frames, styles, etc.) - Async/await supported - Promises are awaited before returning - File operations via UXP storage APIs (with sandbox rest…
| Parameter | Type | Description |
|---|---|---|
code * | string | JavaScript code to execute in InDesign |
actions | array | Saved actions to call from the code, by name (list_actions lists them). Each becomes an async function named in camelCase -- alt-text-audit becomes altTextAudit -- taking the action's params as one ob… |
description | string | Brief description shown in the InDesign plugin panel. REQUIRED FORMAT: Line 1: What Sidekick is doing (present progressive tense, e.g., 'Getting the page count') Line 2: Manual alternative with keyb… |
snapshot
Capture a snapshot of a page or spread from the active InDesign document. Returns the image as base64-encoded JPEG, rendered at the resolution a vision model can actually use (you do not set dpi). Pass an optional `region` ([x0,y0,x1,y1], normalized 0..1 over the page) to zoom into part of a page at full detail — use this when a whole-page snapshot is too coarse to read an image or fine type. To capture one specific object by id, use `snapshot_object` instead. Pass `preview: true` for a cheap low-resolution thumbnail — use it for quick 'did the layout roughly change / is the block where…
| Parameter | Type | Description |
|---|---|---|
index * | integer | Zero-based index of the page or spread to capture |
target * | string | Whether to capture a single page or an entire spread |
description | string | Brief description shown in the InDesign plugin panel. REQUIRED FORMAT: Line 1: What Sidekick is doing (present progressive tense, e.g., 'Capturing page 1 for review') Line 2: Manual alternative (e.g… |
preview | boolean | Set true for a low-resolution thumbnail (~0.3 MP) for quick rough-glance checks where you don't need to read detail. Ignored when `region` is set (region always captures at full detail). |
region | array | Optional zoom-box [x0,y0,x1,y1] in normalized 0..1 page coordinates (top-left origin). Omit to capture the whole page. Only valid with target 'page'. Example: [0.5,0,1,0.4] = top-right area. |
snapshot_object
Capture a single page item (frame, image, group, …) from the active InDesign document as a base64 JPEG, at the resolution a vision model can use (you do not set dpi). By default it renders the object **as it appears on the page** — including anything overlapping it, and with any parts hidden by content in front left hidden (so it reflects what's actually visible). Pass `isolate: true` to render **only the object itself**: this strips overlapping items, but also reveals any parts of the object that are covered on the page — so it shows the object's full content rather than just the visib…
| Parameter | Type | Description |
|---|---|---|
pageItemId * | integer | The id of the page item to capture (from get_layout with includeItems) |
description | string | Brief description shown in the InDesign plugin panel. REQUIRED FORMAT: Line 1: What Sidekick is doing (present progressive tense, e.g., 'Capturing image frame for review') Line 2: Manual alternative… |
isolate | boolean | Render only the object itself, stripping overlapping page content (default false = render it as composed on the page). Note: isolating reveals parts of the object that are covered by other items on th… |
show_snapshot
Capture a snapshot and PRESENT it inline in the chat for the user to see. Returns the same base64 JPEG as `snapshot`, but in MCP Apps hosts (e.g. Claude Desktop) it also renders as a full inline preview with fit-to-width and zoom — no need to expand the tool accordion. Use this ONLY when the user asked to see a result, or when showing a finished result is genuinely useful to them. For your own iterative verification ('did the layout change', 'is the block where I dropped it'), use `snapshot` / `snapshot_object` instead — those stay collapsed and won't clutter the chat. Targets mirror the…
| Parameter | Type | Description |
|---|---|---|
description | string | Brief description shown in the InDesign plugin panel. REQUIRED FORMAT: Line 1: What Sidekick is doing (present progressive tense, e.g., 'Showing page 1') Line 2: Manual alternative (e.g., 'You can a… |
index | integer | Zero-based index of the page or spread to capture (required with `target`). |
isolate | boolean | With `pageItemId`: render only the object itself, stripping overlapping content. |
pageItemId | integer | Present a single page item by id (from get_layout with includeItems). When set, `target`/`index`/`region` are ignored. |
preview | boolean | Set true for a low-resolution preview. Ignored with `region` or `pageItemId`. |
region | array | Optional zoom-box [x0,y0,x1,y1] in normalized 0..1 page coordinates (top-left origin). Only valid with target 'page'. |
target | string | Capture a single page or an entire spread. Omit when presenting an object. |
snapshot_zoom
Internal to the show_snapshot viewer: renders a sharper close-up of the part of a snapshot the user zoomed into. Not for assistants: use `snapshot` with `region` for a close-up.
| Parameter | Type | Description |
|---|---|---|
documentId * | integer | Document.id of the snapshot's document. |
maxLongEdgePx * | number | Long edge of the close-up in pixels. |
maxPixels * | number | Pixel count of the close-up. |
pageIndex * | integer | Zero-based page index. |
region * | array | [x0,y0,x1,y1] in normalized 0..1 page coordinates (top-left origin). |
snapshotKey * | string | The key of the snapshot being zoomed into. |
documentName | string | The document's name, checked with the id. |
pageId | integer | Page.id of the snapshot's page. |
get_layout
Get comprehensive layout information for the active InDesign document. Returns page dimensions, margins, and pre-calculated content area coordinates for accurate text frame placement. Use this BEFORE placing text frames to get correct coordinates. The contentArea bounds can be used directly for geometricBounds. Returns: - facingPages: whether document uses facing pages - measurementUnits: horizontal and vertical units (use values as-is, no unit suffix needed) - pages: array with bounds, margins, and contentArea for each page (max 20) - contentArea accounts for page side (recto/verso) automat…
| Parameter | Type | Description |
|---|---|---|
includeItems | boolean | Include each page's items (id, type, bounds, hasGraphic). Use the ids with snapshot_object. Default false. |
get_font_metrics
Get comprehensive font metrics for a specified font. Returns all available metrics including x-height, cap-height, ascender, descender, line gap, underline/strikeout positions, subscript/superscript sizes, and bounding box. The tool searches system fonts (including .ttc collections such as Helvetica), the fonts bundled with InDesign (e.g. Minion Pro, Myriad Pro), and Adobe Fonts installed via Creative Cloud. IMPORTANT: Adobe Fonts limitation - Some Adobe Fonts are loaded on-demand by Adobe apps and may not be locally cached in the CoreSync folder. If a font is available in InDesign but not f…
| Parameter | Type | Description |
|---|---|---|
fontIdentifier * | string | Font identifier - family name (e.g., 'Helvetica'), PostScript name (e.g., 'Helvetica-Bold'), or full name |
refresh | boolean | Force refresh of font cache (rebuilds index from disk) |
style | string | Optional style (e.g., 'Bold', 'Italic') to disambiguate multiple matches |
list_actions
Use this to see the user's saved Sidekick actions and the built-in ones: what each does and the params it takes. Call it before run_action when you need an action's params, when the user asks what actions there are, or when a task looks like one a saved action might already do. It reads the actions folder fresh, so it includes actions saved since this conversation began, from any assistant. set_configuration sets the user's own actions folder (actionsDir) and shared folders (sharedActionsDirs). If set_configuration has no such settings, the user's Sidekick is older than actions: ask the user t…
run_action
Use this to run a saved Sidekick action by name in the user's open InDesign document. An action is JavaScript the user (or Sidekick) saved earlier, with a header that names it, describes it and types its params. Pass the params as one object; leave a param out to use its default. The answer is the action's report as text (summary, rows, what a changeCount means for this run's mode), any problems the report has, its log, and the report as JSON with at most 200 rows. When an action fails, the answer carries the error, the stack (lines refer to the action's file) and the numbered source, so a fi…
| Parameter | Type | Description |
|---|---|---|
name * | string | The action's name, as this description or list_actions gives it |
params | object | The action's params by name; leave one out to use its default |
get_action
Use this to read the source of a saved Sidekick action, for example before changing it at the user's request. Returns the file as it is, header included. list_actions lists the actions.
| Parameter | Type | Description |
|---|---|---|
name * | string | The action's name, as list_actions gives it |
save_action
Use this to save code as a Sidekick action the user can run again by name, from this or any other assistant, and from the Sidekick Actions panel in InDesign when the user's Sidekick plugin has it. Save only when the user asks, or agrees after you offered; never on your own initiative. When saving a fix to an action that failed, say what changed. The source is one JavaScript file: a header, then an async function main(params, sidekick) and any helpers it needs. Saving under an existing name replaces that action. /* @sidekick { "name": "alt-text-audit", "description": "Lists every placed i…
| Parameter | Type | Description |
|---|---|---|
source * | string | The whole action: the @sidekick header, then main and its helpers |
delete_action
Use this to delete one of the user's saved Sidekick actions. Deleting cannot be undone from Sidekick, so always ask the user to confirm first, naming the action. Built-in actions and actions in a shared folder cannot be deleted, nor can a locked (read-only) file; deleting a saved action that replaced a built-in or a shared one brings that one back.
| Parameter | Type | Description |
|---|---|---|
name * | string | The action's name, as list_actions gives it |
get_configuration
Get current Sidekick configuration settings.
set_configuration
Update Sidekick configuration settings.
| Parameter | Type | Description |
|---|---|---|
actionsDir | string | The folder the user's own Sidekick actions are saved in, or "default" to go back to Documents/Sidekick Actions. Sidekick's action tools use the change from their next call, and pass it on to the Sidek… |
observers | boolean | Allow local processes (a demo recorder, a session transcript) to watch commands sent to InDesign. Off by default. |
pinned | boolean | Stay on the installed version: nothing is downloaded. Takes effect when each Sidekick server next starts. The next start runs the version installed with Sidekick, which can be older than the one runni… |
sharedActionsDirs | array | Folders of actions to read in addition to the user's own, for example a studio's shared folder, in order of precedence. Sidekick never writes there; an action of the same name in the user's own folder… |
telemetry | boolean | Enable/disable anonymous error telemetry |
get_health
Use this when the user asks for "sidekick health", whether Sidekick or InDesign is connected, or why InDesign commands fail. Returns Sidekick's health and status: server version/role and the InDesign plugin connection.