Skip to main content

example-mime-type-exists-in-operation-produces

Overview

This rule belongs to the swagger-v2-standards-validation ruleset and states that:

The mime type specified in the Example Object must be one of the Operation Object produces property values (either implicit or inherited).

PropertyValue
EnabledYes
Maximum SeverityError
MessageMime type does not exist in operation produces property.
CodeSWAGGER20STANDARDS_V201
TypeValidation
Rule SystemSemantic
Broad CategoryResponse Examples
Products ImpactedAPI Transformer, Code Generation, Developer Experience Portal
Tagsswagger2 swagger standards semantic validation mime type operation examples example produces

Suggested Fixes

  • Make sure that the mime type matches exactly with one of those specified in the produces property of Operation Object.
  • Mime type value is compared in a case-sensitive manner.

For More Information