Download the PHP package upturnstudio/module-mcp without Composer

On this page you can find all versions of the php package upturnstudio/module-mcp. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package module-mcp

Magento Connector MCP Module

Magento Connector MCP Module turns a Magento 2 / Adobe Commerce store into a Model Context Protocol (MCP) server, so Claude can run read-only GraphQL queries - products, categories, customers, orders, and anything else the store's schema exposes - on behalf of an authenticated admin, using that admin's own Magento permissions.

It connects to Claude exactly like any other MCP integration: as a normal custom connector in Claude.ai / Claude Desktop (Settings > Connectors > Add - the same flow you'd use for any other service) over a standard OAuth 2.1 flow, or as a local MCP server for Claude Code. No special Claude-side support is needed either way.

Two transports, same underlying tools and safety guarantees either way:

For background and a walkthrough, see the blog post: Magento MCP Claude Connector.

Example

Claude calling execute_graphql against a live store, then narrowing the query based on the result - no hand-written integration code, just the schema:

Installation

Running in production mode? Also run bin/magento setup:di:compile before cache:flush.

Setup

  1. Grant the permission. A brand-new ACL resource, UpturnStudio_Mcp::connector ("AI Connector (MCP)"), gates who can authorize this connector at all. It is not granted to any role automatically - go to Admin > System > Permissions > User Roles and add it to whichever role(s) should be allowed to connect Claude.
  2. (HTTP transport only) Set the public base URL. Stores > Configuration > Advanced > AI Connector (MCP) > Public Base URL must be a real https:// URL this store is reachable at, with no path (e.g. https://your-domain.com, not .../mcp) - it's the OAuth issuer and MCP resource identifier, and must never change once a client has registered against it. Not needed for the stdio transport. See "Using it remotely" below for the actual URL to give Claude, which is this value plus /mcp.
  3. (Optional) Set a PageSpeed Insights API key. Stores > Configuration > Advanced > AI Connector (MCP) > Core Web Vitals > PageSpeed Insights API Key. Only used by the check_core_web_vitals tool - leave blank to use Google's free, unauthenticated tier (lower rate limit).

Using it locally (stdio)

--admin-user is a real Magento admin username (not email, not display name) that already has the permission above. Point Claude Code/Desktop's local MCP config at it directly:

To interactively poke at it with the official MCP Inspector instead of a real client:

This shells out to npx @modelcontextprotocol/inspector with the right invocation pre-built (config file, protocolEra, etc.) and auto-switches to a working Node version via nvm first if the active one is too old for the Inspector's own dependencies. Add --cli for one-shot scripted calls (-- --method tools/list --format json) instead of the interactive web UI. Requires Node.js/npx; this only launches the Inspector, it doesn't bundle it.

Using it remotely (HTTP + OAuth)

This works as a completely standard custom connector - no special setup on Claude's side. In Claude.ai: Settings > Connectors > Add custom connector, and paste the public base URL with /mcp appended - not the bare domain. For example, if the Public Base URL configured above is https://your-domain.com, enter:

(Claude Code / Claude Desktop: add it as a remote server pointed at that same /mcp URL instead.) This has to be reachable over the public internet - a local .test/.localhost domain only works with the stdio transport above, not this one.

After adding it, Claude handles the rest automatically:

  1. Claude requests that URL, gets a 401, and follows it to this store's OAuth endpoints (/.well-known/oauth-protected-resource, then /.well-known/oauth-authorization-server).
  2. Claude registers itself as a client (/register) - nothing for the admin to do here.
  3. A browser tab opens to admin/upturnstudio_mcp/oauth/authorize. If the admin isn't already logged into Magento admin, they're asked to log in first, then shown a consent screen naming the connector and asking them to Allow or Deny it.
  4. On Allow, Claude exchanges the result for its own token and the connector is ready to use.

Connected apps can be reviewed and revoked afterwards at Admin > System > AI Connector (MCP).

The token Claude receives is not a Magento admin token - it only works against this module's own /mcp endpoint. Internally, a real (short-lived, never cached) Magento admin token is minted per call so Magento's own GraphQL resolvers and ACL checks see a genuine, live admin identity.

Tools

execute_graphql and introspect_graphql_schema run through Magento's real /graphql endpoint internally (not in-process GraphQL classes) - the schema's own DI wiring is scattered across ~50 modules' etc/graphql/di.xml files and isn't safely reproducible from another area, so this reuses it as-is instead. check_core_web_vitals doesn't need any of that: its entity lookup is a plain url_rewrite table lookup plus a repository fetch, both globally bound services with no area-scoping problem, so it resolves the entity in-process directly rather than paying for a loopback HTTP call to /graphql.

Adding more tools

Other modules can register additional tools without touching this one. Implement UpturnStudio\Mcp\Api\ToolInterface:

Then register it from your own module's etc/di.xml:

It shows up in tools/list and is callable via tools/call on both transports automatically

Security notes


All versions of module-mcp with dependencies

PHP Build Version
Package Version
Requires php Version ~8.2.0||~8.3.0||~8.4.0||~8.5.0
magento/framework Version *
magento/module-backend Version *
magento/module-authorization Version *
magento/module-integration Version *
magento/module-user Version *
magento/module-graph-ql Version *
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package upturnstudio/module-mcp contains the following files

Loading the files please wait ...