Skip to content

Commit a56f66b

Browse files
authored
Merge pull request #536 from thekaveman/remove-options-negotiation
Removing OPTIONS version negotiation
2 parents 956e5e5 + 7932efe commit a56f66b

1 file changed

Lines changed: 1 addition & 17 deletions

File tree

general-information.md

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -219,23 +219,7 @@ Accept: application/vnd.mds+json;version=0.3
219219
> * The `agency` API must respond as if version `0.3` was requested.
220220
> * The `policy` API must respond as if version `0.4` was requested.
221221
222-
If an unsupported or invalid version is requested, the API must respond with a status of `406 Not Acceptable`. If this occurs, a client can explicitly negotiate available versions.
223-
224-
A client negotiates available versions using the `OPTIONS` method to an MDS endpoint. For example, to check if `trips` supports either version `0.2` or `0.3` with a preference for `0.2`, the client would issue the following request:
225-
226-
```http
227-
OPTIONS /trips/ HTTP/1.1
228-
Host: provider.example.com
229-
Accept: application/vnd.mds+json;version=0.2,application/vnd.mds+json;version=0.3;q=0.9
230-
```
231-
232-
The response will include the most preferred supported version in the `Content-Type` header. For example, if only `0.3` is supported:
233-
234-
```http
235-
Content-Type: application/vnd.mds+json;version=0.3
236-
```
237-
238-
The client can use the returned value verbatim as a version request in the `Accept` header.
222+
If an unsupported or invalid version is requested, the API must respond with a status of `406 Not Acceptable`.
239223

240224
[Top][toc]
241225

0 commit comments

Comments
 (0)