Download the PHP package evolution-cms/emcp without Composer

On this page you can find all versions of the php package evolution-cms/emcp. 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 emcp

Total Downloads Latest Stable Version License

eMCP for Evolution CMS

eMCP is the Evolution CMS integration layer for laravel/mcp.

It adapts Laravel MCP to Evo runtime with:

Implementation starts with a strict MVP gate:

Design style:

If you need full architecture and contracts, see DOCS.md (EN) or DOCS.uk.md (UA). Public canonical tool contract: TOOLSET.md. Versioning and BC policy: PRD.md (API Stability Policy section). Operations runbook: OPERATIONS.md.

Requirements

Install

From your Evo core directory:

Publish Config and Stubs

core/custom/config/cms/settings/eMCP.php is created automatically on the first request after install when it is missing, so emcp-config is only needed to restore the defaults. emcp-mcp-config changes the MCP server list, emcp-stubs scaffolds your own servers and tools.

Site-wide switches (write tools, manager/API endpoints, token scopes, rate limit, audit log, streaming) are also available as checkboxes in Tools → MCP settings ({manager_url}/emcp/settings, requires the settings permission). The page edits the same file and keeps its comments.

Published files:

Quick Start (Internal + External)

The default contract is concept-agnostic and follows Laravel MCP behavior first.

  1. Create your MCP server/tool classes:

Generated classes are placed in core/custom/app/Mcp/....

  1. Register server in core/custom/config/mcp.php (servers[]).
  2. Test manager/internal route:
    • POST /{manager_prefix}/{handle} with manager session + permission emcp.
  3. Enable external API mode (if sApi installed):
    • keep mode.api=true in core/custom/config/cms/settings/eMCP.php
    • call POST /{SAPI_BASE_PATH}/{SAPI_VERSION}/mcp/{handle} with Bearer JWT and required mcp:* scopes.
    • get JWT from POST /{SAPI_BASE_PATH}/{SAPI_VERSION}/token (sApi token endpoint).
  4. Optional async:
    • set queue.driver=stask, ensure sTask installed, use dispatch endpoint for long-running jobs.

Personal access tokens (default API auth)

Since this version the API endpoint needs no extra packages: a manager user creates a personal access token and every request runs as that user, with that user's role, permissions and document groups — exactly as if they were logged into the manager.

  1. Give the role the emcp permission (admins have it after migrate).
  2. Open Tools → MCP tokens in the manager ({manager_url}/emcp/tokens), or run php artisan emcp:token:create <username> --scopes=mcp:read,mcp:call --expires=90.
  3. Connect the agent:

Scopes narrow a token, never widen the user: mcp:read (list/read), mcp:call (read-only tools), mcp:write (evo.write.* tools, also gated by security.enable_write_tools), mcp:destructive (extension tools that delete data, also gated by security.enable_destructive_tools), mcp:code (saving snippets, plugins and @EVAL-style bindings, also gated by security.enable_code_tools and a snippet/plugin/module permission), mcp:admin. Tokens are stored hashed, can expire, and are revoked from the same page or with emcp:token:revoke. emcp:token:list shows what exists.

auth.mode in core/custom/config/cms/settings/eMCP.php selects pat (default), sapi_jwt (seiger/sapi JWT, now also impersonating the JWT user) or none.

Write tools

evo.write.content.update|create|publish, evo.write.elements.save, evo.write.cache.clear plus the read tools evo.elements.list|get. Each one re-checks the manager permission of the matching manager action (save_document, publish_document, save_chunk, new_snippet, ...), document-group access, element locks, fires the same OnBefore*FormSave/On*FormSave events and writes a manager_log row, so an admin sees API changes next to browser ones.

Tools from other extras

An extra contributes tools by implementing EvolutionCMS\eMCP\Contracts\ToolProvider and registering it in its service provider's boot():

Tools are plain Laravel\Mcp\Server\Tool classes with a #[Name('vendor.domain.action')]. Mark the ones that change the site with EvolutionCMS\eMCP\Contracts\WritesSite so security.enable_write_tools and the mcp:write scope apply to them, the ones that delete data with DestructiveSite, the ones that store server-side code with ExecutesCode, and declare a required Evo permission with RequiresPermission. Tool code runs as the impersonated manager, so evo()->hasPermission() and the extra's own guards behave as on the page; Support\ToolError builds structured error results. Alternatively list classes under mcp.servers[].extra_tools. Example: elcreator/aimage ships aimage.* tools this way. The full contract (naming, identity rules, error format) is in DOCS.md.

Try it in Docker

Claude Code skills

The repository is a Claude Code plugin marketplace. Its skills teach an agent how to use the tools: emcp (documents, elements, users, cache, extending) and the extras' own plugins.

