# Create encounter request curl 'http://localhost:8080/openmrs/ws/rest/v1/encounter' -H 'Origin: http://localhost:8080' -H 'Accept-Encoding: gzip, deflate, br' -H 'Accept-Language: en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36' -H 'Content-Type: application/json;charset=UTF-8' -H 'Accept: application/json, text/plain, */*' -H 'Referer: http://localhost:8080/openmrs/labtrackingapp/labtrackingOrderDetails.page?orderUuid=6cd7334c-1a54-4ad7-b43b-9798630d82b0' -H 'Cookie: JSESSIONID=akohpj15pvtr; emr.lastSessionLocation=34; __openmrs_language=en_US' -H 'Connection: keep-alive' --data-binary '{"patient":"6c7ffd68-8d0f-4868-bb90-1284a0cdbe8c","encounterType":"10db3139-07c0-4766-b4e5-a41b01363145","location":"199e7d87-92a0-4398-a0f8-11d012178164","encounterProviders":[{"provider":"06cf82e6-47a3-4f7a-b2ba-51eaf463294e","encounterRole":"c458d78e-8374-4767-ad58-9f8fe276e01c"}],"obs":[{"concept":"393dec41-2fb5-428f-acfa-36ea85da6666","value":"ORD-88","uuid":null},{"groupMembers":[{"concept":"226ed7ad-b776-4b99-966d-fd818d3302c2","value":"146825AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA","uuid":null},{"concept":"3cd9ef9a-26fe-102b-80cb-0017a47871b2","value":"3cd9bd04-26fe-102b-80cb-0017a47871b2","uuid":null}],"concept":"2da3ec67-62aa-4be8-a32c-cb32723742c8","uuid":null}]}' --compressed # Create encounter response {"uuid":"be4c2e31-c1a0-408f-ac28-e36a23a34cfa","display":"Specimen Collection 01/19/2017","encounterDatetime":"2017-01-19T20:12:09.000-0500","patient":{"uuid":"6c7ffd68-8d0f-4868-bb90-1284a0cdbe8c","display":"22222222222 - Jack Test","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/patient/6c7ffd68-8d0f-4868-bb90-1284a0cdbe8c","rel":"self"}]},"location":{"uuid":"199e7d87-92a0-4398-a0f8-11d012178164","display":"Klinik Ekstèn","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/location/199e7d87-92a0-4398-a0f8-11d012178164","rel":"self"}]},"form":null,"encounterType":{"uuid":"10db3139-07c0-4766-b4e5-a41b01363145","display":"Specimen Collection","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encountertype/10db3139-07c0-4766-b4e5-a41b01363145","rel":"self"}]},"obs":[{"uuid":"36a6e755-7f39-4203-9b93-b9ba9305d519","display":"Post-pathology diagnosis construct: Burkitt's Lymphoma (Clinical), Confirmed","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/obs/36a6e755-7f39-4203-9b93-b9ba9305d519","rel":"self"}]},{"uuid":"c30874ec-d8ab-49b3-a7c1-425d8239dd70","display":"Test order number: ORD-88","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/obs/c30874ec-d8ab-49b3-a7c1-425d8239dd70","rel":"self"}]}],"orders":[],"voided":false,"visit":{"uuid":"32ad90d9-ccc6-4013-bc7e-ba604f6554ca","display":"Clinic or Hospital Visit @ Mirebalais - 01/18/2017 09:40 PM","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/visit/32ad90d9-ccc6-4013-bc7e-ba604f6554ca","rel":"self"}]},"encounterProviders":[{"uuid":"dff9f64a-b260-4df3-847a-a85979eb85f9","display":"Super User: Ordering Provider","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/dff9f64a-b260-4df3-847a-a85979eb85f9","rel":"self"}]}],"links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa","rel":"self"},{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa?v=full","rel":"full"}],"resourceVersion":"1.9"} # Create EncounterProvider #1 request curl 'http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider' -H 'Origin: http://localhost:8080' -H 'Accept-Encoding: gzip, deflate, br' -H 'Accept-Language: en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36' -H 'Content-Type: application/json;charset=UTF-8' -H 'Accept: application/json, text/plain, */*' -H 'Referer: http://localhost:8080/openmrs/labtrackingapp/labtrackingOrderDetails.page?orderUuid=6cd7334c-1a54-4ad7-b43b-9798630d82b0' -H 'Cookie: JSESSIONID=akohpj15pvtr; emr.lastSessionLocation=34; __openmrs_language=en_US' -H 'Connection: keep-alive' --data-binary '{"provider":"ca105028-37ac-4685-94ab-523f4233cb94","encounterRole":"9b135b19-7ebe-4a51-aea2-69a53f9383af"}' --compressed # Create EncounterProvider #1 response {"uuid":"304b8d9e-2269-4335-ba6c-a7efaeb59f3d","provider":{"uuid":"ca105028-37ac-4685-94ab-523f4233cb94","display":"Dr. What - Dr What","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/provider/ca105028-37ac-4685-94ab-523f4233cb94","rel":"self"}]},"encounterRole":{"uuid":"9b135b19-7ebe-4a51-aea2-69a53f9383af","display":"Attending Surgeon","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounterrole/9b135b19-7ebe-4a51-aea2-69a53f9383af","rel":"self"}]},"voided":false,"links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/304b8d9e-2269-4335-ba6c-a7efaeb59f3d?v=full","rel":"full"}],"resourceVersion":"1.9"} # Create EncounterProvider #2 request curl 'http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider' -H 'Origin: http://localhost:8080' -H 'Accept-Encoding: gzip, deflate, br' -H 'Accept-Language: en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36' -H 'Content-Type: application/json;charset=UTF-8' -H 'Accept: application/json, text/plain, */*' -H 'Referer: http://localhost:8080/openmrs/labtrackingapp/labtrackingOrderDetails.page?orderUuid=6cd7334c-1a54-4ad7-b43b-9798630d82b0' -H 'Cookie: JSESSIONID=akohpj15pvtr; emr.lastSessionLocation=34; __openmrs_language=en_US' -H 'Connection: keep-alive' --data-binary '{"provider":"ce3679bd-be1a-4543-81a4-17b7928979bc","encounterRole":"6e630e03-5182-4cb3-9a82-a5b1a85c09a7"}' --compressed # Create EncounterProvider #2 response {"uuid":"a3f82fe7-e474-47a8-b7dc-4fdf2b811213","provider":{"uuid":"ce3679bd-be1a-4543-81a4-17b7928979bc","display":"Dr Who - Dr Who","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/provider/ce3679bd-be1a-4543-81a4-17b7928979bc","rel":"self"}]},"encounterRole":{"uuid":"6e630e03-5182-4cb3-9a82-a5b1a85c09a7","display":"Assisting Surgeon","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounterrole/6e630e03-5182-4cb3-9a82-a5b1a85c09a7","rel":"self"}]},"voided":false,"links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/a3f82fe7-e474-47a8-b7dc-4fdf2b811213?v=full","rel":"full"}],"resourceVersion":"1.9"} #ENCOUNTER PROVIDERS FROM WEB SERVICE CALL AT THIS POINT http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa?v=custom:(encounterProviders) #JSON dff9f64a-b260-4df3-847a-a85979eb85f906cf82e6-47a3-4f7a-b2ba-51eaf463294e1 - Super Userselfhttp://localhost:8080/openmrs/ws/rest/v1/provider/06cf82e6-47a3-4f7a-b2ba-51eaf463294ec458d78e-8374-4767-ad58-9f8fe276e01cOrdering Providerselfhttp://localhost:8080/openmrs/ws/rest/v1/encounterrole/c458d78e-8374-4767-ad58-9f8fe276e01cfalsefullhttp://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/dff9f64a-b260-4df3-847a-a85979eb85f9?v=full1.9a3f82fe7-e474-47a8-b7dc-4fdf2b811213ce3679bd-be1a-4543-81a4-17b7928979bcDr Who - Dr Whoselfhttp://localhost:8080/openmrs/ws/rest/v1/provider/ce3679bd-be1a-4543-81a4-17b7928979bc6e630e03-5182-4cb3-9a82-a5b1a85c09a7Assisting Surgeonselfhttp://localhost:8080/openmrs/ws/rest/v1/encounterrole/6e630e03-5182-4cb3-9a82-a5b1a85c09a7falsefullhttp://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/a3f82fe7-e474-47a8-b7dc-4fdf2b811213?v=full1.9304b8d9e-2269-4335-ba6c-a7efaeb59f3dca105028-37ac-4685-94ab-523f4233cb94Dr. What - Dr Whatselfhttp://localhost:8080/openmrs/ws/rest/v1/provider/ca105028-37ac-4685-94ab-523f4233cb949b135b19-7ebe-4a51-aea2-69a53f9383afAttending Surgeonselfhttp://localhost:8080/openmrs/ws/rest/v1/encounterrole/9b135b19-7ebe-4a51-aea2-69a53f9383affalsefullhttp://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/304b8d9e-2269-4335-ba6c-a7efaeb59f3d?v=full1.9 # Update encounter request curl 'http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa' -H 'Origin: http://localhost:8080' -H 'Accept-Encoding: gzip, deflate, br' -H 'Accept-Language: en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36' -H 'Content-Type: application/json;charset=UTF-8' -H 'Accept: application/json, text/plain, */*' -H 'Referer: http://localhost:8080/openmrs/labtrackingapp/labtrackingOrderDetails.page?orderUuid=6cd7334c-1a54-4ad7-b43b-9798630d82b0' -H 'Cookie: JSESSIONID=akohpj15pvtr; emr.lastSessionLocation=34; __openmrs_language=en_US' -H 'Connection: keep-alive' --data-binary '{"patient":"6c7ffd68-8d0f-4868-bb90-1284a0cdbe8c","encounterType":"10db3139-07c0-4766-b4e5-a41b01363145","location":"199e7d87-92a0-4398-a0f8-11d012178164","obs":[{"groupMembers":[{"concept":"226ed7ad-b776-4b99-966d-fd818d3302c2","value":"146825AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA","uuid":"c110a409-819d-4861-bb24-17d2d8c21976"},{"concept":"3cd9ef9a-26fe-102b-80cb-0017a47871b2","value":"3cd9bd04-26fe-102b-80cb-0017a47871b2","uuid":"11221a3d-c2d3-457c-a5fb-faa9f0d15a07"}],"concept":"2da3ec67-62aa-4be8-a32c-cb32723742c8","uuid":"36a6e755-7f39-4203-9b93-b9ba9305d519"}],"uuid":"be4c2e31-c1a0-408f-ac28-e36a23a34cfa"}' --compressed # Update encounter response {"uuid":"be4c2e31-c1a0-408f-ac28-e36a23a34cfa","display":"Specimen Collection 01/19/2017","encounterDatetime":"2017-01-19T20:12:09.000-0500","patient":{"uuid":"6c7ffd68-8d0f-4868-bb90-1284a0cdbe8c","display":"22222222222 - Jack Test","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/patient/6c7ffd68-8d0f-4868-bb90-1284a0cdbe8c","rel":"self"}]},"location":{"uuid":"199e7d87-92a0-4398-a0f8-11d012178164","display":"Klinik Ekstèn","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/location/199e7d87-92a0-4398-a0f8-11d012178164","rel":"self"}]},"form":null,"encounterType":{"uuid":"10db3139-07c0-4766-b4e5-a41b01363145","display":"Specimen Collection","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encountertype/10db3139-07c0-4766-b4e5-a41b01363145","rel":"self"}]},"obs":[{"uuid":"36a6e755-7f39-4203-9b93-b9ba9305d519","display":"Post-pathology diagnosis construct: Confirmed, Burkitt's Lymphoma (Clinical)","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/obs/36a6e755-7f39-4203-9b93-b9ba9305d519","rel":"self"}]},{"uuid":"c30874ec-d8ab-49b3-a7c1-425d8239dd70","display":"Test order number: ORD-88","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/obs/c30874ec-d8ab-49b3-a7c1-425d8239dd70","rel":"self"}]}],"orders":[],"voided":false,"visit":{"uuid":"32ad90d9-ccc6-4013-bc7e-ba604f6554ca","display":"Clinic or Hospital Visit @ Mirebalais - 01/18/2017 09:40 PM","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/visit/32ad90d9-ccc6-4013-bc7e-ba604f6554ca","rel":"self"}]},"encounterProviders":[{"uuid":"dff9f64a-b260-4df3-847a-a85979eb85f9","display":"Super User: Ordering Provider","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/dff9f64a-b260-4df3-847a-a85979eb85f9","rel":"self"}]},{"uuid":"a3f82fe7-e474-47a8-b7dc-4fdf2b811213","display":"Dr Who: Assisting Surgeon","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/a3f82fe7-e474-47a8-b7dc-4fdf2b811213","rel":"self"}]},{"uuid":"304b8d9e-2269-4335-ba6c-a7efaeb59f3d","display":"Dr What: Attending Surgeon","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/304b8d9e-2269-4335-ba6c-a7efaeb59f3d","rel":"self"}]}],"links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa","rel":"self"},{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa?v=full","rel":"full"}],"resourceVersion":"1.9"} # Delete Encounter Provider #1 curl 'http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/304b8d9e-2269-4335-ba6c-a7efaeb59f3d' -X DELETE -H 'Origin: http://localhost:8080' -H 'Accept-Encoding: gzip, deflate, sdch, br' -H 'Accept-Language: en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36' -H 'Accept: application/json, text/plain, */*' -H 'Referer: http://localhost:8080/openmrs/labtrackingapp/labtrackingOrderDetails.page?orderUuid=6cd7334c-1a54-4ad7-b43b-9798630d82b0' -H 'Cookie: JSESSIONID=akohpj15pvtr; emr.lastSessionLocation=34; __openmrs_language=en_US' -H 'Connection: keep-alive' --compressed # Delete Encounter Provider #2 curl 'http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/a3f82fe7-e474-47a8-b7dc-4fdf2b811213' -X DELETE -H 'Origin: http://localhost:8080' -H 'Accept-Encoding: gzip, deflate, sdch, br' -H 'Accept-Language: en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36' -H 'Accept: application/json, text/plain, */*' -H 'Referer: http://localhost:8080/openmrs/labtrackingapp/labtrackingOrderDetails.page?orderUuid=6cd7334c-1a54-4ad7-b43b-9798630d82b0' -H 'Cookie: JSESSIONID=akohpj15pvtr; emr.lastSessionLocation=34; __openmrs_language=en_US' -H 'Connection: keep-alive' --compressed # Create EncounterProvider #1 request curl 'http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider' -H 'Origin: http://localhost:8080' -H 'Accept-Encoding: gzip, deflate, br' -H 'Accept-Language: en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36' -H 'Content-Type: application/json;charset=UTF-8' -H 'Accept: application/json, text/plain, */*' -H 'Referer: http://localhost:8080/openmrs/labtrackingapp/labtrackingOrderDetails.page?orderUuid=6cd7334c-1a54-4ad7-b43b-9798630d82b0' -H 'Cookie: JSESSIONID=akohpj15pvtr; emr.lastSessionLocation=34; __openmrs_language=en_US' -H 'Connection: keep-alive' --data-binary '{"provider":"ca105028-37ac-4685-94ab-523f4233cb94","encounterRole":"9b135b19-7ebe-4a51-aea2-69a53f9383af"}' --compressed # Create EncounterProvider #1 response {"uuid":"450e8c53-08aa-49fb-83d9-b23b6190f8b3","provider":{"uuid":"ca105028-37ac-4685-94ab-523f4233cb94","display":"Dr. What - Dr What","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/provider/ca105028-37ac-4685-94ab-523f4233cb94","rel":"self"}]},"encounterRole":{"uuid":"9b135b19-7ebe-4a51-aea2-69a53f9383af","display":"Attending Surgeon","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounterrole/9b135b19-7ebe-4a51-aea2-69a53f9383af","rel":"self"}]},"voided":false,"links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/450e8c53-08aa-49fb-83d9-b23b6190f8b3?v=full","rel":"full"}],"resourceVersion":"1.9"} # Create EncounterProvider #2 request curl 'http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider' -H 'Origin: http://localhost:8080' -H 'Accept-Encoding: gzip, deflate, br' -H 'Accept-Language: en-US,en;q=0.8' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36' -H 'Content-Type: application/json;charset=UTF-8' -H 'Accept: application/json, text/plain, */*' -H 'Referer: http://localhost:8080/openmrs/labtrackingapp/labtrackingOrderDetails.page?orderUuid=6cd7334c-1a54-4ad7-b43b-9798630d82b0' -H 'Cookie: JSESSIONID=akohpj15pvtr; emr.lastSessionLocation=34; __openmrs_language=en_US' -H 'Connection: keep-alive' --data-binary '{"provider":"ce3679bd-be1a-4543-81a4-17b7928979bc","encounterRole":"6e630e03-5182-4cb3-9a82-a5b1a85c09a7"}' --compressed # Create EncounterProvider #2 response {"uuid":"61c03c2d-46a5-4d43-a49a-e31896f1ddb4","provider":{"uuid":"ce3679bd-be1a-4543-81a4-17b7928979bc","display":"Dr Who - Dr Who","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/provider/ce3679bd-be1a-4543-81a4-17b7928979bc","rel":"self"}]},"encounterRole":{"uuid":"6e630e03-5182-4cb3-9a82-a5b1a85c09a7","display":"Assisting Surgeon","links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounterrole/6e630e03-5182-4cb3-9a82-a5b1a85c09a7","rel":"self"}]},"voided":false,"links":[{"uri":"http://localhost:8080/openmrs/ws/rest/v1/encounter/be4c2e31-c1a0-408f-ac28-e36a23a34cfa/encounterprovider/61c03c2d-46a5-4d43-a49a-e31896f1ddb4?v=full","rel":"full"}],"resourceVersion":"1.9"}