Shopify MCP Server
Enables management of Shopify orders through the Admin REST API, allowing users to create new orders and retrieve order status details. It supports both local and remote access via SSE and STDIO transports for integration with MCP clients like Claude Desktop.
README
Shopify MCP Server
A Model Context Protocol (MCP) server for Shopify order management using the official MCP Python SDK.
Features
- ā MCP-Compliant: Follows official MCP specification
- š ļø Two Tools: Create orders and check order status via Shopify Admin REST API
- š Remote Access: SSE transport for cloud deployment
- š Secure: Environment-based credential management
Available Tools
1. create_order
Create new Shopify orders with line items and customer information.
Parameters:
line_items(array, required): Product items to ordercustomer_email(string, optional): Customer emailfinancial_status(string, optional): Payment status (default: "pending")test(boolean, optional): Create as test order (default: true)
2. get_order_status
Retrieve complete order details by order ID.
Parameters:
order_id(integer, required): Shopify order ID
Quick Start
Prerequisites
- Python 3.10 or higher
- Shopify Admin API access token
- Shopify store URL
Local Setup
# Clone the repository
cd mcp-server
# Create and activate virtual environment (recommended)
python -m venv mcpserver
mcpserver\Scripts\activate # Windows
# source mcpserver/bin/activate # macOS/Linux
# Install dependencies
pip install -r requirements.txt
# Configure environment variables
# Create .env file with:
SHOPIFY_ADMIN_API_BASE_URL=https://your-store.myshopify.com/admin/api/2025-07
SHOPIFY_ACCESS_TOKEN=your_access_token_here
USE_DUMMY_RESPONSES=true # Optional: returns mock data when API fails (for testing)
# Run the server
python shopify_mcp_server.py
Testing Mode (Dummy Responses)
For development and testing without valid Shopify credentials, enable dummy response mode:
# In .env file
USE_DUMMY_RESPONSES=true
When enabled:
- ā API errors return realistic mock data instead of error messages
- ā Test tools without valid Shopify store credentials
- ā See what successful responses look like
- ā
All responses include
"dummy_mode": trueflag
Demo:
python demo_dummy_responses.py
Example dummy response:
{
"success": true,
"dummy_mode": true,
"order_id": 9999999999,
"order_number": 1001,
"financial_status": "paid",
"total_price": "79.97",
"note": "This is a dummy response for testing purposes"
}
Disable for production:
USE_DUMMY_RESPONSES=false # or remove the variable entirely
Usage with MCP Clients
Claude Desktop Integration
Add to your Claude Desktop configuration file:
Windows: %APPDATA%\Claude\claude_desktop_config.json
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"shopify": {
"command": "python",
"args": ["C:\\path\\to\\mcp-server\\shopify_mcp_server.py"],
"env": {
"SHOPIFY_ADMIN_API_BASE_URL": "https://your-store.myshopify.com/admin/api/2025-07",
"SHOPIFY_ACCESS_TOKEN": "your_access_token_here"
}
}
}
}
Restart Claude Desktop, and you'll see the Shopify tools available.
MCP Inspector (Testing)
Test your server with the official MCP Inspector:
npx @modelcontextprotocol/inspector python shopify_mcp_server.py
This opens a web interface to test tool discovery and execution.
Remote Deployment
The server uses SSE (Server-Sent Events) transport for remote access, making it compatible with cloud platforms.
Railway Deployment
-
Fork/Clone this repository
-
Connect to Railway:
- Go to Railway.app
- Click "New Project" ā "Deploy from GitHub repo"
- Select this repository
-
Set Environment Variables in Railway dashboard:
SHOPIFY_ADMIN_API_BASE_URL=https://your-store.myshopify.com/admin/api/2025-07 SHOPIFY_ACCESS_TOKEN=your_access_token_here -
Deploy: Railway auto-deploys from
Procfile
Your MCP server will be available at: https://your-app.up.railway.app
Render Deployment
- Connect GitHub repo to Render
- Create new Web Service
- Set environment variables
- Set start command:
python shopify_mcp_server.py
Other Platforms (Fly.io, Heroku, etc.)
The server works on any platform supporting Python web services. Use the start command:
python shopify_mcp_server.py
Transport Options
The server supports two transport modes (configured in code):
# SSE Transport (remote access, default)
mcp.run(transport="sse")
# STDIO Transport (local only, for Claude Desktop)
mcp.run(transport="stdio")
Current configuration: SSE (remote deployment)
Environment Variables
| Variable | Description | Example |
|---|---|---|
SHOPIFY_ADMIN_API_BASE_URL |
Shopify Admin API endpoint | https://store.myshopify.com/admin/api/2025-07 |
SHOPIFY_ACCESS_TOKEN |
Admin API access token | shpat_xxxxx |
USE_DUMMY_RESPONSES |
Enable mock responses for testing (optional) | true or false (default: false) |
Security Best Practices
ā ļø Important Security Notes:
- Never commit
.envfiles to version control (already in.gitignore) - Use environment variables on hosting platforms
- Rotate access tokens regularly
- Enable HTTPS in production (automatic on Railway/Render)
- Restrict API scopes to minimum required permissions
Troubleshooting
"SHOPIFY_ACCESS_TOKEN not set"
- Verify
.envfile exists and contains the token - Check environment variables in your deployment platform
"Order not found" (404)
- Verify the order ID is correct (use numeric ID, not order number)
- Check API access token has permission to read orders
Tools not appearing in Claude Desktop
- Verify configuration file path is correct
- Check Python path in the
commandfield - Restart Claude Desktop after config changes
- Check Claude Desktop logs for errors
Development
Project Structure
mcp-server/
āāā shopify_mcp_server.py # Main MCP server
āāā requirements.txt # Python dependencies
āāā .env # Local environment variables (gitignored)
āāā Procfile # Railway/Heroku deployment
āāā README.md # This file
Testing
Use MCP Inspector for development testing:
npx @modelcontextprotocol/inspector python shopify_mcp_server.py
Resources
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.