Skip to main content
Glama

OTC Dataset Statistics

otc_stats

Retrieve key statistics for the OTC company dataset, including total companies, companies with financials, average shell risk score, and update timestamp.

Instructions

Get statistics about the OTC company dataset: total companies, companies with financials, average shell risk score, last updated timestamp, and data source information. Free endpoint.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The `otc_stats` tool handler registered with MCP server. Calls the Verilex API endpoint /api/v1/otc/stats and returns dataset statistics (company count, last updated, etc.). No input parameters required.
    server.registerTool(
      "otc_stats",
      {
        title: "OTC Dataset Statistics",
        description:
          "Get statistics about the OTC company dataset: total companies, companies with financials, " +
          "average shell risk score, last updated timestamp, and data source information. Free endpoint.",
        inputSchema: {},
      },
      async () => {
        const res = await apiGet<OtcStatsResponse>("/api/v1/otc/stats");
    
        if (!res.ok) {
          return {
            content: [
              {
                type: "text" as const,
                text: `API error (${res.status}): ${JSON.stringify(res.data)}`,
              },
            ],
            isError: true,
          };
        }
    
        return {
          content: [
            { type: "text" as const, text: JSON.stringify(res.data, null, 2) },
          ],
        };
      },
    );
  • TypeScript interface `OtcStatsResponse` defining the expected response shape: dataset name, source, update_frequency, and stats object.
    interface OtcStatsResponse {
      dataset: string;
      source: string;
      update_frequency: string;
      stats: Record<string, unknown>;
    }
  • src/index.ts:43-43 (registration)
    Registration call: `registerOtcTools(server)` is invoked from the main index.ts to register all OTC tools including otc_stats.
    registerOtcTools(server);
  • The `apiGet` helper used by all tools (including otc_stats) to make HTTP GET requests to the Verilex API backend.
    export async function apiGet<T = unknown>(
      path: string,
      params?: Record<string, string | number | undefined>,
    ): Promise<ApiResponse<T>> {
      const url = buildUrl(path, params);
    
      const headers: Record<string, string> = {
        Accept: "application/json",
        "User-Agent": "verilex-mcp-server/0.1.0",
      };
    
      // Forward x402 payment token if present in env (for paid endpoints)
      const paymentToken = process.env.VERILEX_PAYMENT_TOKEN;
      if (paymentToken) {
        headers["X-Payment-Token"] = paymentToken;
      }
    
      const res = await fetch(url, { headers });
      const data = (await res.json()) as T;
    
      const stale = res.headers.get("X-Data-Stale");
      const lastUpdated = res.headers.get("X-Data-Last-Updated");
      const ageSeconds = res.headers.get("X-Data-Age-Seconds");
    
      return {
        ok: res.ok,
        status: res.status,
        data,
        stale: stale === "true",
        lastUpdated: lastUpdated ?? undefined,
        ageSeconds: ageSeconds ? Number(ageSeconds) : undefined,
      };
    }
Behavior3/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. It states the tool retrieves statistics (a read operation), but does not disclose any behavioral traits such as response format, caching behavior, rate limits, or authentication needs. For a simple tool with no parameters, the description is minimally adequate.

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 two sentences that are tightly packed with relevant information: the action, resource, and specific metrics. Every word earns its place, and the structure is front-loaded with the core purpose.

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 has no parameters, no output schema, and is a straightforward stats endpoint, the description provides a reasonable overview. However, it omits details about the output data structure (e.g., whether values are numbers or strings, if there are nested objects). For full completeness, the description should list all expected fields.

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 tool has zero parameters, so the baseline score is 4 per the rubric. The schema coverage is 100%, and the description adds value by enumerating the types of statistics returned, which helps the agent understand what to expect.

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 uses a specific verb 'Get statistics about the OTC company dataset' and lists key metrics (total companies, financials, shell risk score, timestamp, data source). It clearly distinguishes from sibling tools that target other datasets like contract_stats or crypto_stats.

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 only usage guidance is 'Free endpoint', which indicates no cost but does not clarify when to use this tool over sibling stats tools (e.g., company_profile, contract_stats). No context on when not to use or alternatives is provided.

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/carrierone/verilexdata-mcp'

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