Skip to main content
Glama

Count companies

count_companies
Read-only

FREE — how many companies match (market size), e.g. { filters: { countries: ["IT"], naics: ["315"] } }; with by (needs a key) broken down by one dimension (countries, states, industries, naics, employees, revenue …). Exact values from search_options (for: companies). Loading the companies into a list is load_companies (priced in options).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "filters": "<filters>"
    },
    "name": "count_companies"
  }
}

Input Schema

NameRequiredDescriptionDefault
byNoOne dimension to break the total down by: regions, countries, states, industries, sub_industries, naics, employees, reported_employees, revenue, company_types, categories, growth, departments
filtersYesCompany filters — exact values from search_options (for: companies)
languageNoLanguage of `tell_your_user` (default en)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already cover read-only/non-destructive/open-world, so the description's contribution is the cost profile (FREE vs priced loading) and the 'by needs a key' prerequisite, both of which matter for planning and are not in annotations. Return shape is left unspecified.

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?

Dense and front-loaded with the free-tier fact, example, and sibling pointer, with no filler. The telegraphic fragment style (semicolons, 'needs a key') is efficient but slightly harder to parse than plain sentences.

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

Completeness4/5

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

Covers purpose, cost, the optional breakdown, and value sourcing for a tool with no output schema. The one gap is that it never says what comes back (a bare count, or a keyed breakdown when `by` is used), which an agent must infer.

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 coverage is 100%, so the schema carries the parameter burden; the description mainly restates filtering and the `by` breakdown. It does add two non-obvious points the schema does not state, the 'needs a key' condition on `by` and where to get exact filter values (search_options), which lifts it slightly but not above baseline-plus.

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?

States a specific verb and resource ('how many companies match'), frames the use case ('market size'), and explicitly distinguishes itself from the sibling load_companies, which returns lists rather than counts.

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?

Names the alternative (load_companies) and the condition that selects it, and flags that this tool is FREE while loading is priced. It stops short of an explicit 'use this when / don't use this when' rule, but the routing signal is clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources