You can use Webhooks to be notified about events that happen in your ExitBee campaign.
Webhooks let you register a URL that we will be notified anytime an event happens in your campaign.

In order to add a campaign webhook, go to your campaign Settings Page -> Integrations , find webhooks image and click "ADD WEBHOOKS".



A dialog will open and ask you to select the event and  fill the corresponding callback url.






Webhook events


On email subscription


This event is triggered when you run a campaign with a form, and the form is posted by a lead.  Your callback url will be called with a POST payload containing the lead's information:



{
	"country": {
		"name": "##COUNTRY_NAME##",
		"alpha2_code": "##COUNTRY_ALPHA2_CODE##"
	},
	"city": {
		"name": "##CITY_NAME##"
		"lat":  "##CITY_LATITUDE##",
		"lng": "##CITY_LONGTITIDE##",
	},
	"ip": "##LEAD_IP##",,
	"campaign": "##CAMPAIGN_NAME##",
	"form_data": {
		"email": "##LEAD_EMAIL##""
	}
}

Example payload:

{
	"country": {
		"name": "United States",
		"alpha2_code": "US"
	},
	"city": {
		"name": "New Haven",
		"lat": "41.3094000",
		"lng": "-72.9240000"
	},
	"ip": "127.0.0.1",
	"campaign": "lg",
	"form_data": {
		"email": "[email protected]",
		"name": "John Doe",
		"phone": "0281027202"
	}
}


Τhe "form_data" object varies according to the template that your campaign uses and the form fields. In order to view their format for your campaign click "Sample Payload" on the webhooks dialog.