More example corrections
MODIFY
versions/3.0.md
versions/3.0.md
@@ -1915,9 +1915,10 @@ paths:
- name: id
in: path
required: true
- description: the user identifier, as userId or username
+ description: the user identifier, as userId
schema:
type: string
+ get:
responses:
'200':
description: the user being returned
@@ -1930,12 +1931,27 @@ paths:
type: string
format: uuid
links:
- Address:
+ address:
# the target link operationId
operationId: getUserAddress
parameters:
# get the `id` field from the request path parameter named `id`
userId: $request.path.id
+ # the path item of the linked operation
+ /users/{userid}/address:
+ parameters:
+ - name: userid
+ in: path
+ required: true
+ description: the user identifier, as userId
+ schema:
+ type: string
+ # linked operation
+ get:
+ operationId: getUserAddress
+ responses:
+ '200':
+ description: the user's address
```
When a runtime expression evaluates to null, no parameter value is passed to the target operation.
@@ -1944,7 +1960,7 @@ Values from the response body can be used to drive a linked operation.
```yaml
links:
- addressesLink:
+ address:
operationId: getUserAddressByUUID
parameters:
# get the `id` field from the request path parameter named `id`

More example corrections