Webhook Events
Webhooks can subscribe to various events that trigger requests to your endpoints.
You can setup as many webhook endpoints as you need. Each endpoint can subscribe to one or more events. Therefore you could have one endpoint that handles all events or a separate one for each.
Available Events
We will make a HTTP request to your webhook endpoint/s when any of the following events occur. All are optional, but there must be at least one per endpoint to trigger requests.
Claims:
Event Name | Description |
---|---|
claim.created | When a claim is created. |
claim.closed | When a claim's status becomes "closed". |
claim.reopened | When a claim's status becomes "open", after previously being "closed". |
claim.label_added | When a label is added to a claim. |
claim.label_removed | When a label is removed from a claim. |
claim.assigned | When a claim is assigned to a user. |
claim.unassigned | When a claim is unassigned and is no longer assigned to anyone. |
claim.switched_type | When the claim's type is changed. |
Contacts:
Event Name | Description |
---|---|
contact.created | When a contact is created. |
Contact Support to Setup Your Webhook Endpoints
Please contact us via the support chat or email [email protected] to request one or more webhook endpoints to be configured on your account. For each endpoint, please provide the following information:
- The URL of your endpoint. And;
- The events you'd like it to be subscribed to.
Webhook Request Payload
When we send a request to one of your webhook endpoints, we include information about what triggered the event, in both the JSON payload as an event_name
attribute and as a HTTP Header called Event-Name
.
In the response payload we also include metadata about who trigger the event and whether it was via the API or user interface.
Event Metadata Attributes
For every request we make to one of your webhook endpoints, we include the object that is the subject of the event (e.g. claim, contact) in addition to the following metadata:
Attribute | Body / Header | Description |
---|---|---|
event_name | Body + Header | Describes the event that occurred to trigger the webhook request. The value will be one of the strings listed in the table of events above. |
source | Body | Either "ui", meaning a user triggered the event through the user interface, or "api" which means the event is the result of an API call. |
performed_by | Body | If source is "ui", we include performed_by.user_id and performed_by.name attributes to describe the user who performed the event.If source is "api" only performed_by.name is included which refers to the name of the API token used to perform the action. |
Examples of JSON Payload
For the claim webhook event "claim.assigned", performed by a user via the UI:
{
"claim": {...} // Claim object
"event_name": "claim.assigned",
"source": "ui",
"performed_by":
"user_id": 2642
"name": "John Smith"
}
}
For the claim webhook event "claim.created", performed via the API:
{
"claim": {...} // Claim object
"event_name": "claim.created",
"source": "api",
"performed_by":
"name": "Mobile App API Token"
}
}
For the contact webhook event "contact.created", performed by a user via the UI:
{
"contact": {...} // Contact object
"event_name": "contact.created",
"source": "ui",
"performed_by":
"user_id": 2642
"name": "John Smith"
}
}
Example of HTTP Header
For the claim webhook event "claim.created":
Event-Name: "claim.created"
Updated about 1 year ago