execute_custom_query
Run custom SQL-like queries on OpenReplay session data to analyze user behavior, track errors, and measure performance metrics.
Instructions
Execute a custom query on the session data (supports SQL-like syntax for ClickHouse)
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Custom query to execute | |
| parameters | No | Query parameters |
Implementation Reference
- src/index.ts:475-487 (handler)The handler function that implements the logic for the 'execute_custom_query' tool. It currently returns a message indicating that custom queries are not supported and suggests using other tools.private async executeCustomQuery(args: any) { // OpenReplay doesn't expose direct query access, but we can use the search with complex filters const { query, parameters } = args; return { content: [ { type: "text", text: "Custom queries are not directly supported. Please use the specific search and filter tools instead.", }, ], }; }
- src/index.ts:256-262 (schema)Input schema definition for the 'execute_custom_query' tool, specifying the expected parameters.inputSchema: { type: "object", properties: { query: { type: "string", description: "Custom query to execute" }, parameters: { type: "object", description: "Query parameters" } }, required: ["query"]
- src/index.ts:253-264 (registration)Registration of the 'execute_custom_query' tool in the list of available tools returned by list_tools handler.{ name: "execute_custom_query", description: "Execute a custom query on the session data (supports SQL-like syntax for ClickHouse)", inputSchema: { type: "object", properties: { query: { type: "string", description: "Custom query to execute" }, parameters: { type: "object", description: "Query parameters" } }, required: ["query"] } }
- src/index.ts:294-295 (registration)Dispatch case in the CallToolRequestHandler switch statement that routes to the executeCustomQuery method.case "execute_custom_query": return await this.executeCustomQuery(args);