Patient Resource - R4 and DSTU2

446 views
Skip to first unread message

Jonathan Maple

unread,
Mar 23, 2020, 1:13:25 PM3/23/20
to Cerner FHIR Developers
Do the APIs  provide access to the same patient using both the R4 and DSTU2 endpoints?  I.e. if we have a patient ID of 4342008 can we pass that ID into both the R4 and DSTU2 endpoints and retrieve the different FHIR resources of the same patient? 

Walter Seymour (Cerner)

unread,
Mar 23, 2020, 1:38:36 PM3/23/20
to cerner-fhir...@googlegroups.com
Hi Jonathan,

The simple answer to your question is yes, if you were to search for a patient and the patient exists, the patient would be returned on both r4 and dstu2 endpoints.

The only difference is the response would be slightly different, as the specifications for r4 and dstu2 are slightly different. If you would like to see these differences for yourself, you can take a look at our DSTU2[1] ad r4[2] Patient resource retrieval documentation.

[1] https://fhir.cerner.com/millennium/dstu2/individuals/patient/#retrieve-by-id
[2] https://fhir.cerner.com/millennium/r4/individuals/patient/#retrieve-by-id

Thanks,
Walter

Jonathan Maple

unread,
Mar 23, 2020, 3:03:44 PM3/23/20
to cerner-fhir...@googlegroups.com
Awesome - thank you Walter.  Last question - we need to use the DocumentReference.Create call in the DSTU2 API.  Will we be able to certify our app if we utilize both DSTU2 and R4 in our workflows?  Are there any restrictions in using both specs?

On Mon, Mar 23, 2020 at 11:38 AM 'Walter Seymour (Cerner)' via Cerner FHIR Developers <cerner-fhir...@googlegroups.com> wrote:
Hi Jonathan,

The simple answer to your question is yes, if you were to search for a patient and the patient exists, the patient would be returned on both r4 and dstu2 endpoints.

The only difference is the response would be slightly different, as the specifications for r4 and dstu2 are slightly different. If you would like to see these differences for yourself, you can take a look at our DSTU2[1] ad r4[2] Patient retrieval resource documentation.


[1] https://fhir.cerner.com/millennium/dstu2/individuals/patient/#retrieve-by-id
[2] https://fhir.cerner.com/millennium/r4/individuals/patient/#retrieve-by-id

Thanks,
Walter

On Monday, March 23, 2020 at 12:13:25 PM UTC-5, Jonathan Maple wrote:
Do the APIs  provide access to the same patient using both the R4 and DSTU2 endpoints?  I.e. if we have a patient ID of 4342008 can we pass that ID into both the R4 and DSTU2 endpoints and retrieve the different FHIR resources of the same patient? 

--
You received this message because you are subscribed to the Google Groups "Cerner FHIR Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cerner-fhir-devel...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/cerner-fhir-developers/5de4089f-c4a7-4528-87d5-89dd4f8268f3%40googlegroups.com.

Walter Seymour (Cerner)

unread,
Mar 23, 2020, 4:15:00 PM3/23/20
to Cerner FHIR Developers
Yes, you can use both DSTU2 and R4 endpoints in an application if R4 is missing functionality you need, per this previous thread[1].

[1] https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!searchin/cerner-fhir-developers/both$20dstu2$20and$20r4%7Csort:date/cerner-fhir-developers/b5HaiKQgL_s/LHavIiXuAwAJ

Thanks,
Walter


On Monday, March 23, 2020 at 2:03:44 PM UTC-5, Jonathan Maple wrote:
Awesome - thank you Walter.  Last question - we need to use the DocumentReference.Create call in the DSTU2 API.  Will we be able to certify our app if we utilize both DSTU2 and R4 in our workflows?  Are there any restrictions in using both specs?

On Mon, Mar 23, 2020 at 11:38 AM 'Walter Seymour (Cerner)' via Cerner FHIR Developers <cerner-fhir-developers@googlegroups.com> wrote:
Hi Jonathan,

The simple answer to your question is yes, if you were to search for a patient and the patient exists, the patient would be returned on both r4 and dstu2 endpoints.

The only difference is the response would be slightly different, as the specifications for r4 and dstu2 are slightly different. If you would like to see these differences for yourself, you can take a look at our DSTU2[1] ad r4[2] Patient retrieval resource documentation.

[1] https://fhir.cerner.com/millennium/dstu2/individuals/patient/#retrieve-by-id
[2] https://fhir.cerner.com/millennium/r4/individuals/patient/#retrieve-by-id

Thanks,
Walter

On Monday, March 23, 2020 at 12:13:25 PM UTC-5, Jonathan Maple wrote:
Do the APIs  provide access to the same patient using both the R4 and DSTU2 endpoints?  I.e. if we have a patient ID of 4342008 can we pass that ID into both the R4 and DSTU2 endpoints and retrieve the different FHIR resources of the same patient? 

--
You received this message because you are subscribed to the Google Groups "Cerner FHIR Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cerner-fhir-developers+unsub...@googlegroups.com.

Jonathan Maple

