...
Code Block | ||||
---|---|---|---|---|
| ||||
curl --user user:password "host:8080/openmrs/ws/rest/v1/shr/documents?contentType=text%2Fxml&patientId=1&patientIdType=ECID" -H "Accept: text/xml" Response: <linked-list> <org.openmrs.module.shr.contenthandler.api.Content> <payload><data>...</data></payload> <formatCode>xml</formatCode> <contentType>text/xml</contentType> <encoding>UTF-8</encoding> <representation>TXT</representation> <payloadIsUrl>false</payloadIsUrl> <payload><data>...</data></payload> </org.openmrs.module.shr.contenthandler.api.Content> </linked-list> |
Code Block | ||||
---|---|---|---|---|
| ||||
curl --user user:password "host:8080/openmrs/ws/rest/v1/shr/documents?contentType=image%2Fjpg&patientId=1&patientIdType=ECID" -H "Accept: text/xml" Response: <linked-list> <org.openmrs.module.shr.contenthandler.api.Content> <payload>BASE64 Content...</payload> <formatCode>Image</formatCode> <contentType>image/jpg</contentType> <encoding>Binary</encoding> <representation>B64</representation> <payloadIsUrl>false</payloadIsUrl> <payload>BASE64 Content...</payload> </org.openmrs.module.shr.contenthandler.api.Content> <org.openmrs.module.shr.contenthandler.api.Content> <payload>http://imageserver/image.jpg</payload> <formatCode>Image</formatCode> <contentType>image/jpg</contentType> <encoding>Binary</encoding> <representation>BINARY</representation> <payloadIsUrl>true</payloadIsUrl> <payload>http://imageserver/image.jpg</payload> </org.openmrs.module.shr.contenthandler.api.Content> </linked-list> |