Skip to main content
Webhooks documentation light mode
Webhooks documentation dark mode

Overview

When configuring a Pearl, you can set up webhooks to receive real-time notifications at key moments of the call lifecycle. The webhooks available to you depend on whether your Pearl is configured for Inbound or Outbound activity.

Inbound Pearl

Access to the Call Webhook only.

Outbound Pearl

Access to both the Call Webhook and the Lead Webhook.
The Call Webhook payload is identical whether it originates from an Inbound or Outbound Pearl. The Lead Webhook is exclusive to Outbound campaigns, as leads are a concept specific to outbound call management.
Use webhooks only when an external tool needs event notifications. For actual automations tied to how a call ended, rely on Post-Call Actions instead.

Webhook Types

Call Webhook

Sent when a call ends, and when an outbound call starts. Available for both Inbound and Outbound Pearls.

Lead Webhook

Sent when an outbound call starts and when it ends, with the lead’s current status. Available for Outbound Pearls only.

Webhook Version

Select the version that matches your Pearl configuration. V2 is the recommended version and is selected by default.
In V2, all JSON payload keys use camelCase (e.g. pearlId, phoneNumber, collectedData). Statuses, roles, and sentiments are sent as numbers: use the Code column of the tables below. The keys of callData and collectedData are sent exactly as stored, i.e. your variable IDs.

Call Webhook Payload

The Call Webhook is sent when a call ends, and when an outbound call starts. It provides comprehensive data about the call, including its outcome, duration, transcript, and any information collected during the conversation. In a webhook sent at the start of a call, the result fields (summary, recording, tags, overallSentiment…) are null, and transcript and collectedInfo are empty.
Available for both Inbound and Outbound Pearls.

Payload Fields

  • Transferred calls send one more Call Webhook. The one sent when Pearl hands the call over has status InProgress and transferCallDuration set to null. A final webhook follows once the transferred part ends, with the final status, the transferCallDuration and the updated creditDebited.
  • creditDebited only counts the credits charged before the webhook is sent. A later charge, such as an SMS sent by a Post-Call Action, is not included: the Get Call endpoint returns the final amount.

Conversation Statuses

The definition of Success and NotSuccessful is configured at the Pearl level. Refer to the Create a Pearl page for more details.

Call Statuses

Transcript Message

Each entry in the transcript array represents a single message in the conversation.

Collected Info

Each entry in the collectedInfo array represents a variable captured during the call.

Sentiment Values

Example Payload


Lead Webhook Payload

The Lead Webhook is sent when an outbound call starts and when it ends, and again after a transfer. It contains all relevant information about the lead and its current status. Nothing is sent when a lead is added, edited, or deleted.
Available for Outbound Pearls only.

Payload Fields

callData vs collectedData

Lead Statuses

The definition of Success and NotSuccessful is set at the Pearl level. Refer to the Create a Pearl page for details.

Example Payload


Differences Between V1 and V2


Setting Up Webhooks

Webhooks are set in your Pearl’s editor, in the Inbound Settings tab for an inbound Pearl, or the Outbound Settings tab for an outbound one.
1

Turn Webhooks On

In the Webhooks block, select On. Webhooks are off by default, and the webhook lines only appear once they’re on.
Webhooks block of an inbound Pearl, turned on, with its Calls line
Webhooks block of an inbound Pearl, turned on, with its Calls line
2

Enter Your Webhook URLs

Type the endpoint URL of each webhook you want to receive: Calls for the Call Webhook, available for Inbound and Outbound Pearls, and Leads for the Lead Webhook, available for Outbound Pearls only. Your server must respond with any HTTP 2xx status to acknowledge receipt.
Webhooks block of an outbound Pearl with its Calls and Leads lines
Webhooks block of an outbound Pearl with its Calls and Leads lines
3

Choose the Payload Version

Click the version pill at the end of the Calls line to choose V1 or V2 (see Webhook Version). V2 is selected by default.
Payload version menu of the Calls webhook with V1 and V2
Payload version menu of the Calls webhook with V1 and V2
4

Sign Your Webhooks (Optional)

Click the signature pill of a webhook line to attach a Credential, so NLPearl.AI authenticates its requests to your endpoint: pick one of your tokens, create one with New token, or update the selected one with Edit token. No signature sends the webhook without credentials.
Signature menu of the Calls webhook with No signature, a token and New token
Signature menu of the Calls webhook with No signature, a token and New token
The selected credential is applied to every webhook delivery, letting your server verify the request genuinely originates from NLPearl.AI.
Credentials work the same way as in the API Node. A token created here can be reused across your webhooks.
Make sure your webhook endpoint is publicly accessible and responds within 10 seconds. When a delivery fails (a non-2xx response, an error, or a timeout), NLPearl.AI tries again up to 3 attempts in total, 30 seconds apart. Since a delivery can arrive more than once, make your endpoint idempotent.Each request is a POST with the headers Content-Type: application/json; charset=utf-8 and User-Agent: NLPearl/Agent, plus the ones your credential adds.
If your endpoint is behind a firewall, allow the NLPearl IP addresses listed in IP Whitelisting.

Checking Webhook Deliveries

Every webhook sent for a call appears in the Event Log of that call’s details. Each Call Webhook or Lead Webhook event shows the endpoint URL, the number of attempts, and the final status code, or Not sent when the delivery could not leave (for example, when its credential was deleted). Expand the event to see the attempt that settled the delivery: its time, the request with its status code and response time, and the error and response returned by your server, if any. Use it to check that your endpoint received the data, or to find out why it did not.
Call Webhook event expanded in a conversation's Event Log, with its attempt, status code and error
Call Webhook event expanded in a conversation's Event Log, with its attempt, status code and error

Outbound Campaigns

Learn how to create and configure outbound campaigns, including webhook setup.

API Reference – Get Calls

Explore the full call object structure returned by the API.