You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: versions/3.0.md
+2-42Lines changed: 2 additions & 42 deletions
Original file line number
Diff line number
Diff line change
@@ -51,7 +51,6 @@ Additional utilities can also take advantage of the resulting files, such as tes
51
51
- [Callback Object](#callbackObject)
52
52
- [Example Object](#exampleObject)
53
53
- [Link Object](#linkObject)
54
-
- [Link Parameters Object](#linkParametersObject)
55
54
- [Header Object](#headerObject)
56
55
- [Tag Object](#tagObject)
57
56
- [Reference Object](#referenceObject)
@@ -1917,15 +1916,15 @@ The presence of a link does not guarantee the caller's ability to successfully i
1917
1916
1918
1917
As opposed to _dynamic_ links (links provided **in** the response payload), the OAS linking mechanism does not require that link information be provided in a specific response format at runtime.
1919
1918
1920
-
For computing links, and providing instructions to execute them, [variable substitution](#variableSubstitution) is used for accessing values in a response and using them as values while invoking the linked operation.
1919
+
Many operations require parameters to be passed, and these MAY be dynamic depending on the response itself. For computing links, and providing instructions to execute them, [variable substitution](#variableSubstitution) is used for accessing values in a response and using them as values while invoking the linked operation.
1921
1920
1922
1921
##### Fixed Fields
1923
1922
1924
1923
Field Name | Type | Description
1925
1924
---|:---:|---
1926
1925
<a name="linkOperationRef"></a>operationRef | `string` | a relative or absolute reference to an OAS operation. This field is mutually exclusive with the `operationId` field, and must point to the fragment of a valid OAS definition.
1927
1926
<a name="linkOperationId"></a>operationId | `string` | the name of an _existing_, resolvable OAS operation, as defined with a unique `operationId`. This field is mutually exclusive with the `operationRef` field. Relative `operationRef` values MAY be used to locate an existing [Operation Object](#operationObject) in the OAS.
1928
-
<a name="linkParameters"></a>parameters | [Link Parameters Object](#linkParametersObject) | an object representing parameters to pass to an operation as specified with `operationId` or identified via `operationRef`.
1927
+
<a name="linkParameters"></a>parameters | Map[`string` | Any \| [{expression}](#variableSubstitution) | A map representing parameters to pass to the operation as specified with `operationId` or identified via `operationRef`. The key is the parameter name to be used, whereas the value can be a constant or an expression to be evaluated and passed to the linked operation.
1929
1928
<a name="linkHeaders"></a>headers | Map[`string`, [Header Object](#headerObject) \| [Reference Object](#referenceObject)] | Maps a header name to its definition. Note that [RFC7230](https://tools.ietf.org/html/rfc7230#page-22) states header names are case insensitive. This represents the headers to pass to the linked resource. Where conflicts occur between these headers, and those defined in the related operation, these headers override.
1930
1929
<a name="linkDescription"></a>description | `string` | a description of the link, supports [CommonMark syntax](http://spec.commonmark.org/).
1931
1930
<a name="linkServer"></a>server | [Server Object](#serverObject) | a server object to be used by the target operation.
@@ -2317,45 +2316,6 @@ components:
2317
2316
Note that in the use of `operationRef`, the _escaped forward-slash_ is necessary when
Using the `operationId` to reference an operation in the definition has many benefits, including the ability to define media type options, security requirements, response and error payloads.
2322
-
Many operations require parameters to be passed, and these MAY be dynamic depending on the response itself.
2323
-
2324
-
To specify parameters required by the operation, we can use a **Link Parameters Object**.
2325
-
This object contains parameter names along with static or dynamic values:
2326
-
2327
-
##### Patterned Fields
2328
-
Field Pattern | Type | Description
2329
-
---|:---:|---
2330
-
<a name="linkParameterName"></a> {name} | Any \| [{expression}](#variableSubstitution) | A constant value or expression to be evaluated and passed to the linked operation.
2331
-
2332
-
```yaml
2333
-
paths:
2334
-
/user/{username}: # ...
2335
-
/user/{username}/commits:
2336
-
get:
2337
-
operationId: userCommitHistory
2338
-
parameters:
2339
-
- name: username
2340
-
in: path
2341
-
type: string
2342
-
required: true
2343
-
- name: page
2344
-
type: integer
2345
-
format: int32
2346
-
required: true
2347
-
responses: { ... }
2348
-
components:
2349
-
links:
2350
-
UserCommitHistory:
2351
-
operationId: userCommitHistory
2352
-
parameters:
2353
-
username: $response.body#/user/username
2354
-
page: 0
2355
-
```
2356
-
2357
-
In the above, the link for `UserCommitHistory` points to the operation `getUserCommitHistory`, and passes the `username` value from the response payload as well as the static scalar value `0`.
2358
-
2359
2319
#### <a name="headerObject"></a>Header Object
2360
2320
2361
2321
The Header Object follows the structure of the [Parameter Object](#parameterObject), with the following changes:
0 commit comments