socket.help

Mock MCP servers for testing agents and MCP clients

Create a temporary mock MCP server on socket.help with up to 10 tools, input schemas, static responses, errors and delays, served over Streamable HTTP.

Updated 27 October 2026

What a mock MCP server does

A mock MCP server is a temporary Model Context Protocol endpoint whose tools return text you configure. Use it to test how an agent or MCP client discovers tools, validates arguments, handles tool errors and copes with latency, without building a real server. Tools never execute code; each call returns its configured response.

Create a server

POST /api/mcp-servers with a name (up to 80 characters) and 1 to 10 tools. Query parameters set visibility, ttlSeconds and persistent as for other resources. The response includes endpointUrl, a managementToken and, for private servers, an accessToken.

Create a private mock MCP server
curl -X POST https://socket.help/api/mcp-servers \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Weather",
    "tools": [{
      "name": "get_forecast",
      "description": "Return a forecast for a city.",
      "inputSchema": {
        "type": "object",
        "properties": { "city": { "type": "string" } },
        "required": ["city"]
      },
      "response": "Sunny, 21 degrees",
      "delayMs": 500
    }]
  }'

# 201 Created
{
  "id": "SERVER_ID",
  "managementToken": "MANAGEMENT_TOKEN",
  "expiresAt": "2026-10-27T13:00:00.000Z",
  "visibility": "private",
  "accessVersion": "ACCESS_VERSION",
  "accessToken": "ACCESS_TOKEN",
  "endpointUrl": "https://socket.help/mcp/mock/SERVER_ID"
}

Tool fields

The whole configuration must fit in 80 KiB.

Mock tool configuration
FieldRules
nameUnique, 1 to 64 letters, digits, underscores or hyphens
descriptionUp to 500 characters
inputSchematype object with up to 20 properties of type string, number, integer or boolean; optional required list
responseText returned by every call, up to 10,000 bytes
isErrorOptional boolean; true marks the result as a tool error
delayMsOptional, 0 to 2000 milliseconds

Connect a client

The endpoint speaks Streamable HTTP over POST and returns JSON responses. Clients must send Accept: application/json, text/event-stream. GET returns 405: SSE streams and transport sessions are not provided. Supported protocol versions are 2025-11-25, 2025-06-18 and 2025-03-26.

Supported methods are initialize, ping, tools/list and tools/call. Calls are checked against the tool’s schema: missing required arguments, unknown arguments and wrong types return JSON-RPC error -32602. Notifications (requests without an id) get 202.

For a private server, send the access token in X-Access-Token or Authorization: Bearer on every request. Each server accepts up to 120 requests per minute.

Call a mock tool
curl https://socket.help/mcp/mock/SERVER_ID \
  -H "X-Access-Token: $ACCESS_TOKEN" \
  -H 'Accept: application/json, text/event-stream' \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call",
       "params":{"name":"get_forecast","arguments":{"city":"Paris"}}}'

{"jsonrpc":"2.0","id":1,"result":{"content":[{"type":"text","text":"Sunny, 21 degrees"}],"isError":false}}

Read, update and delete

GET /api/mcp-servers/{id} returns the configuration, visibility, accessVersion, expiresAt, uses and endpointUrl. PUT replaces the configuration and returns 204. DELETE removes the server immediately. Use the management token for anonymous servers and your API key for workspace servers.

Frequently asked questions

Can a mock MCP tool return different results for different arguments?

No. Each tool returns the same configured response for every valid call. Arguments are validated against the schema but not used to build the result.

How do I simulate a failing tool?

Set isError to true on the tool. The call succeeds at the protocol level and returns the configured text with isError: true. Add delayMs to simulate latency.

Does the mock server support resources or prompts?

No. It implements initialize, ping, tools/list and tools/call. Other methods return JSON-RPC error -32601.

Can I use an MCP client that requires SSE?

Use a client that supports Streamable HTTP with JSON responses. GET requests for an SSE stream return 405.