Not able to upload a document on DocumentReference - reg

65 views
Skip to first unread message
Assigned to Fenil....@cerner.com by me

Vijay Amirtharaj Xavier

unread,
Jan 18, 2022, 1:29:05 AM1/18/22
to Cerner FHIR Developers
Hi Cerner Team,

I am trying to upload a html document through DocumentReference post request.
But I am getting response as
{
"resourceType":"OperationOutcome",
"issue":
[
{
"severity":"error",
"code":"not-found",
"details":
{
"text":"Not Found"
}
}
]
}



Body Content :
{
  "resourceType": "DocumentReference",
  "status": "current",
  "docStatus": "final",
  "type": {
    "coding": [
      {
        "system": "https://fhir.cerner.com/ec2458f2-1e24-41c8-b71b-0e701af7583d/codeSet/72",
        "code": "20732501",
        "display": "Height Weight Allergy Rule - Text",
        "userSelected": true
      }
    ],
    "text": "Height Weight Allergy Rule - Text"
  },
  "subject": {
    "reference": "Patient/53663272"
  },
  "author": [
    {
      "reference": "Practitioner/21500981"
    }
  ],
  "authenticator": {
    "reference": "Practitioner/21500981"
  },
  "content": [
    {
      "attachment": {
        "contentType": "application/xml;charset=utf-8",
        "data": "IDwhRE9DVFlQRSBodG1sIFBVQkxJQyAiLS8vVzNDLy9EVEQgWEhUTUwgMS4xLy9FTiIKImh0dHA6Ly93d3cudzMub3JnL1RSL3hodG1sMTEvRFREL3hodG1sMTEuZHRkIj4KPGh0bWwgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGh0bWwiPgo8aGVhZD4KICA8dGl0bGU+VGVzdCBkb2N1bWVudDwvdGl0bGU+CjwvaGVhZD4KPGJvZHk+CgogIHNvbWUgY29udGVudCBoZXJlLi4uCiAgRG9jdW1lbnQgY3JlYXRlZCBieSBWaWpheSBBbWlydGhhcmFqCgo8L2JvZHk+CjwvaHRtbD4gCg==",
        "title": "Height Weight Allergy Rule",
        "creation": "2022-01-18T06:15:35.000Z"
      }
    }
  ],
  "context": {
    "encounter": [
      {
        "reference": "Encounter/4208059"
      }
    ],
    "period": {
      "start": "2020-01-01T00:00:00.000Z",
      "end": "2020-01-01T01:00:00.000Z"
    }
  }
}

Response Header : X-Request-Id: d53fe738-d7d8-41ad-9681-6a21eda15112



Please help me to resolve this.

Thanks
Vijay Amirtharaj

Fenil Desani (Cerner)

unread,
Jan 18, 2022, 11:42:40 AM1/18/22
to Cerner FHIR Developers
Hello,

You can POST to open endpoint. Please use the secure closed endpoint.

Thanks,
Fenil

Vijay Amirtharaj Xavier

unread,
Jan 18, 2022, 12:45:29 PM1/18/22
to cerner-fhir...@googlegroups.com
Hello Fenil, 

Thanks for your response. 

Secure closed endpoints mean the production one ? or do we have any other url for testing the sandbox for upload document. 

As of now I am using the open sandbox url for other read request for all resources types on system account. 

Please suggest me. 

Thanks & Regards
Vijay Amirtharaj

--
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/08d5f038-2f18-4d7a-a50f-0af1c67891f6n%40googlegroups.com.

Fenil Desani (Cerner)

unread,
Jan 18, 2022, 1:56:22 PM1/18/22
to Cerner FHIR Developers
Our public Sandbox has two endpoints to access resources.
  1. Open (not Auth needed) : https://fhir-open.cerner.com
  2. Closed (Auth needed): https://fhir-ehr-code.cerner.com

Vijay Amirtharaj Xavier

unread,
Jan 19, 2022, 2:45:51 AM1/19/22
to Cerner FHIR Developers
Hi Fenil,

Thanks for the reference url:

I have tried with this closed endpoint and I am able to upload the document, but there is no return response body (JSON) from the server.

Below is my POSTMAT log for your reference and please let me know the solution.

Log from PostMan:

POST https://fhir-ehr-code.cerner.com/r4/ec2458f2-1e24-41c8-b71b-0e701af7583d/DocumentReference

