Cartix
Cartix is a read-only MCP connector that lets AI agents safely query and inspect WooCommerce orders, products, and inventory data.
Search and filter orders by status and ISO date range, with pagination.
Retrieve full normalized details for a specific order by ID, including line items, prices, and status.
Search the product catalog by keyword or SKU, with pagination.
Retrieve full details for a specific product by ID, including SKU, pricing, stock quantity, and status.
Audit store-wide inventory and filter for low-stock or out-of-stock items (threshold <= 5).
All operations are read-only; no create/update/delete/refund actions, and customer PII and credentials are stripped.
Provides read-only access to a WooCommerce merchant store, exposing tools to search and retrieve orders by status and date range, fetch order details with line items, search and retrieve products from the catalog, and inspect inventory levels with low-stock and out-of-stock filtering. Customer PII is stripped and all operations are read-only, with built-in rate-limit handling and bounded pagination.
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., "@Cartix which pending orders have been waiting more than 24 hours?"
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.
Cartix — WooCommerce Agent Connector
Cartix is a secure, read-only Model Context Protocol (MCP) connector that enables autonomous AI agents (Agent Studio, Claude Desktop, Cursor) to safely query, inspect, and reason over WooCommerce store data.
Built for the Razorpay Forward-Deployed Engineer, Agent Studio assessment.
Table of Contents
Related MCP server: WooCommerce Insights MCP
1. Overview & Problem Statement
The Problem
Merchants store critical operational data across WooCommerce (orders, fulfillment statuses, customer purchases, catalog pricing, and inventory levels). Normally, store managers must manually navigate dashboards, execute multiple searches, calculate order delays, and inspect stock logs to answer routine operational questions:
"Which pending orders have been waiting for more than 24 hours?"
"Which products are out of stock or running low?"
"Are any pending orders affected by products that are currently out of stock?"
AI agents cannot reliably access raw WooCommerce REST APIs directly because:
Exposing raw API credentials to an LLM context creates critical security vulnerabilities.
Raw merchant payloads contain sensitive customer PII (billing addresses, phone numbers, customer emails) and massive unstructured payloads that exhaust context windows.
Upstream merchant APIs enforce strict rate limits (HTTP 429), pagination boundaries, and transient network errors that LLMs cannot manage autonomously.
The Cartix Solution
Cartix serves as the hardened, reliable bridge between the AI agent and WooCommerce. It abstracts store complexity into clean, typed MCP tool primitives, enforces strictly read-only access, handles upstream rate-limiting with exponential backoff and jitter, redacts secrets, strips customer PII, and bounds pagination limits.
2. Architecture & Protocol Flow
┌─────────────────────────┐
│ Merchant / User │
└────────────┬────────────┘
│ Natural Language
▼
┌─────────────────────────┐
│ Agent Studio / LLM │
│ Claude / Cursor │
└────────────┬────────────┘
│
│ MCP Protocol (JSON-RPC 2.0)
▼
┌───────────────────────────────────────────────────────────┐
│ CARTIX │
│ MCP Server │
│ │
│ ┌─────────────────────────────────────────────────────┐ │
│ │ MCP Tools │ │
│ │ search_orders get_order search_products │ │
│ │ get_product get_inventory │ │
│ └──────────────────────────┬──────────────────────────┘ │
│ │ │
│ ┌──────────────────────────▼──────────────────────────┐ │
│ │ Service Layer │ │
│ │ OrderService ProductService InventoryService │ │
│ │ Validation Normalization Data Minimization│ │
│ └──────────────────────────┬──────────────────────────┘ │
│ │ │
│ ┌──────────────────────────▼──────────────────────────┐ │
│ │ Reliability Layer │ │
│ │ Exponential Backoff + Jitter • 429 Retry-After │ │
│ │ Token-Bucket Rate Limiter • Bounded Pagination │ │
│ │ Structured CartixError • Safe Logging + RequestIDs │ │
│ └──────────────────────────┬──────────────────────────┘ │
│ │ │
│ ┌──────────────────────────▼──────────────────────────┐ │
│ │ WooCommerce Client │ │
│ │ HTTPS Basic Auth • Secret Redaction • Timeouts │ │
│ └──────────────────────────┬──────────────────────────┘ │
└─────────────────────────────┼─────────────────────────────┘
│ HTTPS / REST (Read-Only)
▼
┌─────────────────────────┐
│ WooCommerce │
│ Merchant Store │
└─────────────────────────┘3. Agent vs Connector Boundaries
Responsibility | AI Agent (e.g. Agent Studio) | Cartix MCP Connector | WooCommerce |
Natural Language Understanding | ✅ Primary | ❌ No | ❌ No |
Tool Selection & Query Strategy | ✅ Primary | ❌ No | ❌ No |
Reasoning Over Timestamps & Stock | ✅ Primary | ❌ No | ❌ No |
Store Authentication & Secret Storage | ❌ Never | ✅ Server-side only | ❌ No |
Rate-Limit Backoff & Retries | ❌ No | ✅ Automatic (429 handling) | ❌ No |
Data Normalization & PII Removal | ❌ No | ✅ Strips PII, compacts schemas | ❌ No |
Source of Truth for Store Data | ❌ No | ❌ No | ✅ Primary |
4. Supported MCP Tools
Cartix exposes 5 production-ready, read-only MCP tools implemented in TypeScript with Zod validation:
1. search_orders
Purpose: Search and filter orders by status, date range, and pagination.
Inputs:
status(string, optional): Filter by status (pending,processing,completed,on-hold,failed,cancelled,refunded,any).date_from(ISO 8601 string, optional): Inclusive start datetime.date_to(ISO 8601 string, optional): Inclusive end datetime.page(integer, default: 1): Page number.limit(integer, 1-100, default: 20): Maximum records to return.
Output: Normalized order summaries with total amount, item count, timestamps, and bounded pagination metadata.
2. get_order
Purpose: Retrieve full details for a specific order by numeric ID.
Inputs:
order_id(positive integer, required): WooCommerce order ID.
Output: Complete normalized order containing line items (product ID, name, quantity, unit price, line total), status, and sanitized billing info. Returns
NOT_FOUNDif invalid.
3. search_products
Purpose: Search the catalog by text keyword or SKU.
Inputs:
query(string, optional): Keyword to match against titles, descriptions, or SKUs.page(integer, default: 1): Page number.limit(integer, 1-100, default: 20): Page size limit.
Output: Normalized product objects (ID, name, SKU, price, stock status, stock quantity).
4. get_product
Purpose: Retrieve full catalog specifications for a single product by numeric ID.
Inputs:
product_id(positive integer, required): WooCommerce product ID.
Output: Normalized product record with pricing tiers, stock quantity, and manage_stock flag.
5. get_inventory
Purpose: Audit store-wide inventory with deterministic low-stock and out-of-stock filtering.
Inputs:
low_stock_only(boolean, default: false): Whentrue, filters for items withstock_status === 'outofstock'or managedstock_quantity <= 5.page(integer, default: 1): Page number.limit(integer, 1-100, default: 20): Page size limit.
Output: Inventory records with
is_low_stockindicators.
5. Security & Data Minimization
What the Agent CAN do
✓ Search orders by status and date filters
✓ Retrieve specific order line items and statuses
✓ Search product catalog and inspect prices
✓ Query inventory levels and identify stockouts
What the Agent CANNOT do
✗ Create, modify, cancel, or refund orders
✗ Create, edit, or delete products
✗ Modify stock quantities or prices
✗ Access customer personal information (billing address, phone, email, customer IP are stripped)
✗ Access WooCommerce credentials, API keys, or raw authentication headers
Secret Scrubbing
All loggers and error formatters scrub sensitive credential patterns (ck_..., cs_..., Basic ..., Bearer ...) before any output.
6. Prerequisites & Installation
Prerequisites
Node.js: v20.0.0 or higher
npm: v10.0.0 or higher
WooCommerce Store: A WooCommerce store or test sandbox with REST API credentials
Installation
# Clone the repository
git clone https://github.com/ilakkiyan-j/Cartix.git
cd Cartix
# Install dependencies
npm install
# Copy environment template
cp .env.example .env7. WooCommerce Setup & Credentials
Log in to your WordPress admin dashboard (
https://your-store.com/wp-admin).Verify Settings → Permalinks is set to Post name (pretty permalinks are required for WooCommerce REST API).
Navigate to WooCommerce → Settings → Advanced → REST API.
Click Add Key:
Description:
Cartix Read-Only ConnectorPermissions: Select
Read
Copy the generated credentials into your local
.env:
WOOCOMMERCE_URL=https://your-store.com
WOOCOMMERCE_CONSUMER_KEY=ck_xxxxxxxxxxxxxxxxxxxxxxxx
WOOCOMMERCE_CONSUMER_SECRET=cs_xxxxxxxxxxxxxxxxxxxxxxxx
MCP_TRANSPORT=stdio
PORT=3000
NODE_ENV=development8. Read-Only Connection Verification
Cartix provides a non-mutating diagnostic script (scripts/verify-connection.ts) to validate store connectivity, API credentials, and read access before connecting AI agents:
# Verify read-only WooCommerce credentials and endpoint status
npm run verifyThis diagnostic utility connects via HTTPS Basic Auth, queries /wp-json/wc/v3/system_status, lists sample products, and retrieves recent orders without writing or mutating any merchant records.
9. Running the MCP Server
# Start in development mode (watches for changes)
npm run dev
# Build TypeScript
npm run build
# Start compiled production server (Stdio transport by default)
npm start10. Connecting to MCP Clients
1. Agent Studio (Razorpay)
Configure Cartix as a standard MCP tool source in Agent Studio:
Transport:
stdio(Command:node /absolute/path/to/Cartix/dist/src/index.js) orstreamable-http(Endpoint:http://localhost:3000/mcp)Environment: Pass
WOOCOMMERCE_URL,WOOCOMMERCE_CONSUMER_KEY, andWOOCOMMERCE_CONSUMER_SECRET.
2. Claude Desktop Configuration
Add Cartix to your Claude Desktop configuration (claude_desktop_config.json):
{
"mcpServers": {
"cartix": {
"command": "node",
"args": ["/absolute/path/to/Cartix/dist/src/index.js"],
"env": {
"WOOCOMMERCE_URL": "https://your-store.com",
"WOOCOMMERCE_CONSUMER_KEY": "ck_xxxxxxxxxxxxxxxxxxxxxxxx",
"WOOCOMMERCE_CONSUMER_SECRET": "cs_xxxxxxxxxxxxxxxxxxxxxxxx",
"MCP_TRANSPORT": "stdio"
}
}
}
}3. Cursor / Custom MCP Client
Connect using standard stdio transport pointing to node dist/src/index.js.
11. Testing & Verification
Cartix maintains an extensive automated test suite covering unit, integration, and failure modes on Vitest.
# Run all 60 tests
npm test
# Run tests with coverage report
npm run test:coverage
# Run TypeScript typecheck
npm run typecheck
# Verify build
npm run buildTest Coverage Highlights
Unit Tests: Input validation, Zod schemas, order/product/inventory normalizers, error serialization.
Reliability Tests: 429 rate limit backoff,
Retry-Afterheader extraction, exponential jitter scaling, 5xx server retry, fast-fail on 401/403/404.Integration Tests: In-memory MCP client-server pair, tool discovery (
tools/list), dynamic execution (tools/call), structured error responses (isError: true).Failure Tests: Malformed ISO dates, non-integer IDs, empty searches, upstream disconnects (
ECONNREFUSED), 503 errors, and secret leakage audits.
12. Docker Deployment
Build Docker Image
docker build -t cartix:latest .Run Container (HTTP Streamable Mode)
docker run -d \
-p 3000:3000 \
-e WOOCOMMERCE_URL="https://your-store.com" \
-e WOOCOMMERCE_CONSUMER_KEY="ck_xxxxxxxxxxxx" \
-e WOOCOMMERCE_CONSUMER_SECRET="cs_xxxxxxxxxxxx" \
-e MCP_TRANSPORT="streamable-http" \
--name cartix-mcp \
cartix:latest13. Documentation Website & Live Deployment
Cartix includes a standalone documentation website and interactive developer portal:
Location:
/website(HTML5, Vanilla CSS, and JavaScript; no frameworks required).GitHub Pages Deployment: Automatically built and published via
.github/workflows/deploy-pages.yml.Live URL:
https://ilakkiyan-j.github.io/Cartix/
14. Assumptions & Limitations
Read-Only Scope: Cartix intentionally does not perform write, refund, order modification, or product update operations for this assessment.
Deterministic Low-Stock: A product is classified as low stock if
stock_status === 'outofstock'or managedstock_quantity <= 5.Authentication: Uses WooCommerce REST API v3 Basic Authentication over HTTPS.
Pagination Ceiling: Results per tool request are bounded to a maximum of
100items (MAX_PAGE_SIZE=100) to protect context window tokens.
15. Future Evolution
For production multi-tenant deployments, Cartix can evolve to include:
OAuth 2.0 / WooCommerce App Authorization: Enabling zero-credential one-click merchant onboarding.
Webhook Ingestion: Real-time push updates for
order.createdandproduct.out_of_stock.Multi-Store Aggregation: Single agent interface across multiple regional WooCommerce stores.
Write Actions with Human-in-the-Loop Gating: Exposing refund and status update tools with explicit approval tokens.
Available Tools
5 toolsget_inventoryB
Retrieve inventory levels and stock status for products in the WooCommerce store. Supports filtering for low-stock and out-of-stock items (deterministic low stock threshold <= 5).
Inputs: page, limit, low_stock_only.
get_orderA
Retrieve complete normalized details for a specific WooCommerce order by its integer ID, including line items, prices, status, and customer notes. Returns NOT_FOUND error if order does not exist.
Inputs: order_id (required).
get_productA
Retrieve full normalized details for a specific WooCommerce product by its integer ID, including SKU, price, sale price, stock quantity, and stock status. Returns NOT_FOUND if product does not exist.
Inputs: product_id (required).
search_ordersA
Search and filter WooCommerce merchant orders by status and date range. Returns compact, normalized order summaries with total amounts, item counts, status, and pagination metadata.
Inputs: page, limit, status, date_to, +1 more.
search_productsA
Search the WooCommerce product catalog by text query or SKU. Returns normalized products including pricing, stock quantity, stock status, and pagination metadata.
Inputs: page, limit, query.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 5 tools
search_orders vs get_order and search_products vs get_product are cleanly separated by search-vs-fetch-by-ID intent. get_inventory overlaps somewhat with get_product since both expose stock quantity and status, but its cross-product filtering purpose (low/out-of-stock) keeps it distinguishable.
Every tool follows a strict verb_noun pattern: search_orders, get_order, search_products, get_product, get_inventory. The search/get verbs are used consistently and predictably across resource types.
Five tools is well-scoped and each earns its place for a read-oriented WooCommerce query server. It sits slightly lean, leaving little room for customer or category lookups, but nothing is redundant or bloated.
The read surface is solid for orders, products, and inventory, but there is no customer lookup and no write/lifecycle operations (order status updates, product edits, creation). If the server is strictly read-only this is acceptable, but as a WooCommerce merchant surface it has notable gaps.
Maintenance
Related MCP Connectors
Connect AI to store orders, products and inventory with scoped access and human approvals.
Manage WordPress blogs and WooCommerce shops from Claude, ChatGPT, Cursor and other MCP apps.
Hosted WooCommerce MCP server for Claude, ChatGPT and Cursor, with each action switched per account.
Federated commerce search across independent WooCommerce merchants. Keyless, read-only MCP server.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to interact with WooCommerce stores via the WooCommerce REST API, supporting operations like listing products, orders, and customers.249 npmMIT
- FlicenseNot gradedqualityCmaintenanceEnables secure, read-only access to WooCommerce store data through MCP-compatible assistants, letting users query products, orders, sales summaries, and inventory alerts without exposing store credentials.-
- FlicenseNot gradedqualityBmaintenanceMCP server that gives AI agents secure, read-only access to WooCommerce merchant orders through validated list, get, and search tools. It returns normalized order data with bounded pagination, Zod validation, timeouts, retry/backoff and Retry-After-aware rate-limit handling, plus safe structured errors instead of raw payloads or credentials.-
- AlicenseBqualityCmaintenanceA read-only MCP server that lets an Agent Studio agent query a WooCommerce store's orders, products, inventory and customers, with pagination, filtering, typed errors and automatic rate-limit retry. It never mutates store data, keeping the blast radius of an agent's actions bounded to reads.7MIT