shopify-mcp
Shopify MCP 服务器
(如果喜欢请留下星星!)
适用于 Shopify API 的 MCP 服务器,支持通过 GraphQL API 与商店数据交互。该服务器提供用于管理产品、客户、订单等的工具。
特征
产品管理:搜索和检索产品信息
客户管理:加载客户数据并管理客户标签
订单管理:高级订单查询和过滤
GraphQL 集成:与 Shopify 的 GraphQL Admin API 直接集成
全面的错误处理:清晰的 API 和身份验证问题错误消息
Related MCP server: Shopify MCP Server
先决条件
Node.js(版本 16 或更高版本)
Shopify 自定义应用访问令牌(请参阅下面的设置说明)
设置
Shopify 访问令牌
要使用此 MCP 服务器,您需要在 Shopify 商店中创建一个自定义应用程序:
在 Shopify 管理员中,转到**“设置”** > “应用和销售渠道”
单击**“开发应用程序”** (您可能需要先启用开发人员预览)
单击**“创建应用程序”**
为您的应用设置名称(例如“Shopify MCP Server”)
点击配置管理 API 范围
选择以下范围:
read_products,write_productsread_customers,write_customersread_orders,write_orders
点击**“保存”**
点击**“安装应用程序”**
单击**“安装”**即可让应用访问您的商店数据
安装后,您将看到您的Admin API 访问令牌
复制此令牌 - 您将需要它进行配置
与 Claude Desktop 一起使用
将其添加到您的claude_desktop_config.json中:
{
"mcpServers": {
"shopify": {
"command": "npx",
"args": [
"shopify-mcp",
"--accessToken",
"<YOUR_ACCESS_TOKEN>",
"--domain",
"<YOUR_SHOP>.myshopify.com"
]
}
}
}Claude 桌面配置文件的位置:
MacOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%/Claude/claude_desktop_config.json
替代方案:使用环境变量在本地运行
如果您更喜欢使用环境变量而不是命令行参数:
使用您的 Shopify 凭据创建一个
.env文件:SHOPIFY_ACCESS_TOKEN=your_access_token MYSHOPIFY_DOMAIN=your-store.myshopify.com使用 npx 运行服务器:
npx shopify-mcp-server
直接安装(可选)
如果要全局安装该包:
npm install -g shopify-mcp-server然后运行它:
shopify-mcp-server --accessToken=<YOUR_ACCESS_TOKEN> --domain=<YOUR_SHOP>.myshopify.com可用工具
产品管理
get-products获取所有产品或按标题搜索
输入:
searchTitle(可选字符串):按标题过滤产品limit(数量):返回的最大产品数量
get-product-by-id通过 ID 获取特定产品
输入:
productId(字符串):要检索的产品的 ID
客户管理
get-customers获取客户或按姓名/电子邮件搜索
输入:
searchQuery(可选字符串):按姓名或电子邮件过滤客户limit(可选数字,默认值:10):返回的最大客户数量
update-customer更新客户信息
输入:
id(字符串,必需):Shopify 客户 ID(仅限数字 ID,例如“6276879810626”)firstName(字符串,可选):客户的名字lastName(字符串,可选):客户的姓氏email(字符串,可选):客户的电子邮件地址phone(字符串,可选):客户的电话号码tags(字符串数组,可选):应用于客户的标签note(字符串,可选):关于客户的注释taxExempt(布尔值,可选):客户是否免税metafields(对象数组,可选):用于存储附加数据的客户元字段
get-customer-orders获取特定客户的订单
输入:
customerId(字符串,必需):Shopify 客户 ID(仅限数字 ID,例如“6276879810626”)limit(可选数字,默认值:10):返回的最大订单数量
订单管理
get-orders通过可选过滤获取订单
输入:
status(可选字符串):按订单状态过滤limit(可选数字,默认值:10):返回的最大订单数量
get-order-by-id通过ID获取特定订单
输入:
orderId(字符串,必需):完整的 Shopify 订单 ID(例如,“gid://shopify/Order/6090960994370”)
update-order使用新信息更新现有订单
输入:
id(字符串,必需):Shopify 订单 IDtags(字符串数组,可选):订单的新标签email(字符串,可选):更新客户电子邮件note(字符串,可选):订单备注customAttributes(对象数组,可选):订单的自定义属性metafields(对象数组,可选):排序元字段shippingAddress(对象,可选):送货地址信息
调试
如果遇到问题,请检查 Claude Desktop 的 MCP 日志:
tail -n 20 -f ~/Library/Logs/Claude/mcp*.log执照
麻省理工学院
Available Tools
5 toolsget-customersD
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| searchQuery | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Tool has no description.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Tool has no description.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Tool has no description.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Tool has no description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Tool has no description.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Tool has no description.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get-ordersD
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| status | No | any |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Tool has no description.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Tool has no description.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Tool has no description.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Tool has no description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Tool has no description.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Tool has no description.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get-product-by-idD
| Name | Required | Description | Default |
|---|---|---|---|
| productId | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Tool has no description.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Tool has no description.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Tool has no description.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Tool has no description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Tool has no description.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Tool has no description.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get-productsD
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| searchTitle | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Tool has no description.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Tool has no description.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Tool has no description.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Tool has no description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Tool has no description.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Tool has no description.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
update-orderD
| Name | Required | Description | Default |
|---|---|---|---|
| customAttributes | No | ||
| No | |||
| id | Yes | ||
| metafields | No | ||
| note | No | ||
| shippingAddress | No | ||
| tags | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Tool has no description.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Tool has no description.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Tool has no description.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Tool has no description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Tool has no description.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Tool has no description.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
5 tool updates
v1.0.0- First observed
get-customers - First observed
get-orders - First observed
get-product-by-id - First observed
get-products - First observed
update-order
TDQS
Scored across 5 tools
Each tool has a clearly distinct purpose targeting specific Shopify resources: customers, orders, products, and order updates. There is no overlap in functionality, making it easy for an agent to select the correct tool for each task without confusion.
The naming follows a consistent verb-noun pattern with hyphens (e.g., get-customers, update-order), which is predictable and readable. The minor deviation is that 'get-product-by-id' includes a preposition, slightly breaking the pure verb-noun style, but overall the pattern is clear and mostly uniform.
With 5 tools, the count is reasonable for a Shopify integration, but it feels borderline thin for covering the domain comprehensively. While core read operations are present, the scope might benefit from additional tools for full CRUD or lifecycle coverage, such as creating or deleting resources.
The tool set has significant gaps for a Shopify server, focusing heavily on read operations (get-customers, get-orders, get-products) with only one update tool (update-order). Missing are create and delete operations for customers, orders, and products, as well as other common actions like inventory management or webhook handling, which limits agent workflows and could lead to failures in broader tasks.
Maintenance
Related MCP Connectors
Shopify MCP Pack — wraps the Shopify Admin REST API (2024-01)
Manage a Shopify store's Sternify bundles, gifts, upsells, banners and reviews via OAuth.
The public product catalogue and collections of any Shopify storefront, as structured JSON.
Read store products, orders, customers, categories and coupons; adjust inventory and update orders.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables interaction with Shopify store data using the GraphQL API, supporting product, customer, and order management with comprehensive error handling.15125 npm18MIT
- -licenseNot gradedqualityNot gradedmaintenanceEnables interaction with Shopify store data via GraphQL API, providing tools for managing products, customers, orders, discounts, and more with robust error handling.125 npm30-
- AlicenseNot gradedqualityDmaintenanceEnables interaction with Shopify stores through GraphQL API, providing tools for managing products, customers, orders, and more.125 npm10MIT
- AlicenseCqualityDmaintenanceEnables interaction with Shopify store data through GraphQL API, providing tools for managing products, customers, orders, blogs, and articles.152,216 npm4MIT