ClinicalTrials.gov · API Governance Rules
ClinicalTrials.gov API Rules
Spectral linting rules defining API design standards and conventions for ClinicalTrials.gov.
9 Rules
error 3
warn 5
info 1
Rule Categories
ctg
Rules
error
ctg-info-contact
API contact information must be present.
$.info
warn
ctg-info-license
API license must be declared.
$.info
error
ctg-server-https
All server URLs must use HTTPS.
$.servers[*].url
warn
ctg-server-versioned
Data API server URL must include /api/v2.
$.servers[?(@.url && @.url.indexOf('clinicaltrials.gov') > -1)].url
warn
ctg-operation-tags
Every operation must declare at least one tag.
$.paths[*][get,post,put,patch,delete]
warn
ctg-operation-summary
Every operation must include a short summary.
$.paths[*][get,post,put,patch,delete]
error
ctg-operation-id
Every operation must declare a unique operationId.
$.paths[*][get,post,put,patch,delete]
info
ctg-pagination-page-size
List endpoints should support pageSize and pageToken parameters.
$.paths[?(@property == '/studies')].get.parameters[*].name
warn
ctg-nct-id-pattern
nctId path parameters should match the NCT identifier pattern.
$.paths[?(@property.match(/{nctId}/))]