How to retrieve partially a resource
Optimize bandwidth usage and improve responsiveness
GET /resources/123?fields=(name,partner(name)) |
Single-entity GET endpoints
Partial responses (e.g. with field query param) should not be returned. |
Partial Response
Sometimes an API client only needs a specific subset of data in the response message. |
Resource View
To reduce network traffic, it is sometimes useful to allow the client to limit which parts of the resource the server should return in its responses, returning a view of the resource instead of the full resource representation. |
Standard request headers
Prefer return=minimal, return=representation |
Standard response headers
Preference-Applied |
Use Conventional Query Strings
fields — to retrieve a subset of fields |
Define useful resources |
Support Filtering of Resource Fields |