Skip to main content
Glama

datasets_bbb_businesses_facets

Read-only

Aggregate the BBB businesses dataset by category, state, city, rating, accreditation, entity type, BBB alert title, or whether a profile has alerts. Use datasets_bbb_businesses_search to search for matching businesses.

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": {
      "facet": "<facet>"
    },
    "name": "datasets_bbb_businesses_facets"
  }
}

Input Schema

NameRequiredDescriptionDefault
qNoOptional full-text match on the business name/category, max 256 characters.
cityNoOptional exact city slug as in the profile URL, e.g. san-diego. Use the values returned by facets?facet=city with a state filter, and send state with it.
pageNoResult page number, 1-based, default 1; page times page_size must not exceed 10000.
sortNoOptional sort order. Allowed values: relevance, rating_desc, rating_asc, accredited_first, name_asc, years_in_business_desc, complaints_desc. Defaults to relevance with q, otherwise accredited_first.
facetYesRequired facet to aggregate. Allowed values: country, address_country, category, state, city, rating, accredited, entity_type, run_id, alert_title, has_alerts.
limitNoValues per page, default 50, max 1000.
stateNoOptional exact 2-letter state or province code as in the profile URL, e.g. tx. Use the values returned by facets?facet=state.
offsetNoValues to skip, default 0. Page with offset += limit while has_more is true; offset plus limit must not exceed 10000.
ratingNoOptional exact letter-grade rating filter. Allowed values: A+, A, A-, B+, B, B-, C+, C, C-, D+, D, D-, F.
run_idNoOptional exact crawl run id filter, e.g. bbb-20260906. Use the values returned by facets?facet=run_id.
countryNoOptional country filter, parsed from the profile URL. Allowed values: us, ca.
categoryNoOptional exact category filter, e.g. Plumber (case-sensitive). Use the values returned by facets?facet=category.
page_sizeNoPage size, default 20, max 100; page times page_size must not exceed 10000.
accreditedNoOptional accreditation filter; true keeps only accredited businesses, false only the others.
has_alertsNoOptional BBB-alert filter; true keeps businesses whose profile carries at least one BBB alert, false keeps refreshed records with none. Records not yet re-crawled since the field was added match neither.
alert_titleNoOptional exact BBB alert title filter, e.g. Pattern of Complaint. Use the values returned by facets?facet=alert_title.
entity_typeNoOptional exact entity-type filter, e.g. Limited Liability Company (LLC) (case-sensitive). Use the values returned by facets?facet=entity_type.
min_complaintsNoOptional floor against total_complaints (BBB's three-year complaint count), 0 or greater, e.g. 1 for businesses with at least one complaint.
address_countryNoOptional country filter derived from the business address, separate from the profile-URL country. Allowed values: us, ca.
min_rating_rankNoOptional numeric floor against the denormalized rating rank (A+=12 down to F=0), e.g. 10 for 'A- and above'.

Output Schema

NameRequiredDescriptionDefault
dataYesThe tool result payload (shape varies per tool; see each tool's docs resource).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / address_country
      Added value: +{
      +  "description": "Optional country filter derived from the business address, separate from the profile-URL country. Allowed values: us, ca.",
      +  "type": "string"
      +}
    • changedInput schema / properties / facet / description
      Previous value: -"Required facet to aggregate. Allowed values: country, category, state, city, rating, accredited, entity_type, run_id, alert_title, has_alerts."New value: +"Required facet to aggregate. Allowed values: country, address_country, category, state, city, rating, accredited, entity_type, run_id, alert_title, has_alerts."
  2. Changed6 schema fields changed
    • changedInput schema / properties / accredited / description
      Previous value: -"Optional accreditation filter; true keeps only accredited businesses."New value: +"Optional accreditation filter; true keeps only accredited businesses, false only the others."
    • changedInput schema / properties / category / description
      Previous value: -"Optional exact category filter, e.g. Plumber. Use the values returned by facets?facet=category."New value: +"Optional exact category filter, e.g. Plumber (case-sensitive). Use the values returned by facets?facet=category."
    • changedInput schema / properties / city / description
      Previous value: -"Optional exact city filter, parsed from the profile URL."New value: +"Optional exact city slug as in the profile URL, e.g. san-diego. Use the values returned by facets?facet=city with a state filter, and send state with it."
    • changedInput schema / properties / entity_type / description
      Previous value: -"Optional exact entity-type filter, e.g. Limited Liability Company (LLC)."New value: +"Optional exact entity-type filter, e.g. Limited Liability Company (LLC) (case-sensitive). Use the values returned by facets?facet=entity_type."
    • changedInput schema / properties / run_id / description
      Previous value: -"Optional exact crawl run id filter."New value: +"Optional exact crawl run id filter, e.g. bbb-20260906. Use the values returned by facets?facet=run_id."
    • changedInput schema / properties / state / description
      Previous value: -"Optional exact 2-letter state/province filter, parsed from the profile URL, e.g. tx."New value: +"Optional exact 2-letter state or province code as in the profile URL, e.g. tx. Use the values returned by facets?facet=state."
  3. Changed4 schema fields changed
    • addedInput schema / properties / country
      Added value: +{
      +  "description": "Optional country filter, parsed from the profile URL. Allowed values: us, ca.",
      +  "type": "string"
      +}
    • changedInput schema / properties / facet / description
      Previous value: -"Required facet to aggregate. Allowed values: category, state, city, rating, accredited, entity_type, run_id, alert_title, has_alerts."New value: +"Required facet to aggregate. Allowed values: country, category, state, city, rating, accredited, entity_type, run_id, alert_title, has_alerts."
    • addedInput schema / properties / limit
      Added value: +{
      +  "description": "Values per page, default 50, max 1000.",
      +  "type": "integer"
      +}
    • addedInput schema / properties / offset
      Added value: +{
      +  "description": "Values to skip, default 0. Page with offset += limit while has_more is true; offset plus limit must not exceed 10000.",
      +  "type": "integer"
      +}
  4. Changed5 schema fields changed
    • addedInput schema / properties / alert_title
      Added value: +{
      +  "description": "Optional exact BBB alert title filter, e.g. Pattern of Complaint. Use the values returned by facets?facet=alert_title.",
      +  "type": "string"
      +}
    • changedInput schema / properties / facet / description
      Previous value: -"Required facet to aggregate. Allowed values: category, state, city, rating, accredited, entity_type, run_id."New value: +"Required facet to aggregate. Allowed values: category, state, city, rating, accredited, entity_type, run_id, alert_title, has_alerts."
    • addedInput schema / properties / has_alerts
      Added value: +{
      +  "description": "Optional BBB-alert filter; true keeps businesses whose profile carries at least one BBB alert, false keeps refreshed records with none. Records not yet re-crawled since the field was added match neither.",
      +  "type": [
      +    "null",
      +    "boolean"
      +  ]
      +}
    • addedInput schema / properties / min_complaints
      Added value: +{
      +  "description": "Optional floor against total_complaints (BBB's three-year complaint count), 0 or greater, e.g. 1 for businesses with at least one complaint.",
      +  "type": [
      +    "null",
      +    "integer"
      +  ]
      +}
    • changedInput schema / properties / sort / description
      Previous value: -"Optional sort order. Allowed values: relevance, rating_desc, rating_asc, accredited_first, name_asc, years_in_business_desc. Defaults to relevance with q, otherwise accredited_first."New value: +"Optional sort order. Allowed values: relevance, rating_desc, rating_asc, accredited_first, name_asc, years_in_business_desc, complaints_desc. Defaults to relevance with q, otherwise accredited_first."
  5. First observed

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and openWorldHint=true, so the safety profile is covered. The description adds only the aggregation semantics and does not mention the 10,000-row offset/page ceiling that constrains deep paging, nor anything about idempotency or result shape; with annotations present, this is an acceptable but modest addition.

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?

Two sentences: what it aggregates first, the alternative second. No filler, no repetition of schema-level detail, and the actionable routing advice is placed where an agent will see it.

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?

With an output schema present the description need not explain return values, and the schema carries parameter constraints, so the remaining job is purpose plus sibling routing, which is done. The only gap is that the description does not hint at the discover-facets-then-filter workflow the schema references, but that information is available elsewhere.

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 every one of the 20 parameters is already documented in detail, including enum values and the facet-then-filter chaining pattern. The description's facet list largely restates the required 'facet' parameter's allowed values, adding no filtering syntax or constraint detail beyond the schema; baseline 3 applies.

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?

States a specific verb ('Aggregate') and a specific resource (the BBB businesses dataset) and enumerates the grouping dimensions, which lets an agent distinguish it from the search/item siblings. The enumeration is slightly incomplete versus the schema's allowed facet list (country, address_country, run_id are omitted), so it is not fully precise.

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?

Explicitly routes the agent to datasets_bbb_businesses_search when it wants matching records rather than counts, which is the main selection decision here. It does not spell out when aggregation is inappropriate (e.g. record-level retrieval or detail lookup via datasets_bbb_businesses_item), but the core alternative is named.

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.