The At-Home Phlebotomy orders are composed of two different lifecycles, the Order lifecycle and the appointment lifecycle, detailed in the following sections.
As discussed in
Lab Test Lifecycle - Statuses,
each lab testing modality has the following format
[HIGH-LEVEL STATUS].[TEST MODALITY].[LOW-LEVEL STATUS]
For each modality, there can be multiple low-level status, for At Home Phlebotomy the possible low-level status are:
ordered: Vital received the order, stored it into our system, and started processing it asynchronously.
requisition_created: An order requisition form was validated and created with the partner laboratory, making the order available to be carried out.
appointment_scheduled: An appointment was scheduled or rescheduled for the order.
draw_completed: The phlebotomy appointment was completed and the blood was drawn successfuly.
appointment_cancelled: The appointment was cancelled, by either the patient, Vital or you.
partial_results: The laboratory has started making partial results available.
completed: The laboratory processed the blood sample and final results are available.
cancelled: The order was cancelled by either the patient, Vital or you.
The Finite State Machine that defines the possible transitions for the low-level statuses described above is illustrated in the following diagram.
Possible state transitions for the At-Home Phlebotomy Order low-level statuses.
orderedstate to the
requisition_createdstate, this must be manually triggered via the Vital Dashboard.
The appointment lifecycle is separate from the order lifecyle, and it corresponds to a single appointment. The possible status are defined as follows:
scheduled: An appointment was scheduled or rescheduled.
in-progress: The phlebotomist is in their way to the patient address.
cancelled: The appointment was cancelled by either the patient, Vital or you.
completed: The phlebotomy appointment was completed and the blood was drawn successfuly
The Finite State Machine that defines the possible transitions for the appointment statuses described above is illustrated in the following diagram.
Possible state transitions for the At-Home Phlebotomy Appointment statuses.
The events are related to a single appointment. An order can have multiple existing appointments in Vital system, although only one appointment will be considered active and returned when using the GET Appointment endpoint.