Awell Health Developer Hub
Dev Hub

We recommend reading more about "Awell Hosted Pages" first before moving on.

This mutation starts a pathway or care flow first and immediately creates a session for the patient stakeholder. If you want to create a Hosted Pages session for an ongoing pathway, have a look at the Start Hosted Pages session mutation.

Use cases

There are use cases, like onboarding and intake flows, where you might want a stakeholder (e.g. a patient) to start a care flow themselves and immediately let them complete activities in their care flows.

Example: a patient visits your website and there's a button to start an onboarding flow. Clicking the button should both start a care flow and immediately allow the patient to complete activities in that care flow.

Request

Mutation

01

Required variables

pathway_definition_id specifies what pathway definition needs to be started.

01

Optional variables

Patient

Every careflow is linked to a patient in Awell. Patients are uniquely identified in Awell by their Awell patient ID and the (business) identifier systems you configured in your tenant. Learn more about identifiers here.

You can pass in patient_id (Awell patient ID) or patient_identifier (business identifier) to start a care flow for an existing patient. If both are passed in, only patient_id will be used.

When you are passing the Awell patient ID:

01

When you are passing a business identifier:

01

If no patient_id or patient_identifier is provided, we create an anonymous patient. Have a look at the createPatient mutation if you don't have a patient created yet and need to create one first.

Data points (baseline info)

You have the ability to pass some initial data when starting a pathway. What data you can pass on pathway start needs to be configured in Awell Studio via the settings (see Pathway > Settings > General).

When your baseline data points are configured and your pathway is published, you can query the available baseline data points via the publishedPathwayDefinitions query.

There are required and optional baseline data points. A pathway will not be started until all required baseline data points have a value.

Passing baseline info is as easy as providing an array of objects in the following format:

01

Success and cancel URL

The success_url and cancel_url specify where the stakeholder should be redirected to when the care flow/pathway session is completed or canceled/interrupted respectively. If success_url and cancel_url are not specified, then static success and cancel pages will be shown in the Hosted Pages application.

01

Language

Languages should be passed as an ISO 639-1 shortcode.If no language is passed, it defaults to English.

01

Awell Hosted Pages is currently available in the following languages:

  • English (en)
  • Dutch (nl)
  • Estonian (et)
  • French (fr)
  • Romanian (ro)
  • Spanish (es)
  • Russian (ru)

Session expiration

A session expires after 60 minutes but the timer is reset after every completion of an activity. A session also expires when there are no pending activities left in a pathway.

How to use