> ## Documentation Index
> Fetch the complete documentation index at: https://docs.connectivehealth.io/llms.txt
> Use this file to discover all available pages before exploring further.

# MedicationDispense

> The FHIR MedicationDispense resource as produced by Connective Health

[FHIR R4 MedicationDispense](https://www.hl7.org/fhir/R4/medicationdispense.html) ·
[US Core MedicationDispense](https://hl7.org/fhir/us/core/STU9/StructureDefinition-us-core-medicationdispense.html)

<Info>
  This resource is currently only produced for the [Bulk Medication History](/fhir/bulk-medication-history-bundle) bundle.
</Info>

# Stable ID

The `id` is derived from the patient, last filled date, sold date, product code, drug description, directions,
strength, and days supply. If a subsequent request contains a record with all of the same values, it resolves to
the same `MedicationDispense`.

# Fields

| Field                                                                                                                  | Cardinality | Notes                                                                                                                                                                              |
| ---------------------------------------------------------------------------------------------------------------------- | ----------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `meta.profile`                                                                                                         | 1..1        | Always set to the US Core MedicationDispense profile URL.                                                                                                                          |
| `status`                                                                                                               | 1..1        | Always `completed` -- this bundle only represents historical fill records, so no other status is used.                                                                             |
| `subject`                                                                                                              | 1..1        | Reference to the [Patient](/fhir/resources/patient).                                                                                                                               |
| `authorizingPrescription`                                                                                              | 1..1        | Reference to the corresponding [MedicationRequest](/fhir/resources/medication-request).                                                                                            |
| `medication`                                                                                                           | 1..1        | Reference to the same [Medication](/fhir/resources/medication) resource referenced by the `MedicationRequest`.                                                                     |
| `location`                                                                                                             | 1..1        | Reference to the dispensing pharmacy's [Location](/fhir/resources/location).                                                                                                       |
| `daysSupply`                                                                                                           | 0..1        | Populated when the source days-supply value is a valid number.                                                                                                                     |
| `dosageInstructionFirstRep.text`                                                                                       | 0..1        | The source free-text directions (same value as on the `MedicationRequest`).                                                                                                        |
| Extension: [refillsRemaining](http://hl7.org/fhir/StructureDefinition/medicationdispense-refillsRemaining)             | 0..1        | An integer, populated when the source refills value is a valid number.                                                                                                             |
| Extension: Connective Health drug class (`https://fhir.connectivehealth.io/medhistory/StructureDefinition/drug-class`) | 0..\*       | One repetition per drug class associated with the medication's NDC code, looked up from a reference data set. This is a Connective Health-specific extension, not part of US Core. |
| `whenPrepared`                                                                                                         | 0..1        | The source last-filled date.                                                                                                                                                       |
| `whenHandedOver`                                                                                                       | 0..1        | The source sold date.                                                                                                                                                              |
