Skip to main content

valid-component-name

Overview

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

Component name must contain only alphanumeric, dash (-), underscore (_) and period (.) characters. Spaces are not allowed.

PropertyValue
EnabledYes
Maximum SeverityError
MessageComponent name is invalid.
CodeOPENAPI3SYNTAX_V020
TypeValidation
Rule SystemSyntax
Broad CategoryComponents
Products ImpactedAPI Transformer, Code Generation, Developer Experience Portal
Tagsopenapi3 openapi syntax validation name components

Suggested Fixes

  • Ensure that the component name follows the regex pattern ^[a-zA-Z0-9.-_]+$
  • Remove any invalid characters from the component name.
  • Remove any spaces from the name.

For More Information