unread,
Mar 25, 2020, 3:27:27 PM3/25/20
to Cerner FHIR Developers
Thanks Walter - We've seen varying answers to this question.  See here where the answer seems to differ:
https://groups.google.com/forum/#!searchin/cerner-fhir-developers/kingston%7Csort:date/cerner-fhir-developers/WdSM2K11xNQ/5Vybo2Z-AQAJ

In our case, our workflow needs to save a document back to the patient's chart using the DSTU2 DocumentReference.Create call.  We also require the insurance information which is only available in R4.  We've already developed the app/workflow against the Cerner Sandbox using DSTU2.   

We are evaluating these 2 paths within Cerner: 
  1. Rewrite our app to the R4 standard and use the DSTU2 DocumentReference.Create call to fill the gap
  2. Use our previously developed DSTU2 code and fill the Insurance coverage gap with the R4 call. 
What are your thoughts/recommendations?

On Monday, March 23, 2020 at 2:15:00 PM UTC-6, Walter Seymour (Cerner) wrote:
Yes, you can use both DSTU2 and R4 endpoints in an application if R4 is missing functionality you need, per this previous thread[1].

[1] https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!searchin/cerner-fhir-developers/both$20dstu2$20and$20r4%7Csort:date/cerner-fhir-developers/b5HaiKQgL_s/LHavIiXuAwAJ

Thanks,
Walter

On Monday, March 23, 2020 at 2:03:44 PM UTC-5, Jonathan Maple wrote:
Awesome - thank you Walter.  Last question - we need to use the DocumentReference.Create call in the DSTU2 API.  Will we be able to certify our app if we utilize both DSTU2 and R4 in our workflows?  Are there any restrictions in using both specs?

Walter Seymour (Cerner)

unread,
Mar 25, 2020, 3:58:18 PM3/25/20
to Cerner FHIR Developers
Hi Jonathan,

Here is a better thread[1] that may answer your question. You should create a R4 app, and we can configure your scopes manually to include the needed DSTU2 resource.

[1] https://groups.google.com/forum/#!searchin/cerner-fhir-developers/both$20dstu2%7Csort:date/cerner-fhir-developers/XjIdAKQ7PHA/jWvC6wsPAwAJ.

Thanks,
Walter

Jonathan Maple

unread,
Nov 4, 2020, 12:37:27 PM11/4/20
to Cerner FHIR Developers
Hi Walter - We have our R4 app developed and are to the point of needing to use some DSTU2 resources.  How do we proceed?

Thanks,
Jonathan

Walter Seymour (Cerner)

unread,
Nov 4, 2020, 1:38:20 PM11/4/20
to Cerner FHIR Developers
Hi Jonathan,

Since the previous posts, R4 now has the ability to create docs. https://fhir.cerner.com/millennium/r4/documents/document-reference/#create

You should be able to add the DocumentReference.write scope to your app in the code console, and you can test it out from there. Were there any other DSTU2 resources you were planning on using?

Thanks,
Walter

Yu Xu

unread,
Nov 5, 2020, 12:11:21 PM11/5/20
to Cerner FHIR Developers
Hi Walter,

I'm working with Jonathan on R4 app development. I need to create appointment and use the Slot resource. From my search of related threads, looks like I have to use the DSTU2 APIs/Resources for Slot. Now I have access to the Cerner R4 sandbox server. How can I access the DSTU2 server to access the Slot resource, or maybe other resources as our development proceeds?

Thank you very much,
Yu

Aaron McGinn (Cerner)

unread,
Nov 6, 2020, 7:32:29 PM11/6/20
to Cerner FHIR Developers
 The developer portal currently doesn't expose this to you (an upcoming enhancement!), so we will have to add it for you. All we need is the App/Client ID and the DSTU2 scopes you need for development!

-Aaron (Cerner)

Yu Xu

unread,
Nov 8, 2020, 7:23:50 PM11/8/20
to Cerner FHIR Developers
Hi Aaron,

My client ID is f4f83702-99b5-4b1d-9c7e-e3f299c1a5d1, which is used in my R4 project.
The scope I need now is Read/Write for Slot resource.
A question: when I access to the DSTU2, what is the URL for authorization and resource access?

THANK YOU VERY MUCH,
Yu

Yu Xu

unread,
Nov 8, 2020, 8:32:09 PM11/8/20
to Cerner FHIR Developers
Hi Aaron,

More specifically, the scope is system/Slot read and write.
THANKS,
Yu

Yu Xu

unread,
Nov 11, 2020, 9:51:39 AM11/11/20
to Cerner FHIR Developers
Hi Aaron,

Has my client ID been set up for DSTU2 access?

Thank you very much,
Yu

Walter Seymour (Cerner)

unread,
Nov 11, 2020, 11:41:29 AM11/11/20
to Cerner FHIR Developers
Hi Yu,

These two scopes have been added to your app in our authorization server.

The authorization URL will not change between DSTU2 and R4. For the FHIR resources URL, there will be a slight difference between the two versions. You will need to replace 'R4' with 'DSTU2' when making requests for DSTU2 resources:
https://fhir-ehr-code.cerner.com/dstu2/ec2458f2-1e24-41c8-b71b-0e701af7583d/Condition

