Workleap · API Governance Rules
Workleap — wl api guidelines rules
Spectral linting rules defining API design standards and conventions for Workleap.
19 Rules
error 2
warn 17
Published by Workleap
Served by the provider at https://github.com/workleap/wl-api-guidelines/blob/764bd20880f60765a48197b7ee0afca9bc0bd2bd/.workleap.rules.yaml; the copy below was fetched from there.
Rule Categories
items
must
path
schema
schemas
Rules
error
schema-ids-must-have-alphanumeric-characters-only
All schema ids must only contain alphanumeric characters. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schema-ids-must-have-alphanumeric-characters-only
$.components.schemas
warn
schemas-properties-must-have-a-type
All schemas properties must have a type or schema reference. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schemas-properties-must-have-a-type-and-path-schema-properties-must-have-a-type
$..schemas.*.properties.*
warn
schemas-properties-must-have-a-type-backend
All schemas properties must have a type or schema reference. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schemas-properties-must-have-a-type-and-path-schema-properties-must-have-a-type
$..schemas.*.properties.*
warn
schemas-properties-must-have-a-type-frontend
All schemas properties must have a type, schema reference, or composition keyword (allOf/anyOf/oneOf). Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schemas-properties-must-have-a-type-and-path-schema-properties-must-have-a-type
$..schemas.*.properties.*
warn
path-schema-properties-must-have-a-type
All path schema properties must have a type or schema reference. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schemas-properties-must-have-a-type-and-path-schema-properties-must-have-a-type
$..schema.properties.*
warn
path-schema-properties-must-have-a-type-backend
All path schema properties must have a type or schema reference. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schemas-properties-must-have-a-type-and-path-schema-properties-must-have-a-type
$..schema.properties.*
warn
path-schema-properties-must-have-a-type-frontend
All path schema properties must have a type, schema reference, or composition keyword (allOf/anyOf/oneOf). Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schemas-properties-must-have-a-type-and-path-schema-properties-must-have-a-type
$..schema.properties.*
warn
schema-object-must-have-a-type
All schema objects must have a type or schema reference. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schema-object-must-have-a-type
$.components.schemas.*
warn
schema-object-must-have-a-type-backend
All schema objects must have a type or schema reference. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schema-object-must-have-a-type
$.components.schemas.*
warn
schema-object-must-have-a-type-frontend
All schema objects must have a type, schema reference, or composition keyword (allOf/anyOf/oneOf). Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schema-object-must-have-a-type
$.components.schemas.*
warn
items-must-have-a-type
All items must have a type or schema reference. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#items-must-have-a-type
$.components.schemas..items
warn
items-must-have-a-type-backend
All items must have a type or schema reference. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#items-must-have-a-type
$.components.schemas..items
warn
items-must-have-a-type-frontend
All items must have a type, schema reference, or composition keyword (allOf/anyOf/oneOf). Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#items-must-have-a-type
$.components.schemas..items
warn
schema-name-length-must-be-short
Schema name must not be too long to support client generation. Current limitation comes from Ruby packages which uses tar and has a limit of 100 characters. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#schema-name-length-must-be-short
$.components.schemas[*]~
warn
must-not-use-base-server-url
Must not use base server url in spec to be able to generate a single client compatible with multiple environments. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#must-not-use-base-server-url
$.servers[*].url
warn
must-accept-content-types
All endpoint bodies MUST accept the header with (one of) Content-Type: application/json, multipart/form-data, application/octet-stream. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#must-accept-content-types
$.paths[*].*.requestBody.content
warn
must-return-content-types
Endpoint bodies for 200 responses MUST return the header with (one of) Content-Type: application/json, image/png, application/octet-stream. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#must-return-content-types
$.paths[*].*.responses['200'].content
warn
must-support-client-credentials-oauth2
Contract must support client credentials with oauth2. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#must-support-client-credentials-oauth2
$.components.securitySchemes.*
error
must-use-get-post-methods
BFF API endpoints must only use GET or POST methods. Refer to: https://gsoftdev.atlassian.net/wiki/spaces/TEC/pages/3858235678/IDP+OpenAPI+Rulesets#must-use-get-post-methods
$.paths[*]
Spectral Ruleset
Work with this as data
Every ruleset here is available over the APIs.io API and to AI agents over MCP.