valid-enum-field-types
Overview
This rule belongs to the apimatic-preliminary-validation
ruleset and states that:
All fields of an enumeration model must have the same type: "String" or "Number". Other types are currently not supported.
Property | Value |
---|---|
Enabled | Yes |
Maximum Severity | Error |
Message | Enumeration model contains one or more fields that are of a type other than "String" or "Number" which is not supported. |
Code | APIMATICPRE_V514 |
Type | Validation |
Rule System | Semantic |
Broad Category | Global Types/Models |
Products Impacted | Code Generation, Developer Experience Portal, API Transformer |
Tags | preliminary checks validation apimatic type enumeration field property custom type model complex model |
Suggested Fixes
- Make sure all fields of an enumeration model have the same type.
- Make sure that type of all fields is set and is non-empty, non-null.
- Remove all references to types other than "String" and "Number".