FHIR Chat · Page indexing · implementers

Stream: implementers

Topic: Page indexing


view this post on Zulip Hacène Khemici (Jul 25 2018 at 16:45):

In a search, is there such a thing as a page 0, or do the pages start at 1?
Would I say
GET /Observation?count=10&page=0
or
GET /Observation?count=10&page=1

Thank you!

view this post on Zulip Chris Moesel (Jul 25 2018 at 17:03):

FHIR doesn't actually prescribe exactly what paged links should look like. It only prescribes a mechanism by which a server provides the client links for the first, previous, next, and last pages. Whether those use a page parameter (and whether it is 0 or 1 indexed) is completely up to the server implementation. See: http://hl7.org/fhir/2018May/http.html#paging

view this post on Zulip Chris Moesel (Jul 25 2018 at 17:04):

That said, the example in the doc seems to use a 1-based page parameter (but again, that's technically an implementation detail, not part of the spec).

view this post on Zulip Lloyd McKenzie (Jul 25 2018 at 17:17):

The URL for the next page could easily just contain a GUID. There's no expectation it'll be parseable or generatable


Last updated: Apr 12 2022 at 19:14 UTC