TsgcWSAPIClient_MCP › Methods › UnsubscribeResource
Cancels a previous resource subscription (resources/unsubscribe).
procedure UnsubscribeResource(const aUri: string);
| Name | Type | Description |
|---|---|---|
aUri | const string | URI of the resource whose subscription should be terminated. Must match a URI previously passed to SubscribeResource. |
Sends the JSON-RPC resources/unsubscribe request so the server stops emitting notifications/resources/updated notifications for the given URI. Call this method during teardown, when the user navigates away from the resource, or before closing the transport. Unsubscribing a URI that was never subscribed is a no-op at the client level and may return an error from the server.
MCP.UnsubscribeResource('file:///project/config.yaml');