3. Designing Representations
This chapter describes how to design representations, how to use HTTP headers on requests and responses, choice of media types and formats, and error handling.
- How to Use Entity Headers to Annotate Representations
- How to Interpret Entity Headers
- How to Avoid Character Encoding Mismatch
- How to Choose a Representation Format and Media Type
- How to Design XML Representations
- How to Design JSON Representations
- How to Design Representations of Collections
- How to Keep Collections Homogeneous
- How to Use Portable Data Formats in Representations
- When to Use Entity Identifiers
- How to Encode Binary Data in Representations
- When and How to Serve HTML Representations
- How to Return Errors
- How to Treat Errors in Clients

{ 2 comments… read them below or add one }
I wanted to see a recipe on representing content with relations. The recipe should be covering the use-cases one-to-one, one-to-many and many-to-many. I see most of the time people interact with relational databases and would love to see their entities over http and in a REST way.
-Ramesh
Ramesh,
Chapter 5 deals with how to communicate relations between resources using links. Note that relations in database tables may or may not translate into resource relations. It all depends on your resource model.
Subbu