Query
Description
The Query event type can be used to search for orders based on specified filter criteria. The response for this query is expected to be in the Order:QueryResponse event type format. The required elements and populated response may vary depending on the specific EHR system being integrated with.
API endpoints for Order Query
Sync REST API Endpoint to call the API: https://{base_url}/api/v1/order/query.
Async REST API Endpoint to call the API: https://{base_url}/api/v1/endpoint.
Data Model JSON for Query
Query - Sample Payload
{
"Meta": {
"DataModel": "Order",
"EventType": "Query",
"EventDateTime": "2022-08-16T14:21:20.733Z",
"Test": true,
"Destinations": [
{
"ID": "2fca1ee7-8582-4192-bc91-5a20fcf19d60",
"Name": "Destinations EMR"
}
],
"Logs": [
{
"ID": "5016388a-856a-4657-844e-8ab98c217268",
"AttemptID": "44fa157d-a48c-47cc-b309-ae042d146999"
}
],
"FacilityCode": null
},
"Patients": [
{
"Identifiers": [
{
"ID": "0000000001",
"IDType": "MR"
},
{
"ID": "3570592f-f859-496b-b1b1-b03bb7172d18",
"IDType": "EHRID"
},
{
"ID": "02698f4b-5187-4fc7-8b91-a7a86d931ff4",
"IDType": "NIST"
}
]
}
],
"VisitNumbers": [],
"StartDateTime": "2020-05-05T06:00:00.000Z",
"EndDateTime": "2020-05-05T07:00:00.000Z",
"OrderIDs": [
"157965300"
],
"Procedures": [
{
"Code": "49086-2",
"Codeset": null
}
]
}