regenerator2000: Skill for Claude Code

.agent/skills/add-mcp-tool/SKILL.md

add-mcp-tool is a skill for Claude Code, Codex from ricardoquesada/regenerator2000. It costs 18 tokens per session (637 once invoked), scanned A, original, Apache-2.0.

A workflow for adding a new tool to an MCP server, a service that lets AI agents call external tools, in a Rust codebase.

In plain words
What is it for?
Use it when adding a tool to the server's tool list and implementing the matching call logic.
Why use it?
It lays out where to declare the tool, describe its inputs, connect its handler, and confirm the design before coding.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

This is ricardoquesada/regenerator2000's own configuration. It tells Claude Code and Codex how to work on regenerator2000 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 regenerator2000 configures →

Reuse

Borrowing it

Nothing to install: this file belongs to ricardoquesada/regenerator2000. 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/ricardoquesada/regenerator2000/main/.agent/skills/add-mcp-tool/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/ricardoquesada/regenerator2000

Made for: Claude Code, Codex.

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 add-mcp-tool

README.md
[![agentmods](https://agentmods.dev/badge/skills/ricardoquesada/regenerator2000/add-mcp-tool/github.svg)](https://agentmods.dev/skills/ricardoquesada/regenerator2000/add-mcp-tool)
Your own site
<a href="https://agentmods.dev/skills/ricardoquesada/regenerator2000/add-mcp-tool"><img src="https://agentmods.dev/badge/skills/ricardoquesada/regenerator2000/add-mcp-tool/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 add-mcp-tool

Your own site · 80×15
<a href="https://agentmods.dev/skills/ricardoquesada/regenerator2000/add-mcp-tool"><img src="https://agentmods.dev/badge/skills/ricardoquesada/regenerator2000/add-mcp-tool.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 18 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 637 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00637
Opus 5 $0.00009 $0.00318
Sonnet 5 $0.00004 $0.00127
Haiku 4.5 $0.00002 $0.00064

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

Security

Grade A, and why

add-mcp-tool 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 10d 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.

.agent/skills/add-mcp-tool/SKILL.md · 88 lines

How it starts

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

Add MCP Tool Workflow

Use this workflow when adding a new tool to the crates/regenerator2000-core/src/mcp/handler.rs server.

1. Plan the Tool

Before writing code, confirm with the user:

  • Tool Name (e.g., r2000_get_memory)
  • Arguments (e.g., address: u16, length: u16)
  • Return Type (e.g., Vec<u8>)
  • Description

2. Define the Tool in list_tools

In crates/regenerator2000-core/src/mcp/handler.rs:

  • Use define_tool! macro or manually add the JSON definition inside the list_tools function.
  • Ensure arguments follow the JSON schema format.

Example:

json!({
    "name": "r2000_my_tool",
    "description": "Description of what the tool does.",
    "inputSchema": {
        "type": "object",
        "properties": {
            "arg1": { "type": "string", "description": "..." }
        },
        "required": ["arg1"]
    }
})

3. Implement the Handler Logic

In crates/regenerator2000-core/src/mcp/handler.rs:

  • Locate handle_tool_call_internal.
  • Add a new match arm for your tool name.
  • Call a dedicated implementation function (create one if it doesn't exist).

Example:

"r2000_my_tool" => {
    let arg1 = args["arg1"].as_str().ok_or(McpError::InvalidParams("Missing arg1".to_string()))?;
    let result = my_tool_impl(app_state, arg1)?;
    Ok(json!({ "content": [{ "type": "text", "text": result }] }))
}

4. Create the Implementation Function

In crates/regenerator2000-core/src/mcp/handler.rs (or a sub-module):

  • Create a function named [tool_name]_impl.
  • Accept &mut AppState (or &AppState if read-only).
  • Return Result<Value, McpError> or a specific type.

5. Add Verification Test

In tests/verify_mcp.py:

  • Create a new function test_[tool_name](client).
  • Use client.rpc("tools/call", { ... }).
  • Verify the result ("PASS" or "FAIL").
  • Add the function call to the if __name__ == "__main__": block.

6. Verify Correctness

  • Run the verify-mcp skill:
    .agent/skills/verify-mcp/scripts/verify.sh
    
  • Fix any compilation errors or test failures.

Read the full file on GitHub · 88 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. 10d ago First seen · 88 lines · 18 tokens per session scan A 00e8741fe167

Subscribe to this mod's changes

add-mcp-tool is a skill published in the GitHub repository ricardoquesada/regenerator2000 (164 stars, last pushed 15d ago), licensed Apache-2.0. It adds 18 tokens to every session and 637 once invoked, about $0.0001 per session on Opus 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

Other skills, from other repositories

n8n-subworkflows

Build reusable, composable n8n sub-workflows. Use when extracting shared logic, building anything multi-step or reused across workflows, or any workflow over 10 nodes — and whenever the user mentions sub-workflows, Execute Workflow, reuse, shared/common logic, modular workflows, "Define Below" inputs…

czlonkowski/n8n-mcp · 121 tokens

n8n-code-tool

Write JavaScript or Python for the n8n Custom Code Tool (@n8n/n8n-nodes-langchain.toolCode) — the AI-agent-callable tool, NOT the workflow Code node. Use when building a Code Tool attached to an AI Agent, writing code that an LLM will invoke, parsing the query input, returning a string result, defining an input schema…

czlonkowski/n8n-mcp · 221 tokens

sanity-best-practices

Sanity development best practices for schema design, GROQ queries, TypeGen, Visual Editing, images, Portable Text, Studio structure, localization, migrations, Sanity Functions, webhooks, Blueprints, and framework integrations such as Next.js, Nuxt, Astro, Remix, SvelteKit, Angular, Hydrogen, and the App SDK. Use this…

sanity-io/agent-toolkit · 164 tokens

tech-specs

To define clear, testable tech specs from requirements — target-state architecture, contracts, interfaces.

griddynamics/rosetta · 23 tokens

mcp-google-map-project

Project knowledge for developing and maintaining @cablate/mcp-google-map. Architecture, Google Maps API guide, GIS domain knowledge, and design decisions. Read this skill to onboard onto the project or make informed development decisions.

cablate/mcp-google-map · 49 tokens

frontmcp-development

Use when building any FrontMCP server component other than a tool (for tools, use create-tool). Covers @Resource static resources and parameterized URI templates; @Prompt reusable prompts (RAG, multi-turn); @Provider singleton dependency-injection providers (database pools, API clients); @Agent autonomous LLM agents…

agentfront/frontmcp · 196 tokens