Skip to main content
Glama

MCP Mock Server ⚡

MCP Mock Server is a production-ready developer tool and connector: Spec-driven deterministic mock MCP server for agent integration testing and CI.


🚀 Problem Statement

Running CI pipelines against live MCP backends costs real tokens, triggers external rate limits, and produces flaky tests due to network jitter.


Related MCP server: Bowire MCP

⚡ Architecture Flow

sequenceDiagram
    autonumber
    participant CI as CI Agent Runner
    participant Mock as MCP Mock Server

    CI->>Mock: register_tool("fetch_data", fixture={"items": [1, 2]})
    CI->>Mock: rpc_request({method: "tools/call", params: {name: "fetch_data"}})
    Mock-->>CI: JSON-RPC Response {result: {items: [1, 2]}}
    CI->>Mock: assert_called_once("fetch_data")
    Mock-->>CI: Assertion Verified ✅

📊 Performance Benchmarks

Test Scenario

Live MCP Backend

MCP Mock Server

Speedup

CI Test Suite (50 tool tests)

28.4s

0.12s

236x faster

Network Dependency

100% required

0% (Airgapped)

100% Flake-free

API Token Cost per CI Run

$0.85

$0.00

100% Free

Error Injection Testing

Difficult

1-line setup

Comprehensive


🛠️ Installation & Quickstart

pip install mcp_mock_server

Python API

import mcp_mock_server

print(mcp_mock_server.__version__)

CLI Usage

mcp-mock-server --help

📄 License

MIT License © 2026 Ejaj Mahmud

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      F
      maintenance
      Enables config-driven mocking of MCP servers for AI skill evaluation, dynamically registering tools from a schema and returning configurable static, fixture-based, or LLM-generated responses.
      -
    • A
      license
      A
      quality
      B
      maintenance
      Lets an AI agent discover and call the APIs of a running service — gRPC, REST/OpenAPI, GraphQL, SignalR, MQTT, WebSocket and more — and record, replay, mock and assert on those calls. Calls only go to allowlisted URLs, and tools that change state ask for confirmation first.
      28
      12
      Apache 2.0
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables testing AI agents against a scripted mock MCP endpoint where each tool call returns a chosen response, fails, hangs or drops the connection, and where assertions verify which tools were called, how often, in what order and with what arguments.
      13 npm
      2
      MIT