Skip to main content
Glama
honeycombio
by honeycombio

get_slo

Retrieve detailed Service Level Objective information by ID from Honeycomb observability data. Get SLO metrics including compliance, target, time period, and budget remaining for monitoring system performance.

Instructions

Retrieves a specific SLO (Service Level Objective) by ID with detailed information. This tool returns a detailed object containing the SLO's ID, name, description, time period, target per million, compliance, budget remaining, SLI alias, and timestamps.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
environmentYesThe Honeycomb environment
datasetYesThe dataset containing the SLO
sloIdYesThe ID of the SLO to retrieve

Implementation Reference

  • The handler function that implements the core logic of the 'get_slo' tool: validates parameters, fetches SLO data using the Honeycomb API, simplifies the response structure, and returns it in MCP format.
    handler: async ({ environment, dataset, sloId }: { environment: string; dataset: string; sloId: string }) => {
      // Validate input parameters
      if (!environment) {
        return handleToolError(new Error("environment parameter is required"), "get_slo");
      }
      if (!dataset) {
        return handleToolError(new Error("dataset parameter is required"), "get_slo");
      }
      if (!sloId) {
        return handleToolError(new Error("sloId parameter is required"), "get_slo");
      }
    
      try {
        // Fetch SLO details from the API
        const slo = await api.getSLO(environment, dataset, sloId);
        
        // Simplify the response to reduce context window usage
        const simplifiedSLO: SimplifiedSLODetails = {
          id: slo.id,
          name: slo.name,
          description: slo.description || '',
          time_period_days: slo.time_period_days,
          target_per_million: slo.target_per_million,
          compliance: slo.compliance,
          budget_remaining: slo.budget_remaining,
          sli: slo.sli?.alias,
          created_at: slo.created_at,
          updated_at: slo.updated_at,
        };
        
        return {
          content: [
            {
              type: "text",
              text: JSON.stringify(simplifiedSLO, null, 2),
            },
          ],
          metadata: {
            sloId,
            dataset,
            environment
          }
        };
      } catch (error) {
        return handleToolError(error, "get_slo");
      }
    }
  • Zod schema defining the input parameters for the 'get_slo' tool: environment, dataset, and sloId.
    schema: {
      environment: z.string().describe("The Honeycomb environment"),
      dataset: z.string().describe("The dataset containing the SLO"),
      sloId: z.string().describe("The ID of the SLO to retrieve"),
    },
  • TypeScript interface defining the simplified structure of SLO data returned by the tool.
    interface SimplifiedSLODetails {
      id: string;
      name: string;
      description: string;
      time_period_days: number;
      target_per_million: number;
      compliance: number;
      budget_remaining: number;
      sli: string | undefined;
      created_at: string;
      updated_at: string;
    }
  • Registration of the 'get_slo' tool by including its creator function in the tools array passed to the MCP server registration.
    // SLO tools
    createListSLOsTool(api),
    createGetSLOTool(api),
  • Import of the createGetSLOTool function used to instantiate and register the 'get_slo' tool.
    import { createListSLOsTool } from "./list-slos.js";
    import { createGetSLOTool } from "./get-slo.js";
Behavior2/5

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

No annotations are provided, so the description carries full burden. It states this is a retrieval operation but doesn't disclose important behavioral traits like authentication requirements, rate limits, error conditions, or whether this is a read-only operation. The description provides basic functional information but lacks operational context.

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

Conciseness4/5

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

The description is appropriately sized with two sentences. The first sentence states the purpose clearly, and the second provides useful information about the return format. However, listing specific return fields could be considered slightly verbose when no output schema exists.

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

Completeness3/5

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

For a retrieval tool with 3 parameters and no annotations or output schema, the description provides adequate functional information but lacks operational context. It explains what the tool does and what it returns, but doesn't address authentication, error handling, or other behavioral aspects that would be helpful for an agent.

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?

Schema description coverage is 100%, so the schema already documents all three parameters. The description doesn't add any parameter-specific information beyond what's in the schema. The baseline of 3 is appropriate when the schema does the heavy lifting for parameter documentation.

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?

The description clearly states the specific action ('Retrieves'), resource ('a specific SLO by ID'), and scope ('with detailed information'). It distinguishes from sibling tools like 'list_slos' by specifying retrieval of a single SLO rather than listing multiple SLOs.

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

Usage Guidelines3/5

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

The description implies usage when detailed information about a specific SLO is needed, but doesn't explicitly state when to use this tool versus alternatives like 'list_slos' or other sibling tools. No explicit exclusions or prerequisites are mentioned.

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/honeycombio/honeycomb-mcp'

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