What is the syntax for a JSON:API Accept
HTTP header with multiple extensions? I can't find it in the spec.
Here are some possibilities I could think of for a client that wants to use both the https://my-ext1
and https://my-ext2
extensions:
Accept: application/vnd.api+json; ext="https://my-ext1 https://my-ext2"
Accept: application/vnd.api+json; ext="https://my-ext1, https://my-ext2"
Accept: application/vnd.api+json; ext="https://my-ext1; https://my-ext2"
Accept: application/vnd.api+json; ext="https://my-ext1"; "https://my-ext2"
Accept: application/vnd.api+json; ext="https://my-ext1"; ext="https://my-ext2"
I've searched online for an answer, but haven't found anything useful. I'm implementing a JSON:API server, so I'd like to know the official syntax it needs to support.
Spaces are used as separator for the list:
The values of the ext and profile parameters MUST equal a space-separated (U+0020 SPACE, “ “) list of extension or profile URIs, respectively.
Source: JSON:API specification v1.1: 5.4 Rules for Media Type Parameters