non-empty-schema-properties-key
Overview
This rule belongs to the openapi-v3-apimatic-linting
ruleset and states that:
In OpenAPI specifications, a schema's property keys should be non-empty strings. Empty property keys can cause issues when working with schemas and can lead to errors when the specification is used to generate code or documentation.
Property | Value |
---|---|
Enabled | Yes |
Maximum Severity | Error |
Message | Schema properties keys should not be empty. |
Code | OPENAPI3APIMATIC_L685 |
Type | Linting |
Rule System | Semantic |
Broad Category | OpenAPI Schemas |
Products Impacted | API Transformer, Code Generation, Developer Experience Portal |
Tags | openapi3 openapi apimatic semantic linting empty property key schema |
Suggested Fixes
- Check the OpenAPI specification to confirm if any property key is empty for the schema.
- If any property key is empty, remove the empty key from the schema definition.
- Ensure that all property keys are non-empty strings.