Skip to main content
Glama

insumer_credits

Check your verification credit balance, subscription tier (free/pro/enterprise), and daily rate limit for the current API key to determine usage capacity for on-chain attestation queries.

Instructions

Check verification credit balance, tier (free/pro/enterprise), and daily rate limit for the current API key.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The tool registration and handler for 'insumer_credits'. It calls GET /credits on the API and formats the result (credit balance, tier, rate limit).
    server.tool(
      "insumer_credits",
      "Check verification credit balance, tier (free/pro/enterprise), and daily rate limit for the current API key.",
      {},
      async () => {
        const result = await apiCall("GET", "/credits");
        return formatResult(result);
      }
    );
  • src/index.ts:447-455 (registration)
    The tool is registered using server.tool() with the name 'insumer_credits' on the McpServer instance.
    server.tool(
      "insumer_credits",
      "Check verification credit balance, tier (free/pro/enterprise), and daily rate limit for the current API key.",
      {},
      async () => {
        const result = await apiCall("GET", "/credits");
        return formatResult(result);
      }
    );
  • The apiCall helper function used by the handler to make authenticated requests to the Insumer API.
    async function apiCall(
      method: string,
      path: string,
      body?: Record<string, unknown>
    ): Promise<{ ok: boolean; data?: unknown; error?: unknown; meta?: unknown }> {
      if (!apiKey) {
        return { ok: false, error: "INSUMER_API_KEY is not set. Call the insumer_setup tool to generate a free API key instantly, then add it to your MCP config as INSUMER_API_KEY and restart." };
      }
      const url = `${API_BASE}${path}`;
      const res = await fetch(url, {
        method,
        headers: {
          "Content-Type": "application/json",
          "X-API-Key": apiKey,
        },
        body: body ? JSON.stringify(body) : undefined,
      });
      return res.json() as Promise<{
        ok: boolean;
        data?: unknown;
        error?: unknown;
        meta?: unknown;
      }>;
    }
  • The formatResult helper function that formats API responses into MCP content blocks, setting isError on failure.
    function formatResult(result: {
      ok: boolean;
      data?: unknown;
      error?: unknown;
      meta?: unknown;
    }) {
      if (result.ok) {
        return {
          content: [{ type: "text" as const, text: JSON.stringify(result, null, 2) }],
        };
      }
      return {
        content: [{ type: "text" as const, text: JSON.stringify(result, null, 2) }],
        isError: true,
      };
Behavior3/5

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

No annotations are provided. The description indicates a read-like operation (check) but does not explicitly state if it is safe, free, or has any side effects. It lacks details on authentication or rate limits for the tool itself, leaving some behavioral uncertainty.

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?

A single, front-loaded sentence that efficiently conveys the tool's purpose without any unnecessary words. Every part of the description contributes to understanding.

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

Completeness5/5

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

Given no parameters and no output schema, the description fully specifies what information the tool provides (balance, tier, rate limit). It is sufficient for an agent to select and invoke the tool correctly.

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

Parameters4/5

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

The input schema has zero parameters, and the description adds meaning by explaining what the tool returns (balance, tier, rate limit). Per the baseline rule for 0 parameters, a score of 4 is justified.

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 verb 'Check' and specifies three concrete resources: verification credit balance, tier (free/pro/enterprise), and daily rate limit. It is distinct from sibling tools like insumer_buy_credits or insumer_attest.

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?

The description implies usage when the agent needs current credit information or tier status. It does not explicitly contrast with alternatives, but the context is clear and no misleading information is present.

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/douglasborthwick-crypto/mcp-server-insumer'

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