Skip to main content
Glama
kajirita2002

honeycomb-mcp-server

honeycomb_query_result_create

Generate query results by running specific queries on datasets using a dedicated MCP server. Input dataset slug and query ID to execute and retrieve query outputs.

Instructions

Create a new query result (run a query)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
datasetSlugYesDataset slug to create query result for
queryIdYesQuery ID to run

Implementation Reference

  • Handler case in the CallToolRequest switch statement that handles the honeycomb_query_result_create tool call by parsing arguments and invoking the client.createQueryResult method.
    case "honeycomb_query_result_create": {
      const args = request.params
        .arguments as unknown as QueryResultCreateArgs;
      if (!args.datasetSlug || !args.queryId) {
        throw new Error("datasetSlug and queryId are required");
      }
      const response = await client.createQueryResult(
        args.datasetSlug,
        args.queryId,
        {
          disable_series: args.disable_series,
          disable_total_by_aggregate: args.disable_total_by_aggregate,
          disable_other_by_aggregate: args.disable_other_by_aggregate,
          limit: args.limit
        }
      );
      return {
        content: [{ type: "text", text: JSON.stringify(response) }],
      };
    }
  • Core helper method in HoneycombClient class that executes the HTTP POST request to the Honeycomb API endpoint `/query_results/{datasetSlug}` to create and return a query result ID.
    async createQueryResult(datasetSlug: string, queryId: string, options?: {
      disable_series?: boolean;
      disable_total_by_aggregate?: boolean;
      disable_other_by_aggregate?: boolean;
      limit?: number;
    }): Promise<any> {
      const response = await fetch(`${this.baseUrl}/query_results/${datasetSlug}`, {
        method: "POST",
        headers: this.headers,
        body: JSON.stringify({
          query_id: queryId,
          disable_series: options?.disable_series ?? false,
          disable_total_by_aggregate: options?.disable_total_by_aggregate ?? true,
          disable_other_by_aggregate: options?.disable_other_by_aggregate ?? true,
          limit: options?.limit ?? 10000
        }),
      });
    
      if (!response.ok) {
        const errorBody = await response.text();
        console.error(`Query result creation error: Status=${response.status}, Body=${errorBody}`);
        throw new Error(`Failed to create query result: ${response.statusText}`);
      }
    
      return await response.json();
    }
  • Tool definition object including input schema for validating arguments to the honeycomb_query_result_create tool.
    const queryResultCreateTool: Tool = {
      name: "honeycomb_query_result_create",
      description: "Run a previously created query and return a query result ID that can be used to retrieve the results.",
      inputSchema: {
        type: "object",
        properties: {
          datasetSlug: {
            type: "string",
            description: "The dataset slug or use `__all__` for endpoints that support environment-wide operations.",
          },
          queryId: {
            type: "string",
            description: "The unique identifier (ID) of the query to run.",
          },
          disable_series: {
            type: "boolean",
            description: "Whether to disable series in the query result",
          },
          disable_total_by_aggregate: {
            type: "boolean",
            description: "Whether to disable total by aggregate in the query result",
          },
          disable_other_by_aggregate: {
            type: "boolean",
            description: "Whether to disable other by aggregate in the query result",
          },
          limit: {
            type: "integer",
            description: "Maximum number of results to return",
          },
        },
        required: ["datasetSlug", "queryId"],
      },
    };
  • index.ts:783-796 (registration)
    Registration of all tools including honeycomb_query_result_create (via queryResultCreateTool) in the ListToolsRequest handler.
    return {
      tools: [
        authTool,
        datasetsListTool,
        datasetGetTool,
        columnsListTool,
        queryCreateTool,
        queryGetTool,
        queryResultCreateTool,
        queryResultGetTool,
        datasetDefinitionsListTool,
        boardsListTool,
        boardGetTool,
      ],
  • TypeScript interface defining the expected input arguments for the query result create tool.
    interface QueryResultCreateArgs {
      datasetSlug: string;
      queryId: string;
      disable_series?: boolean;
      disable_total_by_aggregate?: boolean;
      disable_other_by_aggregate?: boolean;
      limit?: number;
    }
Behavior2/5

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

With no annotations provided, the description carries full burden but only states the basic action. It doesn't disclose behavioral traits such as whether this is a read-only or mutating operation (implied mutation from 'Create'), potential side effects, rate limits, authentication needs, or what the output looks like (no output schema).

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?

The description is extremely concise with a single, front-loaded sentence that directly states the purpose without any wasted words. Every part of the sentence earns its place by combining the action and method.

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

Completeness2/5

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

Given the complexity of a tool that creates/executes queries (implied mutation), no annotations, and no output schema, the description is incomplete. It lacks crucial context such as what the tool returns, error conditions, or how it interacts with the Honeycomb system beyond the basic action.

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?

The schema description coverage is 100%, so the schema already documents both parameters fully. The description adds no additional meaning beyond what's in the schema (e.g., it doesn't explain the relationship between datasetSlug and queryId or provide usage examples), meeting the baseline for high schema coverage.

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

Purpose4/5

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

The description clearly states the action ('Create a new query result') and the method ('run a query'), which specifies the verb and resource. However, it doesn't differentiate from sibling tools like 'honeycomb_query_result_get' or explain how this differs from just running a query directly versus creating a result object.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing an existing query), when-not-to-use scenarios, or how it relates to siblings like 'honeycomb_query_create' or 'honeycomb_query_result_get'.

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

Related 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/kajirita2002/honeycomb-mcp-server'

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