Webhooks allow you to send transaction data to your own endpoints when a transaction is created, updated, or deleted. You can use this functionality to integrate with automation platforms like Zapier.
In addition to Actions, Latwy can send raw transaction data to your own endpoints when a transaction is created, updated, or deleted. To create a new webhook, go to the Actions page and click on the Webhooks
connection. This connection was created automatically when you signed up for an account, but it will only be accessible if you are a Premium subscriber.
Click on Create webhook
, then specify the endpoint, the events you want sent to that endpoint, and a brief description. Click Save
to create the webhook.
Webhooks are delivered via POST
requests to your endpoints with a JSON body. Regardless of the type of event, each JSON body has two top-level keys:
transaction.created
, transaction.updated
, or transaction.deleted
.transaction
object.transaction.created
and transaction.updated
For these two event types, the format of the webhook payloads are the same, with the exception of the type
. Here's an example:
{
"data": {
"transaction": {
"account": {
"group": "joint",
"id": "5555",
"institution": "Capital One",
"name": "Tom's SavorOne",
"type": "CREDIT_CARD"
},
"amount": 14005,
"amount_in_dollars": "140.05",
"category": "FOOD_AND_DRINK",
"created_at": "2024-01-14T18:01:20.301588+00",
"date": "2024-01-14",
"date_us": "1/14/2024",
"id": "trans_hPmemAdWlDLFZQtDqKK",
"merchant": "WHOLE FOODS MARKET",
"subcategory": "GROCERIES",
"tags": [
"joint"
],
"updated_at": "2024-01-18T18:01:20.301588+00"
}
},
"type": "transaction.created"
}
transaction.deleted
This webhook payload is the same as above, except that the tags
array within the transaction
object is absent, and the account
entry within the transaction
object will be a string containing the account ID, not the entire account object.