Calry Webhooks
Get notified of any changes to the Calry system.
Overview​
Calry Webhooks are designed to notify you of any changes within the Calry system, ensuring you stay informed about key system events, such as Data Syncs, Calry Link status, Integration Account status etc.
In this guide, you'll learn how to add and manage these webhooks. Webhooks will come in the form of inbound POST requests to your API, which you can use to trigger the creation, update, or deletion of data in your system to mirror some event in Calry, or any other action you want - you are only limited by the code you can write.
Adding a webhook​
To create webhooks, go to the Webhooks management console in your Calry left side bar and click Webhook.
Enable the webhook by clicking the left toggle button.
Click on the Add Endpoint button on the top right to add a new endpoint.
On the next page, add the endpoint name, add the URL that you want Calry to send a POST request to. This URL should point to a POST route in your API that you'll build to handle the incoming payload.
Make sure to select the event types that you want to trigger the webhook.
Create the endpoint by clicking the Create button.
Your endpoint will now be listed in the Webhooks management console. You can edit or delete the endpoint by clicking the respective buttons.
System Events​
Events that are triggered by changes to the Calry system, such as when a user links an account, or when a user's data is updated.
account.created
- A integration account has been created.account.updated
- A integration account has been updated.account.deleted
- A integration account has been deleted.link.created
- A link has been created.link.updated
- A link has been updated.link.deleted
- A link has been deleted.sync.complete
- A sync has been completed.sync.error
- A sync has been errored.sync.paused
- A sync has been paused.
Payload Properties​
The payload that Calry sends to your webhook endpoint will contain the following properties:
hook
- Objectid
- string- The ID of the webhook that was triggered.
timestamp
- string- The date and time that the webhook was triggered.
eventType
- string- The type of event that triggered the webhook.
source
- string- The source of the webhook that was triggered. [CALRY_WEBHOOK]
data
- Object- integrationAccountId - string
- The unique identifier for the Integration Account.
- workspaceId - string
- The unique identifier for the Workspace.
- result - SUCCESS | FAILURE
- The result of the event that triggered the webhook.
- integrationAccountId - string
Example Payloads​
{
"data": {
"integrationAccountId": "4a905074-4dd9-426a-b5a9-cf7c9bb33034",
"result": "SUCCESS",
"workspaceId": "6fd2160c-3ea6-42c2-bcdd-2eef89f5ca66"
},
"hook": {
"eventType": "sync.complete",
"id": "c1348091-bd3e-4598-9e7f-5ea457f02e85",
"timeStamp": "2024-02-09T11:33:41.658Z",
"source": "CALRY_WEBHOOK"
}
}