Introduction
Webhooks is a way of getting data to your system without making API requests.
This article will describe how you can configure webhooks, their payload structure and how you can track their logs.
Webhooks
Webhooks are internal e-satisfaction processes that deliver data to any service (URL) based on triggered events. Using webhooks you can retrieve data from e-satisfaction without pulling them using our APIs but simply creating a route that will be called by our systems to deliver data.
Webhooks are configured per Questionnaire.
IPs for Firewall Whitelist
Before moving forward, make sure you have read our IPs for firewall whitelist and enabled these IPs, if necessary.
Setup Webhooks
You should be able to see your webhooks from your Questionnaire Page, by selecting the "Webhooks" section on the left sidebar:
You can create a new webhook simply by clicking on the "Create New" button on the top right corner of the panel, and the following dialog will be displayed:
Field | Description |
Title | A friendly title for your webhook |
Active | Activate or deactivate the webhook execution |
Target Url | The url that will be called |
Triggers
Webhooks are called on the following events:
- Questionnaire Instance Completed
Payload
Each webhook delivers the completed questionnaire. Here is an example of the payload:
{ "instance_id": "MwiaXfV5TzekAO1OY6t6Fg", "questionnaire_id": "hAQ7YISTasdRBefCGpzw", "responder_id": "7SW2HQzQk6kqExZel55og", "locale": "en-us", "valid_days": 0, "editable": true, "finalized": true, "question_ids": "DA0SyCcTSxCoj3bsWWKU4A,U6gNW8noROmKey6YxSxSOg,jDjnfqgRVi6ZecGAmI2Uw,xOGu5VnfRPu3PpI0ubdaEQ,nr4zz1GSRylJiK4bvrg,bcC0MqEgSum01hkGbnRl2w,MaBEOvUqRuaXIf2chiVriQ,RcQbeWQoi7iSw2QSbWFw,VGW3wTdSR5S0rYpMkV0Itg", "created_time": "2019-05-09T18:23:45+03:00", "updated_time": "2019-05-09T17:24:05+03:00", "sent_time": null, "delivered_time": null, "viewed_time": "2019-05-09T18:23:47+03:00", "submitted_time": "2019-05-09T18:24:00+03:00", "completed_time": "2019-05-09T18:24:01+03:00", "processed_time": null, "flow_time": null, "created_by": "BCnXVWSCTYipZhnImGWJyA", "updated_by": "BCnXVWSCTYipZhnImGWJyA", "questionnaire": { "questionnaire_id": "hAQ7YISTasdRBefCGpzw", "template_questionnaire_id": null, "owner_application_id": "Gfvpy8zfSWCgusUWN5eZfQ", "display_name": "Checkout", "title": "30 seconds for better e-purchases!", "description": "Tell us your opinion and help us improve our services for you!", "valid_days": 0, "editable": true, "desktop_collapsed": false, "non_collapsed_questions_count": 1, "questionnaire_icon_url": "", "key_question_id": "YXfpdc8TXmXUgkocXWHeQ", "credits_accountable": true, "created_time": "2017-11-07T08:36:49+02:00", "updated_time": "2019-05-09T17:23:38+03:00", "created_by": null, "updated_by": "t8GnPHCMTouoSgregUY9Ow" }, "responder": { "responder_id": "7SW2HQzQk6kqExZel55og", "application_id": "Gfvpy8zfSWCgusUWN5eZfQ", "locale": "en-us", "created_time": "2019-05-09T18:23:45+03:00", "updated_time": "2019-05-09T18:23:45+03:00", "created_by": "BCnXVWSCTYipZhnImGWJyA", "updated_by": "BCnXVWSCTYipZhnImGWJyA", "metadata_values": [] }, "responses": { "hxtOOLOSJioqQuSqYpw": { "response_id": "hxtOOLOSJioqQuSqYpw", "instance_id": "MwiaXfV5TzekAO1OY6t6Fg", "question_id": "jDjnfqgRVi6ZecGAmI2Uw", "value": "10", "value_extended": "10", "locale": "en-us", "created_time": "2019-05-09T18:24:02+03:00", "updated_time": "2019-05-09T18:24:02+03:00", "created_by": "BCnXVWSCTYipZhnImGWJyA", "updated_by": "BCnXVWSCTYipZhnImGWJyA", "question": { "question_id": "jDjnfqgRVi6ZecGAmI2Uw", "template_question_id": null, "group_id": "eDI6bL3QAKCebKbtCfLA", "type_id": 1, "title": "How satisfied are you with our e-shop?", "description": "", "display_name": "", "required": true, "enabled": true, "fixed": true, "display_order": 1, "custom_values": "0;10;1", "icon_url": null, "probability": 1, "legacy_question_id": null, "created_time": "2017-11-14T14:35:21+02:00", "updated_time": "2019-03-14T15:16:22+02:00", "created_by": null, "updated_by": "t8GnPHCMTouoSgregUY9Ow" } } }, "metadata_values": { "IBjVcwHkReSbr9klPAqDIA": { "instance_id": "MwiaXfV5TzekAO1OY6t6Fg", "metadata_id": "IBjVcwHkReSbr9klPAqDIA", "value": "Mozilla\/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/73.0.3683.103 Safari\/537.36", "value_extended": "Mozilla\/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/73.0.3683.103 Safari\/537.36", "created_time": "2019-05-09T18:23:45+03:00", "updated_time": "2019-05-09T17:23:45+03:00", "anonymized_time": null, "created_by": "BCnXVWSCTYipZhnImGWJyA", "updated_by": "BCnXVWSCTYipZhnImGWJyA", "metadata": { "metadata_id": "IBjVcwHkReSbr9klPAqDIA", "application_type_id": null, "application_id": null, "name": "user_agent", "title": "User Agent", "description": "The browser the user used to respond to the questionnaire", "type": "text", "anonymize": false, "created_time": "2018-02-01T23:35:29+02:00", "updated_time": "2018-02-01T23:35:29+02:00", "created_by": null, "updated_by": null } } }, "segments": { "WL87hasSiqfKiBoXJRjQ": { "segment_id": "WL87hasSiqfKiBoXJRjQ", "template_questionnaire_id": null, "questionnaire_id": "hAQ7YISTasdRBefCGpzw", "title": "Happy", "description": null, "active": true, "icon_url": null, "created_time": "2019-01-11T10:07:41+02:00", "updated_time": "2019-01-11T10:07:41+02:00", "created_by": "t8GnPHCMTouoSgregUY9Ow", "updated_by": "t8GnPHCMTouoSgregUY9Ow" } }, "campaign": { "instance_campaign_id": "gv74lzW4TUqDFiY18lqdQ", "questionnaire_instance_id": "MwiaXfV5TzekAO1OY6t6Fg", "campaign_id": "iu6PRh1TYOxOuMnnY6uSA", "created_time": "2019-05-09T18:24:02+03:00", "updated_time": "2019-05-09T18:24:02+03:00", "completed_time": null, "processed_time": null, "created_by": "BCnXVWSCTYipZhnImGWJyA", "updated_by": "BCnXVWSCTYipZhnImGWJyA", "base_campaign": { "campaign_id": "iu6PRh1TYOxOuMnnY6uSA", "application_id": "Gfvpy8zfSWCgusUWN5eZfQ", "type_id": 2, "tracking_id": null, "title": "Refer a Friend", "description": null, "priority": 0, "image_url": "", "image_mobile_url": null, "target_url": "", "frequency_cap_minutes": 0, "frequency_cap_hours": 0, "frequency_cap_days": 0, "locale": null, "active": true, "start_time": "2019-04-05T20:19:00+03:00", "end_time": null, "thank_you_content": null, "anonymize": false, "created_time": "2019-04-05T17:18:14+03:00", "updated_time": "2019-04-19T12:09:35+03:00", "created_by": "t8GnPHCMTouoSgregUY9Ow", "updated_by": "t8GnPHCMTouoSgregUY9Ow" } }, "tags": [] }
Deliveries
You can check all the webhook deliveries by clicking the details button on the right side of each webhook:
Delivery Details
You can see the details of each delivery by clicking on the details button.
The Request Details:
And the Response Details: