metaswarm: Command for Claude Code

.claude/commands/external-tools-health.md

external-tools-health is a command for Claude Code from dsifry/metaswarm. It costs 18 tokens per session (720 once invoked), scanned A, original, MIT.

A command that checks whether configured external AI tools are available and reports their versions, authentication details, and configuration status.

In plain words
What is it for?
Use it to run health checks for external AI tools, inspect the external-tools configuration, and identify missing authentication or setup.
Why use it?
It quickly shows which integrations are ready and points to setup guidance for unavailable tools.

Command for Claude Code

Written for Claude Code: ${CLAUDE_PLUGIN_ROOT variable. Also seen: mentions Codex; mentions Gemini CLI.

This is dsifry/metaswarm's own configuration. It tells Claude Code how to work on metaswarm itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything metaswarm configures →

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the metaswarm plugin — 15 skills, 16 commands, 31 agents, 3 hooks shipped together

Reuse

Borrowing it

Nothing to install: this file belongs to dsifry/metaswarm. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/dsifry/metaswarm/main/.claude/commands/external-tools-health.md
Clone the repo
git clone --depth 1 https://github.com/dsifry/metaswarm

Made for: Claude Code.

Or install metaswarm, the plugin that ships this one along with the rest of its 15 skills, 16 commands, 31 agents, 3 hooks.

Wrote 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.

agentmods badge for external-tools-health

README.md
[![agentmods](https://agentmods.dev/badge/commands/dsifry/metaswarm/external-tools-health/github.svg)](https://agentmods.dev/commands/dsifry/metaswarm/external-tools-health)
Your own site
<a href="https://agentmods.dev/commands/dsifry/metaswarm/external-tools-health"><img src="https://agentmods.dev/badge/commands/dsifry/metaswarm/external-tools-health/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.

agentmods 80×15 button for external-tools-health

Your own site · 80×15
<a href="https://agentmods.dev/commands/dsifry/metaswarm/external-tools-health"><img src="https://agentmods.dev/badge/commands/dsifry/metaswarm/external-tools-health.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 18 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 720 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00018 $0.00720
Opus 5.5 $0.00007 $0.00288
Sonnet 5.5 $0.00004 $0.00144
Haiku 4.5 $0.00002 $0.00072

Measured 24d ago against content hash df4dadfb54e2, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

external-tools-health 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 24d 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.

.claude/commands/external-tools-health.md · 45 lines

How it starts

The opening of the file, as written. The whole thing — 45 lines — stays where its author put it; the contents beside it link to each section on GitHub.

External Tools Health Check

Check the status of external AI tools (Codex CLI, Gemini CLI) and their configuration.

Usage

/external-tools-health

Steps

  1. Locate the adapters. The plugin's bin/ is on PATH; PLUGIN_ROOT/CLAUDE_PLUGIN_ROOT often isn't set:

    MS_BIN="$(dirname "$(command -v metaswarm-agents.sh 2>/dev/null || echo "${CLAUDE_PLUGIN_ROOT:-${PLUGIN_ROOT:-.}}/bin/metaswarm-agents.sh")")"
    AD="$MS_BIN/../skills/external-tools/adapters"
    
  2. Run each adapter's health check. Each prints one JSON object with "tool", "status" (ready or unavailable), "version" (not_installed if the CLI is missing), "auth_valid" and "model":

    bash "$AD/codex.sh" health || echo '{"tool":"codex","status":"error","version":"unknown","auth_valid":"unknown","model":"unknown"}'
    bash "$AD/gemini.sh" health || echo '{"tool":"gemini","status":"error","version":"unknown","auth_valid":"unknown","model":"unknown"}'
    

    A "status":"error" row means the adapter itself failed (for example, Gemini can exit non-zero while resolving its model). Report it as an adapter error and show the adapter's stderr. Don't infer that the CLI is missing or logged out. To see the model for a specific role, add --role <role>. Models come from .metaswarm/models.yaml (roles.<role>.codex|gemini).

  3. Check configuration. Read .metaswarm/external-tools.yaml if it exists, and report which adapters are enabled or disabled. If external-tools.yaml still has an adapters.<tool>.model, report that it is no longer read (removed in 0.14.0) and that the model belongs in .metaswarm/models.yaml roles.<role>.<tool>.

  4. Report status. Show a summary table with one row per tool: status, version, auth_valid, model, and whether it's enabled in the config. Give each tool that isn't ready the remedy that matches its state:

    • For a "status":"error" row (the adapter itself failed, e.g. model resolution): show the adapter's stderr and fix that cause. Don't suggest install or login.
    • version is not_installed: install the CLI.
    • auth_valid is false: log in (codex login, or set OPENAI_API_KEY / the Gemini credentials).
    • Disabled in .metaswarm/external-tools.yaml: enable it there if it's wanted.

Read the full file on GitHub · 45 lines

Changes

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.

  1. 24d ago Changed · +11 lines · +18 tokens per session df4dadfb54e2
  2. 25d ago Changed · +22 lines c82b269e9e75
  3. 3mo ago First seen · 12 lines · 0 tokens per session scan A c3493b036dc7

Subscribe to this mod's changes

external-tools-health is a command published in the GitHub repository dsifry/metaswarm (442 stars, last pushed yesterday), licensed MIT. It adds 18 tokens to every session and 720 once invoked, about $0.0001 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-08-30.

Related

external-tools-health compared with commands from other repositories

external-tools-health next to 6 commands from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
external-tools-healthdsifry/metaswarmCommand442yesterdayMITA18Claude Code
qa-changesOpenHands/extensionsCommand190todayMITA63Claude Code
auditar-cascadingluanpdd/kit-mcpCommand52d agoMITA54Claude Code
react-nativegetsentry/toolkitCommand983todaynoneA0Claude Code
http-serviceMadAppGang/magusCommand16yesterdayMITA27Claude Code
doctordoncheli/don-cheli-sddCommand593mo agoApache-2.0A76Claude Code
doctorfatihkan/badiCommand81mo agoMITA0Claude Code