Workflow or API calls:
Reminder: If this is referring to a client domain or EHR activity—not the public sandbox—do not include API request data or live patient data.
Background Information:
Hello Oracle Cerner team,
I’m currently testing the FHIR **DocumentReference** resource integration in the Cerner R4 Sandbox environment.
My goal is to upload a PDF report (base64-encoded) to a patient record using a valid FHIR DocumentReference POST request.
Below is the exact request JSON I’m using in Postman:
{
"resourceType": "DocumentReference",
"status": "current",
"docStatus": "final",
"type": {
"coding": \[
{
"system": "https://fhir-myrecord.sandboxcerner.com/r4/c7d3f529-30be-4b1a-a249-08d6fd6343c3/codeSet/72",
"code": "550694647",
"display": "Device Interrogation",
"userSelected": true
}
\],
"text": "Device Interrogation"
},
"subject": {
"reference": "Patient/19297556"
},
"author": \[
{
"reference": "Practitioner/16965273"
}
\],
"authenticator": {
"reference": "Practitioner/16965273"
},
"content": \[
{
"attachment": {
"contentType": "application/pdf",
"data": "JVBERi0xLjMKMSAwIG9iago8PAovQ291bnQgMQovS2lkcyBbMyAwIFJdCi9NZWRpYUJveCBbMCAwIDU5NS4yOCA4NDEuODldCi9UeXBlIC9QYWdlcwo+PgplbmRvYmoKMiAwIG9iago8PAovT3BlbkFjdGlvbiBbMyAwIFIgL0ZpdEggbnVsbF0KL1BhZ2VMYXlvdXQgL09uZUNvbHVtbgovUGFnZXMgMSAwIFIKL1R5cGUgL0NhdGFsb2cKPj4KZW5kb2JqCjMgMCBvYmoKPDwKL0NvbnRlbnRzIDQgMCBSCi9QYXJlbnQgMSAwIFIKL1Jlc291cmNlcyA3IDAgUgovVHlwZSAvUGFnZQo+PgplbmRvYmoKNCAwIG9iago8PAovRmlsdGVyIC9GbGF0ZURlY29kZQovTGVuZ3RoIDI4OQo+PgpzdHJlYW0KeJxtkbFuwjAURXe+4o4wxMROkxC2IkAqQ4VKRhaLPMBtbEeOW5S/rwlFAqWrdc959z0LbEYxS3NcRosS0zUHz1gcozxiVV6feJoxMUNevFxTZYXxkn7UgfBmPDlnT9Ira/BBjXUe+/FO6qam/WSC8vNPMV0LcPF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TQzNjg4ODFGNkM0MDk5MzREREM3RD48QTJFNDYyNUFBM0U0MzY4ODgxRjZDNDA5OTM0RERDN0Q+XQo+PgpzdGFydHhyZWYKOTkxCiUlRU9GCg==",
"title": "Device Interrogation Report",
"creation": "2025-10-06T22:33:26+05:30"
}
}
\],
"context": {
"period": {
"start": "2025-10-06T22:33:26+05:30",
"end": "2025-10-06T22:33:26+05:30"
}
}
}
Request Configuration:
-
Method: POST
-
Endpoint:
https://fhir-myrecord.sandboxcerner.com/r4/c7d3f529-30be-4b1a-a249-08d6fd6343c3/DocumentReference
-
Headers:
Content-Type: application/fhir+json,
Accept: */*
Authorization: Bearer <access_token>
Response:
{
"resourceType": "OperationOutcome",
"issue": [
{
"severity": "error",
"code": "invalid",
"details": {
"text": "Invalid request"
}
}
]
}
I’ve verified:
- The
Content-Type and Accept headers are correctly set to application/fhir+json and */*
- The patient (
Patient/19297556) and practitioner (Practitioner/16965273) exist in the sandbox.
- The Base64 PDF is valid and decodes successfully.
Could you please clarify:
- Is
DocumentReference creation (with Base64-encoded PDF attachments) currently supported in this sandbox environment?
- Are any additional fields, I do see a post from this oracle forum saying that encounter is not a mandatory field, so I removed the encounter from the payload and tried it.Can you please confirm about this one?
- Are there any known restrictions on the MIME type or attachment data size for PDF uploads?
- Please let us know why we are getting bad request
Any example or working sample request for uploading a DocumentReference resource with a PDF attachment would be extremely helpful.
Developer questions:
Are you an OPN Member? YES
Have you signed up to be in the Healthcare Developer Track? No
Are you a registered Code Program member? No
Does your App have a presence on the Oracle Healthcare App Marketplace? Y No
Are you developing on behalf of an Oracle Health client?
If so, which client: Atlanticare
Sandbox TenantId:c7d3f529-30be-4b1a-a249-08d6fd6343c3
Expected Result:
Actual Result:
X-Request-Id:
/A4ECEB5A9C789EF990B987118E299E33+KUXx_P1Fp
opc-request-id:
/A4ECEB5A9C789EF990B987118E299E33/0DF6CD90855D75D495F1EB6E3B31C1C1
Date/time of the example:
Wed, 29 Oct 2025 19:06:58 GMT
@sukesh-konjeti-oracle @Christopher Brashear-Oracle @Daniel Alistar-Oracle @Albert-Attila Keresztesi-Oracle @Ionut Balan-Oracle @Jacob Jewell-Oracle @Harsh Pathak-Oracle @Madhur Thangadurai Rajendran-Oracle @Aaron McGinn-Oracle @Ashoka P-Oracle @Kennan Keim-Oracle @brett-murray-oracle @Zachary Turnbell-Oracle @Stefan Ioachim-Oracle @Adrian Hernandez-Oracle @Marian Melinte-Oracle