This article is for technical users / developers to sync contact details from Envoke to an external database (CRM).
After an Envoke form submission, have the contact data send to an endpoint for your integration. Form submissions use web hooks to send data to you.
Set up the hook
An example cURL request to create a new "form_submission" hook:
curl -X POST -u {API_USER_ID}:{API_PASSWORD} -d "{\"url\":\"https://path-to-my-integration.com\",\"type\":\"form_submission\"}" "https://e1.envoke.com/v1/hooks"
Result
Once the hook has been setup, Envoke will make a POST request to the provided endpoint after each form submission.
Here's an example payload of what will be delivered:
[{
"id": "5405861",
"date_created": "2018-10-20T20:39:31+00:00",
"first_name": "Testing",
"last_name": "",
"title": "",
"email": "test@envoke.com",
"company": "",
"phone": "",
"address_1": "",
"address_2": "",
"city": "",
"country": "CA",
"province": "NU",
"postal_code": "",
"website": "",
"language": "",
"feedback": "Comment from a test lead!",
"consent_status": "Express",
"consent_description": "Form submission",
"consent_effective_date": "2019-02-23T03:04:34+00:00",
"consent_expiry": "",
"custom_fields": {
"custom_field_name1": "Field Value 1",
"custom_field_name2": "Field Value 2"
},
"interests": [
"Affiliate Program",
"Consumer",
"Request to be contacted",
"long-haul"
],
"autoresponders": [
"New contact welcome series"
],
"contact_id": "679051",
"contact_external_id": "74f07cbe8542cd9da108268769eac090",
"contact_remote_id": "",
"contact_created": false,
"submission_type":"form_submission",
"submission_time":"2022-02-14",
"form_id": "f0e6494a90a9739cb255082e59442b2a",
"form_name": "Hook demo form",
"form_url": "https://website.com",
"visitor_id":"61fa9d0d12ac4a4648fab7d0",
"visit_id":"61fa9d0d12ac4a4648fab7d0",
"pageview_id":"61faa42bf8d98f6bfbc018cd"
}]