University of York · API Governance Rules
University of York API Rules
Spectral linting rules defining API design standards and conventions for University of York.
7 Rules
error 3
warn 4
Rule Categories
oai
Rules
error
oai-info-title-present
API must declare a title.
$.info
error
oai-info-version-present
API must declare a version.
$.info
warn
oai-contact-email-present
Repository contact email should be published (OAI-PMH adminEmail convention).
$.info.contact
warn
oai-single-endpoint
OAI-PMH repositories expose a single base URL; only the /oai2 path is expected.
$.paths
error
oai-verb-parameter-required
Every operation must require the OAI-PMH 'verb' query parameter.
$.paths[*].get.parameters[?(@.name=='verb')]
warn
oai-verb-enum-complete
The verb parameter should enumerate the six OAI-PMH 2.0 verbs.
$.paths[*].get.parameters[?(@.name=='verb')].schema
warn
oai-xml-response-media-type
OAI-PMH responses are XML; the 200 response should declare application/xml.
$.paths[*].get.responses['200'].content