Skip to main content
Glama

clinicaltrials_studies_facets

Read-only

Returns the ClinicalTrials.gov search filter panel for a search: total studies, per-option counts for status, sex, age group, healthy volunteers, phase, study type, results, funder type, documents, violations and results submission, plus the synonym ids the engine matched for each query term. Use it to size a search or pick agg_filters and synonyms values before clinicaltrials_studies.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "clinicaltrials_studies_facets"
  }
}

Input Schema

NameRequiredDescriptionDefault
idNoStudy IDs query (IdSearch area: NCT numbers, org and secondary IDs)
idsNoComma-separated NCT numbers (also matches NCT aliases)
cityNoLocation city (AREA[LocationCity])
condNoConditions or disease query (Essie syntax, ConditionSearch area)
intrNoIntervention or treatment query (InterventionSearch area)
leadNoLead sponsor name query (LeadSponsorName field)
locnNoLocation terms query (LocationSearch area)
outcNoOutcome measure query (OutcomeSearch area)
termNoOther terms query (Essie syntax, BasicSearch area)
sponsNoSponsor or collaborator query (SponsorSearch area)
stateNoLocation state or region (AREA[LocationState])
age_toNoEligible age range end
titlesNoTitle or acronym query (TitleSearch area)
countryNoLocation country (AREA[LocationCountry])
patientNoPatient-friendly search (PatientSearch area)
advancedNoEssie expression filter, ANDed with the location, date and age filters
age_fromNoEligible age range start: number and unit (Years, Months, Weeks, Days, Hours, Minutes)
distanceNoRadius with km or mi unit
latitudeNoLatitude of the distance filter (with longitude and distance)
start_toNoStudy start date to
synonymsNoComma-separated area:synonym_id pairs from /clinicaltrials/studies/facets
geo_decayNoProximity ranking for the distance filter: func:(gauss|exp|linear),scale:<d>(km|mi),offset:<d>(km|mi),decay:<n>
longitudeNoLongitude of the distance filter
start_fromNoStudy start date from (YYYY, YYYY-MM or YYYY-MM-DD)
agg_filtersNoSearch-page filters as id:key pairs, keys space-separated, ids comma-separated; ids and keys: status (not, rec, act, com, ter, enr, sus, wit, unk, ava, nla, tna, afm), sex (f, m), ages (child, adult, older), healthy (y), phase (0, 1, 2, 3, 4, NA), studyType (int, obs, obs_patreg, exp, exp_indiv, exp_inter, exp_treat), results (with, without), funderType (nih, fed, industry, other), docs (prot, sap, icf), violation (y), ressub (n, y, c)
completion_toNoStudy completion date to
overall_statusNoComma-separated overall statuses. Documented values: ACTIVE_NOT_RECRUITING, COMPLETED, ENROLLING_BY_INVITATION, NOT_YET_RECRUITING, RECRUITING, SUSPENDED, TERMINATED, WITHDRAWN, AVAILABLE, NO_LONGER_AVAILABLE, TEMPORARILY_NOT_AVAILABLE, APPROVED_FOR_MARKETING, WITHHELD, UNKNOWN.
completion_fromNoStudy completion date from
first_posted_toNoFirst posted date to
first_posted_fromNoFirst posted date from
last_update_posted_toNoLast update posted date to
primary_completion_toNoPrimary completion date to
last_update_posted_fromNoLast update posted date from
primary_completion_fromNoPrimary completion date from
results_first_posted_toNoResults first posted date to
results_first_posted_fromNoResults first posted date from

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. Added

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, openWorldHint=true and idempotentHint=false, so safety is covered; the description adds that the response is a filter panel with per-option counts and engine-matched synonym ids — information not derivable from annotations. It does not discuss cost/latency or what happens with zero filters, which would have pushed this higher.

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?

Two sentences, front-loaded with the what and followed by the when-to-use routing. The long enumeration in sentence one is dense but each item is a real output facet, so it earns its place rather than padding.

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?

For a 36-parameter tool with zero required params, 100% schema coverage and a present output schema, the description supplies the essential framing: the parameters are the search filters, the response is the facet panel, and the output feeds the sibling search tool. It stops short of explaining edge behaviors (e.g., empty-query behavior or how counts are scoped), but nothing critical for correct invocation is missing.

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% and every one of the 36 filter parameters is already documented in the schema, so the description is not required to carry parameter meaning. It does add one useful link — that the returned synonym ids are the values to feed into `synonyms` and that counts map to `agg_filters` — but the schema itself already notes synonyms come from this facets endpoint, so the added value is modest.

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 names a specific verb and resource — 'Returns the ClinicalTrials.gov search filter panel for a search' — and enumerates exactly what the panel contains (total studies, per-option counts for status, sex, age group, phase, study type, results, funder type, documents, violations, results submission, plus matched synonym ids). This is clearly distinguishable from clinicaltrials_studies, which performs the actual search rather than the facet/preflight step.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states the use case directly: 'Use it to size a search or pick agg_filters and synonyms values before clinicaltrials_studies.' The alternative tool is named and the condition that selects it (you need counts or filter/synonym values before searching) is explicit, leaving nothing to inference.

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.