A framework-agnostic server for the Model Context Protocol: expose tools,
resources and prompts over STDIO or HTTP, declared with attributes or registered on the builder. It serves both the
initialize handshake and the stateless 2026-07-28 revision.
composer require mcp/serverSome features need an extra package:
symfony/finderfor the file-based discovery of tools, resources and promptsfirebase/php-jwtfor validating OAuth access tokens with theJwtTokenValidator- a PSR-6 or PSR-16 cache for the cached discovery and the session stores that use them
symfony/lockfor session locks- PSR-7 and PSR-17 implementations for the HTTP transport, for example
nyholm/psr7
To build a client as well, install mcp/sdk instead.
This repository is a read-only split of mcp/sdk.