External Text (ComfyUI Deploy)
The Text Field That Turns Your Prompt Into an API Parameter
- text
Take a plain text field, tell the ComfyUI Deploy backend "this one is a callable input," and you've got ComfyUIDeployExternalText. It's the prompt-as-API-parameter node: whatever a remote caller types into your deployed form ends up here, and locally it's just a pass-through that hands you its default. If you're building a public ComfyUI endpoint, this is the node your positive prompt rides through.
How it works
The contract is the same family pattern as the slider nodes. input_id (default input_text) is the key a request carries. The node's run() literally returns default_value - that's the whole implementation - and the magic happens on the platform side: when a request arrives, the backend finds every node whose input_id matches a request key and writes the submitted value straight into that node's default_value. So locally the string in default_value is what flows through the graph, and deployed it's whatever the caller sent.
The input_id → default_value rewrite is even special-cased in the backend specifically for ExternalText and its wildcard sibling, so it's the best-supported node in the pack. Wire the output text into a CLIP Text Encode (positive or negative), and your API now has a prompt box.
The inputs that matter
input_id- the request key,input_textby default. Rename to something likepositive_promptif you want self-documenting API JSON.default_value- your local preview prompt and the fallback when a caller sends nothing. Set it to a prompt that produces a decent test image, because that's what you'll see every time you hit Queue locally.display_name/description- the label and help text shown on the deployed form. This is the one node where filling these in pays off most: your API's users will literally read them.
Installing
ComfyUI Manager → search "ComfyUI Deploy", or:
cd ComfyUI/custom_nodes
git clone https://github.com/BennyKok/comfyui-deploy
Restart ComfyUI. No models to download; dependencies are just aiofiles, pydantic, opencv-python, imageio-ffmpeg, brotli, tabulate.
When to pick this vs External Text Any
The pack ships a near-identical node, ComfyUIDeployExternalTextAny, whose output type is the wildcard * instead of STRING. Reach for plain ExternalText when the downstream socket is a normal string (CLIP text encode, most text inputs). Reach for the Any variant when you're feeding something finicky that expects a different type label, or when you want one text value to flow into several differently-typed inputs. For 90% of prompt work, this one - ExternalText - is the one you want.
Gotchas
The honest caveat: locally this node is indistinguishable from a core String node, so it's easy to forget it's an API contract. If you change the input_id, remember callers must use the new key. And empty default_value means an empty string flows through when nothing is supplied - which some CLIP encoders accept fine and others treat as "no prompt," so set a real default.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| input_id | STRING | input_text | — |
| default_valueopt | STRING | — | |
| display_nameopt | STRING | — | |
| descriptionopt | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| text | STRING | — |