Skip to main content

unique-case-insensitive-schema-component-key

Overview

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

A duplicate schema component key has been detected, indicating that there are multiple schemas with the same key defined in the components section. Since keys are compared in case-insensitive manner, it is important that each schema component in the API specification has a unique key.

PropertyValue
EnabledYes
Maximum SeverityError
MessageDuplicate schema component key found, ignoring case sensitivity.
CodeOPENAPI3CODEGEN_L130
TypeLinting
Rule SystemSemantic
Broad CategoryOpenAPI Components
Products ImpactedCode Generation, Developer Experience Portal
Tagscode generation sdks openapi3 openapi semantic linting apimatic components schemas key duplicate case insensitive

Suggested Fixes

  • Remove duplicate keys.
  • Assign a unique key to the conflicting schema.
  • Keys are compared in a case-insensitive manner to prevent issues in Code Generation.

For More Information