Logo de Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop)

Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop)

Comunidade
ramakay

A Shopify MCP Server built to interact with Mock.shop

Publicado porramakay
RepositórioShopifyMockMCP
IdiomaTypeScript
Forks
5
Estrelas
13
Ferramentas disponíveis
0
Tipo de transportestdio
Categorias
Links
  • Conecte ferramentas a fluxos de trabalho de IA

    Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) disponibiliza recursos MCP que podem ser usados por clientes e agentes de IA compatíveis.

  • 0 ferramentas disponíveis

    Confira abaixo as ações que podem ser chamadas, incluindo nomes e descrições quando fornecidos pelo servidor.

  • Configuração pronta para copiar

    Use os exemplos de instalação para configurar este servidor no seu cliente MCP preferido.

  • Indicadores da comunidade de código aberto

    13 estrelas e 5 forks no repositório vinculado.

Shopify MCP Proxy & Mock Server (ShopifyMCPMockShop)

This project implements a Model Context Protocol (MCP) server that acts as an intelligent bridge and proxy to Shopify's Storefront API. It uniquely supports mock.shop for safe development and testing without requiring real store credentials.

The server communicates via Standard Input/Output (stdio), making it suitable for local integration with clients like Claude Desktop and Cursor.

Motivation

Generic AI developer tools and off-the-shelf MCP servers often promise much but can lack the transparency, safety mechanisms (like explicit ToolAnnotations), stability, or specific features needed for controlled development and testing, especially against rapidly evolving APIs like Shopify's.

This project was born from the need for a reliable, open-source Shopify MCP server that:

  • Prioritizes Safety: Integrates deeply with mock.shop to provide a crucial sandbox for risk-free development and accurate testing without impacting live stores.
  • Emphasizes Transparency & Control: Allows developers (and their AI partners) to understand exactly how interactions with the Shopify API occur, including which API versions are used and the potential impact of actions (via ToolAnnotations like readonly, destructive, etc.).
  • Addresses Specific Needs: Fills the gap left by purely informational tools or closed-source commercial offerings by providing a safe execution engine tailored for Shopify development workflows.

The goal is to enable developers to confidently leverage AI assistance for Shopify tasks, knowing they have a tool built with intentional guardrails and clear operational context.

Architecture

System Overview

The ShopifyMCPMockShop server follows a layered architecture that provides clean separation between MCP protocol handling and Shopify API integration:

System Architecture

Data Flow

This sequence diagram illustrates how a typical request flows through the system, from user interaction to API response:

Data Flow Diagram

Tool Hierarchy

The MCP server exposes a comprehensive set of tools organized by Shopify resource type:

Tool Hierarchy

Setup & Running Locally

This server is a standalone Node.js script.

  1. Clone the repository:

    bash
    git clone https://github.com/ramakay/ShopifyMockMCP.git
    cd ShopifyMCPMockShop
  2. Install dependencies:

    bash
    npm install
  3. Build the server:

    bash
    npm run build

    This compiles the TypeScript code into JavaScript in the dist directory (dist/server.js).

  4. Configure Environment (Optional - for Real Store):

    • If you want to connect to a real Shopify store instead of mock.shop, set the following environment variables before running the server (e.g., via export or a .env file loaded by your client):
      • SHOPIFY_STORE: Your store domain (e.g., your-store.myshopify.com). Required for real store usage.
      • SHOPIFY_ACCESS_TOKEN: Your Storefront API access token. Required for real store usage.
      • SHOPIFY_VERSION: Optional specific Storefront API version (e.g., 2025-04). Defaults to latest stable.
    • Note: Using mock.shop (default when SHOPIFY_STORE is not set) requires no environment variables.
    • Note: Admin API functionality is currently disabled but planned for future updates. Configuration variables (USE_ADMIN_API, ADMIN_ACCESS_TOKEN, ADMIN_VERSION) are not currently used.
  5. Running: The server is intended to be launched automatically by MCP clients (like Claude Desktop or Cursor) using the stdio configuration. You do not need to run npm run start manually. See the "Usage" section below.

Usage with Cursor or Claude Desktop

Configure your MCP client (Cursor, Claude Desktop) to launch this server via stdio. Add an entry like the following to the respective configuration file:

  • Claude Desktop: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Cursor: ~/.cursor/mcp.json (or similar)
