subscriptionId property

Object? get subscriptionId

Identifies the subscription stream a notification was delivered on. The server MUST include this key on every notification delivered via a SubscriptionsListenRequestsubscriptions/listen stream, so the client can correlate the notification with the originating subscription. The key is absent on notifications not delivered via a subscription stream (e.g. progress notifications for an in-flight request), which is why it is optional here.

The value is the JSON-RPC ID of the subscriptions/listen request that opened the stream.

Implementation

Object? get subscriptionId => $optional('io.modelcontextprotocol/subscriptionId', $any);