Scalable Inference Serving · API Governance Rules
Scalable Inference Serving API Rules
Spectral linting rules defining API design standards and conventions for Scalable Inference Serving.
17 Rules
error 5
warn 9
info 3
Rule Categories
oip
Rules
error
oip-v2-prefix
All Open Inference Protocol paths must start with /v2/
$.paths[*]~
warn
oip-health-paths-standard
Health endpoints must use /v2/health/{live|ready} naming convention
$.paths[?(@property.match(/health/))]~
warn
oip-model-path-convention
Model paths must use /v2/models/{model_name} naming convention
$.paths[?(@property.match(/models/))]~
error
oip-inference-post-only
Inference endpoints must use HTTP POST
$.paths[?(@property.match(/\/infer$/))]
warn
oip-operation-ids-pascal-case
Operation IDs should use PascalCase (e.g., RunInference, GetModelMetadata)
$.paths[*][*].operationId
warn
oip-inference-response-has-model-name
Inference 200 responses must include model_name in the response schema
$.paths[?(@property.match(/infer/))].post.responses['200'].content['application/json'].schema
error
oip-error-response-has-error-field
Error responses must include an 'error' field in the response schema
$.components.schemas.ErrorResponse.properties
warn
oip-tensor-datatype-enum
TensorDatatype must enumerate all OIP-defined data types
$.components.schemas.TensorDatatype
error
oip-inference-request-has-inputs
Inference request bodies must define an 'inputs' required field
$.components.schemas.InferenceRequest.required
error
oip-tensor-input-required-fields
RequestInput must require name, shape, datatype, and data
$.components.schemas.RequestInput.required
warn
oip-operations-tagged
All operations must have at least one tag
$.paths[*][get,post,put,patch,delete]
info
oip-tags-title-case
All tags in the info and operation tags must use Title Case
$.paths[*][*].tags[*]
warn
oip-operations-have-summaries
All operations must have a summary for Swagger UI display
$.paths[*][get,post,put,patch,delete]
warn
oip-summaries-title-case
Operation summaries must use Title Case
$.paths[*][*].summary
info
oip-schemas-have-descriptions
All component schemas should have a description
$.components.schemas[*]
info
oip-properties-have-descriptions
Schema properties should have descriptions
$.components.schemas[*].properties[*]
warn
oip-servers-defined
At least one server must be defined
$