shopify-mcp
by GeLi2001
MCP server for Shopify api, usable on mcp clients such as Anthropic's Claude and Cursor IDE
What is shopify-mcp
Shopify MCP Server
(please leave a star if you like!)
MCP Server for Shopify API, enabling interaction with store data through GraphQL API. This server provides tools for managing products, customers, orders, and more.
Features
- Product Management: Search and retrieve product information
- Customer Management: Load customer data and manage customer tags
- Order Management: Advanced order querying and filtering
- GraphQL Integration: Direct integration with Shopify's GraphQL Admin API
- Comprehensive Error Handling: Clear error messages for API and authentication issues
Prerequisites
- Node.js (version 16 or higher)
- Shopify Custom App Access Token (see setup instructions below)
Setup
Shopify Access Token
To use this MCP server, you'll need to create a custom app in your Shopify store:
- From your Shopify admin, go to Settings > Apps and sales channels
- Click Develop apps (you may need to enable developer preview first)
- Click Create an app
- Set a name for your app (e.g., "Shopify MCP Server")
- Click Configure Admin API scopes
- Select the following scopes:
read_products
,write_products
read_customers
,write_customers
read_orders
,write_orders
- Click Save
- Click Install app
- Click Install to give the app access to your store data
- After installation, you'll see your Admin API access token
- Copy this token - you'll need it for configuration
Usage with Claude Desktop
Add this to your claude_desktop_config.json
:
{
"mcpServers": {
"shopify": {
"command": "npx",
"args": [
"shopify-mcp",
"--accessToken",
"<YOUR_ACCESS_TOKEN>",
"--domain",
"<YOUR_SHOP>.myshopify.com"
]
}
}
}
Locations for the Claude Desktop config file:
- MacOS:
~/Library/Application Support/Claude/claude_desktop_config.json
- Windows:
%APPDATA%/Claude/claude_desktop_config.json
Alternative: Run Locally with Environment Variables
If you prefer to use environment variables instead of command-line arguments:
-
Create a
.env
file with your Shopify credentials:SHOPIFY_ACCESS_TOKEN=your_access_token MYSHOPIFY_DOMAIN=your-store.myshopify.com
-
Run the server with npx:
npx shopify-mcp-server
Direct Installation (Optional)
If you want to install the package globally:
npm install -g shopify-mcp-server
Then run it:
shopify-mcp-server --accessToken=<YOUR_ACCESS_TOKEN> --domain=<YOUR_SHOP>.myshopify.com
Available Tools
Product Management
-
get-products
- Get all products or search by title
- Inputs:
searchTitle
(optional string): Filter products by titlelimit
(number): Maximum number of products to return
-
get-product-by-id
- Get a specific product by ID
- Inputs:
productId
(string): ID of the product to retrieve
Customer Management
-
get-customers
- Get customers or search by name/email
- Inputs:
searchQuery
(optional string): Filter customers by name or emaillimit
(optional number, default: 10): Maximum number of customers to return
-
update-customer
- Update a customer's information
- Inputs:
id
(string, required): Shopify customer ID (numeric ID only, like "6276879810626")firstName
(string, optional): Customer's first namelastName
(string, optional): Customer's last nameemail
(string, optional): Customer's email addressphone
(string, optional): Customer's phone numbertags
(array of strings, optional): Tags to apply to the customernote
(string, optional): Note about the customertaxExempt
(boolean, optional): Whether the customer is exempt from taxesmetafields
(array of objects, optional): Customer metafields for storing additional data
-
get-customer-orders
- Get orders for a specific customer
- Inputs:
customerId
(string, required): Shopify customer ID (numeric ID only, like "6276879810626")limit
(optional number, default: 10): Maximum number of orders to return
Order Management
-
get-orders
- Get orders with optional filtering
- Inputs:
status
(optional string): Filter by order statuslimit
(optional number, default: 10): Maximum number of orders to return
-
get-order-by-id
- Get a specific order by ID
- Inputs:
orderId
(string, required): Full Shopify order ID (e.g., "gid://shopify/Order/6090960994370")
-
update-order
- Update an existing order with new information
- Inputs:
id
(string, required): Shopify order IDtags
(array of strings, optional): New tags for the orderemail
(string, optional): Update customer emailnote
(string, optional): Order notescustomAttributes
(array of objects, optional): Custom attributes for the ordermetafields
(array of objects, optional): Order metafieldsshippingAddress
(object, optional): Shipping address information
Debugging
If you encounter issues, check Claude Desktop's MCP logs:
tail -n 20 -f ~/Library/Logs/Claude/mcp*.log
License
MIT
Leave a Comment
Comments section will be available soon. Stay tuned!
Frequently Asked Questions
What is MCP?
MCP (Model Context Protocol) is an open protocol that standardizes how applications provide context to LLMs. Think of MCP like a USB-C port for AI applications, providing a standardized way to connect AI models to different data sources and tools.
What are MCP Servers?
MCP Servers are lightweight programs that expose specific capabilities through the standardized Model Context Protocol. They act as bridges between LLMs like Claude and various data sources or services, allowing secure access to files, databases, APIs, and other resources.
How do MCP Servers work?
MCP Servers follow a client-server architecture where a host application (like Claude Desktop) connects to multiple servers. Each server provides specific functionality through standardized endpoints and protocols, enabling Claude to access data and perform actions through the standardized protocol.
Are MCP Servers secure?
Yes, MCP Servers are designed with security in mind. They run locally with explicit configuration and permissions, require user approval for actions, and include built-in security features to prevent unauthorized access and ensure data privacy.
Related MCP Servers
Ableton Live MCP Server
MCP Server implementation for Ableton Live OSC control
Airbnb MCP Server
AI Agent Marketplace Index Search MCP Server
MCP Server for AI Agent Marketplace Index from DeepNLP
Algorand MCP Implementation
Algorand Model Context Protocol (Server & Client)
mcp-server-apache-airflow
pypi.org/project/mcp-server-apache-airflow/
airtable-mcp-server
๐๏ธ๐ค Airtable Model Context Protocol Server, for allowing AI systems to interact with your Airtable bases
Airtable MCP Server
Search, create and update Airtable bases, tables, fields, and records using Claude Desktop and MCP (Model Context Protocol) clients
Alphavantage MCP Server
A MCP server for the stock market data API, Alphavantage API.
Amadeus MCP Server
Amadeus MCP(Model Context Protocol) Server
Anki MCP Server
An MCP server for Anki
Submit Your MCP Server
Share your MCP server with the community
Submit Now