Any property in the "data" response payload can be used in the configured URL for the webhook.
Webhook parameters follow a standard curly brace style replacement syntax:
https://your-app.com/endpoint/?patient={patient_external_id}
The PainChek webhook system will match anything inside the {} with the corresponding property in the response payload's "data" object.
For example, if the payload was:
{ "event": "assessment_add", "data": { "uuid": "03824b1c-e7f4-4898-bc82-3ec7d39232f9", "patient": "9c2fa320-f080-4f2f-bc30-d5f2234c675e", "patient_external_id": "85352119-04e5-4549-8245-79c27e1cddda", "...": "..." } }
...the URL above would be transformed into this:
https://your-app.com/endpoint/?patient=85352119-04e5-4549-8245-79c27e1cddda
Using dot notation, the client can extract sub-property values as well. For example, the following is conceivably possible:
https://your-app.com/endpoint/?check={data.face.descriptors.brow_lowering}
If the payload was:
{ "event": "assessment_add", "data": { "uuid": "03824b1c-e7f4-4898-bc82-3ec7d39232f9", "patient": "9c2fa320-f080-4f2f-bc30-d5f2234c675e", "data": { "face": { "descriptors": { "brow_lowering": true, "cheek_raising": false, "...": "..." } } } } }
...the URL above would be transformed into this:
https://your-app.com/endpoint/?check=true