Photoshop Document Import
Bring the whole Photoshop document's story into ComfyUI as clean JSON
- photoshop_packet_json
- layer_manifest_json
- summary_json
MKRPhotoshopDocumentImport is the metadata door into the Photoshop bridge. The Photoshop side of this pack is a UXP plugin panel (the scaffold ships in addons/photoshop/ with a manifest, an index.html, and index.js), and when that panel sends ComfyUI a snapshot of the current document - name, size, color mode, and its layer list - this node normalizes that raw payload into a stable, predictable bridge packet.
Why does that matter? Because the payload coming out of a UXP plugin is whatever the plugin chose to serialize, and your ComfyUI graph needs a consistent shape to build workflows on. This node defaults missing fields (Untitled.psd, RGB, 0 dimensions), sanitizes strings, and reshapes the layer data into a clean list. From that point on, everything else in the Photoshop lane can rely on one schema: mkrshift_photoshop_bridge_v1.
The input
- photoshop_payload_json - the payload from the Photoshop UXP panel. If it's invalid JSON you get warnings and defaults rather than a crash. In a fully wired setup this arrives over the pack's transport/endpoint lane; for a first test, paste it in from the panel.
The outputs
- photoshop_packet_json - the normalized packet: document name, width, height, color mode, and the layers array. This is the canonical record of what Photoshop looked like.
- layer_manifest_json - just the
layersarray. This is the useful one: a list of layer records you can iterate over, count, or use to decide which layer to target on the way back out. - summary_json - document name, layer count, warnings. The sanity check: if
layer_countis 0, the plugin didn't actually send layers.
Where this fits
It's the front end of a roundtrip: pull the document structure in → generate or modify in ComfyUI → push results back as a new layer via the output/export lanes. If you're doing layer-aware retouch or compositing against a real PSD, this node is how your graph learns what it's working with. Without it you'd be parsing plugin JSON by hand every time, which is a job nobody should want.
Installing and gotchas
One pack, one install:
cd ComfyUI/custom_nodes
git clone https://github.com/criskb/MKRShift_Nodes
restart, or ComfyUI Manager → "MKRShift". No dependencies, no models. Remember the Photoshop plugin is a separate piece you install inside Photoshop itself - the ComfyUI node just consumes what the plugin sends.
The honest gotcha: this node only knows what the plugin told it. If the UXP panel isn't installed or hasn't connected, there's nothing to normalize, and you'll get an empty packet with defaults. Also, this is document metadata - it does not load pixels. For actual image data in, that's MKRPhotoshopImageImport's job. Mixing them up is the classic first-run confusion.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| photoshop_payload_json | STRING | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| photoshop_packet_json | STRING | — |
| layer_manifest_json | STRING | — |
| summary_json | STRING | — |