Skip to main content
Glama
hackle-io
by hackle-io

analytics-chart-detail

Fetch and visualize detailed analytics from A/B test charts by providing chart ID and type using the hackle-mcp server's tool.

Instructions

fetch analytics chart detail. You can visualize the chart using this tool's result.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
chartIdYesChart id
chartTypeYesType of the chart. Will throw an error if given chartId's chart type is different from chartType.

Implementation Reference

  • The handler function for the 'analytics-chart-detail' tool. It constructs a query string with chartType, fetches the chart details from the API using WebClient.get, stringifies the JSON response, and returns it as text content.
    async ({ chartId, chartType }) => { const qs = stringify({ chartType }, { addQueryPrefix: true }); return { content: [ { type: 'text', text: JSON.stringify(await WebClient.get(`/api/v1/analytics/charts/${chartId}${qs}`)), }, ], }; },
  • Input schema defined using Zod: requires chartId (positive number) and chartType (one of FUNNEL, DATA_INSIGHT, RETENTION, USER_PATH).
    { chartId: z.number().positive().describe('Chart id'), chartType: z .enum(['FUNNEL', 'DATA_INSIGHT', 'RETENTION', 'USER_PATH']) .describe("Type of the chart. Will throw an error if given chartId's chart type is different from chartType."), },
  • src/index.ts:291-312 (registration)
    The server.tool call that registers the 'analytics-chart-detail' tool, providing the name, description, input schema, and inline handler function.
    server.tool( 'analytics-chart-detail', "fetch analytics chart detail. You can visualize the chart using this tool's result.", { chartId: z.number().positive().describe('Chart id'), chartType: z .enum(['FUNNEL', 'DATA_INSIGHT', 'RETENTION', 'USER_PATH']) .describe("Type of the chart. Will throw an error if given chartId's chart type is different from chartType."), }, async ({ chartId, chartType }) => { const qs = stringify({ chartType }, { addQueryPrefix: true }); return { content: [ { type: 'text', text: JSON.stringify(await WebClient.get(`/api/v1/analytics/charts/${chartId}${qs}`)), }, ], }; }, );

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/hackle-io/hackle-mcp'

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