Skip to main content
Glama

MCPServer — Python MCP Server with JSON Data Store

A complete, production-ready MCP (Model Context Protocol) Server built with Python.

  • REST API (FastAPI) backed by JSON files — zero DB setup

  • 17 MCP Tools that wrap every API endpoint

  • Mock OAuth for development → swap to real OAuth with one config flag

  • Ready for Claude Desktop, MCP Inspector, and any MCP client


Project Structure

MCPServer/
├── data/                     ← JSON "database" files (users, products, orders)
├── app/
│   ├── auth/                 ← Mock OAuth + real OAuth placeholder
│   ├── db/json_store.py      ← Thread-safe CRUD over JSON files
│   ├── routers/              ← FastAPI routes (users, products, orders)
│   ├── schemas/              ← Pydantic request/response models
│   ├── config.py             ← Settings (loaded from .env)
│   └── main.py               ← FastAPI entry point
├── mcp_server/
│   ├── tools/
│   │   ├── api_client.py     ← HTTP client calling the FastAPI backend
│   │   ├── user_tools.py     ← MCP tools for Users
│   │   ├── product_tools.py  ← MCP tools for Products
│   │   └── order_tools.py    ← MCP tools for Orders
│   └── server.py             ← MCP server entry point (stdio)
├── .env.example
└── requirements.txt

Related MCP server: etsy-mcp

Quick Start

1. Install dependencies

cd MCPServer
python -m venv .venv
.venv\Scripts\Activate.ps1
pip install -r requirements.txt

2. Configure environment

Copy-Item .env.example .env
# Edit .env if needed (defaults work out of the box)

3. Start the REST API

uvicorn app.main:app --reload --port 8000

Click Authorize in Swagger UI and enter: dev-secret-key-change-me

4. Start the MCP Server

python -m mcp_server.server

Available MCP Tools (17 total)

Users

Tool

Description

list_users

List users (filter by active/role)

get_user

Get user by ID

create_user

Create a new user

update_user

Update user fields

delete_user

Delete a user

Products

Tool

Description

list_products

List products (filter by category/price/active)

get_product

Get product by ID

create_product

Create a new product

update_product

Update product fields

update_product_stock

Update stock level only

delete_product

Delete a product

Orders

Tool

Description

list_orders

List orders (filter by user/status)

get_order

Get order by ID

create_order

Place an order (total auto-computed)

update_order

Update status or shipping address

cancel_order

Cancel pending/processing order

get_user_order_summary

Spending summary for a user


Connect to Claude Desktop

Add to %APPDATA%\Claude\claude_desktop_config.json:

{
  "mcpServers": {
    "mock-api": {
      "command": "python",
      "args": ["-m", "mcp_server.server"],
      "cwd": "C:/path/to/MCPServer",
      "env": {
        "API_BASE_URL": "http://localhost:8000",
        "MOCK_API_KEY": "dev-secret-key-change-me"
      }
    }
  }
}

Switching to Real OAuth

  1. Set USE_MOCK_AUTH=false in .env

  2. Fill OAUTH_ISSUER, OAUTH_AUDIENCE, OAUTH_JWKS_URI in .env

  3. Implement validate_token() in app/auth/oauth.py

  4. Uncomment python-jose in requirements.txt and reinstall

  5. Update api_client.py to fetch a real access token instead of the API key

No other files need to change.


API Authentication (Development)

All endpoints require a Bearer token:

Authorization: Bearer dev-secret-key-change-me
git clone https://github.com/Bhanuprakashdadi145/Mcp-Server.git
cd MCPServer
python -m venv .venv
.\.venv\Scripts\Activate.ps1
pip install -r requirements.txt
Copy-Item .env.example .env
uvicorn app.main:app --reload --port 8000
python -m mcp_server.server

Change MOCK_API_KEY in .env to any value you prefer.

F
license - not found
-
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • F
    license
    -
    quality
    D
    maintenance
    A Model Context Protocol (MCP) server built with the mcp-framework for developing and managing custom tools. It provides a structured foundation for building and integrating modular components like data processors and API clients into Claude Desktop.
    Last updated
    7
  • A
    license
    A
    quality
    D
    maintenance
    A production-grade MCP server that enables AI assistants like Claude to read Etsy shop data—listings, orders, inventory, and stats—through eight read-only tools, using OAuth and automatic pagination.
    Last updated
    8
    MIT
  • A
    license
    C
    quality
    B
    maintenance
    MCP server that exposes the Amazon Selling Partner API to Claude Desktop and any other MCP client. It wraps the python-amazon-sp-api SDK and ships 55+ tools across 19 SP-API scopes with automatic pagination, throttle-aware retry and multi-marketplace support.
    Last updated
    53
    2
    MIT

View all related MCP servers

Related MCP Connectors

  • Hosted Amazon Seller Central and Amazon Ads MCP server for Claude, ChatGPT, Cursor, and agents.

  • Hosted Amazon Seller and Vendor MCP server for Claude, ChatGPT, Cursor, Codex, Gemini, Copilot.

  • Hosted MCP endpoint with realistic fake data for prototyping agents. 12 tools, no setup.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Bhanuprakashdadi145/Mcp-Server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server