{
  "resourceType": "Encounter",
  "meta": {
    "profile": [
      "https://fhir.nottinghamshire.gov.uk/STU3/StructureDefinition/CareConnect-SHD-Encounter-1"
    ]
  },
  "text": {
    "status": "additional",
    "div": "<div xmlns=\"http://www.w3.org/1999/xhtml\">An example of a SHD-Encounter used to cancel a Supported Discharge Referral</div>"
  },
  "contained": [
    {
      "resourceType": "Practitioner",
      "id": "shd-lead-clinician",
      "meta": {
        "profile": [
          "https://fhir.nottinghamshire.gov.uk/STU3/StructureDefinition/CareConnect-SHD-Practitioner-1"
        ]
      },
      "name": [
        {
          "use": "official",
          "text": "Ms Laura Clarke"
        }
      ]
    },
    {
      "resourceType": "Location",
      "id": "shd-location",
      "meta": {
        "profile": [
          "https://fhir.nottinghamshire.gov.uk/STU3/StructureDefinition/CareConnect-SHD-Location-1"
        ]
      },
      "name": "Ward 22",
      "managingOrganization": {
        "reference": "#shd-hospital"
      }
    },
    {
      "resourceType": "Organization",
      "id": "shd-hospital",
      "meta": {
        "profile": [
          "https://fhir.nottinghamshire.gov.uk/STU3/StructureDefinition/CareConnect-SHD-Organization-1"
        ]
      },
      "identifier": [
        {
          "system": "https://fhir.nhs.uk/Id/ods-site-code",
          "value": "RK5BC"
        }
      ],
      "name": "King's Mill Hospital"
    }
  ],
  "extension": [
    {
      "extension": [
        {
          "url": "medicallyFitStatus",
          "valueCoding": {
            "system": "https://fhir.nottinghamshire.gov.uk/STU3/codesystem/SHD-MedicallyFitStatus",
            "code": "01",
            "display": "Medically Fit"
          }
        },
        {
          "url": "dateDeemedMedicallyFit",
          "valueDateTime": "2019-01-30T10:56:00+00:00"
        }
      ],
      "url": "https://fhir.nottinghamshire.gov.uk/STU3/StructureDefinition/Extension-SHD-MedicallyFitDetails"
    }
  ],
  "identifier": [
    {
      "system": "http://fhir.sfht.nhs.uk/encounter/identifier",
      "value": "11a2d937-39d5-439e-bc6a-d5e586eSteve"
    }
  ],
  "status": "cancelled",
  "statusHistory": [
    {
      "extension": [
        {
          "url": "https://fhir.nottinghamshire.gov.uk/STU3/StructureDefinition/Extension-SHD-EncounterStatusChangeReason",
          "valueCodeableConcept": {
            "coding": [
              {
                "system": "https://fhir.nottinghamshire.gov.uk/STU3/codesystem/SHD-CancellationReason",
                "code": "08",
                "display": "Patient has died"
              }
            ],
            "text": "Patient has died"
          }
        }
      ],
      "status": "in-progress",
      "period": {
        "start": "2019-01-25T00:00:00+00:00",
        "end": "2019-02-01T00:00:00+00:00"
      }
    }
  ],
  "type": [
    {
      "coding": [
        {
          "system": "https://fhir.nottinghamshire.gov.uk/encounter/type",
          "code": "supported-discharge"
        }
      ]
    }
  ],
  "participant": [
    {
      "individual": {
        "reference": "#shd-lead-clinician"
      }
    }
  ],
  "period": {
    "start": "2019-01-25T00:00:00+00:00",
    "end": "2019-02-03T00:00:00+00:00"
  },
  "reason": [
    {
      "text": "Description of the reason why the patient was admitted to hospital"
    }
  ],
  "location": [
    {
      "location": {
        "reference": "#shd-location"
      }
    }
  ]
}