Examples
Dispenses
When a full dispense is registered, the dispensed medications are not registered. It is assumed that the prescribed medication has been sold to the patient.
Request
shellscript
curl --location -X POST 'http://localhost:8082/ePrescription/dispense/{eprescription_unique_id}' \
--header 'Authorization: Bearer acs:{bearer_token}' \
--header 'Content-Type: application/json'Response, when OK
shellscript
HTTP/200 OKResponse, if E-Prescription has already been fully dispensed before
shellscript
{
"error_code": "forbidden",
"message": "You aren't authorized to perform this operation.",
"trace": {
"Version": "00",
"TraceID": "f0a1839a35cefe06fd345dd39819a8d8",
"ParentID": "ec4b592d01c5d818",
"Flags": "00"
},
"cause": {
"StatusCode": 403,
"Message": "prescription has been already fully dispensed",
"Code": "unknown_error",
"Trace": {
"Version": "00",
"TraceID": "f0a1839a35cefe06fd345dd39819a8d8",
"ParentID": "8d0eed3790f120fa",
"Flags": "00"
}
}
}In the case of partial dispensing, both the referenced item in the e-prescription and the medication are added to the call.
Request
shellscript
curl --location -X POST 'http://localhost:8082/ePrescription/dispense/{eprescription_unique_id}' \
--header 'Authorization: Bearer acs:{bearer_token}' \
--header 'Content-Type: application/json' \
--data '[{"id":"2333266", "amount":1}]'Response
shellscript
HTTP/200 OKDispense of a substitute medication: When performing a partial dispense, use "substitute" and "substitute_id_type" (Values: {1:free text for extemporaneous prescriptions; 2:GTIN ;3:Pharmacode}) parameters.
Request
shellscript
curl --location -X POST 'http://localhost:8082/ePrescription/dispense/{eprescription_unique_id}' \
--header 'Authorization: Bearer acs:{bearer_token}' \
--header 'Content-Type: application/json' \
--data '[{"id":"2333266", "substitute":"2555546", "substitute_id_type":2, "amount":1}]'Response
shellscript
HTTP/200 OKDispense despite existing full dispense It is at the discretion of the pharmacist to dispense a medication despite the full delivery of an e-prescription. Usage of the force parameter:
Request
shellscript
curl --location -X POST 'http://localhost:8082/ePrescription/dispense/{erezept_unique_id}?force=true' \
--header 'Authorization: Bearer acs:{bearer_token}' \
--header 'Content-Type: application/json' \
--data '[{"id":"2333266", "amount":1}]'Response
shellscript
HTTP/200 OKSimultaneous dispensing of multiple medications with one call
Request
shellscript
curl --location -X POST 'http://localhost:8082/ePrescription/dispense/{erezept_unique_id}' \
--header 'Authorization: Bearer acs:{bearer_token}' \
--header 'Content-Type: application/json' \
--data '[{"id":"2333266", "amount":1}, {"id":"7680413141250", "amount":2}]'Response
shellscript
HTTP/200 OK