Skip to main content
Glama

comfyui_run_workflow

Run any ComfyUI workflow by submitting its JSON. Wait for execution to get outputs and status, or receive a prompt ID for non-blocking processing.

Instructions

Submit an arbitrary ComfyUI workflow for execution.

    See also: comfyui_run_workflow_stream for a streaming variant that emits
    per-node progress events while the workflow executes.

    Args:
        workflow: JSON string of a ComfyUI workflow (API format).
                  Each key is a node ID, each value has 'class_type' and 'inputs'.
        wait: If True, block until execution completes and return structured result
              with status, outputs, and elapsed time. If False (default), return
              immediately with just the prompt_id.
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
waitNo
workflowYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description discloses important behavioral details beyond annotations: the tool can block until completion (wait=True) and return structured results with status, outputs, and elapsed time, or return immediately with only a prompt_id (wait=False). It does not contradict any annotations and adds useful context about execution behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is tightly written: a one-sentence purpose, a single 'See also' note, and a structured Args section. Every sentence adds value with no repetition of schema details or unnecessary filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is moderately complex (executing arbitrary workflows) and the description covers parameters, wait behavior, and return variants. The presence of an output schema lightens the need to explain return values. Missing some edge-case context like error handling or side effects, but it is reasonably complete for an execution tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With schema description coverage at 0%, the description fully compensates. It explains the workflow parameter's structure ('JSON string of a ComfyUI workflow (API format). Each key is a node ID, each value has class_type and inputs') and describes the wait parameter's effect and default value.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description begins with a specific verb and resource: 'Submit an arbitrary ComfyUI workflow for execution.' This clearly states the tool's function and distinguishes it from the streaming variant by naming 'comfyui_run_workflow_stream' as a variant that emits per-node progress events.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly provides an alternative: 'See also: comfyui_run_workflow_stream for a streaming variant...' This tells the agent when to consider the sibling tool instead. It also explains the wait parameter's behavior, giving clear context for choosing synchronous vs. asynchronous execution.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/hybridindie/comfyui_mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server