Search Calendar Events
search_calendar_eventsSearch for NIP-52 calendar events (date-based and time-based). Supports temporal filters (start/end time ranges), geohash location filtering, hashtag filtering, and the edufeed educational attributes (free, registrationRequired, attendanceMode, educationalLevel). Returns events from the configured calendar relay. TIME SEMANTICS (NIP-52): start/end are the raw tags — end is EXCLUSIVE and is omitted for one-day and instantaneous events, so never read a missing end as "unknown". Use effectiveEnd (Unix seconds when the event is over), allDay (31922: whole days, no clock time) and lastDay (all-day events: the inclusive last calendar day). Times of 31923 events are in startTzid/endTzid. ATTRIBUTES: attributes carries registration, price (free = amount 0), attendance mode (online/offline/mixed) and Bildungsstufe; a missing field means "no statement", never "no" or "not free". AUTHOR: every event has author {name, bot}; bot: true marks an automated account such as an event mirror or crawler — group or de-emphasise those unless the user asks for imports. Operators may hide bulk sources by default (see hiddenSources in the result); pass includeHiddenSources: true to see them. When presenting an event to the user, render it as a markdown link: prefer the event url (the edufeed-app viewer at /, which shows fuller details) over sourcePage (the original external event page). Never construct an naddr or viewer URL yourself — use the naddr/url fields as returned.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "search_calendar_events"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| free | No | true: only events tagged free of charge (price 0). Events without a price statement are NOT returned, so leave it unset unless the user insists on free. false adds no filter. | |
| kinds | No | NIP-52 kinds to query (default: [31922, 31923]). 31922 = date-based event, 31923 = time-based event (both in `events`); 31924 = calendar, a titled list of event coordinates (in `calendars`); 31925 = RSVP, one user's attendance intention (in `rsvps`). "Who is coming to event X" = kinds [31925] with the event's coordinate in `references`; "events in calendar Y" = resolve the calendar's eventRefs. Time-range, geohash and attribute filters match event kinds only, so combining them with 31924/31925 returns no calendars or RSVPs. | |
| limit | No | Maximum number of results (1-250, default: 20) | |
| query | No | Free-text topic for the events. Combines with a time range (startAfter/startBefore/endAfter/endBefore) in a single server-side query — e.g. "events about X in the next week" is one call. With a geohash, the relay runs the topic search and filters one page of 250 hits by location, so "events about X near a place" works but may return fewer than limit. | |
| since | No | Return events created at or after this Unix timestamp | |
| until | No | Return events created at or before this Unix timestamp | |
| authors | No | Filter by author pubkeys (hex format) | |
| geohash | No | Geohash prefix for location-based search | |
| endAfter | No | Only events still running after this Unix timestamp (strict: NIP-52 `end` is exclusive, so an event ending exactly then is over). "Ongoing or upcoming" = endAfter: now; one-day and instantaneous events are included via their effective end. | |
| hashtags | No | Filter by hashtags (e.g., ["meetup", "nostr"]) | |
| community | No | Return calendar events shared into this community (Communikey). Accepts a hex pubkey or npub; resolve a community name with resolve_author. Combines with a time range (startAfter/startBefore/endAfter/endBefore) in a single server-side query, so "events shared with X next week" is one call. With a geohash the relay applies the community filter in its topic search and post-filters one page of 250 hits by location. | |
| endBefore | No | Only events over by this Unix timestamp (inclusive: an event ending exactly then counts) | |
| references | No | Filter by referenced coordinates (`a` tags): with kinds [31925] the event an RSVP answers (`31923:<pubkey>:<d>`); with kinds [31924] calendars listing that event; with event kinds, events requesting inclusion in that calendar (`31924:<pubkey>:<d>`). | |
| startAfter | No | Only events starting at or after this Unix timestamp (inclusive) | |
| startBefore | No | Only events starting at or before this Unix timestamp (inclusive) | |
| participants | No | Filter by participant pubkeys (`p` tags, hex): events naming them, or RSVPs to their events. | |
| attendanceMode | No | Only online, in-person (offline) or hybrid (mixed) events; untagged events match none. | |
| educationalLevel | No | Only events for this KIM Bildungsstufe concept URI, e.g. https://w3id.org/kim/educationalLevel/level_C (Fortbildung), level_A (Hochschule), level_B (Vorbereitungsdienst), level_1 (Primarbereich). | |
| includeHiddenSources | No | Also return events from operator-hidden bulk sources (event mirrors, imported catalogues). Default false; the result reports how many were hidden. | |
| registrationRequired | No | Only events that do (true) or do not (false) require registration; untagged events match neither. |