Resource Notifications
Resource Notifications enable a server to proactively tell the client that a specific resource's content has changed (e.g., via notifications/resources/list_changed or notifications/resources/updated).
Use Cases
- Log Monitoring: Streaming updates to a log file as they occur.
- Shared Documents: Notifying the AI that a collaborative document has been updated by another user.
- Live Metrics: Updating a model on changing system statistics.
Questions & Answers
What is the purpose of "Resource Notifications" in MCP?
Resource notifications allow a server to proactively alert a client when the content or availability of a specific resource has changed. This eliminates the need for the client to constantly poll the server for updates.
How do these notifications differ from a standard resource read?
A standard read is a "pull" operation where the client requests data. a notification is a "push" event initiated by the server, ensuring the client has the most up-to-date information as soon as it becomes available.
What are some common use cases for real-time resource updates?
Common use cases include log monitoring (streaming new log entries), collaborative document editing (alerting the AI to changes made by others), and tracking live system metrics or statistics that change frequently.