JSONPlaceholder MCP Server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@JSONPlaceholder MCP Server get user details for ID 5"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
JSONPlaceholder MCP Server
A modern Model Context Protocol (MCP) server built with FastMCP that provides access to the JSONPlaceholder API - a free fake REST API for testing and prototyping.
Features
This MCP server provides Resources, Tools, and Prompts for interacting with JSONPlaceholder:
π§ Tools (Actions)
get_posts - Retrieve all posts or a specific post by ID
get_users - Retrieve all users or a specific user by ID
get_comments - Retrieve comments, optionally filtered by post ID
get_albums - Retrieve albums, optionally filtered by user ID
get_photos - Retrieve photos, optionally filtered by album ID
get_todos - Retrieve todos, optionally filtered by user ID
create_post - Create a new post (simulated)
search_posts - Search posts by title or body content
π Resources (Data Access)
posts://all - Get all posts as a resource
posts://{post_id} - Get a specific post as a resource
users://all - Get all users as a resource
users://{user_id} - Get a specific user as a resource
π Prompts (Templates)
analyze_post - Generate analysis prompt for a specific post
user_profile_summary - Create comprehensive user profile analysis
How to add it to cursor:
"mcpServers": {
"jsonplaceholder": {
"command": "/Users/danielpopa/Projects/work/mcp-server/cursor_runner.sh",
"args": []
}
}
} Prerequisites
Python 3.10+
uv package manager
Installation
Clone or download this project
The project is already configured with uv. Simply run:
uv syncDevelopment & Testing
MCP Inspector (recommended for development):
uv run mcp dev server.pyThis opens an interactive web interface to test all tools, resources, and prompts.
Direct server execution:
uv run python server.pyTest API connectivity:
uv run python test_server.pyClaude Desktop Integration
Install directly into Claude Desktop:
uv run mcp install server.py --name "JSONPlaceholder API"Usage Examples
Once connected to an MCP client, you can:
Use Tools:
"Get all posts from JSONPlaceholder"
"Show me user details for user ID 1"
"Search for posts containing 'dolor'"
"Create a new post titled 'Test' with body 'Hello World' for user 1"
Access Resources:
The client can load
posts://allto get all posts as contextLoad
users://5to get user 5's details as background information
Use Prompts:
Use the "analyze_post" prompt with post ID 1 for detailed post analysis
Use "user_profile_summary" with user ID 2 for comprehensive user profiling
Related MCP server: MockMCP
API Information
This server uses the JSONPlaceholder API (https://jsonplaceholder.typicode.com/), which provides:
100 posts
10 users
500 comments
100 albums
5000 photos
200 todos
No API key is required as it's completely free and public.
Architecture
Built with FastMCP, this server demonstrates modern MCP patterns:
Decorator-based setup - Clean, Pythonic code
Type hints - Better development experience
Async/await - Efficient HTTP requests
Resource management - Proper data exposure to LLMs
Prompt templates - Reusable interaction patterns
Development tools - Built-in testing and debugging
Development
The server uses:
FastMCP - Modern MCP server framework
httpx - Async HTTP client
Python 3.10+ - Modern Python features
uv - Fast Python package management
Available Tools
8 toolscreate_postB
Create a new post (simulated - JSONPlaceholder doesn't actually store data)
Inputs: title (required), body (required), user_id (required).
get_albumsB
Retrieve albums, optionally filtered by user ID or get a specific album
Inputs: user_id, album_id.
get_commentsB
Retrieve comments, optionally filtered by post ID or get a specific comment
Inputs: post_id, comment_id.
get_photosB
Retrieve photos, optionally filtered by album ID or get a specific photo
Inputs: album_id, photo_id.
get_postsC
Retrieve all posts or a specific post by ID from JSONPlaceholder
Inputs: post_id.
get_todosB
Retrieve todos, optionally filtered by user ID or get a specific todo
Inputs: user_id, todo_id.
get_usersC
Retrieve all users or a specific user by ID
Inputs: user_id.
search_postsC
Search posts by title or body content
Inputs: query (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogβ¦
TDQS
Scored across 8 tools
Most tools are clearly distinct by resource type (posts, albums, comments, photos, todos, users), but 'get_posts' and 'search_posts' have overlapping purposes since both retrieve posts with different filtering approaches. The descriptions help clarify the distinction, but an agent might occasionally misselect between them.
All tools follow a consistent verb_noun pattern with 'create_' or 'get_' or 'search_' prefixes, all in snake_case. This predictability makes it easy for agents to understand and use the tool set without confusion.
With 8 tools, this server is well-scoped for interacting with JSONPlaceholder's mock REST API resources. Each tool corresponds to a key resource (posts, albums, comments, photos, todos, users), and the count is neither too sparse nor bloated for the domain.
The server covers retrieval (get) operations for all major resources and creation for posts, but lacks update and delete operations, which are typical in CRUD workflows. This creates notable gaps that agents must work around, as they cannot modify or remove data beyond creating posts.
Maintenance
Related MCP Connectors
AI-callable tools for API mocking, testing, monitoring, security, and automation.
Hosted MCP endpoint with realistic fake data for prototyping agents. 12 tools, no setup.
Agent utility API: 28+ free endpoints (hash, QR, DNS, scrape, JWT...) run by an autonomous AI agent.
API Tool Calls: Home cost planners, proofreading, QR and barcodes, page to Markdown, SEO checks and recalls. Free agent tools: 20 calls/day per IP, no key.
Related MCP Servers
- AlicenseAqualityDmaintenanceProvides seamless access to the Fake Store API for AI assistants with 18 CRUD tools for managing e-commerce data including products, carts, and users. Perfect for e-commerce demos, testing, and learning MCP development with zero configuration required.185 npmMIT
- AlicenseNot gradedqualityDmaintenanceHosted MCP endpoint that returns realistic fake data for prototyping agents. Paste one URL into Claude Code, Cursor, or Claude Desktop β 12 pre-built tools covering users, products, orders, events, email, and knowledge base search. No signup, no config, no auth. Built for developers who want to prototype agent workflows before wiring up a real backend.MIT
- AlicenseBqualityDmaintenanceManages user data with resources, tools, and prompts for CRUD operations on a JSON file.21MIT
- AlicenseAqualityDmaintenanceProvides AI assistants with access to the Fake Store API for e-commerce prototyping and testing, enabling queries on products, carts, and users.912 npmMIT