JSON response for resources without "Total"

47 views
Skip to first unread message

Sam

unread,
May 23, 2018, 10:22:33 PM5/23/18
to Cerner FHIR Developers

Hi Folks,

We would like to get some information on return response for a resource as follows..

For few responses where the medication orders are around 10-15, we are getting responseJSON.entry.resource.total (This holds the number of returned records)
So, the question is, if the responses are substantial or even above 20, we are not seeing "Total" in the response body.

Is there a way we can access total number of records in the response?


Kindly direct me to any group reference if this has been already answered.

Thank you,
Sam.

Auto Generated Inline Image 1
Auto Generated Inline Image 2

Bradley Strecker (Cerner)

unread,
May 24, 2018, 8:22:55 AM5/24/18
to Cerner FHIR Developers
Hi Sam,

The "total" field contains the total number of matching entries rather than just the number of entries in current the response bundle. [1]

When the matching entries all fit on a single response page we can determine and return the total value. When the results are spread across multiple pages that value is not available so cannot be not returned. 

Unfortunately, short of paging through the results and keeping track of the number of entries, there is no good way to query for or coerce the total to be returned.

Regards,
- bradley

Reply all
Reply to author
Forward
0 new messages