allow-reserved-only-for-query-parameter
Overview
This rule belongs to the openapi-v3-standards-linting
ruleset and states that:
Property allowReserved
is only valid for query parameters (i.e. parameter location is set to query
) and helps determine whether the parameter value should allow reserved characters. This property cannot be used with any other types of parameters e.g. path, header, or cookie.
Property | Value |
---|---|
Enabled | Yes |
Maximum Severity | Warning |
Message | Property allowReserved is used for a non-query parameter. |
Code | OPENAPI3STANDARDS_L064 |
Type | Linting |
Rule System | Semantic |
Broad Category | Parameters |
Products Impacted | API Transformer, Code Generation, Developer Experience Portal |
Tags | openapi3 openapi standards semantic linting reserved characters query parameter |
Suggested Fixes
- Remove property
allowReserved
from the current Parameter Object. - Change the parameter location to
query
if you want to allow sending it with reserved characters.