Provides a structured HTTP client tool that supports GET, POST, PUT, PATCH, DELETE, HEAD, and OPTIONS requests with configurable headers, timeouts, redirect handling, and session persistence. Returns structured responses including status codes, headers, body content, timing metrics, and error handling.
curl-mcp
curl-mcp is an open-source HTTP/cURL tool for the Model Context Protocol (MCP).
It provides a single tool:
curl_request
This server is intended for use with any MCP-compatible client, such as:
ChatGPT Desktop
Roo Code
Cursor
Cline
Continue.dev
Custom MCP agents
No client-specific configuration examples are included here β each MCP client provides its own method for adding local MCP servers.
You simply run
β¨ Features
π MCP stdio server
Run locally and expose thecurl_requesttool to any MCP client.π§° Full HTTP support
SupportsGET,POST,PUT,PATCH,DELETE,HEAD,OPTIONS.π§± Structured JSON responses
Includes:HTTP status code
status text
headers
raw text body
timing metrics
total size
simple advice messages
π Timeout & network error handling
UsesAbortControllerunder the hood.π§ͺ Integration-test friendly
Includes a self-describing JSON test file for humans or AI agents.
π¦ Installation (from source)
βΆοΈ Running the MCP server
Start the stdio MCP server:
This launches the curl-mcp MCP server on stdio.
Your MCP client should then be configured (via its own UI or config system) to run that command.
Important:
MCP clients each have their own method of adding a local MCP server.
Please refer to your clientβs documentation for how to register a local command.
π Tool: curl_request
Input (schema overview)
Output (schema overview)
Notes:
Default
User-Agentis injected if none is provided (curl-mcp/<version>); override via headers if needed.response_typedefaults to text. Usejsonto parse/pretty-print JSON,binaryfor base64 + content-type/size metadata.persist_sessionis opt-in and keeps cookies in-memory for chained calls;follow_redirectscan be turned off to capture redirect responses.
π§ͺ Integration Tests
The file:
contains human- and AI-readable integration scenarios such as:
simple GET
POST echo
header round-trip
timeout behaviour
error handling
joke/cat/dog APIs
NASA APOD
Weather data for London
These can be executed manually or by an MCP client/agent using curl_request.
π Public Project Structure
π₯ Requirements
Node.js 20 or later (native
fetchsupport)
π§ Roadmap
Optional binary/base64 response mode
Optional JSON parse mode
Richer advice metadata
Simple test runner script
Packaging for npm / Homebrew
π License
MIT
This server cannot be installed