Skip to content

Commit 3b31954

Browse files
authored
Add changelog for 0.2.0 (#187)
1 parent 2c96922 commit 3b31954

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ All notable changes to `mcp/sdk` will be documented in this file.
77

88
* Make `Protocol` stateless by decouple if from `TransportInterface`. Removed `Protocol::getTransport()`.
99
* Change signature of `Builder::addLoaders(...$loaders)` to `Builder::addLoaders(iterable $loaders)`.
10+
* Removed `ClientAwareInterface` in favor of injecting a `RequestContext` with argument injection.
11+
* The `ClientGateway` cannot be injected with argument injection anymore. Use `RequestContext` instead.
12+
* Removed `ClientAwareTrait`
13+
* Removed `Protocol::getTransport()`
14+
* Added parameter for `TransportInterface` to `Protocol::processInput()`
15+
1016

1117
0.1.0
1218
-----

src/Capability/Discovery/SchemaGenerator.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
namespace Mcp\Capability\Discovery;
1313

1414
use Mcp\Capability\Attribute\Schema;
15-
use Mcp\Server\ClientGateway;
1615
use Mcp\Server\RequestContext;
1716
use phpDocumentor\Reflection\DocBlock\Tags\Param;
1817

@@ -416,7 +415,7 @@ private function parseParametersInfo(\ReflectionMethod|\ReflectionFunction $refl
416415
if ($reflectionType instanceof \ReflectionNamedType && !$reflectionType->isBuiltin()) {
417416
$typeName = $reflectionType->getName();
418417

419-
if (is_a($typeName, ClientGateway::class, true) || is_a($typeName, RequestContext::class, true)) {
418+
if (is_a($typeName, RequestContext::class, true)) {
420419
continue;
421420
}
422421
}

src/Server/ClientGateway.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,8 @@
4343
*
4444
* Example usage in a tool:
4545
* ```php
46-
* public function analyze(string $text, ClientGateway $client): string {
46+
* public function analyze(string $text, RequestContext $context): string {
47+
* $client = $context->getClientGateway();
4748
* // Send progress notification
4849
* $client->notify(new ProgressNotification("Starting analysis..."));
4950
*

0 commit comments

Comments
 (0)