json
{
  "mcpServers": {
    // ... other servers ...
    "shopify-mcp": {
      "command": "node",
      "args": [
        "/full/path/to/ShopifyMCPMockShop/dist/server.js"
      ],
      "env": {
        // Only needed if connecting to a REAL store:
        // "SHOPIFY_STORE": "your-store.myshopify.com",
        // "SHOPIFY_ACCESS_TOKEN": "your-storefront-token",
        // "SHOPIFY_VERSION": "2025-04"
      },
      "disabled": false,
      "alwaysAllow": []
    }
    // ... other servers ...
  }
}

Important:

  • Replace /full/path/to/ShopifyMCPMockShop with the absolute path to where you cloned the repository.
  • Only include the env variables if you are connecting to a real store.
  • Restart your client (Cursor/Claude Desktop) after modifying the configuration.

Available Tools

This MCP server currently provides tools for interacting with the Shopify Storefront API.

Tool NameDescriptionAPI
getShopInfoFetches basic shop details (name, description, currency).Storefront
getProductByIdFetches a specific product by ID. If includeImages is true, returns JSON details and the first image (75px) as a base64 ImageContentBlock.Storefront
findProductsSearches/filters products with pagination/sorting.Storefront
getCollectionByIdFetches a specific collection by ID, optionally including products.Storefront
findCollectionsSearches/filters collections with pagination/sorting.Storefront
cartCreateCreates a new shopping cart.Storefront
cartLinesAddAdds line items to an existing shopping cart.Storefront
cartLinesUpdateUpdates line items (e.g., quantity) in an existing shopping cart.Storefront
cartLinesRemoveRemoves line items from an existing shopping cart.Storefront
getCartFetches the details of an existing shopping cart by ID.Storefront

(Note: Admin API tools like getCustomerById and createProduct are planned for future updates and are currently disabled.)

Inspecting Server Capabilities

To verify the server is built correctly and see the exact capabilities it advertises to MCP clients, you can use the inspect script defined in package.json:

bash
# Ensure you have run 'npm install' and 'npm run build' first
# Run this from the project root directory
npm run inspect

This command executes the compiled server (node dist/server.js) and sends the standard mcp/capabilities request via its standard input. The server processes this request and prints its capabilities (including available tools, resource templates, and server information) as a JSON response to its standard output, which you will see in your terminal. This is useful for debugging and confirming the server's advertised functionality.

Known Issues

  • Inline Image Rendering: Clients like Claude Desktop and Cursor currently render ImageContentBlocks (used by getProductById when includeImages is true) in a separate UI block below the main text response, rather than inline. Attempts to use Markdown or HTML image tags within text blocks also failed to render inline in these clients.

Future Plans

  • Re-integrate and test Admin API tools (getCustomerById, createProduct, etc.).
  • Add configuration options for Admin API credentials (USE_ADMIN_API, ADMIN_ACCESS_TOKEN, ADMIN_VERSION).
  • Implement a testing framework.
  • Explore resource handling if client support improves.

License

MIT License

Instalação

TypingMind
{
  "mcpServers": {
    "shopifymockmcp": {
      "command": "node",
      "args": [
        "dist/server.js"
      ]
    }
  }
}

Use o MCP de Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) com vários modelos de IA

O TypingMind conecta as ferramentas MCP no nível do espaço de trabalho. Assim, após conectar Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop), é possível usá-lo com diferentes modelos de IA no TypingMind, em vez de configurá-lo separadamente para cada modelo. Este MCP é executado localmente no seu dispositivo por meio do conector MCP do TypingMind.

Guia de configuração para usar o conector local

Use esta opção quando o servidor MCP precisar acessar arquivos locais, aplicativos ou recursos privados no seu computador.

1

Abra as configurações de MCP

No TypingMind, vá até Configurações, Configurações avançadas e depois Model Context Protocol e selecione Configurar conector.

  1. Abra o TypingMind no navegador.
  2. Clique no ícone de Ajustes.
  3. Acesse Configurações avançadas.
  4. Abra a seção Model Context Protocol.
  5. Clique em Configurar conector e selecione Este dispositivo.
Tela de configuração do conector MCP do TypingMind com a opção Este dispositivo selecionada
2

