Open
Description
Runtime expression examples include the following:
Source Location | example expression | notes |
---|---|---|
Requested media type | $request.header.accept |
|
Request parameter | $request.path.id |
Request parameters MUST be declared in the parameters section of the parent operation or they cannot be evaluated. This includes request headers. |
The 2nd example says that headers MUST be defined as parameters. But the 1st example refers to the Accept
header which is not allowed in parameters.
Is $request.header.accept
is an invalid example? Or are runtime expressions supposed to access any request headers?
Similarly, the section about callback path keys provides an example with the Content-Type
header:
$request.header.content-Type application/json
Like Accept
, Content-Type
is not allowed in parameters. Is this example valid or not?