Webhook

Integrate with our webhook to receive imported data into your backend.

Pulter uses webhooks to notify your application whenever there's a data import. .

Creating webhooks

Webhooks require three elements to function:

  1. A callback URL - This is the URL that Pulter will send a POST request to when an event is triggered.

  2. A signing secret - This is a secret (usually a random string) that will be used to sign each request. You should validate against this secret on each incoming webhook so you can verify that the request came from Pulter. The system will auto-generate a webhook secret if none is provided.

  3. A list of events - This is a list of events that will trigger this webhook.

Integration

There are two ways to receive the Imported data via webhook

  • First, set your Importer's Webhook URL in the Pulter admin dashboard. Pulter will make a POST request with a JSON body containing the imported data and some other useful details.

  • Or, You can pass in the URL you want Pulter to call via the webhookUrl field in the settings when you initialize the Pulter instance.

Webhook Events

You can view all the webhook events that has been sent, view the response log and can also resend the event if you're probably testing your webhook event. With this setup, none of your webhook events is lost, because you can always resend them. Note: dataSync needs to be set to true for this to work

When a client uploads a csv file using your Importer in the frontend, Pulter will send the csv rows to the Webhook URL in batches of 5,000 rows by default if batchSize is not used. Each batch request will wait for a response from your backend before sending the next batch request. We do this to allow you to process the import in your backend as part of the webhook request, without the need to manage your own processing queuing system.

Webhook request format

{
  "id": "clewr9x160001bxowssfzcznm",
  "templateId": "cl6q9lmji2146jk99hfc01rea",
  "index": 1,
  "count": 1,
  "totalRows": 1000,
  "event_name": "all",
  "data": [
      {
        "last_name": "Rodmann",
        "age": "44",
        "email": "Christy.Rodmann@mailmail.com",
        "__index": "ee6add27-e2c1-44f7-8ab2-08a6e0423206",
      },
      ......
  ],
  "user": {
      "id": "modu8402j7gqtltvqx264p"
  },
  "metadata": {}
}

Your webhook server must respond to receive the next batch.

Event types

This is the full list of webhook events available in Pulter:

Last updated