Skip to Main Content

R4 APIs (Millennium)

Announcement

For information related to the Oracle Partner Network (OPN) Industry Healthcare Track please visit our OPN Industry Healthcare Program page.

For specific questions related to Oracle Partner Network (OPN), please contact Partner Assistance.

Millennium FHIR and non-FHIR API Specifications and Supporting Documents can be found HERE on docs.oracle.com
Soarian FHIR API Specifications and Supporting Documents can be found HERE on docs.oracle.com.

Read and Write Patients in Secure Sandbox

Abdul Moiz SarwarDec 7 2024 — edited Dec 16 2024

Workflow or API calls:

I want to access some data related to the logged in practitioner in the sandbox. Currently I tried reading a patient from the sandbox. However, I am facing an error as mentioned below. I also need some guidance on approach to achieve the desired goals.

Credentials I am using for login:

Username: portal
Password: <redacted>

After successfully exchanging the authorization code for an access token, I tried reading a patient on the sandbox. However I faced an issue.

"response": {
        "message": "code=\"urn:cerner:error:oauth2:resource-access:tenant-mismatch\", error=\"invalid_token\", error_description=\"Token is not valid for this tenant\"",
        "code": 401
    }

Authorization Endpoint: https://authorization.cerner.com/tenants/ec2458f2-1e24-41c8-b71b-0e701af7583d/protocols/oauth2/profiles/smart-v1/personas/provider/authorize?response_type=code&redirect_uri=https%3A%2F%2F<my-redirect-url>&client_id=<my-client-id>&state=<state>&scope=openid%20profile%20user/*.*&aud=https%3A%2F%2Ffhir-ehr-code.cerner.com%2Fr4%2Fec2458f2-1e24-41c8-b71b-0e701af7583d%2F

Token Endpoint: https://authorization.cerner.com/tenants/ec2458f2-1e24-41c8-b71b-0e701af7583d/hosts/api.cernermillennium.com/protocols/oauth2/profiles/smart-v1/token

Read Endpoint: https://fhir-ehr-code.cerner.com/r4/ec2458f2-1e24-41c8-b71b-0e701af7583d/Patient/12742400

I obtained the ID from some comments on forms.

I want to read appointments for this logged in practitioner.
I also want to be able to create appointments for this practitioner.

Is the scope correct? or is there an issue with the Read Endpoint? I am confused and clueless.

Any helpful resources are appreciated aswell.

Background Information:

Are you an OPN Member? No
Have you signed up to be in the Healthcare Developer Track? No
Are you a registered Code Program member? Yes
Does your App have a presence on the Oracle Healthcare App Marketplace? No

Are you developing on behalf of an Oracle Health client?
If so, which client:

Application ID: ce445b93-1696-435e-a59a-52ebcd770c0a
Client ID: e8b7208d-ecd4-4db1-96c4-5ba786415715

Expected Result:

A Patient object in response

Actual Result:

"response": {
        "message": "code=\"urn:cerner:error:oauth2:resource-access:tenant-mismatch\", error=\"invalid_token\", error_description=\"Token is not valid for this tenant\"",
        "code": 401
    }
This post has been answered by Christopher Brashear-Oracle on Feb 10 2025
Jump to Answer
Comments
Post Details
Added on Dec 7 2024
3 comments
1,088 views