Fires when a prescription data record is transmitted to the pharmacy. targetEntity is the PrescriptionFulfillment. Categories: PRESCRIPTION, PHARMACY. The eventType is prescription_sent_to_pharmacy.
Field guarantees
| Field | Guarantee |
|---|---|
eventData.pharmacy, eventData.affiliate | ✅ Always present (v1) |
pharmacy_id in v2 | ✅ Always present (pharmacy aliases to pharmacy_id) |
v1 payload (legacy)
ownerEntity is the full patient document (contains PHI); abbreviated here.
{
"ownerEntityModel": "Patient",
"targetEntityModel": "PrescriptionFulfillment",
"deleted": false,
"ownerEntity": { "id": "pat::74cb56c2-xxxx-xxxx-xxxx-5bf3ba2737aa", "firstName": "<PATIENT_FIRST_NAME>", "lastName": "<PATIENT_LAST_NAME>", "…": "full patient document" },
"targetEntity": {
"status": "completed",
"prescription": "prescr::85a93377-xxxx-xxxx-xxxx-91cf715d2e57",
"order": "order::b6b288b5-xxxx-xxxx-xxxx-074dcdbfc4b2",
"id": "prfm::8579e3c2-xxxx-xxxx-xxxx-424c82e68945"
},
"eventTitle": "Prescription Data Record Sent To Pharmacy",
"eventDescription": "Prescription data record for \"<PRODUCT_NAME>\" was sent to the \"<PHARMACY_NAME>\" pharmacy.",
"eventType": "prescription_sent_to_pharmacy",
"eventData": {
"pharmacy": "phar::4c1228bf-xxxx-xxxx-xxxx-f62157e57e9c",
"affiliate": "aff::c1636be3-xxxx-xxxx-xxxx-9dddc26e77b3"
},
"createdAt": "2023-06-12T22:00:16.876Z",
"updatedAt": "2023-06-12T22:00:16.876Z",
"__v": 0,
"id": "event::04304618-xxxx-xxxx-xxxx-e9451fe604eb"
}eventData field | Type | Always? | Notes |
|---|---|---|---|
pharmacy | string | ✅ | Pharmacy id the record was sent to |
affiliate | string | ✅ | Affiliate id |
v2 payload
Sanitized envelope. pharmacy aliases to pharmacy_id (on the PHARMACY allowlist); affiliate is surfaced as the top-level affiliate_id. order_id/commerce_status resolve from the fulfillment's order.
{
"event_type": "prescription_sent_to_pharmacy",
"event_id": "event::04304618-xxxx-xxxx-xxxx-e9451fe604eb",
"api_version": "2026-08-09",
"timestamp": "2026-05-30T14:00:00.000Z",
"affiliate_id": "aff::c1636be3-xxxx-xxxx-xxxx-9dddc26e77b3",
"patient_id": "pat::74cb56c2-xxxx-xxxx-xxxx-5bf3ba2737aa",
"patient_external_id": "ext-patient-123",
"patient_marketing_consent": false,
"is_returning_patient": true,
"pharmacy_id": "phar::4c1228bf-xxxx-xxxx-xxxx-f62157e57e9c",
"order_id": "order::b6b288b5-xxxx-xxxx-xxxx-074dcdbfc4b2",
"commerce_status": "requires_order_processing"
}| Field | Delivered in v2 | Notes |
|---|---|---|
| Envelope + patient identity | ✅ | |
pharmacy_id | ✅ | From eventData.pharmacy |
order_id, commerce_status | ✅ | From the fulfillment's order |
