createVirtualVisit

abstract fun createVirtualVisit(activity: FragmentActivity, patient: Patient, virtualVisitDetails: VirtualVisitDetails, paymentMethod: PaymentMethod, virtualActor: VirtualActor? = null, registerPushNotification: RegisterPushNotification? = null): DataObserver<Triple<VirtualVisitTypeName, String, Intent>>

Creates a new virtual visit.

Return

Triple(VirtualVisitTypeName, visitId, Intent). VirtualVisitTypeName - will be a String containing either phone or virtual The visitId can be saved and used later in a VirtualService.resumeVirtualVisit call if necessary (for example, if the user closes the app while in the waiting room or video conference). The Intent can be launched to start the virtual visit waiting room.

Parameters

activity

A FragmentActivity that can be used for the SDK to check for required permissions.

patient

A model containing information about the patient that will be receiving care.

virtualVisitDetails

A model containing additional information used to create the virtual visit.

paymentMethod

A PaymentMethod object containing the patient's payment information.

virtualActor

Optional, a VirtualActor object containing information about a parent or app user that is booking the visit for someone else. This is only required when VirtualVisitDetails.patientDeclaration is set to org.dexcare.services.models.PatientDeclaration.Other, and ignored otherwise.

registerPushNotification

A RegisterPushNotification object used to register the Android device for push notifications during the virtual visit. Optional, but highly recommended to be used.

abstract fun createVirtualVisit(fragment: Fragment, patient: Patient, virtualVisitDetails: VirtualVisitDetails, paymentMethod: PaymentMethod, virtualActor: VirtualActor? = null, registerPushNotification: RegisterPushNotification? = null): DataObserver<Triple<VirtualVisitTypeName, String, Intent>>

Creates a new virtual visit.

Return

Triple(VirtualVisitTypeName, visitId, Intent).

  • VirtualVisitTypeName - will be a String containing either phone or virtual The visitId can be saved and used later in a VirtualService.resumeVirtualVisit call if necessary (for example, if the user closes the app while in the waiting room or video conference). The Intent can be launched to start the virtual visit waiting room.

Parameters

fragment

A Fragment that can be used for the SDK to check for required permissions.

patient

A model containing information about the patient that will be receiving care.

virtualVisitDetails

A model containing additional information used to create the virtual visit.

paymentMethod

A PaymentMethod object containing the patient's payment information.

virtualActor

Optional, a VirtualActor object containing information about a parent or app user that is booking the visit for someone else. This is only required when VirtualVisitDetails.patientDeclaration is set to org.dexcare.services.models.PatientDeclaration.Other, and ignored otherwise.

registerPushNotification

A RegisterPushNotification object used to register the Android device for push notifications during the virtual visit. Optional, but highly recommended to be used.