{
  "resourceType": "MedicationRequest",
  "id": "medrx0303",
  "contained": [
    {
      "resourceType": "Medication",
      "id": "med0311",
      "code": {
        "coding": [
          {
            "system": "http://snomed.info/sct",
            "code": "373994007",
            "display": "Prednisone 5 mg oral tablet"
          }
        ]
      }
    }
  ],
  "identifier": [
    {
      "use": "official",
      "system": "http://www.bmc.nl/portal/prescriptions",
      "value": "12345689"
    }
  ],
  "basedOn": [
    {
      "reference": "CarePlan/gpvisit"
    }
  ],
  "groupIdentifier": {
    "use": "official",
    "system": "http://www.bmc.nl/portal/prescriptions",
    "value": "983939393"
  },
  "status": "active",
  "intent": "order",
  "medication": {
    "reference": {
      "reference": "#med0311"
    }
  },
  "subject": {
    "reference": "Patient/pat1",
    "display": "Donald Duck"
  },
  "encounter": {
    "reference": "Encounter/f001",
    "display": "encounter who leads to this prescription"
  },
  "authoredOn": "2015-01-15",
  "requester": {
    "reference": "Practitioner/f007",
    "display": "Patrick Pump"
  },
  "note": [
    {
      "text": "Patient told to take with food"
    }
  ],
  "dosageInstruction": {
    "renderedInstruction": "Take 4 tablets daily for 7 days, then 2 tablets daily for 7 days, then 1 tablet daily for 7 days.",
    "step": [
      {
        "component": [
          {
            "text": "Take 4 tablets daily for 7 days starting January 16, 2015",
            "timing": {
              "repeat": {
                "boundsPeriod": {
                  "start": "2015-01-16",
                  "end": "2015-01-22"
                },
                "frequency": 1,
                "period": 1,
                "periodUnit": "d"
              }
            },
            "route": {
              "coding": [
                {
                  "system": "http://snomed.info/sct",
                  "code": "26643006",
                  "display": "Oral Route"
                }
              ]
            },
            "method": {
              "coding": [
                {
                  "system": "http://snomed.info/sct",
                  "code": "421521009",
                  "display": "Swallow - dosing instruction imperative (qualifier value)"
                }
              ]
            },
            "doseAndRate": [
              {
                "type": {
                  "coding": [
                    {
                      "system": "http://terminology.hl7.org/CodeSystem/dose-rate-type",
                      "code": "ordered",
                      "display": "Ordered"
                    }
                  ]
                },
                "doseQuantity": {
                  "value": 4,
                  "unit": "TAB",
                  "system": "http://terminology.hl7.org/CodeSystem/v3-orderableDrugForm",
                  "code": "TAB"
                }
              }
            ]
          }
        ]
      },
      {
        "component": [
          {
            "text": "Take 2 tablets daily for 7 days starting January 23, 2015",
            "timing": {
              "repeat": {
                "boundsPeriod": {
                  "start": "2015-01-23",
                  "end": "2015-01-29"
                },
                "frequency": 1,
                "period": 1,
                "periodUnit": "d"
              }
            },
            "route": {
              "coding": [
                {
                  "system": "http://snomed.info/sct",
                  "code": "26643006",
                  "display": "Oral Route"
                }
              ]
            },
            "method": {
              "coding": [
                {
                  "system": "http://snomed.info/sct",
                  "code": "421521009",
                  "display": "Swallow - dosing instruction imperative (qualifier value)"
                }
              ]
            },
            "doseAndRate": [
              {
                "type": {
                  "coding": [
                    {
                      "system": "http://terminology.hl7.org/CodeSystem/dose-rate-type",
                      "code": "ordered",
                      "display": "Ordered"
                    }
                  ]
                },
                "doseQuantity": {
                  "value": 2,
                  "unit": "TAB",
                  "system": "http://terminology.hl7.org/CodeSystem/v3-orderableDrugForm",
                  "code": "TAB"
                }
              }
            ]
          }
        ]
      },
      {
        "component": [
          {
            "text": "Take 1 tablets daily for 7 days starting January 30, 2015",
            "timing": {
              "repeat": {
                "boundsPeriod": {
                  "start": "2015-01-30",
                  "end": "2015-02-05"
                },
                "frequency": 1,
                "period": 1,
                "periodUnit": "d"
              }
            },
            "route": {
              "coding": [
                {
                  "system": "http://snomed.info/sct",
                  "code": "26643006",
                  "display": "Oral Route"
                }
              ]
            },
            "method": {
              "coding": [
                {
                  "system": "http://snomed.info/sct",
                  "code": "421521009",
                  "display": "Swallow - dosing instruction imperative (qualifier value)"
                }
              ]
            },
            "doseAndRate": [
              {
                "type": {
                  "coding": [
                    {
                      "system": "http://terminology.hl7.org/CodeSystem/dose-rate-type",
                      "code": "ordered",
                      "display": "Ordered"
                    }
                  ]
                },
                "doseQuantity": {
                  "value": 1,
                  "unit": "TAB",
                  "system": "http://terminology.hl7.org/CodeSystem/v3-orderableDrugForm",
                  "code": "TAB"
                }
              }
            ]
          }
        ]
      }
    ]
  },
  "dispenseRequest": {
    "validityPeriod": {
      "start": "2015-01-15",
      "end": "2016-01-15"
    },
    "numberOfRepeatsAllowed": 1,
    "quantity": {
      "value": 51,
      "unit": "TAB",
      "system": "http://terminology.hl7.org/CodeSystem/v3-orderableDrugForm",
      "code": "TAB"
    },
    "expectedSupplyDuration": {
      "value": 21,
      "unit": "days",
      "system": "http://unitsofmeasure.org",
      "code": "d"
    },
    "dispenser": {
      "reference": "Organization/f001"
    }
  },
  "substitution": {
    "allowedCodeableConcept": {
      "coding": [
        {
          "system": "http://terminology.hl7.org/CodeSystem/v3-substanceAdminSubstitution",
          "code": "TB",
          "display": "Therapeutic Brand"
        }
      ]
    },
    "reason": {
      "coding": [
        {
          "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason",
          "code": "FP",
          "display": "formulary policy"
        }
      ]
    }
  },
  "meta": {
    "tag": [
      {
        "system": "http://terminology.hl7.org/CodeSystem/v3-ActReason",
        "code": "HTEST",
        "display": "test health data"
      }
    ]
  }
}