### GET /search (Location) Source: https://clinicaltrials.gov/data-api/about-api/search-areas Search for clinical trials based on location terms. ```APIDOC ## GET /search?query.locn=[value] ### Description Default search area for the 'Location terms' input field. ### Query Parameters - **query.locn** (text) - Required - The location search query. ### Data Fields - **LocationCity** (GeoName) - Weight: 0.95 - **LocationState** (GeoName) - Weight: 0.95 - **LocationCountry** (text) - Weight: 0.95 - **LocationFacility** (text) - Weight: 0.95 - **LocationZip** (text) - Weight: 0.35 ``` -------------------------------- ### GET /api/info/api_vrs Source: https://clinicaltrials.gov/data-api/about-api/api-migration Returns the current version number of the ClinicalTrials.gov API. ```APIDOC ## GET /api/info/api_vrs ### Description Returns the current version number of the ClinicalTrials.gov API. The version changes when the study structure or API features change. ### Method GET ### Endpoint /api/info/api_vrs ``` -------------------------------- ### GET /search (Sponsor) Source: https://clinicaltrials.gov/data-api/about-api/search-areas Search for clinical trials based on sponsor or collaborator information. ```APIDOC ## GET /search?query.spons=[value] ### Description Default search area for the 'Sponsor / collaborator' input field. ### Query Parameters - **query.spons** (text) - Required - The sponsor search query. ### Data Fields - **LeadSponsorName** (text) - Weight: 1 - **CollaboratorName** (text) - Weight: 0.9 - **OrgFullName** (text) - Weight: 0.6 ``` -------------------------------- ### GET /search (Intervention) Source: https://clinicaltrials.gov/data-api/about-api/search-areas Search for clinical trials based on intervention or treatment criteria. ```APIDOC ## GET /search?query.intr=[value] ### Description Default search area for the 'Intervention / treatment' input field. ### Query Parameters - **query.intr** (text) - Required - The intervention search query. ### Data Fields - **InterventionName** (text) - Weight: 0.95 - **InterventionType** (enum) - Weight: 0.85 - **ArmGroupType** (enum) - Weight: 0.85 - **InterventionOtherName** (text) - Weight: 0.75 - **BriefTitle** (text) - Weight: 0.65 - **OfficialTitle** (text) - Weight: 0.6 - **ArmGroupLabel** (text) - Weight: 0.5 - **InterventionMeshTerm** (text) - Weight: 0.5 - **Keyword** (text) - Weight: 0.5 - **InterventionAncestorTerm** (text) - Weight: 0.4 - **InterventionDescription** (markup) - Weight: 0.4 - **ArmGroupDescription** (markup) - Weight: 0.4 ``` -------------------------------- ### Download Matching Studies Source: https://clinicaltrials.gov/data-api/about-api/api-migration Download a Zip archive containing studies that match specified search criteria, in XML format. The new endpoint `/api/v2/studies` allows for more structured searching. Legacy endpoint support requires constructing a search expression. ```APIDOC ## GET /api/v2/studies ### Description Retrieves a list of studies matching the specified search criteria. The results are returned in JSON format. Search options can be provided as query parameters. ### Method GET ### Endpoint /api/v2/studies ### Parameters #### Query Parameters - **fields** (string) - Optional - Comma-separated list of data elements to include. - **sort** (string) - Optional - Field to sort the results by. - **order** (string) - Optional - Order of sorting ('asc' or 'desc'). - **maxResults** (integer) - Optional - Maximum number of results to return. - **fromRecord** (integer) - Optional - Starting record number for pagination. - **query** (string) - Optional - A structured query string for advanced searching. ### Request Example ```json { "example": "GET /api/v2/studies?query=AREA[ConditionSearch]cancer AND AREA[BasicSearch]treatment&fields=NCTId,Title" } ``` ### Response #### Success Response (200) - **studies** (array) - An array of study objects matching the search criteria. #### Response Example ```json { "example": "{\"studies\": [ { \"NCTId\": \"NCT000001\", \"Title\": \"Example Study Title\" } ]}" } ``` ### Legacy Endpoint Support `GET /ct2/download_studies` ``` -------------------------------- ### Download All API XML Data Source: https://clinicaltrials.gov/data-api/about-api/api-migration Download a Zip archive containing all full study data in XML format. The new endpoint provides this data in JSON format. Legacy endpoint support for XML format is also available. ```APIDOC ## GET /api/v2/studies/download?format=json.zip ### Description Downloads a Zip archive containing all full study data in JSON format. The schema for individual JSON files matches the `/api/v2/studies/{nctId}` endpoint response. ### Method GET ### Endpoint /api/v2/studies/download ### Parameters #### Query Parameters - **format** (string) - Required - Specifies the output format, should be 'json.zip'. ### Request Example ```json { "example": "GET /api/v2/studies/download?format=json.zip" } ``` ### Response #### Success Response (200) - **file** (zip) - A zip archive containing full study data in JSON format. ### Legacy Endpoint Support `GET /AllAPIXML.zip` ``` -------------------------------- ### GET /api/info/data_vrs Source: https://clinicaltrials.gov/data-api/about-api/api-migration Retrieves the date when the ClinicalTrials.gov dataset was last posted. ```APIDOC ## GET /api/info/data_vrs ### Description Returns the date when the ClinicalTrials.gov dataset was posted. ### Method GET ### Endpoint /api/info/data_vrs ### Response #### Success Response (200) - **dataTimestamp** (string) - The date and time the dataset was posted. ``` -------------------------------- ### Download All Public Data Source: https://clinicaltrials.gov/data-api/about-api/api-migration Download a Zip archive containing all public study data in JSON format. The JSON schema for each file is consistent with the response of the `/api/v2/studies/{nctId}` endpoint. Legacy endpoint support for XML format is also available. ```APIDOC ## GET /api/v2/studies/download?format=json.zip ### Description Downloads a Zip archive containing all public study data in JSON format. The schema for individual JSON files matches the `/api/v2/studies/{nctId}` endpoint response. ### Method GET ### Endpoint /api/v2/studies/download ### Parameters #### Query Parameters - **format** (string) - Required - Specifies the output format, should be 'json.zip'. ### Request Example ```json { "example": "GET /api/v2/studies/download?format=json.zip" } ``` ### Response #### Success Response (200) - **file** (zip) - A zip archive containing study data in JSON format. ### Legacy Endpoint Support `GET /AllPublicXML.zip` ``` -------------------------------- ### GET /search (Outcome) Source: https://clinicaltrials.gov/data-api/about-api/search-areas Search for clinical trials based on outcome measures. ```APIDOC ## GET /search?query.outc=[value] ### Description Default search area for the 'Outcome measure' input field. ### Query Parameters - **query.outc** (text) - Required - The outcome measure search query. ### Data Fields - **PrimaryOutcomeMeasure** (text) - Weight: 0.9 - **SecondaryOutcomeMeasure** (text) - Weight: 0.8 - **PrimaryOutcomeDescription** (markup) - Weight: 0.6 - **SecondaryOutcomeDescription** (markup) - Weight: 0.5 - **OtherOutcomeMeasure** (text) - Weight: 0.4 - **OutcomeMeasureTitle** (text) - Weight: 0.4 - **OtherOutcomeDescription** (markup) - Weight: 0.3 - **OutcomeMeasureDescription** (markup) - Weight: 0.3 - **OutcomeMeasurePopulationDescription** (markup) - Weight: 0.3 ``` -------------------------------- ### GET /api/query/study_fields Source: https://clinicaltrials.gov/data-api/about-api/api-migration Retrieves specific fields for a large set of study records. ```APIDOC ## GET /api/query/study_fields ### Description Returns values from selected API fields for a large set of study records. ### Method GET ### Endpoint /api/query/study_fields ### Parameters #### Query Parameters - **fields** (string) - Required - The specific fields to return for the study records. - **expr** (string) - Optional - The search expression used to filter studies. ### Response #### Success Response (200) - **format** (CSV/JSON) - The requested fields for the study records. ``` -------------------------------- ### Intervention Browse Module Fields Source: https://clinicaltrials.gov/data-api/about-api/study-data-structure Details regarding the intervention browse module, including ancestors, leaf topics, and branch topics. ```APIDOC ## Intervention Browse Module Fields ### Description Provides access to MeSH hierarchy data for interventions, including ancestor terms, leaf topics, and branch topics. ### Fields - **InterventionAncestor** (Mesh[]) - Ancestor terms of Intervention MeSH terms. - **InterventionAncestorId** (text) - MeSH ID for the ancestor. - **InterventionAncestorTerm** (text) - MeSH Heading for the ancestor. - **NumInterventionAncestors** (short) - Count of intervention ancestor terms. - **InterventionBrowseLeaf** (BrowseLeaf[]) - Leaf browsing topics for the intervention. - **InterventionBrowseLeafId** (text) - ID for the leaf topic. - **InterventionBrowseLeafName** (text) - Name of the leaf topic. - **InterventionBrowseLeafAsFound** (text) - Normalized term used to find the topic. - **InterventionBrowseLeafRelevance** (enum) - Relevance level of the leaf topic. - **NumInterventionBrowseLeafs** (short) - Count of intervention leaf topics. - **InterventionBrowseBranch** (BrowseBranch[]) - Branch browsing topics for the intervention. - **InterventionBrowseBranchAbbrev** (text) - Short name of the branch topic. - **InterventionBrowseBranchName** (text) - Name of the branch topic. - **NumInterventionBrowseBranches** (short) - Count of intervention branch topics. ``` -------------------------------- ### References Module Source: https://clinicaltrials.gov/data-api/about-api/study-data-structure Details regarding references and citations related to a study protocol. ```APIDOC ## ReferencesModule ### Index Field protocolSection.referencesModule ### Data Type ReferencesModule ### Definition References(https://clinicaltrials.gov/policy/protocol-definitions#References) ## Reference - Citations to publications related to the protocol ### Index Field protocolSection.referencesModule.references ### Data Type Reference[] ### Definition Citations(https://clinicaltrials.gov/policy/protocol-definitions#RefCitations) ## ReferencePMID - PubMed Identifier ### Index Field protocolSection.referencesModule.references.pmid ### Data Type text (stats(https://clinicaltrials.gov/api/v2/stats/field/values?fields=ReferencePMID)) ### Definition PubMed Identifier(https://clinicaltrials.gov/policy/protocol-definitions#PubMedId) ## ReferenceType - Reference Type ### Index Field protocolSection.referencesModule.references.type ### Data Type enum ReferenceType(https://clinicaltrials.gov#enum-ReferenceType) (stats(https://clinicaltrials.gov/api/v2/stats/field/values?fields=ReferenceType)) ### Definition Results Reference(https://clinicaltrials.gov/policy/protocol-definitions#IsResultsRef) ## ReferenceCitation - Reference Citation ### Index Field protocolSection.referencesModule.references.citation ### Data Type text ✓ (stats(https://clinicaltrials.gov/api/v2/stats/field/values?fields=ReferenceCitation)) ### Definition Citation(https://clinicaltrials.gov/policy/protocol-definitions#Citation) ## Retraction ### Index Field protocolSection.referencesModule.references.retractions ### Data Type Retraction[] ## RetractionPMID - PMID for Publication Retraction ### Index Field protocolSection.referencesModule.references.retractions.pmid ### Data Type text (stats(https://clinicaltrials.gov/api/v2/stats/field/values?fields=RetractionPMID)) ### Description PMID for publication retraction ## RetractionSource ### Index Field protocolSection.referencesModule.references.retractions.source ### Data Type text ✓ (stats(https://clinicaltrials.gov/api/v2/stats/field/values?fields=RetractionSource)) ``` -------------------------------- ### GET /api/query/field_values Source: https://clinicaltrials.gov/data-api/about-api/api-migration Retrieves all values found in a single API field for all study records. ```APIDOC ## GET /api/query/field_values ### Description Returns all values found in a single API field for all study records. ### Method GET ### Endpoint /api/query/field_values ### Response #### Success Response (200) - **data** (array) - A list of all values found in the specified field. ```