REQUEST HEADER :
Content-Type: application/json+fhir
Authorization: Bearer XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
User-Agent: PostmanRuntime/7.26.8
Accept: */*
Postman-Token: a31xxxxxxxxxxxxxxxxxxxxxxx3
Host: fhir-ehr-code.cerner.com
Accept-Encoding: gzip, deflate, br
Connection: keep-alive
Content-Length: 1408
Cookie: _ga=GA1.2.1676141304.1633892139

REQUEST BODY :
{
  "resourceType": "DocumentReference",
  "status": "current",
  "docStatus": "final",
  "type": {
    "coding": [
      {
        "system": "https://fhir.cerner.com/ec2458f2-1e24-41c8-b71b-0e701af7583d/codeSet/72",
        "code": "20732501",
        "display": "Height Weight Allergy Rule - Text",
        "userSelected": true
      }
    ],
    "text": "Height Weight Allergy Rule - Text"
  },
  "subject": {
    "reference": "Patient/12724066"
  },
  "author": [
    {
      "reference": "Practitioner/12743472"
    }
  ],
  "authenticator": {
    "reference": "Practitioner/12743472"

  },
  "content": [
    {
      "attachment": {
        "contentType": "application/xml;charset=utf-8",
        "data": "IDwhRE9DVFlQRSBodG1sIFBVQkxJQyAiLS8vVzNDLy9EVEQgWEhUTUwgMS4xLy9FTiIKImh0dHA6Ly93d3cudzMub3JnL1RSL3hodG1sMTEvRFREL3hodG1sMTEuZHRkIj4KPGh0bWwgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGh0bWwiPgo8aGVhZD4KICA8dGl0bGU+VGVzdCBkb2N1bWVudDwvdGl0bGU+CjwvaGVhZD4KPGJvZHk+CgogIHNvbWUgY29udGVudCBoZXJlLi4uCiAgRG9jdW1lbnQgY3JlYXRlZCBieSBWaWpheSBBbWlydGhhcmFqCgo8L2JvZHk+CjwvaHRtbD4gCg==",
        "title": "Height Weight Allergy Rule",
        "creation": "2022-01-19T06:51:22.000Z"
      }
    }
  ],
  "context": {
    "encounter": [
      {
        "reference": "Encounter/97954261"

      }
    ],
    "period": {
      "start": "2020-01-01T00:00:00.000Z",
      "end": "2020-01-01T01:00:00.000Z"
    }
  }
}

RESPONSE HEADER :

HTTP/1.1 201 Created
Content-Type: text/html
Content-Length: 0
Connection: keep-alive
Date: Wed, 19 Jan 2022 07:27:15 GMT
Cache-Control: no-cache
Etag: W/"1"
Last-Modified: Wed, 19 Jan 2022 07:27:14 GMT
Location: https://fhir-ehr-code.cerner.com/r4/ec2458f2-1e24-41c8-b71b-0e701af7583d/DocumentReference/197579544
Server-Response-Time: 9638.663844
Vary: Origin
X-Request-Id: 599efeea-dfae-4fe5-bfd3-7258f4547ec7
X-Runtime: 9.638496
X-Cache: Miss from cloudfront
Via: 1.1 8848e817dbad32b1ae333eabdea228d4.cloudfront.net (CloudFront)
X-Amz-Cf-Pop: MAA51-P1
X-Amz-Cf-Id: jzlMnWwOisL6Nh6sUYQNYVsVy_5txPPzt2x8wKJ3Ts3Q1Gell7K6lQ==

RESPONSE BODY :
EMPTY STRING


Also I am using the following scopes :  "system/Patient.read system/Appointment.read system/DocumentReference.read system/Condition.read system/Practitioner.read system/Encounter.read system/DocumentReference.write"

Please let me know where I am making mistakes.

Thanks
Vijay Amirtharaj

Fenil Desani (Cerner)

unread,
Jan 19, 2022, 11:13:18 AM1/19/22
to Cerner FHIR Developers
The Document has been successfully created and can be found at at  https://fhir-ehr-code.cerner.com/r4/ec2458f2-1e24-41c8-b71b-0e701af7583d/DocumentReference/197579544
The response body would be empty.

Reply all
Reply to author
Forward
0 new messages