Summary of Encounter Interactions

The API exposes three FHIR interactions:

  1. Encounter Search by PHN or Encounter Search by PHN with Date Filters
  2. Encounter Search by ID
  3. Encounter Read

Encounter Search by PHN


FHIR Interaction: ?

HTTP Method: GET

URL: [base]/Encounter?Patient=[BC PHN]


Parameters (In)

Name Cardinality Type Documentation
Patient 1..1 id Patient's BC PHN

Optionally, date filters can be used along with encounter search by PHN. For details, refer to Encounter Search by PHN with Date Filters.

Return Values (Out)

Name Cardinality Type Documentation
bundle 1..1 Bundle A Bundle consists of a list of Encounter resources and/or an OperationOutcome.

This transaction performs the FHIR search interaction using the patient's BC PHN. The query response is a Bundle containing one or more Encounter resources and/or an OperationOutcome. Each Encounter resource contains patient encounter details in the eHealth clinical data repository.

An example of read request and responses:

 [base]/Encounter?Patient=9698656164

Sample response

Encounter Search by PHN with Date Filters


FHIR Interaction: ?

HTTP Method: GET

URL: [base]/Encounter?Patient=[BC PHN]&date=[date prefix][date1]&date=[date prefix][date2]


Parameters (In)

Name Cardinality Type Documentation
Patient 1..1 id Patient's BC PHN
date 0..2 date FHIR date with a date prefix

Return Values (Out)

Name Cardinality Type Documentation
bundle 1..1 Bundle A Bundle consists of a list of Encounter resources and/or an OperationOutcome.

This transaction performs the FHIR search interaction using the patient's BC PHN and optional one or two date filter(s). The query response is a Bundle containing one or more Encounter resources and/or an OperationOutcome. Each Encounter resource contains patient encounter details in the eHealth clinical data repository.

Supported FHIR date prefixes

Prefix Single Date Range
eq the value for the parameter in the resource is equal to the provided value the range of the search value fully contains the range of the target value
gt the value for the parameter in the resource is greater than the provided value the range above the search value intersects (i.e. overlaps) with the range of the target value
lt the value for the parameter in the resource is less than the provided value the range below the search value intersects (i.e. overlaps) with the range of the target value
ge the value for the parameter in the resource is greater or equal to the provided value the range above the search value intersects (i.e. overlaps) with the range of the target value, or the range of the search value fully contains the range of the target value
le the value for the parameter in the resource is less or equal to the provided value the range below the search value intersects (i.e. overlaps) with the range of the target value or the range of the search value fully contains the range of the target value

Note. If one date was supplied, the service would auto fill in the end date with the max date time value which is 9999-12-3123:59:59.9999999. When there is no date prefix provided for a date filter, “eq” is used.

An example of read request and responses:

 [base]/Encounter?Patient=9698656164&date=gt2021-04-01&date=lt2021-04-30

Sample response

Encounter Search by ID


FHIR Interaction: _id

HTTP Method: GET

URL: [base]/Encounter?_id=[Encounter.id]


Parameters (In)

Name Cardinality Type Documentation
id 1..1 id Encounter resource id

Return Value (Out)

Name Cardinality Type Documentation
bundle 1..1 Bundle A Bundle consists of a Encounter resource and/or an OperationOutcome.

This transaction takes the resource id as the parameter and returns an Encounter and or OperationOutcome in a Bundle. The Encounter resource contains details of the patient encounter in the eHealth clinical data repository.

An example of search request and responses:

[base]/Encounter?_id=cdr.9698656164.3ebf0827-5232-4677-9599-50df7b81fff5

Sample response

Encounter Read


FHIR Interaction: /

HTTP Method: GET

URL: [base]/Encounter/[Encounter.id]


Parameters (In)

Name Cardinality Type Documentation
[Encounter.id] 1..1 id Encounter resource ID

Return Values (Out)

Name Cardinality Type Documentation
Encounter 0..1 Encounter Encounter resource
OperationOutcome 0..1 OperationOutcome OperationOutcome

This transaction performs the FHIR read interaction on the resource based on resource.id. The query response is one of the resources: Encounter containing details of the encounter in the eHealth clinical data repository, or an OperationOutcome containing errors or warnings from the interaction.

An example of read request and responses:

 [base]/Encounter/cdr.9698656164.3ebf0827-5232-4677-9599-50df7b81fff5

Sample response