WisWes Magento MCP

by wiswes

Not rated
GitHub

About

Exposes a Magento 2 store's catalog, cart, checkout, customer, sales and wishlist operations as MCP tools, so an AI agent can search products and build a real cart against the live store.

Details

Author
wiswes
Categories
Cloud Service, Other, Database, Automation

Auth — set automatically by the Install handshake (wiswes_mcp/auth/*)

# Composer composer update wiswes/magento-mcp bin/magento setup:upgrade bin/magento setup:di:compile bin/magento cache:flush # Git cd app/code/WisWes/MCP && git fetch && git checkout v<new-tag> && cd - bin/magento setup:upgrade bin/magento setup:di:compile bin/magento cache:flush # ZIP — download the new archive and unzip over the existing folder, then run the same setup commands.
bin/magento module:disable WisWes_MCP bin/magento setup:upgrade bin/magento setup:di:compile bin/magento cache:flush # Composer composer remove wiswes/magento-mcp # Git / ZIP rm -rf app/code/WisWes/MCP # Optional — wipe the install secret bin/magento config:set wiswes_mcp/auth/shared_secret '' bin/magento config:set wiswes_mcp/auth/admin_id ''

In WisWes, clear the connection underConfiguration → Commerce.

The official WisWes module for Magento 2. Plugs your store into theWisWesAI shopping assistant (wiswes.com) over theModel Context Protocol (MCP).

- A stateless MCP HTTP endpoint at/mcp, served through your existing Magento web server — no separate process to manage.
- 22 typed tools across catalog, cart, checkout, customer, sales, and wishlist.
- A one-click admin handshake that hands a shared secret to your WisWes workspace.
- Nightly catalogue push to the WisWes vector index for semantic product search.

What this gives you:theWeschat persona on your storefront can read your live Magento data and act on the cart with no glue code. Shoppers ask questions in natural language, Wes calls the right tool, you ship more orders.

- Module name:WisWes_MCP
- Composer package:wiswes/magento-mcp
- Tested Magento versions:2.4.4, 2.4.5, 2.4.6, 2.4.7
- PHP:8.1 / 8.2 / 8.3 / 8.4

- Install

- Option A — Composer (recommended)
-
Option B — Git clone
-
Option C — ZIP archive

Pick one of the three install paths. Composer is recommended for production.

composer require wiswes/magento-mcp bin/magento module:enable WisWes_MCP bin/magento setup:upgrade bin/magento setup:di:compile bin/magento cache:flush

The package is published onPackagist. Pin a major line withcomposer require wiswes/magento-mcp:^1.0.

mkdir -p app/code/WisWes git clone https://github.com/wiswes/magento.git app/code/WisWes/MCP cd app/code/WisWes/MCP && git checkout v1.0.7 && cd - bin/magento module:enable WisWes_MCP bin/magento setup:upgrade bin/magento setup:di:compile bin/magento cache:flush

Download the archive from theReleases pageand unzip into your Magento root:

unzip ~/Downloads/wiswes-magento-1.0.7.zip -d . mkdir -p app/code/WisWes && mv wiswes-magento-1.0.7 app/code/WisWes/MCP bin/magento module:enable WisWes_MCP bin/magento setup:upgrade bin/magento setup:di:compile bin/magento cache:flush

The MCP endpoint is served by your existing web server athttps://<your-magento>/mcp. There isno separate process to start— oncesetup:upgraderuns, the route is live.

Connecting to your WisWes workspace is a one-click handshake from the Magento admin:
- OpenStores → Configuration → WisWes Chat → WisWes Chat MCP → Connection.
- (Optional) Set theWisWes Dashboard URLif you're connecting to a staging or self-hosted dashboard. Default:https://api.wiswes.com/.
- Save the config.
- OpenStores → Configuration → WisWes Chat → WisWes Chat Widget → Installand click theInstallbutton.
- Magento generates a long random shared secret unique to this install, persists it (encrypted) underwiswes_mcp/auth/shared_secret, and redirects you to the WisWes dashboard with the secret embedded asinstall_tokenin the URL.
- The dashboard saves the token on your tenant's CommerceConfig. From now on every WisWes chat reaches your store asPOST https://<your-magento>/mcpwithAuthorization: Bearer <secret>.

The merchant never sees the secret in the browser — it travels server-to-server via a redirect over HTTPS.

Tools fall into three categories based on the Magento context they need:

WisWes serves product search out of its own vector index, populated from your Magento store. The push runs nightly at 03:00 by default; trigger it manually after a bulk catalogue change:

# from Magento root bin/magento wiswes:products:push # Pushed 4271 products in 43 batches (upserted=4271, skipped_operator=0, skipped_cap=0)

Or clickPush catalogue nowunderStores → Configuration → WisWes Chat → WisWes Chat MCP → Catalogue Sync.

The push ships a compact retrieval payload (sku,name,url,price) plus a metadata blob built from name + short description + searchable attributes. The blob is what WisWes embeds; the retrieval payload is what the LLM sees verbatim when a result matches.

The push is incremental — only enabled, visible products are sent, batched 100 at a time. Auth uses the same shared secret minted by the Install handshake.

The WisWes chat bubble is a single<script>tag. The module doesnotauto-inject it — paste it into Magento's native script areas instead, so your install path is identical to Shopify or any custom storefront:

- Stores → Configuration → Design → HTML Head → Scripts and Style Sheets, or
- default_head_blocks.xmlin your theme

Copy the snippet from your WisWes workspace underConfiguration → Commerce → Embed snippet. It looks like:

<script src="https://app.wiswes.com/api/widget/embed.js?user_token=YOUR_TENANT_TOKEN" defer></script>

The token in the snippet is your tenant ID — every chat that loads via this snippet is scoped to your workspace.
- MCP endpoint reachable.From any host that WisWes can reach:

curl -X POST https://<your-magento>/mcp \ -H 'Authorization: Bearer <your-shared-secret>' \ -H 'Content-Type: application/json' \ -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'

Full tool reference + arguments lives in theWisWes docs.

22 tools across six groups. Names listed are the MCP tool ids the agent sees.

Every tool returns a typed array or throws a MagentoLocalizedExceptionwith a shopper-safe message — no raw stack traces leak to the agent.

Once installed and connected, the day-to-day workflow is:
- Customers chatwith Wes via the WisWes widget on your storefront.
- Wes selects toolsto answer questions or take actions — search the catalog, look up an order, add to cart.
- Tool calls hit/mcpon your store, which reads/writes through Magento's standard service contracts so all your existing extension hooks fire (price rules, stock reservations, sales rules, etc.).
- Results return to Wes, who replies in natural language with product cards, status updates, or confirmations.

You can scope which tools are available per workspace underBehavior → Toolsin WisWes — toggle individual tools on/off, override their description (the prompt text the model reads), or pin argument defaults. None of this requires touching PHP.

Every Magento tool is a plain PHP class with a#[McpTool]attribute. Drop a class intoMcp/Tool/..., rebuild the DI cache, clear the OPcache, and the tool appears in your WisWes workspace within seconds.

<?php declare(strict_types=1); namespace WisWes\MCP\Mcp\Tool\Loyalty; use PhpMcp\Server\Attributes\McpTool; class LoyaltyPointsTool { public function __construct( private readonly \Acme\Loyalty\Api\PointsClient $client, ) {} #[McpTool( name: 'loyalty:points', description: 'Returns the authenticated customer\'s loyalty tier and current points balance. Arguments: none. Customer bearer token required.' )] public function points(): array { $snapshot = $this->client->snapshotForCurrentUser(); return [ 'tier' => $snapshot->getTier(), 'points' => $snapshot->getBalance(), 'tier_progress' => $snapshot->getProgressToNext(), ]; } }
bin/magento setup:di:compile bin/magento cache:flush

The tool appears underBehavior → Toolsin WisWes labelledloyalty:points.

- One tool, one job.The model picks better between ten narrow tools than between three broad ones.
- Be specific indescription.It's the prompt the model reads when deciding whether to call your tool. Include each argument, the return shape, and whennotto use the tool.
- Validate at the boundary.ThrowMagento\Framework\Exception\LocalizedExceptionwith a shopper-safe message — the agent will surface it as-is.
- Return arrays, not DTOs.Strict typed arrays serialize cleanly to MCP. Hide internals (row_id,parent_id, internal flags) from the response unless the model needs them.
- Stay stateless.Tools should work the same on first call and 1,000th call. Cart / order state belongs in Magento, not in the tool class.

#[McpTool( name: 'sales:track_order', description: 'Returns carrier and tracking URL for an order. Arguments: order_id (string, required).' )] public function track(string $orderId): array { $shipment = $this->client->getLatestShipment($orderId); return [ 'order_id' => $orderId, 'carrier' => $shipment->getCarrier(), 'status' => $shipment->getStatus(), 'tracking_url' => $shipment->getTrackingUrl(), ]; }

To run a curated subset, set thewiswes_mcp/tools/includeconfig value to a comma-separated glob list:

bin/magento config:set wiswes_mcp/tools/include 'product:,cart:,order:info' bin/magento cache:flush

(the default) means all built-in + custom tools are exposed.

All settings live underStores → Configuration → WisWes Chat(or viabin/magento config:set).

Auth — set automatically by the Install handshake (wiswes_mcp/auth/)

# Composer composer update wiswes/magento-mcp bin/magento setup:upgrade bin/magento setup:di:compile bin/magento cache:flush # Git cd app/code/WisWes/MCP && git fetch && git checkout v<new-tag> && cd - bin/magento setup:upgrade bin/magento setup:di:compile bin/magento cache:flush # ZIP — download the new archive and unzip over the existing folder, then run the same setup commands.
bin/magento module:disable WisWes_MCP bin/magento setup:upgrade bin/magento setup:di:compile bin/magento cache:flush # Composer composer remove wiswes/magento-mcp # Git / ZIP rm -rf app/code/WisWes/MCP # Optional — wipe the install secret bin/magento config:set wiswes_mcp/auth/shared_secret '' bin/magento config:set wiswes_mcp/auth/admin_id ''

In WisWes, clear the connection underConfiguration → Commerce.

Module installs but no tools show up in WisWes

- Runbin/magento setup:di:compile— required after any new tool class is added.
- Clear OPcache (bin/magento cache:flushor restart php-fpm) — tool discovery happens at first request after a deploy.
- Check the MCP URL is reachable from WisWes (firewall, NAT). From a WisWes-side host:

curl -i -X POST https://<your-magento>/mcp \ -H 'Authorization: Bearer <your-secret>' \ -H 'Content-Type: application/json' \ -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'

- The shared secret rotated or wasn't installed. Re-run the Install handshake fromStores → Configuration → WisWes Chat → Install.
- For customer-scoped tools (cart, customer, order), the storefront chat must be identified — anonymous chats can't read the cart.

Composer can't find a matching version ofwiswes/magento-mcp

Runcomposer clear-cache, then re-trycomposer require wiswes/magento-mcp:^1.0. Packagist refreshes its index within seconds of every tagged push, so this is almost always a stale local cache.

To install from a feature branch that hasn't been tagged yet, add the GitHub source as a VCS repository in yourcomposer.json:

{ "repositories": [ { "type": "vcs", "url": "https://github.com/wiswes/magento" } ] }

Catalogue push reportsskipped_caporskipped_operator

- skipped_cap— your WisWes plan's product index limit was hit. Upgrade the plan or trim the catalog filter.
- skipped_operator— a row was rejected by the WisWes side as malformed (missing SKU, empty name). Inspect via:

bin/magento wiswes:products:push -vvv

- Confirm the module is enabled:bin/magento module:status WisWes_MCP.
- Confirm themcproute is registered:bin/magento info:routes:url:list 2>/dev/null | grep mcp(or checketc/frontend/routes.xml).
- Re-runbin/magento setup:upgrade.

- Docs:https://wiswes.com/docs
- Install guide:
https://wiswes.com/install/magento
- Issues:
https://github.com/wiswes/magento/issues
- Email:
services@wiswes.com
- Paid integration:
https://wiswes.com/services#magento-dev— we install, configure, and ship the widget on your store for you.

Released under theGNU General Public License v3.0— see the LICENSE file for full terms.

Give your AI a direct line into your Swell store. Manage products, orders, and customers through natural conversation.

Centralized management of RePricing for Amazon, eBay, and Kaufland, Lost & Found for Amazon FBA, and integrated HelpDesk.

Skyvia MCP Endpoint is a no-code gateway that makes your business data accessible to AI assistants in real time.

Manage products, orders, and customers on Color Me Shop

A Model Context Protocol (MCP) server and standalone CLI for querying PowerPlatform / Dataverse environments. Supports multiple environments, entity metadata, records, plugins, flows, solutions, workflows, business rules, security roles, and more.

An ecommerce assistant for Salesforce, enabling interaction with orders, returns, and customer service operations.

Shopify MCP server for interacting with Shopify store data through GraphQL, including products, orders, customers, and ecommerce workflows.

D2C eCommerce fulfillment platform: manage orders, inventory, shipments, campaigns, and billing via AI agents

Built for the next generation of intelligent experiences, ActiveCampaign's remote MCP server makes it easy for AI agents to understand, store, and use customer context across tools, channels, and workflows.

Apify-hosted MCP server for Airtable with 15 tools. Full CRUD for records, tables, fields, search, and schema inspection. No local setup needed.

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.