A webhook is a way for an app to provide other applications with real-time information. Palenca delivers data programmatically to keep you updated on your user's connections.
Webhooks enable us to send notifications to your app as a JSON payload, so you can use them to automatically trigger processes in your backend systems.
For example, Palenca will send you a webhook when one of your users successfully connects to Uber (or any other platform), or when we refresh one of your users profile looking for updates on the user’s employment information.
How to use Palenca webhooks
- Be sure to have an endpoint on your server that can listen to
- Create a webhook with our API, providing your local server url where you want to receive the notifications and with the field
"is_sandbox": True. You can find more information about how to do this here.
- Test that your webhook endpoint is working properly using the Palenca sandbox environment.
- Once you validated that your webhook is working properly, you can create a webhook with the field
- You are ready to go. Palenca will start sending you webhooks in the production environment.
The response you'll get from Palenca will include some information about the user or account and the
webhook_action to be notified. You can read more about these actions here.
The following is an example of a webhook payload:
Parameter Description Type Example user_id The ID of the user uuid 054d0a9d-38ec-40cb-a31c-09b483242e4a account_id Account ID uuid 628cdf56-95f1-4397-a154-281112781240 or null country The user's account country string mx or null platform The user's account platform string imss or null webhook_action Type of notification sent str account.created
If we do not get a 200 or 201 status code within 30 seconds of the first POST request to the webhook URL, we will make up to three more calls (stopping if we get a 200 or 201), waiting a few minutes in between each of them.
Data Retrieval Times
|Data||Time Frame||Example Time|
|Profile||Under 30 seconds||12:00:30 PM|
|Employment Info||Under 30 seconds||12:00:30 PM|
|1 Month of Earnings||Under 1 minute||12:01:00 PM|
|2 Month of Earnings||Under 2 minutes||12:02:00 PM|
|3 Month of Earnings||Under 3 minutes||12:03:00 PM|
|Rest of Earnings||Under 30 seconds||> 12:03:00 PM|