Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add Comfy-Org/comfy-skills --skill comfy-sdkgit clone --depth 1 https://github.com/Comfy-Org/comfy-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/comfy-org/comfy-skills/comfy-sdk)<a href="https://agentmods.dev/skills/comfy-org/comfy-skills/comfy-sdk"><img src="https://agentmods.dev/badge/skills/comfy-org/comfy-skills/comfy-sdk/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/comfy-org/comfy-skills/comfy-sdk"><img src="https://agentmods.dev/badge/skills/comfy-org/comfy-skills/comfy-sdk.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00096 | $0.02431 |
| Opus 5.5 | $0.00038 | $0.00972 |
| Sonnet 5.5 | $0.00019 | $0.00486 |
| Haiku 4.5 | $0.00010 | $0.00243 |
Grade A, and why
comfy-sdk scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 20d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 175 lines — stays where its author put it; the contents beside it link to each section on GitHub.
comfy-sdk — build with Comfy Router
Steering only. Model names, schemas, prices and default timeouts change: discover them at run time (section 3) or read them off the installed SDK, and never paste one from memory.
1. Pick the right client
- Router (partner models,
https://api.comfy.org) is reached through themodelsnamespace:- Python:
Comfy().models(AsyncComfy().modelsfor asyncio). - TypeScript: the module-level
comfy.models, aftercomfy.config({ credentials })or withCOMFY_API_KEYset.new Comfy({ apiKey })is the Comfy Cloud workflow client and has no.models.
- Python:
- Cloud (
/api/v2/jobs, run a ComfyUI workflow) is the class client in both SDKs. - Both use the same
COMFY_API_KEY. Hosts are separate:COMFY_ROUTER_BASE_URLredirects Router,COMFY_BASE_URLredirects Cloud. Leave both unset in production.
from comfy_sdk import Comfy
client = Comfy() # reads COMFY_API_KEY
result = client.models.run("<provider>/<model>", {<provider's native body>})
import { comfy } from "@comfyorg/sdk";
comfy.config({ credentials: process.env.COMFY_API_KEY });
const { kind, data, requestId } = await comfy.models.run("<provider>/<model>", {<native body>});
2. Credentials stay on the server
- The SDKs read
COMFY_API_KEYfrom the process environment; neither loads a.envfile. Your framework does that (python-dotenv, Next.js.env.local, etc.). An explicitapi_key=/credentialsargument always wins over the variable. - Never expose the key to a browser bundle (no
NEXT_PUBLIC_/VITE_prefix). Call Router from a server route and return the result to the page. - Preflight before any paid call: list models (section 3). A
401there means the key, not the model, is wrong.
3. Discover, then call
GET /v2/modelslists what the credential can run, with billing facts. Paginate withnext_cursorwhilehas_moreis true; treat cursors as opaque.GET /v2/models/{provider}/{model}/openapi.jsonis that model's input/output schema. The second argument torun/submitis the provider's native body, forwarded unchanged, so build it from this schema, not from another provider's shape.- TypeScript wraps both:
comfy.models.list()walks the catalog andcomfy.models.schema(model)fetches the document. In Python, if the installedclient.modelshas no such helper, call the two routes on the Router host yourself withAuthorization: Bearer <COMFY_API_KEY>. - A model id is exactly two segments,
provider/model.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 20d ago First seen · 175 lines · 96 tokens per session scan A b2bb51a65a48
comfy-sdk is a skill published in the GitHub repository Comfy-Org/comfy-skills (273 stars, last pushed today), licensed MIT. It adds 96 tokens to every session and 2,431 once invoked, about $0.0004 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-11.
comfy-sdk compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| comfy-sdkComfy-Org/comfy-skills | Skill | 273 | today | MIT | A | 96 | Claude Code |
| build-mcp-serveranthropics/claude-plugins-official | Skill | 49k | today | Apache-2.0 | A | 111 | Claude Code |
| data-manager-api-troubleshootinggoogle/skills | Skill | 25k | today | Apache-2.0 | A | 179 | Claude Code, Codex |
| data-manager-api-setupgoogle/skills | Skill | 25k | today | Apache-2.0 | A | 118 | Claude Code, Codex |
| vss-manage-video-io-storageNVIDIA-AI-Blueprints/video-search-and-summarization | Skill | 2.0k | today | Apache-2.0 | A | 143 | Claude Code, Codex |
| workers-best-practicescloudflare/skills | Skill | 3.5k | 5d ago | Apache-2.0 | A | 25 | Claude Code |
| vss-search-archiveNVIDIA-AI-Blueprints/video-search-and-summarization | Skill | 2.0k | today | Apache-2.0 | A | 67 | Claude Code, Codex |