{
  "resourceType": "SubscriptionTopic",
  "id": "admission",
  "extension": [
    {
      "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
      "valueCode": "fhir"
    }
  ],
  "url": "http://example.org/FHIR/SubscriptionTopic/admission",
  "identifier": [
    {
      "system": "urn:ietf:rfc:3986",
      "value": "urn:uuid:915c2040-b0a8-4935-adf8-94d6e1a74052"
    }
  ],
  "title": "admission",
  "status": "active",
  "publisher": "HL7 International / FHIR Infrastructure",
  "contact": [
    {
      "telecom": [
        {
          "system": "url",
          "value": "http://www.hl7.org/Special/committees/fiwg"
        }
      ]
    }
  ],
  "description": "Example admission topic",
  "trigger": [
    {
      "description": "Encounter resource moving to state \u0027in-progress\u0027 or event matching HL7v2 ADT^A01",
      "resource": "http://hl7.org/fhir/StructureDefinition/Encounter",
      "supportedInteraction": [
        "create",
        "update"
      ],
      "queryCriteria": {
        "previous": "status:not\u003din-progress",
        "resultForCreate": "test-passes",
        "current": "status\u003din-progress",
        "resultForDelete": "test-fails",
        "requireBoth": true
      },
      "fhirPathCriteria": "(%previous.id.empty() or (%previous.status !\u003d \u0027in-progress\u0027)) and (%current.status \u003d \u0027in-progress\u0027)",
      "event": {
        "coding": [
          {
            "system": "http://terminology.hl7.org/CodeSystem/v2-0003",
            "code": "A01",
            "display": "ADT/ACK - Admit/visit notification"
          }
        ]
      },
      "canFilterBy": [
        {
          "description": "Matching based on the Patient (subject) of an Encounter or based on the Patient\u0027s group membership (in/not-in).",
          "resource": "Encounter",
          "filterParameter": "patient",
          "modifier": [
            "in",
            "not-in"
          ]
        }
      ],
      "notificationShape": [
        {
          "resource": "Encounter",
          "include": [
            "Encounter:patient",
            "Encounter:practitioner",
            "Encounter:service-provider",
            "Encounter:account",
            "Encounter:diagnosis",
            "Encounter:observation",
            "Encounter:location"
          ]
        }
      ]
    }
  ]
}