Skip to main content

schema-component-key-uses-pascal-case

Overview

This rule belongs to the openapi-v3-codegen-linting ruleset and states that:

To enhance the readability and maintain consistency, it is recommended that the keys defined in the components object's schemas are formatted using PascalCase. PascalCase is a naming convention in which each word in a phrase is capitalized, without spaces or underscores between them. This convention helps to make the keys stand out more clearly and allows for easier identification and understanding of the different components. By adhering to this convention, developers can also avoid potential errors and improve the overall quality of the code.

PropertyValue
EnabledNo
Maximum SeverityWarning
MessageSchema component key is not in PascalCase format.
CodeOPENAPI3CODEGEN_L132
TypeLinting
Rule SystemSemantic
Broad CategoryOpenAPI Components
Products ImpactedCode Generation, Developer Experience Portal
Tagscode generation sdks openapi3 openapi semantic linting apimatic components schemas key pascal case

Suggested Fixes

  • Ensure that schema is properly formatted with the first letter of each word capitalized.
  • Make sure that the schema does not contain any spaces or underscores.

For More Information