Schematic · API Governance Rules
Schematic API Rules
Spectral linting rules defining API design standards and conventions for Schematic.
11 Rules
error 1
warn 8
info 2
Rule Categories
schematic
Rules
warn
schematic-operation-ids-camel-case
Operation IDs should use camelCase naming consistent with Schematic API conventions.
$.paths[*][get,post,put,patch,delete].operationId
warn
schematic-summary-title-case
Operation summaries should use Title Case for consistency.
$.paths[*][get,post,put,patch,delete].summary
warn
schematic-list-operations-return-arrays
Operations with 'list' in the operationId should return an array or paginated response object.
$.paths[*].get
info
schematic-count-endpoints-exist
Schematic APIs expose count endpoints alongside list endpoints. Count endpoints should follow the /count suffix pattern.
$.paths
warn
schematic-response-data-wrapper
Schematic API responses wrap data in a 'data' field with a ResponseData schema. Response schemas should follow the *ResponseData naming convention.
$.components.schemas
error
schematic-api-key-auth-header
Schematic API uses X-Schematic-Api-Key header for authentication. All operations should be secured with ApiKeyAuth.
$.components.securitySchemes.ApiKeyAuth
warn
schematic-error-response-schema
All error responses (4xx, 5xx) should reference the ApiError schema.
$.paths[*][*].responses[4xx,5xx]
warn
schematic-upsert-operations-use-post
Schematic upsert operations use POST method. Operations named 'upsert*' should use POST.
$.paths[*].post.operationId
warn
schematic-delete-operations-by-id
Delete operations should target resources by ID path parameter.
$.paths[*].delete
info
schematic-bulk-check-operations
Flag check operations support both single-key (/flags/{key}/check) and bulk (/flags/check-bulk) patterns.
$.paths['/flags/check-bulk']
warn
schematic-pagination-params
List operations should support pagination via limit and offset parameters.
$.paths[*].get.parameters[*].name