Skip to main content
Glama
nks-hub

rybbit-mcp

by nks-hub

List Events

rybbit_list_events
Read-onlyIdempotent

Retrieve and filter individual website event records with timestamps, types, and properties for analytics review and data analysis.

Instructions

List raw events for a site with filtering and pagination. Returns individual event records with timestamps, types, pathnames, event names, and properties. When filtering by event_name, only matching events are returned (not entire sessions).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
siteIdYesSite ID (numeric ID or domain identifier)
startDateNoStart date in ISO format (YYYY-MM-DD)
endDateNoEnd date in ISO format (YYYY-MM-DD)
timeZoneNoIANA timezone (e.g., Europe/Prague). Default: UTC
filtersNoArray of filters. Example: [{parameter:'browser',type:'equals',value:['Chrome']},{parameter:'country',type:'equals',value:['US','DE']}]
pastMinutesStartNoAlternative to dates: minutes ago start (e.g., 60 = last hour)
pastMinutesEndNoAlternative to dates: minutes ago end (default 0 = now)
pageNoPage number, 1-indexed (default: 1)
limitNoResults per page (default: 20-50 depending on endpoint, max 200)
eventNameNoFilter to only return events with this exact event_name (e.g., 'ad_click'). More precise than using the filters array which returns entire sessions.

Implementation Reference

  • The handler function for the `rybbit_list_events` tool, which fetches event data and applies optional filtering.
    async (args) => {
      try {
        const params = client.buildAnalyticsParams(args);
        const data = await client.get<EventsApiResponse>(`/sites/${args.siteId}/events`, params);
    
        // Post-filter: if eventName specified, filter to only matching events
        // This works around the backend's session-level event_name filtering
        if (args.eventName && data?.data) {
          data.data = data.data.filter(
            (e) => e.event_name === args.eventName
          );
        }
    
        return {
          content: [{ type: "text" as const, text: truncateResponse(data) }],
        };
      } catch (err) {
        const message = err instanceof Error ? err.message : String(err);
        return {
          content: [{ type: "text" as const, text: `Error: ${message}` }],
          isError: true,
        };
      }
    }
  • Registration of the `rybbit_list_events` tool including its definition and input schema.
    server.registerTool(
      "rybbit_list_events",
      {
        title: "List Events",
        annotations: { readOnlyHint: true, idempotentHint: true, openWorldHint: true, destructiveHint: false },
        description:
          "List raw events for a site with filtering and pagination. Returns individual event records with timestamps, types, pathnames, event names, and properties. When filtering by event_name, only matching events are returned (not entire sessions).",
        inputSchema: {
          ...analyticsInputSchema,
          ...paginationSchema,
          eventName: z
            .string()
            .optional()
            .describe("Filter to only return events with this exact event_name (e.g., 'ad_click'). More precise than using the filters array which returns entire sessions."),
        },
      },
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint, idempotentHint, and destructiveHint, establishing safety characteristics. The description adds valuable behavioral context about the return format (individual records with timestamps, types, pathnames) and the filtering scope limitation, but omits details about pagination limits or performance characteristics.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences with zero waste: first establishes purpose and capabilities (filtering/pagination), second describes return values, third clarifies critical filtering behavior. Information is front-loaded and every sentence earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema available, the description adequately explains return values (individual records with specific fields). It covers the key behavioral nuance regarding session vs. event-level filtering. Missing only minor details like pagination maximums or time range constraints.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Input schema has 100% description coverage, establishing baseline competency. The description reinforces the semantic distinction regarding event_name filtering versus filters array, though this largely restates schema content. No additional parameter syntax or format guidance is provided beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states the tool 'List raw events for a site,' specifying the resource (raw events), action (list), and scope (site-level). The term 'raw' effectively distinguishes this from aggregated analytics siblings like rybbit_get_metric or rybbit_get_overview.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit guidance on the critical distinction between event_name filtering (returns individual events) versus filters array (returns entire sessions). However, it does not explicitly state when to choose this tool over rybbit_list_sessions or other event retrieval tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nks-hub/rybbit-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server