I’m developing a REST API service for a large social networking website I’m involved in. So far, it’s working great. I can issue GET, POST, P
I prefer using HTTP Headers for this kind of contextual information.
For the total number of elements, I use the X-total-count header.
For links to next, previous page, etc. I use HTTP Link header:
http://www.w3.org/wiki/LinkHeader
Github does it the same way: https://developer.github.com/v3/#pagination
In my opinion, it's cleaner since it can be used also when you return content that doesn't support hyperlinks (i.e binaries, pictures).