Skip to main content
Glama

list_templates

Retrieve available workflow templates to streamline ComfyUI automation and simplify workflow management.

Instructions

List available workflow templates.

Returns list of template names for get_workflow_template().

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function for the list_templates tool. Decorated with @mcp.tool() for registration. Returns the list of keys from the TEMPLATES dictionary.
    def list_templates(ctx: Context = None) -> list: """List available workflow templates. Returns list of template names for get_workflow_template(). """ if ctx: ctx.info("Listing templates") return list(TEMPLATES.keys())
  • Predefined workflow templates dictionary used by the list_templates tool to list available templates.
    TEMPLATES = { "empty": {}, "fal-flux-dev": { "1": { "class_type": "RemoteCheckpointLoader_fal", "inputs": {"ckpt_name": "fal-ai/flux/dev"}, }, "2": {"class_type": "StringInput_fal", "inputs": {"text": "A beautiful landscape"}}, "3": {"class_type": "IntegerInput_fal", "inputs": {"value": 1024}}, "4": {"class_type": "IntegerInput_fal", "inputs": {"value": 1024}}, "5": {"class_type": "IntegerInput_fal", "inputs": {"value": 28}}, "6": {"class_type": "FloatInput_fal", "inputs": {"value": 3.5}}, "7": { "class_type": "SaveImage_fal", "inputs": {"filename_prefix": "flux_output", "images": ["1", 0]}, }, }, "fal-flux-schnell": { "1": { "class_type": "RemoteCheckpointLoader_fal", "inputs": {"ckpt_name": "fal-ai/flux/schnell"}, }, "2": {"class_type": "StringInput_fal", "inputs": {"text": "A beautiful landscape"}}, "3": { "class_type": "SaveImage_fal", "inputs": {"filename_prefix": "flux_schnell", "images": ["1", 0]}, }, }, }
  • Call to register_workflow_tools within register_all_tools, which registers the list_templates tool among others.
    register_workflow_tools(mcp)

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/IO-AtelierTech/comfyui-mcp'

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