Webhooks allow you to be notified on your server when certain events happen, rather than having to poll our API all the time. For more info on webhooks in general see working with webhooks

Subscribe to Webhooks and HTTP request configuration

When subscribing to a webhook, the following can be configured:

  • URL: the URL the webhook notification will be sent to
  • HTTP HEADERS: Additional custom headers to be sent as part of the HTTP request (this can be used to perform authentication)

🖥️

Configuring

You can configure webhooks through the partner portal under the developer section.

Retries

Failed notifications are retried up to a maximum of 30 times.
The backoff delay is 5000 milliseconds multiplied by the number of retries.

Objects

Webhooks are available for the following Objects and Events:

Orders

Webhooks fire as a customer order transitions through each order state (dispatched, delivered, etc.)

Event NameDescriptioneventType
Order createdOrder has been createdORDER.CREATED
Order dispatchedOrder has been dispatchedORDER.DISPATCHED
Order out for deliveryOrder is out for delivery (Note: this is subject to shipping method)ORDER.OUT_FOR_DELIVERY
Order deliveredOrder delivered to customer (Note: this is subject to shipping method)ORDER.RECEIVED
Order return out for deliveryOrder has been returned by customer and is out for delivery to lab (Note: this is subject to shipping method)ORDER.RETURN_OUT_FOR_DELIVERY
Order return deliveryOrder delivered from customer to lab (Note: this is subject to shipping method)ORDER.RETURN_RECEIVED

Phlebotomy

Webhooks fire as a customer phlebotomy order transitions through each state (nurse assigned, appointment scheduled, etc.)

Event NameDescriptioneventType
Nurse assignedNurse has been assigned (Mobile Phlebotomy Only)PHLEBOTOMY.NURSE_ASSIGNED
Appointment scheduledAppointment has been scheduledPHLEBOTOMY.APPOINTMENT_SCHEDULED
Appointment rescheduledAppointment has been rescheduledPHLEBOTOMY.APPOINTMENT_RESCHEDULED
Appointment cancelledAppointment has been cancelledPHLEBOTOMY.APPOINTMENT_CANCELLED
Appointment completedAppointment has been completedPHLEBOTOMY.APPOINTMENT_COMPLETED

Tests

Webhooks fire as a customer test transitions through the each testing state (registered, received by the lab, resulted, etc.)

Event NameDescriptioneventType
Test registeredTest has been registered by patientTEST.REGISTERED
Test received at labTest has been received by the labTEST.LAB_ACCESSIONED
Test results readyLab test results are readyTEST.PROCESSED
Test commentary uploadedA clinical commentary has been uploadedTEST.CLINICAL_COMMENTARY_UPLOADED

📘

Full webhook event schemas

View event schemas for the full details of each webhook.

🚧

Improving security

Check out Security section for more details on how to keep your implementation secure.