Provide a pattern for listing resources while querying a resource collection.
{
"@context": "http://www.w3.org/ns/hydra/context.jsonld",
"id": "http://api.example.com/an-issue/comments",
"type": "Collection",
"totalItems": 4980,
"item": [
... a subset of the members of the Collection ...
],
"view": {
"id": "http://api.example.com/an-issue/comments?page=3",
"type": "PartialCollectionView",
"first": "/an-issue/comments?page=1",
"previous": "/an-issue/comments?page=2",
"next": "/an-issue/comments?page=4",
"last": "/an-issue/comments?page=498"
}
}
Use Case
Provide a pattern for listing resources while querying a resource collection.
Proposal
Use Hydra Collections, except instead of using the "
member" property for the list of resources, use "item", as the term "member" has a specific meaning within the sport and physical activity sector, anditemis consistent with the existingtotalItemsproperty.Example
See also