Thanks,
Walter

Yu Xu

unread,
Nov 11, 2020, 3:59:53 PM11/11/20
to Cerner FHIR Developers
Hi Walter,

THANKS for your support.
Could you also help provisioning for the account listed below:

Client Id: 35cd1e1c-9506-49a8-a1b7-b0d38fb72158

App Id: 188bb8c2-fd60-4e7a-8040-21606a801ada

THANKS again,
Yu

Aaron McGinn (Cerner)

unread,
Nov 11, 2020, 7:51:24 PM11/11/20
to Cerner FHIR Developers
To clarify, you need system/Slot.read and system/Slot.write on the client ID you mentioned?

-Aaron (Cerner)

Yu Xu

unread,
Nov 12, 2020, 2:59:37 PM11/12/20
to Cerner FHIR Developers
Hi Aaron,

This IS is used for testing our overall implementation and should need more scopes. I'll check and get back.
THANKS for checking!
Yu

Yu Xu

unread,
Nov 12, 2020, 3:26:52 PM11/12/20
to Cerner FHIR Developers
Hi Aaron,

Following are the required scopes:

system/Appointment.read

system/Coverage.read

system/DocumentReference.read

system/Encounter.read

system/MedicationRequest.read

system/Patient.read

system/Person.read

system/Practitioner.read

system/Appointment.write

system/Coverage.write

system/DocumentReference.write

system/Encounter.write

system/MedicationRequest.write

system/Patient.write

system/Practitioner.write


THANKS,
Yu

Aaron McGinn (Cerner)

unread,
Nov 13, 2020, 12:48:22 PM11/13/20
to Cerner FHIR Developers
The app you mentioned (client ID: 35cd1e1c-9506-49a8-a1b7-b0d38fb72158) already has all of these scopes as they are all available in the R4 spec. I see you did not mention Slot in what was required. Did you need it added to this app?

-Aaron (Cerner)

Yu Xu

unread,
Nov 19, 2020, 10:11:42 AM11/19/20
to Cerner FHIR Developers
Hi Aaron,

Thanks for confirmation. Yes the client ID: 35cd1e1c-9506-49a8-a1b7-b0d38fb72158 also need Slot read.
I've tried accessing the Slot resource from the R4 sandbox server after successful auth, with the obtained DSTU2 token in which Slot/read, write is granted (looks like).
I used example from the DSTU2 Slot API web page, searching slot by Slot type with following request URL:
but got error:
DSTU2 Get Failed Hl7.Fhir.Rest.FhirOperationException: Operation was unsuccessful because of a client error (Forbidden). Body has no content.
Response Headers:
X-Request-ID: 5ffe4e05-9e3f-4272-9f1a-1ae11788705c
WWW-Authenticate: Bearer realm="fhir-ehr-code.cerner.com", error="insufficient_scope"
X-Cache: Error from cloudfront
Via: 1.1 81ba239f918c2c88c443afb9bffa9d8f.cloudfront.net (CloudFront)
X-Amz-Cf-Pop: ORD51-C2
X-Amz-Cf-Id: 5cbFtp7nF4ALGFTrTcVgCPpkLn2GlXDF76So8Z1Ckl9f5LlrhyzaIg==

Looks like I can't search Slot using type. could you help check?

What slot type IDs are available from the sandbox?
What slot IDs, ID range I can use for my tests?

I also tried search slot using a slot ID 21265426-633867-3121665-0, and got:
Fhir Slot.Get Failed. Hl7.Fhir.Rest.FhirOperationException: Operation was unsuccessful because of a client error (NotFound). OperationOutcome: Overall result: FAILURE (1 errors and 0 warnings)

Response Headers:
X-Request-ID: 45bece7f-acab-4c08-a2c9-e8102ed4349c
X-Runtime: 0.025883
X-Cache: Error from cloudfront
Via: 1.1 dc44064c54cfe99859200f562d23535e.cloudfront.net (CloudFront)
X-Amz-Cf-Pop: ORD51-C2
X-Amz-Cf-Id: TRA2qUEmoa_l5oKxhbFd062vsxOrXfKkAJXiXfvE8DIM-YXd_ZlGDQ==

Thank you very much!
Yu

Yu Xu

unread,
Nov 25, 2020, 1:58:02 PM11/25/20
to Cerner FHIR Developers
Hi Aaron,

Do you have update?

I have tried retrieve/create DSTU slot with both base URL as shown below:

Both got insufficient_scope error.
I also find that to create complete appointment resource I need DSTU Schdule too. Could you help assign Schedule system/read and system/write for my client ID f4f83702-99b5-4b1d-9c7e-e3f299c1a5d1

Thank you very much and Happy Thanksgiving!
Yu

Aaron McGinn (Cerner)

unread,
Nov 30, 2020, 12:13:58 PM11/30/20
to Cerner FHIR Developers
The 'insufficient_scope' error implies the system/Slot.read was not in either your app's configuration and/or your authorization request. I have added Slot.read and Slot.write for the app mentioned above. Note that the Slot resource is currently only supported in DSTU2.

-Aaron (Cerner)
Reply all
Reply to author
Forward
0 new messages