Other agents can use skills/evolution-cms-mcp/SKILL.md directly. An extra that adds tools ships its skill in its own skills/ folder with a .claude-plugin/plugin.json, and is listed in .claude-plugin/marketplace.json.

Design Philosophy (Optional Reading)

Why This Product Exists (4 Core Questions, Aristotle)

This is the shortest way to understand eMCP as a product, not just a package.

  1. Material cause: what it consists of (hard boundaries):

    • protocol/runtime from laravel/mcp
    • Evo adapter layer (ServiceProvider, registry, routes, middleware, publish)
    • optional access/async integrations (sApi, sTask)
    • canonical contracts (SPEC.md, TOOLSET.md)
  2. Formal cause: what form makes it a product (not components):

    • one execution contract from request to audited response
    • one policy model for manager/API access (ACL + scopes + limits)
    • one versioned public tool contract for ecosystem consumers
    • one stable extension model for third-party packages
  3. Efficient cause: what puts it in motion (workflows + triggers):

    • internal trigger: manager MCP call (/{manager_prefix}/{handle})
    • external trigger: API MCP call (/{SAPI_BASE_PATH}/{SAPI_VERSION}/mcp/{handle})
    • async trigger: dispatch into sTask worker for long operations
    • lifecycle trigger: package install/publish/register/test
  4. Final cause: why it is built this way:
    • keep Laravel MCP semantics intact
    • keep Evo integration explicit and operable
    • support both internal and external MCP usage
    • allow multiple orchestration strategies on top of one neutral MCP foundation

Conceptual Model (Design Lens)

This lens helps explain architecture decisions:

Practical implication:

Install Verification (1 minute)

For Gate A, use manager endpoint /{manager_prefix}/{server_handle} (default: /emcp/content). Gate A is manager ACL protected, so run checks as a logged-in manager with emcp permission (session cookie required).

  1. Verify GET returns 405 on MCP endpoint:

  2. Verify JSON-RPC initialize:

Expected:

Register MCP Servers (Evo style)

Unlike Laravel default routes/ai.php, eMCP registers servers from config.

Example in core/custom/config/mcp.php:

Notes:

Access Model

Ecosystem Interop

eMCP is the MCP platform layer for the Evo ecosystem:

This keeps the core declarative and neutral: one MCP foundation for multiple orchestration concepts.

Evo Domain Tools

Artisan Commands

From Laravel MCP (available via eMCP adapter):

For mcp:start content-local, first enable content-local in core/custom/config/mcp.php and disable conflicting server entries if they expose identical tool names.

Third-party servers

Register project-specific tools on a separate Laravel\Mcp\Server class and add that class as its own entry in core/custom/config/mcp.php. Third-party tool names must not use the reserved evo.* namespace. Do not subclass the package ContentServer only to append project tools, because the inherited evo.* toolset is package-owned and the registry will reject that external server.

php artisan emcp:test --server=<handle> runs generic initialize and tools/list checks for third-party servers. When the selected class is the canonical eMCP ContentServer, it also verifies the required Evolution toolset. Add --expect-tool=<name> (repeatable) to fail when a tool an Extra contributes is missing; EXTRA_CI.md wires this into a reusable workflow. Use php artisan emcp:list-servers to see both accepted servers and concrete reasons why configured entries were rejected.

eMCP operational commands:

Repository Checks (for first run in package workspace)

If you are validating this repository directly:

These checks validate composer.json and run PHP syntax lint across package sources.

One-click demo + full MCP verification:

This target installs demo Evo, starts php -S, issues sApi JWT, runs php artisan emcp:test, then runs composer run test with HTTP runtime integration enabled. After run, detailed evidence is written to:

If GitHub API auth is needed during install, pass token via ENV (same pattern as evolution):

Fallback ENV names are also supported: GITHUB_TOKEN, GH_TOKEN.

Manual content-read MCP examples (same calls used in demo/logs.md):

Optional runtime integration check (against deployed environment):

CI release note:

Async (sTask-first)

If queue.driver=stask and sTask is installed, eMCP can run long MCP calls via worker emcp_dispatch. If sTask is missing, fallback behavior follows queue.failover (sync or fail).

Security Notes

Security Defaults

Security release checklist: SECURITY_CHECKLIST.md. Threat model: THREAT_MODEL.md. Architecture freeze: ARCHITECTURE_FREEZE_CHECKLIST.md.

License

MIT (LICENSE).


All versions of emcp with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
evolution-cms/evolution Version ^3.5.2
laravel/mcp Version ^0.5.9
seiger/sapi Version ^1.0
seiger/stask Version ^1.0.10 || ^2.0
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 evolution-cms/emcp contains the following files

Loading the files please wait ...