$npx -y skills add ma-compbio-lab/SkillFoundry --skill clinicaltrials-study-searchUse this skill to search the current ClinicalTrials.gov v2 API for condition or keyword matches when you need official clinical-study metadata. Do not use it for legacy API URLs or offline work.
| 1 | ## Purpose |
| 2 | Query the current ClinicalTrials.gov v2 API and save structured study metadata for a condition or free-text term. |
| 3 | |
| 4 | ## When to use |
| 5 | - You need official clinical study metadata. |
| 6 | - You want a lightweight search path for cohort or intervention discovery. |
| 7 | |
| 8 | ## When not to use |
| 9 | - You need patient-level data. |
| 10 | - You are working against deprecated ClinicalTrials.gov API examples. |
| 11 | |
| 12 | ## Inputs |
| 13 | - A condition query or a general term query |
| 14 | - Optional page size and output path |
| 15 | |
| 16 | ## Outputs |
| 17 | - JSON payload containing `studies` |
| 18 | |
| 19 | ## Requirements |
| 20 | - Python 3.13+ |
| 21 | - Network access to `clinicaltrials.gov` |
| 22 | |
| 23 | ## Procedure |
| 24 | 1. Run `python3 skills/clinical-biomedical-data-science/clinicaltrials-study-search/scripts/search_clinicaltrials.py --condition melanoma --page-size 3 --out skills/clinical-biomedical-data-science/clinicaltrials-study-search/assets/melanoma_studies.json`. |
| 25 | 2. Inspect the first `protocolSection.identificationModule` block. |
| 26 | 3. Use the result list for follow-up triage or cohort narrowing. |
| 27 | |
| 28 | ## Validation |
| 29 | - Command exits successfully. |
| 30 | - Output contains `studies`. |
| 31 | - A common query returns at least one study. |
| 32 | |
| 33 | ## Failure modes and fixes |
| 34 | - 404 or legacy errors: use `api/v2` endpoints only. |
| 35 | - No results: switch between `--condition` and `--term`. |
| 36 | |
| 37 | ## Safety and limits |
| 38 | - Public study metadata only. |
| 39 | - This skill does not provide patient-level or operational medical guidance. |
| 40 | |
| 41 | ## Examples |
| 42 | - `python3 .../search_clinicaltrials.py --term melanoma --page-size 2` |
| 43 | |
| 44 | ## Provenance |
| 45 | - ClinicalTrials.gov API overview: https://clinicaltrials.gov/data-api/about-api |
| 46 | |
| 47 | ## Related skills |
| 48 | - `ncbi-pubmed-search` |