Skip to main content
Glama

download_civitai_model

Download a CivitAI model to your ComfyUI models folder. Resolves model ID or version ID via API and saves to a specified subfolder like checkpoints or loras.

Instructions

Download a model from CivitAI into the local ComfyUI models/ directory and return the saved absolute path. Resolves a CivitAI model id (latest version) or a model-version id to a download URL via the CivitAI REST API, then streams the file to disk. LOCAL-ONLY: writes under <COMFYUI_PATH>/models/<target_subfolder>/ and errors when COMFYUI_PATH is unset (e.g. a remote --comfyui-url target). Provide at least one of model_id or model_version_id. Gated/early-access models require CIVITAI_API_TOKEN (sent as a bearer header, never in the URL); without it they fail.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
target_subfolderYesTarget subfolder under ComfyUI models/ (e.g. 'checkpoints', 'loras', 'vae').
model_version_idNoCivitAI model-version id (from the URL ?modelVersionId=...). If both model_id and model_version_id are given, this selects the specific version of that model.
model_idNoCivitAI model id. The latest version is used unless model_version_id is also provided.
filenameNoOverride the saved filename (defaults to the CivitAI file name, or the URL basename).
Behavior4/5

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

With no annotations provided, the description carries the full burden. It discloses the resolution via REST API, streaming to disk, local path structure, environment variable requirement, and bearer token handling for gated models. It does not address overwrite behavior or error handling for network failures, but covers the critical aspects.

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

Conciseness4/5

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

The description is a well-structured paragraph that starts with the core action, then explains the resolution process, local constraint, input requirements, and token handling. While efficient, it could be slightly more concise by combining the local-only and error conditions into a single statement.

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?

Given the absence of an output schema and annotations, the description provides sufficient context: it explains the API interaction, environment prerequisites, authentication needs, and error conditions. It lacks detail on overwrite behavior and network failure handling, but overall it is complete enough for an agent to use the tool correctly.

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

Parameters4/5

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

Although schema coverage is 100% (all parameters have descriptions), the description adds value by explaining the relationship between model_id and model_version_id (e.g., 'latest version' and version selection when both provided) and the default behavior for filename. This exceeds the baseline 3 for high schema coverage.

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 clearly states the tool's action ('Download a model from CivitAI'), the destination ('local ComfyUI models/ directory'), and the return value ('saved absolute path'). It distinguishes itself from the sibling 'download_model' by explicitly mentioning CivitAI-specific resolution and local-only nature.

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

Usage Guidelines4/5

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

The description specifies that at least one of model_id or model_version_id must be provided, warns about gated models requiring CIVITAI_API_TOKEN, and clarifies the local-only limitation (errors when COMFYUI_PATH is unset). However, it does not explicitly mention an alternative tool (e.g., 'download_model') for non-CivitAI downloads, which would improve guidance.

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

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