Skip to main content

required-operation-responses

Overview

This rule belongs to the openapi-v3-standards-validation ruleset and states that:

The Operation Object in an OpenAPI v3.0.x document must specify list of possible responses that can be returned from executing this operation, using the responses property.

PropertyValue
EnabledYes
Maximum SeverityError
MessageRequired property responses in Operation Object is missing.
CodeOPENAPI3STANDARDS_V050
TypeValidation
Rule SystemSemantic
Broad CategoryOperations
Products ImpactedAPI Transformer, Code Generation, Developer Experience Portal
Tagsopenapi3 openapi standards semantic validation responses operation

Suggested Fixes

  • Add missing responses property in the Operation object.
  • Make sure that the responses property is a valid object and not set as null.

For More Information