Patient JSON - ?mapping error

Hi,

Just comparing the HL7 spec to the output from Graham Grieve’s reference implementation server this evening.

The JSON spec for HumanName says:

{
“resourceType” : “HumanName”,
// from Element: extension
“use” : “”, // usual | official | temp | nickname | anonymous | old | maiden
“text” : “”, // Text representation of the full name
“family” : “”, // Family name (often called ‘Surname’)
“given” : [""], // Given names (not always ‘first’). Includes middle names
“prefix” : [""], // Parts that come before the name
“suffix” : [""], // Parts that come after the name
“period” : { Period } // Time period when name was/is in use
}

Whereas test output from Graham’s server says:

“name” : [{“use” : “official”,“family” : [“Donald”],“given” : [“Duck”,“D”]}]

In other words family is being returned as an array, whereas it is a string in the documentation.

Any ideas which one is ‘correct’? I’m expecting the spec is correct and the implementation is accidentally returning an array of 1 object…

Best wishes,

Andrew

Which server? what URL?

Hi Grahame,

Sorry - that would help!

“url” : “http://fhir2.healthintersections.com.au/open/Patient?_format=application/json+fhir&search-id=40a9930d-0106-4746-a288-47457fe26a&&family=Donald%2CDuck&given=Donald%2CDuck&_sort=_id

is the URL I’m using (copy and pasted the search response out of the JSON so you might be able to even find the query from its id).

So you are using the R2 version of the server (fhir2.healhintersections.com.au) but looking at the R3 version of the specification

Aha - brilliant! I had thought I’d made a note of the spec differences that might affect me, but I hadn’t spotted that one. (having to stick to the R2 spec until Mirth puts a new technical preview out).

Thanks for that!

Best wishes,

Andrew

We’re hard at work on R3 updates! :slight_smile:

1 Like