1: <?php
2:
3: declare(strict_types=1);
4:
5: /**
6: * This file is part of the Nexus MCP SDK package.
7: *
8: * (c) 2025 John Paul E. Balandan, CPA <paulbalandan@gmail.com>
9: *
10: * For the full copyright and license information, please view
11: * the LICENSE file that was distributed with this source code.
12: */
13:
14: namespace Nexus\Mcp\Server\Message\Notification;
15:
16: use Nexus\Mcp\Message\Notification;
17:
18: /**
19: * An optional notification from the server to the client, informing it that the list of prompts
20: * it offers has changed. This may be issued by servers without any previous subscription from the client.
21: */
22: final readonly class PromptListChangedNotification extends Notification implements ServerNotification
23: {
24: /**
25: * @param non-empty-string $jsonrpc JSON-RPC version. Must be 2.0.
26: * @param null|array<string, mixed> $meta Reserved by MCP to allow clients and servers to attach
27: * additional metadata to their interactions.
28: */
29: public function __construct(string $jsonrpc, ?array $meta = null)
30: {
31: $params = null === $meta ? null : ['_meta' => $meta];
32:
33: parent::__construct($jsonrpc, 'notifications/prompts/list_changed', $params);
34: }
35: }
36: