SearchEventsTool

class SearchEventsTool(context: Context) : McpTool

Searches calendar events whose TITLE or DESCRIPTION contains query (SQL LIKE substring; %, _ and \ in query match literally), via ContentResolver on CalendarContract.Events, newest first. Requires READ_CALENDAR. Output: events (list of {id, title, start, end, location, description, all_day} with times formatted yyyy-MM-dd HH:mm — device timezone for timed events, UTC for all-day events, which the provider stores at UTC-midnight boundaries), count, and the echoed query, capped at limit (1–100, default 10). Recurring events appear once (their base row), not per occurrence.

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