Skip to main content
Glama

venice_get_rate_limits

Retrieve current rate limits, usage statistics, and account details to monitor API consumption and manage access effectively.

Instructions

Get current rate limits, usage, and account information

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Registration of the 'venice_get_rate_limits' tool using server.tool, including the inline handler function and empty input schema.
    server.tool(
      "venice_get_rate_limits",
      "Get current rate limits, usage, and account information",
      {},
      async () => {
        const response = await veniceAPI("/api_keys/rate_limits");
        const data = await response.json() as RateLimitsResponse;
        if (!response.ok) return { content: [{ type: "text" as const, text: `Error: ${data.error?.message || response.statusText}` }] };
        return { content: [{ type: "text" as const, text: JSON.stringify(data.data, null, 2) }] };
      }
    );
  • The asynchronous handler function that calls the Venice API to retrieve rate limits and returns the formatted response or error.
    async () => {
      const response = await veniceAPI("/api_keys/rate_limits");
      const data = await response.json() as RateLimitsResponse;
      if (!response.ok) return { content: [{ type: "text" as const, text: `Error: ${data.error?.message || response.statusText}` }] };
      return { content: [{ type: "text" as const, text: JSON.stringify(data.data, null, 2) }] };
    }
  • TypeScript interface for the RateLimitsResponse used in the tool handler for type assertion.
    export interface RateLimitsResponse extends VeniceAPIError {
      data?: Record<string, unknown>;
    }
  • Helper function veniceAPI that makes authenticated HTTP requests to the Venice AI API, used by the tool handler.
    export async function veniceAPI(endpoint: string, options: RequestInit = {}): Promise<Response> {
      const url = `${BASE_URL}${endpoint}`;
      const headers: Record<string, string> = {
        "Authorization": `Bearer ${API_KEY}`,
        "Content-Type": "application/json",
        ...(options.headers as Record<string, string> || {}),
      };
      return fetch(url, { ...options, headers });
    }
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states what the tool does but doesn't describe behavioral traits such as whether it requires authentication, has rate limits itself, returns real-time or cached data, or what format the output takes. For a tool with zero annotation coverage, this is inadequate.

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 a single, efficient sentence that directly states the tool's purpose without any fluff. It's front-loaded and every word earns its place, making it highly concise and well-structured.

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?

Given the tool's complexity (simple read operation with no parameters) and lack of annotations/output schema, the description is minimally complete. It specifies what information is retrieved but doesn't cover behavioral aspects like authentication needs or output format. This is adequate for a basic tool but leaves gaps in context.

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 0 parameters with 100% coverage, so no parameter documentation is needed. The description doesn't add parameter details, which is appropriate. Baseline for 0 parameters is 4, as it avoids unnecessary information while being complete for the schema.

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 tool's purpose with specific verbs ('Get') and resources ('current rate limits, usage, and account information'). It distinguishes itself from siblings like venice_get_rate_limit_logs (which likely shows historical logs) and venice_list_api_keys (which focuses on API keys). However, it doesn't explicitly differentiate from all siblings, keeping it at 4 rather than 5.

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 when it's appropriate (e.g., for monitoring API usage or checking account status) or when not to use it (e.g., for historical data or specific resource management). With siblings like venice_get_rate_limit_logs available, this lack of context is a significant gap.

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/georgeglarson/venice-mcp'

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