ComfyUI custom node pack for the Capsule Video Template API.
- Copy this
comfyui-capsule/folder intoComfyUI/custom_nodes/. pip install -r requirements.txtin your ComfyUI venv (onlyrequests).- Restart ComfyUI.
Find them in the node picker under Capsule.
The main node. Submits a template export, polls until done, optionally downloads the MP4.
Static widgets:
api_key— your Capsule API keyproject_id— defaults to6a087e2a66a340cf14b8d4e1aspect_ratio— Wide / Square / Verticalpoll_interval_sec,timeout_sec,download_localinputs_json— the serialized template input values (single source of truth)
Dynamic widgets:
- One per field returned by
GET /projects/<id>/templateInputs. Added automatically whenapi_keyandproject_idare both set (debounced 600ms). Also re-loadable via the 📥 Load template fields button. - Dynamic widgets are not serialized; their values flow into
inputs_json, which is.
Outputs:
video_url—https://render.capsule.video/media/<cloudJobId>local_path— path to downloaded MP4 (empty ifdownload_localis off)export_id
Standalone inspection node — returns the raw template schema as a JSON string. Not required for normal use; the render node fetches the schema on its own.
comfyui-capsule/
__init__.py ← Node registration
capsule_nodes.py ← Python nodes + /capsule/template_inputs HTTP route
requirements.txt
web/
capsule.js ← Frontend extension: dynamic widgets + auto-fetch
- The schema parser in
capsule.js(normalizeSchema) accepts{inputs: [...]},{fields: [...]}, or a top-level array. Tested against Capsule's current response shape. - API keys are sent from the browser to the local Comfy server, which proxies to Capsule. Fine for local/self-hosted use. For shared deployments, swap to reading the key from a
CAPSULE_API_KEYenv var incapsule_nodes.pyand remove the widget. - Comfy Cloud does not support arbitrary custom node installs — this pack requires local/self-hosted ComfyUI or a third-party host (RunComfy, ThinkDiffusion, MimicPC, etc.).