ClinicalTrials.gov enables AI agents to search registered clinical studies by condition, intervention, location, recruitment status, and study phase. Retrieve trial protocols, eligibility criteria, investigator details, outcome measures, and study results to support clinical research and evidence reviews.
Codex is OpenAI's coding agent for the terminal. It reads MCP servers from its config and signs in to remote ones with OAuth.
This guide connects ClinicalTrials.gov MCP to Codex through MewCP, so Codex can use ClinicalTrials.gov MCP's 6 tools, like search_trials, get_trial_details and search_by_sponsor.
ClinicalTrials.gov MCP needs no credentials, but every call still runs through MewCP: scoped, checked and logged like any other.
More apps
Manage courses, assignments, rosters and student activity within Google Classroom. Create learning workflows, track submissions and organize educational content across classrooms.
AI's impact on real-world sectors, as a structured record for agents: source-linked headlines placed in one of 18 sectors (healthcare, law, retail, government, defense and more), with outlet, country and time, since June 2026
The Synthesize Bio MCP Server enables AI agents to compare gene expression between sample groups, analyze bulk and single-cell RNA sequencing data, and run long-running bioinformatics workflows that return completed analysis reports.
Search Microsoft Learn documentation and training content through MCP, helping AI agents find relevant technical guidance, tutorials, modules, and learning resources.
Other clients
ClinicalTrials.gov MCP works the same way in every client below. Pick yours for its own guide.
Free to start.
Scope access to the exact ClinicalTrials.gov MCP tools and accounts you allow, work and personal side by side. Anything outside that scope is refused at call time, even when the model asks for it.
Each call is logged: what ran, on which account, and whether it worked. Failures come back structured, so the agent knows whether to retry instead of guessing.
Every app sits behind one secure MCP URL, and there is no server for you to deploy or keep running. Add an integration in the dashboard and it is live on the next call, with no config to change and no new credentials to wire up. Tools load only when a task needs them, so your agent stays fast and focused however many apps you connect.
Run this and approve access in the browser window.
Start a new chat and ask: "List the tools you can use from MewCP." You should see your connected apps.
Search ClinicalTrials.gov database for clinical trials. This is the PRIMARY tool for finding trials. WHEN TO USE: - Finding trials for a disease/condition (e.g., 'What trials exist for lung cancer?') - Finding trials testing a specific drug/treatment (e.g., 'Find pembrolizumab trials') - Finding trials in a geographic area (e.g., 'Clinical trials in Boston') - General trial discovery and research questions USE DIFFERENT TOOLS FOR: - Detailed info on a specific trial by NCT ID -> use get_trial_details - All trials by a specific company -> use search_by_sponsor (or search_trials with sponsor=...) - Analyzing endpoints/outcomes -> use analyze_endpoints - Patient eligibility matching -> use search_by_eligibility QUERY SYNTAX (for condition, intervention, sponsor, location): - Boolean: 'cancer AND immunotherapy', 'aspirin OR ibuprofen', 'tumor NOT benign' - Exact phrase: '"breast cancer"' (with quotes) - Grouping: '(lung OR breast) AND cancer' - Synonyms are automatically included (e.g., 'heart attack' finds 'myocardial infarction') BEST PRACTICES: - Start with condition parameter for disease-focused searches - Add status=['RECRUITING'] to find active trials patients can join - Use phase filter for specific development stages (PHASE1, PHASE2, PHASE3, PHASE4) - Set count_total=true to know total matches (useful for: 'How many trials exist for X?') - Use page_size=50-100 for broader overviews, page_size=10 for quick lookups
Get comprehensive details for a specific clinical trial using its NCT ID. WHEN TO USE: - User provides a specific NCT ID (e.g., 'Tell me about NCT04567890') - Need full eligibility criteria, endpoints, or locations for a specific trial - Following up on a trial found via search_trials - Answering detailed questions about a known trial - Verifying patient eligibility for a specific trial USE search_trials INSTEAD FOR: - Finding trials (this tool requires knowing the NCT ID) - Browsing trials by condition/intervention/sponsor WHAT THIS RETURNS: - Full eligibility criteria (inclusion/exclusion) - Study design and methodology - Primary, secondary, and other endpoints with timeframes - All study locations with contact info - Sponsor and collaborator details - Study dates and enrollment numbers - Results link if trial has published results NCT ID FORMAT: 'NCT' followed by 8 digits (e.g., NCT04567890, NCT00001234)
Find all clinical trials sponsored by a specific company or organization. Functionally equivalent to search_trials(sponsor=...). WHEN TO USE: - Questions about a company's pipeline (e.g., 'What is Pfizer working on?') - Competitive intelligence (e.g., 'What cancer drugs is Novartis developing?') - Tracking pharma company portfolios and development programs - Finding trials from academic institutions (e.g., 'Mayo Clinic', 'NIH') USE search_trials INSTEAD FOR: - Disease-focused searches where sponsor doesn't matter - Finding trials by treatment name rather than sponsor EXAMPLES: - 'Pfizer Phase 3 trials' -> sponsor_name='Pfizer', phase=['PHASE3'] - 'Moderna COVID vaccines' -> sponsor_name='Moderna', condition='COVID-19' - 'Active Merck oncology trials' -> sponsor_name='Merck', condition='cancer', status=['RECRUITING'] TIPS: - Partial names work: 'Pfizer' matches 'Pfizer Inc', 'Pfizer Pharmaceuticals' - Set count_total=true to get total number of trials by sponsor - Combine with phase filter to see early vs late stage pipeline
Find principal investigators (PIs) and research sites conducting trials in a therapeutic area. WHEN TO USE: - 'Who are the leading researchers in Alzheimer trials?' - 'Find investigators at Mayo Clinic working on cancer' - 'Which sites in California are running diabetes trials?' - Site selection for planning new trials - Building investigator networks and collaborations USE search_trials FOR: - Finding trials themselves rather than investigators - When you need trial details, not investigator info WHAT THIS RETURNS: - Investigator names and roles (Principal Investigator, Sub-Investigator) - Institutional affiliations - Facility/site names - Geographic locations - Associated trial NCT IDs and titles TIPS: - Use condition parameter to focus on a disease area - Add institution to find investigators at specific hospitals/universities - Use location for geographic focus (city, state, country) - Increase page_size to 50-100 for more comprehensive investigator lists - Use investigator_name for direct name search via advanced query syntax ADVANCED: For direct investigator name search, use the investigator_name parameter which searches in OverallOfficialName and ResponsiblePartyInvestigatorFullName fields.
Analyze primary and secondary outcome measures (endpoints) from clinical trials. MODES (provide ONLY nct_id OR condition, not both): 1. Single Trial: Provide nct_id ONLY to analyze one specific trial's endpoints 2. Aggregate: Provide condition ONLY to analyze patterns across multiple trials If both provided, nct_id takes precedence (single trial mode). SINGLE TRIAL MODE (nct_id): - Returns all endpoints for the specified trial - Useful for understanding specific trial design - Example: nct_id='NCT03661411' AGGREGATE MODE (condition): - Analyzes endpoints across many trials in a therapeutic area - Identifies common endpoint patterns and measures - Useful for protocol design and competitive analysis - Example: condition='diabetes', phase=['PHASE3'] WHAT THIS RETURNS: - List of primary endpoints (main efficacy measures) - List of secondary endpoints (additional outcomes) - List of other endpoints (exploratory outcomes) - Most common measures across analyzed trials - Timeframes for each endpoint measurement EXAMPLES: - Single trial: nct_id='NCT03661411' - Phase 3 cancer endpoints: condition='cancer', phase=['PHASE3'] - Recent diabetes outcomes: condition='diabetes', start_date_after='2022-01-01'
Find clinical trials matching specific patient eligibility criteria. Use this for patient-trial matching and finding trials a specific patient might qualify for. DEFAULT STATUS: Only searches RECRUITING trials. To include completed, upcoming, or all trials, explicitly set the status parameter. WHEN TO USE: - Patient matching: 'Find trials for a 65-year-old female with diabetes' - Specific criteria: 'Trials requiring HbA1c > 8%' or 'BRCA positive trials' - Age-restricted searches: 'Pediatric cancer trials' or 'Trials for elderly patients' - Finding trials by inclusion/exclusion criteria USE search_trials FOR: - General disease/condition searches - When patient demographics don't matter ELIGIBILITY KEYWORDS TIPS: - Use medical abbreviations: 'ECOG', 'HbA1c', 'BMI', 'eGFR' - Search criteria text: 'prior chemotherapy', 'treatment naive' - Biomarkers: 'BRCA mutation', 'HER2 positive', 'PD-L1' - Lab values: 'creatinine', 'ALT', 'bilirubin' - ICD-10 codes indicate specific subtypes (E10.x=Type 1, E11.x=Type 2, etc.) - Disease subtypes matter: Type 1 vs Type 2 diabetes, HER2+ vs HER2- cancer, etc. EXAMPLES: - '65yo diabetic patient' -> condition='diabetes', min_age='18 Years', max_age='70 Years' - 'Breast cancer with BRCA' -> condition='breast cancer', eligibility_keywords='BRCA' - 'Recruiting trials for men with prostate cancer' -> condition='prostate cancer', sex='MALE'