SM

spurtcommerce/mcp

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

2 stars 0 forks 质量 57 趋势 8

MCP (Model Context Protocol) server for SpurtCommerce - enables AI agents to interact with SpurtCommerce via Product, Store, and Category APIs for search and browsing.

概览

This project implements a server that interacts with . The protocol supports various tools to interact with Spurtcommerce APIs for and category browsing. At the moment, the following APIs are supported: To run the Spurtcommerce MCP server using npx, use the following command: If you are working on the MCP server locally, you can run it by setting the MCP_SERVER_PATH environment variable to the absolute path of your built server file: If MCP_SERVER_PATH is not set or is empty, the client will fall back to: Add the following configuration to your settings.json. For more information, read the or the . On , you may need this alternative setup: This MCP server provides the following tools:

README

以下为原文 README 节选,完整内容请查看原文。

Spurtcommerce MCP Server

This project implements a Model Context Protocol (MCP) server that interacts with Spurtcommerce.
The protocol supports various tools to interact with Spurtcommerce APIs for product search and category browsing.

At the moment, the following APIs are supported:

  • Product API
  • Store API
  • Categories API

Setup

To run the Spurtcommerce MCP server using npx, use the following command:

npx -y @spurtcommerce/mcp@latest

Run from local build (for development)

If you are working on the MCP server locally, you can run it by setting the MCP_SERVER_PATH environment variable to the absolute path of your built server file:

export MCP_SERVER_PATH="/absolute/path/to/build/index.js"

If MCP_SERVER_PATH is not set or is empty, the client will fall back to:

npx @spurtcommerce/mcp@latest

Usage with Cursor or Claude Desktop

Add the following configuration to your settings.json.
For more information, read the Cursor MCP documentation or the Claude Desktop MCP guide.

{
  "mcpServers": {
    "spurtcommerce-mcp": {
      "command": "npx",
      "args": ["-y", "@spurtcommerce/mcp@latest"],
      "env": {
        "SPURTCOMMERCE_API_URL": "https://your_backend/api",
        "SPURTCOMMERECE_API_KEY": "your_api_key_here"
      }
    }
  }
}

Windows Configuration

On Windows, you may need this alternative setup:

{
  "mcpServers": {
    "spurtcommerce-mcp": {
      "command": "cmd",
      "args": ["/k", "npx", "-y", "@spurtcommerce/mcp@latest"],
      "env": {
        "SPURTCOMMERCE_API_URL": "https://your_backend/api",
        "SPURTCOMMERECE_API_KEY": "your_api_key_here"
      }
    }
  }
}

Environment Variables

Variable Description
SPURTCOMMERCE_API_URL Base API URL for your Spurtcommerce backend
SPURTCOMMERECE_API_KEY API key for authenticating requests
MCP_SERVER_PATH (Optional) Absolute path to the built MCP server file for local development

Available Tools

This MCP server provides the following tools:

Tool Name Description
get_product_by_sku Retrieve detailed product information using SKU
get_all_category Fetch all available product categories
search_products Search products by keyword or filters

Tool Usage Guidelines

  • get_product_by_sku → Use when you know the SKU and want full product details.
  • get_all_category → Use when you need a list of categories for navigation or filtering.
  • search_products → Use when searching products by name, category, or other filters.

Available Prompts

Prompt Name Description
在 GitHub 查看完整 README

安装

npx -y @spurtcommerce/mcp@latest
新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "spurtcommerce-mcp": { "command": "npx", "args": ["-y", "@spurtcommerce/mcp@latest"], "env": { "SPURTCOMMERCE_API_URL": "https://your_backend/api", "SPURTCOMMERECE_API_KEY": "your_api_key_here" } } } }