_count & _page

Paging search results

Search results can contain many records, for more convenient work we can use pagination. Available parameters are: _count β€” total records on the page, page β€” specific page, output Bundle includes link section with first, self, next, previous, and last page constructed URLs.

Default count value

Configure default value for count search parameter with

BOX_SEARCH_DEFAULT__PARAMS_COUNT=<number>

The default value is 100.

Be careful! Too high value of _count parameter can lead to the OutOfMemoryError due to the memory requirements to load many values.

Example

GET /Patient?_count=10&_page=3

# 200
resourceType: Bundle
type: searchset
entry:
- resource:
    ...
total: 206
link:
- {relation: first, url: '/Patient?_count=10&_page=1'}
- {relation: self, url: '/Patient?_count=10&_page=3'}
- {relation: next, url: '/Patient?_count=10&_page=4'}
- {relation: previous, url: '/Patient?_count=10&_page=2'}
- {relation: last, url: '/Patient?_count=10&_page=21'}

Last updated