Execute o comando do conector

Selecione Este dispositivo, copie o comando do TypingMind e execute-o no Terminal. Mantenha o processo em execução enquanto usa o MCP.

  1. Copie o comando de configuração exibido pelo TypingMind.
  2. Abra o Terminal no macOS ou o Windows Terminal no Windows.
  3. Cole e execute o comando.
  4. Autorize a instalação do pacote se o Terminal pedir confirmação para continuar.
  5. Mantenha o processo em execução na janela do Terminal enquanto usa as ferramentas MCP.
3

Adicione Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) como servidor

Quando o status do conector for Pronto, clique em Editar e cole a configuração do servidor MCP.

  1. Aguarde até que o status do conector mostre Pronto.
  2. Clique em Editar.
  3. Cole a configuração do servidor MCP de Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop).
  4. Salve a lista de servidores.
  5. Atualize para confirmar se o conector ainda está pronto para uso.
Configurações de MCP do TypingMind mostrando um servidor ativo e o botão Editar
{
  "mcpServers": {
    "shopifymockmcp": {
      "command": "npx",
      "args": [
        "-y",
        "@ramakay/shopify-mcp-proxy"
      ]
    }
  }
}
4

Use a conexão com diferentes modelos

Salve a lista de servidores, abra Plugins, ative as ferramentas MCP de Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop), selecione qualquer modelo de IA compatível no TypingMind e use as ferramentas no chat ou atribua-as a um agente de IA.

  1. Abra a página Plugins no TypingMind.
  2. Ative as ferramentas MCP de Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop).
  3. Inicie um chat e escolha o modelo de IA que deseja usar.
  4. Use as ferramentas MCP no chat ou atribua-as a um agente de IA.
  5. Mude para outro modelo de IA sempre que necessário, sem reconectar o MCP.
Chat do TypingMind usando ferramentas MCP ativadas com um modelo de IA selecionado
Pode usar Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) para me ajudar nesta tarefa?
Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop)
Claro. Já li.
Veja o que encontrei usando Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop).

Perguntas frequentes

Para que serve o servidor MCP Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop)?

Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) é um servidor MCP que permite que aplicativos de IA compatíveis se conectem a ferramentas externas e informações de contexto. No TypingMind, basta adicionar esse servidor MCP uma vez para disponibilizar suas ferramentas no seu espaço de trabalho com IA.

Posso usar o MCP Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) com vários modelos de IA no TypingMind?

Sim. O TypingMind conecta as ferramentas MCP no nível do espaço de trabalho, permitindo usar Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) com diferentes modelos de IA, como Claude, ChatGPT, Gemini ou outros modelos configurados no TypingMind, sem configurar o servidor MCP separadamente para cada modelo.

Por que usar o MCP Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) com o TypingMind?

O TypingMind é uma das melhores interfaces de chat com LLMs porque reúne vários modelos de IA, prompts, plugins, agentes de IA, chaves de API e ferramentas MCP em um só espaço de trabalho. Com Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) conectado, é possível usar suas ferramentas MCP nos seus modelos preferidos e manter seu fluxo de trabalho de chat organizado no TypingMind.

Como conecto o MCP Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) ao TypingMind?

Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) funciona por meio do conector MCP local do TypingMind. Essa é a melhor opção quando o servidor MCP precisa acessar arquivos locais, apps de desktop, ferramentas de linha de comando ou recursos privados no seu computador.

Quais ferramentas o MCP Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) oferece no TypingMind?

Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) disponibiliza recursos MCP que podem ser ativados na página Plugins do TypingMind e usados no chat ou atribuídos a agentes de IA.

Preciso compartilhar minhas chaves de API com o TypingMind para usar o MCP Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop)?

Não. O TypingMind prioriza o uso local e permite manter seus provedores de modelos, chaves de API, prompts e configuração MCP sob seu controle. Se Shopify MCP 代理与模拟服务器 (ShopifyMCPMockShop) exigir autenticação, adicione os cabeçalhos, as configurações OAuth ou a configuração local exigidos por esse servidor MCP ao criar a conexão.

Servidores MCP relacionados

Ver todos

Crie seu próprio espaço de IA agora

Inscreva-se na nossa newsletter para receber novidades sobre recursos e futuros sorteios 👇