Skip to main content

valid-raml-syntax

Overview

This rule belongs to the raml-validation ruleset and states that:

RAML API definitions must be valid YAML 1.2-compliant documents.

PropertyValue
EnabledYes
Maximum SeverityBlocking
MessageProvided RAML API definition is invalid.
CodeRAML_V001
TypeValidation
Rule SystemSemantic
Broad CategoryBasic Structure
Products ImpactedAPI Transformer, Code Generation, Developer Experience Portal
Tagsraml semantic validation yaml syntax

Suggested Fixes

  • Ensure that the file uses valid YAML syntax.
  • Ensure that all properties in the RAML file are indented correctly.
  • Ensure that each element in the RAML file has the expected type.
  • Ensure that an array is not defined as an object or vice versa.
  • Ensure that where a number is expected, a string value is not provided, etc.
  • For objects, ensure that each property has a correct type assigned to it.

For More Information