Kick off the SDK based on Symfony's MCP SDK

This commit is contained in:
Christopher Hertel 2025-07-25 11:40:39 +02:00
commit ee0dffe369
No known key found for this signature in database
GPG key ID: 111F6BFF7B6B5AA3

View file

@ -0,0 +1,31 @@
<?php
/*
* This file is part of the official PHP MCP SDK.
*
* A collaboration between Symfony and the PHP Foundation.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Mcp\Server\RequestHandler;
use Mcp\Message\Request;
use Mcp\Message\Response;
/**
* @author Christopher Hertel <mail@christopher-hertel.de>
*/
final class PingHandler extends BaseRequestHandler
{
public function createResponse(Request $message): Response
{
return new Response($message->id, []);
}
protected function supportedMethod(): string
{
return 'ping';
}
}