Webhooks are secondary actions that can be performed for each buyer in your campaigns.
- Before getting started
- How to enable a Webhook
- Execution Rules
- Create an HTTP Webhook
- Create an email Webhook
- Important Notes
Before getting started
- Webhooks can be HTTP or email.
- Secondary actions cost less per transaction as they are not real time, but fire close to real time (subject to a few minutes delay in extraordinary cases).
- You can setup unlimited webhooks for each buyer.
- In order to utilize webhook/secondary action, you must have a real time action setup in your campaign.
- LeadProsper does not store or parse any responses from webhooks.
How to enable a Webhook/Secondary action on your campaign
- Navigate to the campaigns tab in your Lead Prosper account.
- Create a new campaign, or select the campaign you wish to add a webhook and choose edit.
- Once in the campaign, choose the buyer you wish to add a webhook to, and choose edit.
- Scroll to the Webhooks box and choose +Add.
- In the window, choose wether you would like an HTTP or Email webhook .
Webhooks are executed based on rules.
- All the time, any status
- This means regardless of the status of the real time action, the webhook will execute.
- If POST
- was accepted - activate the webhook if the response of the real time action was accepted.
- was duplicated - activate the webhook if the response of the real time action was duplicated.
- was failed - activate the webhook if the response of the real time action was failed.
- was not processed - activate the webhook if the response of the real time action was not processed .
- If PING (Ping Post only)
- was accepted - activate the webhook if the response of the ping was accepted.
- was duplicated - activate the webhook if the response of the ping was duplicated.
- was failed - activate the webhook if the response of the ping was failed.
Execution rules are presented once you have chosen a webhook type.
Create an HTTP Webhook
This is the URL Lead Prosper will post the data to if all validation criteria has been met by your field validations and filters. This URL will be found in the API spec supplied to you by the lead buyer client.
Select whether your API post should use the POST or GET method. Typically the lead buyer client's API spec will specify which method they would like to accept.
Select the format your buyer client's API will accept (Form or JSON). This will change the format in the payload field for you to easily edit.
Building the Payload
This is where you must enter the body that we will send the request.
- On top of the editor, you will see all the available fields and their short-codes.
- The editor will visually display your body based on the selected payload type.
- Please check the numbered sidebar in the editor and make sure there are no errors, as shown here:
in some cases, your buyers will require special headers, such as an API key or username and password.
- Headers can be added by specifying the Key and the Value of your headers.
- You can add as many as you need.
- Some headers don't need to be added, as Lead Prosper automatically adds them.
- They are:
- They are:
Create an Email Webhook
If you have chosen the email webhook type, Lead Prosper will deploy and email once your webhook condition has been met.
Building the Payload
The payload mirrors the body of the email which will be deployed by Lead Prosper when your webhook conditions are met.
- You can format the email to include additional details and content.
Adding a recipient
To add a recipient, simply enter the email in the "send to the following emails" box and choose Add.
Please test your setup before going live, and make sure that the email/HTTP recipient has received the tests.
- It is also a good idea to add Lead Prosper to the safe senders list of any email recipient.