W3C home > Mailing lists > Public > public-linked-json@w3.org > May 2017

Re: Pagination best practices

From: Daniel Smedegaard Buus <danielbuus@gmail.com>
Date: Mon, 22 May 2017 12:28:54 +0200
Message-ID: <CAHnuAew3yOhVcSmHy1SoGn2+Tim0d5uHAdx3k0OfkmEV=8N1PQ@mail.gmail.com>
To: Adrian Pohl <pohl@hbz-nrw.de>
Cc: public-linked-json@w3.org
A follow-up question:

What do you guys do with nested resources that page? For instance, in
my api you may request a related resource to be denormalized, e.g. you
could GET /users?expand=posts, and instead of User.post being an IRI
to /users/:id/posts, it'll resolve that IRI, providing each user's
posts as nested graphs inside the user records. But, this is limited
to a default page size, in which case I'd like to provide pagination
links as well.

Do you guys do something like this as well?

Cheers :)

On 22 May 2017 at 12:07, Daniel Smedegaard Buus <danielbuus@gmail.com> wrote:
> Thank you everyone :)
>
> I'm gonna read through those w3c documents to get a better
> understanding. Adrian, I was looking at hydra for this, but was
> reluctant to use it as it seems to bring in quite a bit of "baggage."
> But I think I might actually end up with something based on it, as it
> seems to be the de facto "api thing" to use on top of JSON-LD
>
> Has either of you done pagination yourself? It'd be really cool to see
> examples of homegrown syntax :)
>
> Cheers!
> Daniel
Received on Monday, 22 May 2017 10:30:07 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:18:49 UTC