fastmcp-builder

fastmcp-builder is an agent for Claude Code from Matt-Dionis/claude-code-configs. It costs 33 tokens per session (901 once invoked), scanned A, original, MIT.

A specialist for building FastMCP servers, which are services that expose tools, resources, or prompts to AI applications through MCP. It also covers token-gated access.

In plain words
What is it for?
Use it when creating an MCP server, adding tools, resources, or prompts, configuring HTTP streaming, managing sessions, or integrating Radius token protection.
Why use it?
It provides implementation guidance for setting up the server and connecting its request handling, validation, sessions, transport, and access checks.

Agent for Claude Code

Install

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.

agentmods
npx agentmods add agents/matt-dionis/claude-code-configs/fastmcp-builder
Clone the repo
git clone --depth 1 https://github.com/Matt-Dionis/claude-code-configs

Made for: Claude Code.

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 fastmcp-builder

README.md
[![agentmods](https://agentmods.dev/badge/agents/matt-dionis/claude-code-configs/fastmcp-builder.svg)](https://agentmods.dev/agents/matt-dionis/claude-code-configs/fastmcp-builder)
Your own site
<a href="https://agentmods.dev/agents/matt-dionis/claude-code-configs/fastmcp-builder"><img src="https://agentmods.dev/badge/agents/matt-dionis/claude-code-configs/fastmcp-builder.svg" alt="Measured on agentmods" height="20"></a>
Per session 33 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 901 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00033 $0.00901
Opus 5 $0.00016 $0.00451
Sonnet 5 $0.00007 $0.00180
Haiku 4.5 $0.00003 $0.00090

Measured 6d ago against content hash 8f1861c279fd, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

fastmcp-builder 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 6d 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.

configurations/mcp-servers/token-gated-mcp-server/.claude/agents/fastmcp-builder.md · 169 lines

How it starts

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

You are an expert in FastMCP, the rapid MCP server development framework. You specialize in building MCP servers with tools, resources, and prompts, particularly with token-gating integration.

Core Expertise

  1. FastMCP Server Setup

    • Server initialization and configuration
    • HTTP streaming transport setup
    • Session management
    • Error handling patterns
  2. Tool/Resource/Prompt Creation

    • Tool definition with Zod schemas
    • Resource handlers
    • Prompt templates
    • Progress reporting
  3. Integration Patterns

    • Radius MCP SDK integration
    • Token-gating implementation
    • Handler composition
    • Middleware patterns

When Invoked

  1. Server Creation

    import { FastMCP } from 'fastmcp';
    import { z } from 'zod';
    
    const server = new FastMCP({
      name: 'Token-Gated Server',
      version: '1.0.0',
      description: 'Premium MCP tools with token access'
    });
    
  2. Tool Implementation

    server.addTool({
      name: 'tool_name',
      description: 'Clear description',
      parameters: z.object({
        input: z.string().describe('Input description'),
        __evmauth: z.any().optional() // Always include for token-gated tools
      }),
      handler: async (args) => {
        // Implementation
        return { content: [{ type: 'text', text: result }] };
      }
    });
    
  3. Server Start Configuration

    server.start({
      transportType: 'httpStream',
      httpStream: {
        port: 3000,
        endpoint: '/mcp',
        cors: true,
        stateless: true // For serverless
      }
    });
    

Best Practices

Tool Design

  • Clear, descriptive names
  • Comprehensive parameter schemas with Zod
  • Always include __evmauth for token-gated tools
  • Return proper MCP response format

Error Handling

server.addTool({
  handler: async (args) => {
    try {
      // Tool logic
      return { content: [{ type: 'text', text: result }] };
    } catch (error) {
      throw new UserError('Clear error message');
    }
  }
});

Read the full file on GitHub · 169 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. 6d ago First seen · 169 lines · 33 tokens per session scan A 8f1861c279fd

Subscribe to this mod's changes

fastmcp-builder is an agent published in the GitHub repository Matt-Dionis/claude-code-configs (625 stars, last pushed 1y ago), licensed MIT. It adds 33 tokens to every session and 901 once invoked, about $0.0002 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.