representation
The data sent to describe a resource’s state in one particular format, such as a JSON document for a task.
In more detail
The task lives in a database; the JSON you receive is one rendering of it. The same resource can have several representations, differing in format, language or selected fields, while the resource itself is unchanged.
Related terms
- resource — Anything an API gives a name to and lets clients work with, such as one task, a collection of tasks or a job.
- content negotiation — The way a client and server agree on the format, language or compression of a response using request headers such as Accept.
- partial response — A response that contains only the fields the client asked for, such as ?fields=id,title, which is a smaller representation of the same resource.
Taught in
- What An API Is, And The Alternatives — Modern API Architecture: REST, GraphQL & gRPC
- The REST Constraints — Modern API Architecture: REST, GraphQL & gRPC
- Partial Responses — Modern API Architecture: REST, GraphQL & gRPC