HL7 ORP messages acknowledge or respond to a pharmacy or treatment order (OMP). An ORP message is sent from the pharmacy information system (PIS) back to the ordering application (such as an EHR or clinical system) to confirm that a medication prescription or treatment order has been received, verified, filled, or rejected by the pharmacist. This page explains what an ORP message represents, the trigger event that carries it, every segment the message can contain and what each one holds, and how an ORP response relates to FHIR. Sample content is constructed for illustration with fictional identifiers.
What an ORP message represents
An ORP message — ORP stands for Pharmacy/Treatment Order Response — communicates a pharmacy system's response to a medication order. The core of the message is the MSA segment, which provides the transaction-level acknowledgement status, and one or more repeating ORDER groups containing an echoed RXO segment to identify the specific medication ordered, its dosage, and administration instructions.
The sender is the pharmacy information system (PIS) or dispensing application, and the receiver is the clinical application or EHR that placed the medication order. The ORP message acts as the matching response in a request-response exchange: the clinician orders a medication using an OMP^O09, and the pharmacy returns an ORP^O10 to confirm that the medication order has been accepted and added to the patient's active pharmacy profile.
When an ORP message is sent
An ORP message is sent after a pharmacy information system processes a medication order. It fires when the pharmacy system validates the medication code, checks for clinical drug-drug interactions, confirms the patient's billing data, and accepts or rejects the order.
Trigger event
The ORP message type carries a single trigger event:
ORP^O10– Pharmacy/Treatment Order Response message.
The trigger O10 pairs with the OMP^O09 pharmacy order. The receiving application matches the response to the original order using the placer order number in ORC-2 and the message control ID echoed in MSA-2.
Integration topology
The diagram shows the pharmacy system returning an order response through the integration engine to the clinical system that placed the order.
{{diagram: pharmacy system → ORP message → integration engine → clinical system (EHR)}}
Typical senders: pharmacy information system (PIS), pharmacy dispensing application, inpatient pharmacy software.
Typical receivers: EHR, clinical order entry system, computerized physician order entry (CPOE) terminal.
Direction: response in a request-response pattern — the pharmacy system responds to the ordering system's medication order.
Segments in an ORP message
The ORP_O10 message opens with a header block (MSH, MSA, and optional ERR segments) followed by optional patient/visit context and one or more repeating ORDER groups. Cardinality follows HL7 notation: [X] optional, {X} repeating, [{X}] optional and repeating; a bare code is required. Each segment code links to its canonical field-by-field reference.
| Segment | Description |
|---|---|
MSH | Message Header. Opens every ORP message. It names the sending and receiving applications, stamps the creation time, declares the trigger event in MSH-9 (ORP^O10), carries the message control id in MSH-10, and pins the HL7 version. |
MSA | Message Acknowledgement. Required. Echoes the original OMP message control id in MSA-2 and carries the acknowledgement code (e.g., AA accepted, AE error). |
[{ERR}] | Error. Details validation or application errors encountered when processing the medication order. Optional and repeating. |
[{NTE}] | Notes and Comments. Header-level comments or text notes. Optional and repeating. |
[PID] | Patient Identification. Patient associated with the pharmacy order. Optional. |
[PV1] | Patient Visit. Encounter details related to the patient. Optional. |
ORC | Common Order. Opens each ORDER group. It carries the order status, the placer order number, and the filler order number (assigned by the pharmacy system). Required within each repeating order group. |
[{TQ1}] | Timing/Quantity. Timing and frequency schedule for the medication administration. Optional and repeating. |
RXO | Pharmacy/Treatment Order. Echoes the medication detail from the request: the medication name/code, dose, units, and route. Required. |
[{RXR}] | Pharmacy Route. The route of administration (e.g., oral, intravenous). Optional and repeating. |
[{RXC}] | Pharmacy Component. Details of drug components or ingredients for compound orders. Optional and repeating. |
[{NTE}] | Notes and Comments (Line). Comments or pharmacist instructions for this specific medication line. Optional. |
[ ] = optional, { } = repeating
Sample ORP message
Note. Constructed for illustration. Medication codes, order numbers, and patient identifiers are fictional.
MSH|^~&|PHARMSYS|MERCY|EHRSYS|MERCY|20260604090000||ORP^O10^ORP_O10|MSG00048|P|2.5.1
MSA|AA|MSG00047
PID|1||MR98765^^^MERCY^MR||SMITH^PATRICIA^A||19720315|F
ORC|OK|REQ20260604-003^EHRSYS|FIL20260604-003^PHARMSYS||||||20260604090000|||ATT001^JONES^CAROL^^^^MD
RXO|500^Amoxicillin^L|500|mg|capsule|oral|QD
RXR|PO^Oral^HL70162
NTE|1||Order verified by pharmacist; dispensing active.
What this sample shows
The ORP^O10 in MSH-9 marks a pharmacy order response. MSA carries acknowledgement code AA (Application Accept) and acknowledges the original request control ID MSG00047. PID associates the response with patient MR98765. ORC carries order status OK (Order Accepted), links to placer order number REQ20260604-003, and supplies the pharmacy filler order number FIL20260604-003. The RXO echoes the medication Amoxicillin, dose 500 mg, capsule form. RXR specifies route PO (Oral). The NTE confirms that the order has been verified.
Working with ORP messages
Matching and Verification
When an ORP response is received, the ordering system correlates MSA-2 with the outbound request. The placer order number in ORC-2 is used to match individual lines. This correlation is essential for clinical staff to verify that the pharmacy has reviewed and verified the order before administration begins.
Handling Pharmacist Rejections
If a pharmacist rejects an order (due to duplicate therapy, contraindications, or dosage errors), ORC-5 will carry a status of UA (Unable to Accept) or RE (Rejected), and the message will carry explanatory details in NTE or ERR. Receiving applications should process these status updates to alert the prescribing physician, ensuring that drug therapies are updated or corrected.
Vendor variance. Pharmacy systems differ in how they communicate pharmacist modifications. Some systems return an ORP message showing a status of
SC(Status Changed) orA(Accepted with modifications) and update the medication dosage fields in the echoedRXOsegment. Prescribing EHRs must compare the echoedRXOsegment with their original request to detect pharmacist adjustments.
FHIR equivalent
A pharmacy order response maps conceptually to status changes on the FHIR MedicationRequest resource, representing updates to the status field (e.g. from draft to active or completed).
The HL7 v2-to-FHIR Implementation Guide publishes no message map for ORP_O10 and no ConceptMap for the RXO segment. Consequently, any FHIR translation must be mapped manually, using MSA-2 and ORC-2 to locate the existing MedicationRequest resource and updating its status or adding pharmacy filler identifiers as identifier elements.
Common pitfalls
Pitfall. Assuming the order is active without checking
ORC-5orMSA-1. Presuming pharmacy acceptance on an error or rejection response can lead to clinical staff attempting to administer medication that was never dispensed.
Pitfall. Overlooking pharmacist modifications. Ignoring updates in the echoed
RXOsegment can result in the EHR displaying the doctor's original requested dose while the pharmacy is dispensing a modified dose.
How Vorro handles ORP messages
Vorro ingests ORP responses over MLLP, validates the application acknowledgement code in MSA, and correlates each response to its originating OMP request. Vorro updates the status of the medication line items in the ordering EHR based on ORC-5 (Order Status) and passes through the pharmacy filler order number from ORC-3. Where a FHIR destination is configured, Vorro updates the corresponding MedicationRequest resource state manually, since the HL7 v2-to-FHIR guide provides no published map for this message.
Related messages
- OMP — the pharmacy order message that initiates this response.
- RDS — the pharmacy dispense message.
- RAS — the pharmacy administration message.
