For the complete documentation index, see llms.txt. This page is also available as Markdown.

Documentation MCP server

Real-time access to the full Commerce Layer developer documentation via an HTTP MCP endpoint

Commerce Layer architecture enables AI agents to execute every commerce action programmatically. But accessible APIs are only half the equation for agentic commerce — AI agents also need to understand how to use those APIs correctly, which means access to documentation in formats they can effectively consume and reason about. In short, documentation must be AI-ready too. That's why Commerce Layer docs ship with features designed for AI systems to retrieve accurate, contextual answers in real time.

What is the Documentation MCP?

The Commerce Layer Documentation MCP is an HTTP MCP server that gives AI assistants structured, real-time access to the full developer documentation — no scraping, no stale training data, no manual context-pasting.

The server is available at the following URL:

https://docs.commercelayer.io/~gitbook/mcp

It's compatible with Claude, ChatGPT, Cursor, VS Code with GitHub Copilot, and any other client that implements the Model Context Protocol.

Why does it exist?

The Documentation MCP exposes Commerce Layer's developer documentation as structured resources that AI tools can discover and retrieve in real time. This means an AI assistant can answer questions about the Core API, Metrics API, Provisioning API, Rules Engine, and more by reading the actual documentation — rather than relying on its training data, which may be outdated or incomplete.

You can easily leverage it for:

  • Asking questions about Commerce Layer APIs during development.

  • Looking up endpoint parameters, resource schemas, and authentication patterns.

  • Getting step-by-step guidance from how-to guides directly in your editor.

  • Answering questions about Commerce Layer in AI-powered support workflows.

What can you ask it?

Once connected, you can ask your AI assistant things like:

  • "How do I create an order with line items using the Core API?"

  • "What authentication method should I use for a B2B storefront?"

  • "What's the difference between a sales channel token and an integration token?"

  • "Which filter predicates can I use on the orders endpoint?"

  • "How do I use the JavaScript SDK to list SKUs with a custom filter?"

  • "What does the _place trigger attribute do on an order?"

  • "How do I set up a market with a custom price list and inventory model?"

  • "Walk me through a complete checkout flow end to end."

  • "Show me the full schema for the shipments resource."

The assistant reads the actual documentation in real time — not its training data — so answers reflect the current state of the API.

How to connect

The Documentation MCP uses HTTP transport. There is no binary to install or build step required. Just register the endpoint URL in your MCP client's configuration. No authentication required.

1

Add the Documentation MCP server

You have two options:

Connect via the Claude Desktop UI (no authentication required)

Open Claude Desktop, click Customize in the compose area, and select Add connector. Enter a service name — e.g. Commerce Layer Docs — and the endpoint URL:

Connect via the config file (no token needed)

Open your claude_desktop_config.json file:

  • MacOS~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows%APPDATA%\Claude\claude_desktop_config.json.

Add the following entry under mcpServers:

2

Save and restart

Save the file and restart Claude Desktop. The server will be available in your next conversation.

For the full setup reference, see the Claude Desktop MCP guide.

Authentication and permissions

The Documentation MCP requires no authentication. The endpoint is publicly accessible — no token, no credentials, and no setup beyond registering the URL in your client.

pen-nib-slash

The Documentation MCP is read-only by design. There are no write operations and no access to Commerce Layer account data.

List of tools

Two tools are available, designed to work in sequence: search to surface relevant content, then fetch to read any page in full.

Tool
Can write?
Description

searchDocumentation

Search across the documentation to find relevant information, code examples, API references, and guides. Returns contextual content with titles and direct links to the matching pages.

getPage

Fetch the full markdown content of a documentation page by URL. Use after searchDocumentation when partial results are not enough and you need the complete page.

LLM-friendly formats

Beyond the MCP server, to make Commerce Layer APIs documentation content available in text-based formats that are easier for LLMs to process, ingest, and work with, you can leverage the following text files. On top of that, all of the pages of Commerce Layer docs are automatically available as markdown files.

llms.txt files

Two LLM-optimized text files are available at the root of the docs site.

  • Index — contains an index of all the page URLs and titles of our API docs sites, providing a comprehensive list of all available markdown-formatted pages:

  • Full content — contains the full content of our API docs sites in one file that can be passed to LLMs as context:

To query Core API documentation specifically, use the Core MCP server, which includes documentation tools scoped to Core API content.

Per-page markdown

Every documentation page is available as a markdown file. If you append the .md extension to any page, you will see the content of that page rendered in markdown which you can pass to an LLM for more efficient processing without the overhead of HTML parsing. For example:

Last updated