PollNotificationWatchTool

Returns the notifications a watch has matched since it was registered (or since the last clearing poll), via WatchRegistry.poll. Each watch buffers at most WatchRegistry.MAX_BUFFERED_EVENTS events; older ones are dropped and counted in dropped. clear (default true) drains the buffer so the next poll only sees newer events; pass false to peek. An unknown or expired watch_id returns watch_not_found.

Output: watch_id, count, dropped, expires_at, and events — each a map with key, package_name, title, text, big_text, sub_text, ticker_text, category, channel_id, group_key, is_ongoing, is_clearable, channel_importance, posted_at, when, has_reply_action, action_labels. The key works with the notifications-reply tools (reply_to_notification, invoke_notification_action, dismiss_notification).

Constructors

Link copied to clipboard
constructor(context: Context)

Properties

Link copied to clipboard
open override val annotations: ToolAnnotations
Link copied to clipboard
open override val description: String
Link copied to clipboard
open override val name: String
Link copied to clipboard
open override val outputSchema: Map<String, Any>
Link copied to clipboard
open override val parameters: List<ToolParameter>

Functions

Link copied to clipboard
open suspend override fun execute(params: Map<String, Any>): ToolResult