constant-parameter-cannot-be-optional
Overview
This rule belongs to the apimatic-preliminary-validation
ruleset and states that:
Constant parameters cannot be declared optional.
Property | Value |
---|---|
Enabled | Yes |
Maximum Severity | Error |
Message | Endpoint has an optional parameter which is also declared as a constant. |
Code | APIMATICPRE_V212 |
Type | Validation |
Rule System | Semantic |
Broad Category | Endpoint Parameters |
Products Impacted | Code Generation, Developer Experience Portal, API Transformer |
Tags | preliminary checks validation apimatic parameter constant endpoint |
Suggested Fixes
- Set the parameter as a required parameter.
- Make the parameter non-constant.