How I registered an MCP server for 3,760 retailers — and what I learned

Yesterday CLI Market was a PyPI package.
This week it’s an official MCP Registry server:

Here’s what it took to get listed, what the registry validation looks like, and why MCP is the missing layer between e-commerce and AI agents.

**


This content originally appeared on DEV Community and was authored by Ricardo Cuba

Yesterday CLI Market was a PyPI package.
This week it's an official MCP Registry server:

Here's what it took to get listed, what the registry validation looks like, and why MCP is the missing layer between e-commerce and AI agents.

**

The MCP Registry: what it took to get listed

**
The Model Context Protocol Registry at registry.modelcontextprotocol.io is the canonical
directory of MCP servers. Getting listed isn't just about having a working server — the registry validates ownership, checks schema compliance, and verifies that the package actually exists.

*Step 1: The mcp.json file
*

Every MCP server needs a mcp.json at the repo root. Ours:
{
"$schema": "https://static.modelcontextprotocol.io/schemas/2025-12-11/server.schema.json"
,
"name": "io.github.Treevu-ai/cli-market",
"title": "CLI Market",
"version": "1.0.1",
"description": "12 MCP tools for search, compare, purchase across 3,760 retailers in 67 c
ountries",
"repository": {
"url": "https://github.com/Treevu-ai/cli-market-world",
"source": "github"
},
"packages": [{
"registryType": "pypi",
"identifier": "cli-market",
"version": "1.0.17",
"transport": { "type": "stdio" }
}]
}

Key decisions:

  • Name format: io.github.{org}/{project} — reverse-DNS, org-scoped
  • registryType: pypi — CLI Market is a Python package on PyPI
  • transport: stdio — the MCP server communicates over standard input/output
  • version locked — no ranges, exact version matching

*Step 2: Proving ownership
*

The registry doesn't trust that cli-market on PyPI belongs to Treevu-ai on GitHub. It validates by scanning the PyPI package README for a specific HTML comment:

<!-- mcp-name: io.github.Treevu-ai/cli-market -->

This line must appear in the README that renders on PyPI. The registry fetches the package, parses the README, and checks that the annotation matches the server name. If it doesn't match — rejected.

We added this to our README, bumped the version to 1.0.17, and uploaded to PyPI. The registry validated it in under a second.

*Step 3: Schema validation
*

The publish endpoint runs the full ServerJSON schema validator. Every field is checked:

description max 100 characters, name must match ^[a-zA-Z0-9.-]+/[a-zA-Z0-9._-]+$,
packages[].identifier must resolve in the registry, packages[].transport.type must be stdio/
streamable-http/sse.

One thing that tripped us up: the schema changed between mcp.json (the repo-side format) and ServerJSON (the registry API format). In the repo, you declare command, args, type. In the registry API, those go inside packages[].transport and packages[] requires registryType + identifier + transport. Getting this right took a few rounds.

*Step 4: Authentication
*

The registry uses GitHub OAuth. We exchanged a GitHub token for a registry JWT:
POST /v0.1/auth/github-at → { registry_token: "eyJ..." }

Then published:
POST /v0.1/publish → { server: {...}, _meta: { status: "active" } }

The token expires, so for updates you re-authenticate. The whole flow is scriptable in under 10 lines of bash.

The 12 tools: architecture

All 12 tools sit on top of a unified VTEX connector that normalizes 3,760 retailer APIs into a single JSON schema.

_Four tools deserve special attention:
_

  • - market_compare — Not a simple price fetch. It first normalizes SKUs across retailers (the same product has different internal IDs at Carrefour Brazil and Sainsbury's UK), deduplicates, and returns a canonical price set. Three steps under one MCP call.
  • market_checkout — Chains: cart validation → stock verification → payment method resolution → order confirmation. All in one invocation. But it never completes autonomously — V1 requires explicit human approval before execution.
  • market_ask — The most composite tool. Natural language input → semantic search → cross-retailer comparison → cart building → checkout readiness. "Buy rice" walks the full pipeline.

The composition pattern — Tools are atomic enough to compose, composite enough to not drown the agent. 12 tools. Not 1 mega-tool. Not 100 individual REST endpoints.

───

What I'd do differently

  1. Read the OpenAPI spec first. The publish endpoint schema is documented at /docs. I guessed from the mcp.json format and hit 5 validation errors before getting it right.

  2. Set up the PyPI annotation early. The mcp-name comment is the ownership proof. Add it to your README before you publish to the registry.

  3. Script the auth flow. GitHub token → registry JWT → publish. Three curl calls. Wrap them in a Makefile target and forget about it.

───

CLI Market is on the registry.
The agent can now search, compare, and buy across 3,760 retailers in 67 countries — all via structured tool calls with zero scraping.

pip install cli-market
io.github.Treevu-ai/cli-market
github.com/Treevu-ai/cli-market-world

Ricardo Cuba
Founder & Product Lead | CLI Market
CEO Sinapsis Innovadora
Trujillo, Perú


This content originally appeared on DEV Community and was authored by Ricardo Cuba


Print Share Comment Cite Upload Translate Updates
APA

Ricardo Cuba | Sciencx (2026-05-20T00:08:56+00:00) How I registered an MCP server for 3,760 retailers — and what I learned. Retrieved from https://www.scien.cx/2026/05/20/how-i-registered-an-mcp-server-for-3760-retailers-and-what-i-learned/

MLA
" » How I registered an MCP server for 3,760 retailers — and what I learned." Ricardo Cuba | Sciencx - Wednesday May 20, 2026, https://www.scien.cx/2026/05/20/how-i-registered-an-mcp-server-for-3760-retailers-and-what-i-learned/
HARVARD
Ricardo Cuba | Sciencx Wednesday May 20, 2026 » How I registered an MCP server for 3,760 retailers — and what I learned., viewed ,<https://www.scien.cx/2026/05/20/how-i-registered-an-mcp-server-for-3760-retailers-and-what-i-learned/>
VANCOUVER
Ricardo Cuba | Sciencx - » How I registered an MCP server for 3,760 retailers — and what I learned. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2026/05/20/how-i-registered-an-mcp-server-for-3760-retailers-and-what-i-learned/
CHICAGO
" » How I registered an MCP server for 3,760 retailers — and what I learned." Ricardo Cuba | Sciencx - Accessed . https://www.scien.cx/2026/05/20/how-i-registered-an-mcp-server-for-3760-retailers-and-what-i-learned/
IEEE
" » How I registered an MCP server for 3,760 retailers — and what I learned." Ricardo Cuba | Sciencx [Online]. Available: https://www.scien.cx/2026/05/20/how-i-registered-an-mcp-server-for-3760-retailers-and-what-i-learned/. [Accessed: ]
rf:citation
» How I registered an MCP server for 3,760 retailers — and what I learned | Ricardo Cuba | Sciencx | https://www.scien.cx/2026/05/20/how-i-registered-an-mcp-server-for-3760-retailers-and-what-i-learned/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.