Encounter

Introduction #

The Encounter model represents a patient encounter connected to a Note in Canvas.

Basic usage #

To get an encounter by identifier, use the get method on the Encounter model manager:

from canvas_sdk.v1.data import Encounter

encounter = Encounter.objects.get(id="b80b1cdc-2e6a-4aca-90cc-ebc02e683f35")

To get an encounter from a note, use the encounter attribute on the Note object:

from canvas_sdk.v1.data import Note

note = Note.objects.get(id="1eed3ea2a8d546a1b681a2a45de1d790")
encounter = note.encounter

Keep in mind that not all notes have an associated encounter, so sometimes note.encounter will be None.

Similary, you can get a note from an Encounter object by using the note attribute:

from canvas_sdk.v1.data import Encounter

encounter = Encounter.objects.get(id="b80b1cdc-2e6a-4aca-90cc-ebc02e683f35")
note = encounter.note

All encounters will have an associated note, which means encounter.note will never be None.

Filtering #

Encounters can be filtered by any attribute that exists on the model.

Filtering for encounters is done with the filter method on the Encounter model manager.

By attribute #

Specify an attribute with filter to filter by that attribute:

from canvas_sdk.v1.data.encounter import Encounter, EncounterState

encounters = Encounter.objects.filter(state=EncounterState.CONCLUDED)

Attributes #

Encounter #

Field NameType
idUUID
dbidInteger
createdDateTime
modifiedDateTime
noteNote
stateEncounterState
mediumEncounterMedium
start_timeDateTime
end_timeDateTime

Enumeration types #

EncounterState #

NameValue
STARTEDSTA
PLANNEDPLA
CONCLUDEDCON
CANCELLEDCAN

EncounterMedium #

NameValue
VOICEvoice
VIDEOvideo
OFFICEoffice
HOMEhome
OFFSITEoffsite
LABlab