Spark Customer Agent MCP Server
Provides tools for product discovery, cart management, coupon handling, and order history access through natural language interactions with Walmart's product ecosystem.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Spark Customer Agent MCP Server Show me smartphones under $300"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Spark Customer Agent MCP Server
A Model Context Protocol (MCP) server for integrating with Walmart products backend API. This server enables customers to shop using natural language through AI-powered conversations, providing tools for product discovery, cart management, coupon handling, and order history access.
๐๏ธ Natural Language Shopping Experience
This MCP server transforms the traditional shopping experience by allowing customers to interact with Walmart's product ecosystem using conversational AI. Customers can simply ask questions like "Show me smartphones under $500" or "What's in my cart?" and get instant, personalized responses.
Related MCP server: Amazon MCP Server
Features
๐ค AI-Powered Shopping: Natural language interactions for seamless shopping experiences
๐ Product Search: Search products by category (smartphones, tv, shoes, healthcare, electronics, fitness)
๐ฐ Price Filtering: Filter smartphones by maximum price with conversational queries
๐ Cart Management: View current cart items through simple voice or text commands
๐๏ธ Coupons: Access available discount coupons via natural language requests
๐ Order History: Retrieve past order information through conversational interface
๐ Reimagining Customer Experience with Emerging Technologies
In today's fast-paced, digital-first world, customer experience is the ultimate competitive advantage. With limitless options at their fingertips, modern shoppers expect seamless, intuitive and highly personalized interactionsโwhether they're browsing online, engaging via mobile or stepping into a physical store.
๐ฎ The Future of Retail Technology
This MCP server represents the convergence of several emerging technologies:
๐ง AI-Powered Shopping Assistants: Conversational commerce that understands customer intent and provides personalized recommendations
๐ Data-Driven Insights: Real-time analysis of shopping patterns to enhance customer engagement
๐ฏ Hyper-Personalized Experiences: Every interaction feels effortless, engaging and deeply relevant
โก Real-Time Commerce: Instant responses to customer queries about products, pricing, and availability
๐ Predictive Shopping: Anticipating customer needs through advanced analytics
Retailers that harness AI, data-driven insights and immersive technologies are redefining customer engagement. From hyper-personalized recommendations and predictive shopping experiences to dynamic pricing models and real-time conversational commerce, emerging technologies are creating deeper, more meaningful relationships between brands and consumers.
This project embodies Walmart's vision of leveraging emerging technologies to transform the way customers shop, offering ultra-personalized experiences that make every interaction feel effortless, engaging and deeply relevant. By combining the power of AI assistants with natural language processing, we're reimagining the future of retail to enhance customer experience, boost engagement and redefine convenience in shopping.
Available Tools
๐ ๏ธ Conversational Shopping Tools
Product Discovery:
get_products_by_category: Fetch products from a specific category using natural languageget_smartphones_by_price: Filter smartphones by maximum price through conversational queries
Cart Management:
get_cart_items: View shopping cart contents with simple voice or text commandsadd_to_cart: Add products to cart with specified quantitiesremove_from_cart: Remove products from cart (single item or all quantities)
Coupon & Discounts:
get_available_coupons: Get available discount codes via natural language requestsapply_coupon: Apply discount coupons to cart for savingsremove_coupon: Remove applied coupons from cart
Order Management:
get_order_history: Access order transaction history through conversational interfaceplace_order: Complete purchase with current cart items
๐ฌ Example Natural Language Interactions
Product Discovery:
"Show me all smartphones under $300" โ Uses
get_smartphones_by_price"What electronics do you have?" โ Uses
get_products_by_category
Cart Management:
"What's in my shopping cart?" โ Uses
get_cart_items"Add iPhone 15 to my cart" โ Uses
add_to_cart"Remove the Nike shoes from my cart" โ Uses
remove_from_cart
Coupons & Discounts:
"Do I have any coupons available?" โ Uses
get_available_coupons"Apply coupon SAVE20 to my cart" โ Uses
apply_coupon"Remove the coupon from my cart" โ Uses
remove_coupon
Order Management:
"Show me my recent orders" โ Uses
get_order_history"Place my order now" โ Uses
place_order
Prerequisites
Node.js (v18 or higher)
pnpm package manager
Backend API running on
http://localhost:3000
Installation
Clone the repository:
git clone https://github.com/khushal1512/spark-mcp.git
cd spark-mcpInstall dependencies:
pnpm installBuild the project:
pnpm buildDevelopment
Run in development mode with hot reload:
pnpm devWatch mode for continuous development:
pnpm watchProduction
Build and start the server:
pnpm build
pnpm startCursor Integration
To use this MCP server with Cursor, add the following configuration to your Cursor settings:
{
"mcpServers": {
"spark-customer-agent": {
"command": "node",
"args": ["path/to/spark-mcp/dist/index.js"]
}
}
}Backend API Endpoints
The server expects the following endpoints to be available:
Product Discovery:
GET /products/{category}- Get products by categoryGET /products/smartphones/{maxPrice}- Get smartphones under max price
Cart Management:
GET /cart- Get cart itemsPOST /cart/add- Add product to cartDELETE /cart/remove- Remove product from cart
Coupon Management:
GET /coupons- Get available couponsPOST /cart/apply-coupon- Apply coupon to cartDELETE /cart/remove-coupon- Remove coupon from cart
Order Management:
GET /orders- Get order historyPOST /orders/place- Place new order
Project Structure
spark-mcp/
โโโ src/
โ โโโ index.ts # Main MCP server implementation
โโโ dist/ # Compiled JavaScript output
โโโ package.json # Project configuration
โโโ tsconfig.json # TypeScript configuration
โโโ README.md # This fileConfiguration
Backend URL: Configure
BACKEND_BASE_URLinsrc/index.tsCategories: Modify
ALLOWED_CATEGORIESarray for different product categories
Contributing
Fork the repository
Create a feature branch:
git checkout -b feature-nameMake your changes
Build and test:
pnpm buildCommit your changes:
git commit -am 'Add some feature'Push to the branch:
git push origin feature-nameSubmit a pull request
License
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
Author
Khushal Agrawal
Available Tools
10 toolsadd_to_cartA
Add a product to the shopping cart with specified quantity
Inputs: productId (required), quantity.
apply_couponA
Apply a discount coupon to the shopping cart
Inputs: couponCode (required).
get_available_couponsA
Fetch all available coupons and discount codes
Inputs: no named parameters.
get_cart_itemsA
Fetch all items currently in the shopping cart
Inputs: no named parameters.
get_order_historyA
Fetch order history and transaction details
Inputs: no named parameters.
get_products_by_categoryB
Fetch all products from a specific category. Available categories: smartphones, tv, shoes, healthcare, electronics, fitness
Inputs: category (required).
get_smartphones_by_priceA
Filter smartphones by maximum price. This endpoint specifically filters smartphones only.
Inputs: maxPrice (required).
place_orderA
Place an order with the current cart items
Inputs: no named parameters.
remove_couponA
Remove the applied coupon from the shopping cart
Inputs: no named parameters.
remove_from_cartA
Remove a product from the shopping cart
Inputs: productId (required), removeAll.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogโฆ
TDQS
Scored across 10 tools
Each tool has a clearly distinct purpose: the product browsing, cart management, coupon, and ordering operations are all separate. The only potential overlap is get_products_by_category and get_smartphones_by_price, but the latter explicitly narrows to a specific category and price filter, making the distinction clear.
All tools follow a consistent verb_noun pattern using snake_case. Retrieval operations start with 'get', cart modifications use 'add_to'/'remove_from', coupon actions use 'apply'/'remove', and ordering uses 'place'. This uniform structure makes the tool names predictable and easy to navigate.
Ten tools is well-scoped for a customer agent focused on e-commerce. The set covers product discovery, cart management, coupon handling, and order placement without superfluous or redundant tools, making it neither too sparse nor bloated.
The tool set covers the core shopping lifecycle: browse by category/price, manage cart with items and coupons, place order, and view history. However, it lacks a direct product detail lookup or search by name/attribute, which is a notable but non-critical gap for agents handling product-specific queries.
Maintenance
Related MCP Connectors
AI shopping gateway for product search, inventory, carts, and merchant-hosted checkout.
Shop Amazon, Walmart, Target and Best Buy from chat: search, pay by card, track orders.
Routes natural-language shopping queries to merchant storefronts, returns normalized results.
AI-powered product search, affiliate links, and price negotiation for e-commerce platforms
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to search products, manage shopping carts, place orders, and retrieve order history from Amazon and Target accounts.3MIT
- AlicenseNot gradedqualityDmaintenanceEnables interaction with Amazon services through AI assistants, allowing users to search products, manage their cart, view order history, and place orders using natural language.10 npmMIT
- AlicenseBqualityDmaintenanceEnables AI agents to search products, manage cart, and track orders on Walmart.com via browser automation.1290 npm4MIT
- AlicenseNot gradedqualityCmaintenanceEnables product discovery, session-scoped carts, and confirmation-gated checkout through natural language, with deterministic routing and safety features.5 npmISC