Quiz Responses
Learn how to get quiz responses to your server via webhooks
Last updated
Learn how to get quiz responses to your server via webhooks
Last updated
This webhook service provides you with information about the answers to the questions in the quizs when you use the quiz feature on your sales sites. When you enable this webhook service, you will only receive responses from users who have completed a purchase. However, if you would like to receive answers from users who have not completed a purchase, you need to check the preference box in the webhook field.
Webhook events are sent to your server via HTTP POST
. You configure the endpoint URL through Developer Tools / Webhooks menu under your project.
By default, webhook notifications include only the quiz responses from users who have paid. You can configure to also receive quiz responses from users who have not paid.
The webhook notification for quiz responses will be sent within 5 minutes for users who have completed their payment. For users who haven’t completed payment, the notification will be sent within 30 minutes. Your server should return a 200 status code. Any other status code will be considered a failure by our backend, and the following retry process will apply:
If the first attempt fails, the next attempt will be made within 1 hour.
If the delivery fails again, it will be retried once per hour, up to a maximum of 10 attempts.
After 10 attempts, if the delivery is still unsuccessful, the process will be stopped.
Webhook events are serialized in JSON. The body of a POST
request to your server will contain the serialized event.
client.subscriberId
Subscriber ID which can be email or phone number.
client.subscriberName
Name and surname of the registered user.
client.email
Subscriber email.
client.uuid
Unique user ID.
client.isPayer
Value is sent as 1
if the user has made a successful payment, otherwise 0
. If it is 1
, it indicates that the purchase transaction has been completed, if it is 0
, it indicates that the purchase transaction has not been completed.
client.platform
User device OS.
client.country
User country.
client.language
User language.
client.utmSource
UTM source parameter.
client.utmCampaign
UTM campaign parameter.
client.utmContent
UTM content parameter.
client.utmTerm
UTM term parameter.
client.paymentModule
It specifies which module the process belongs to. It takes the generate
value for Zotlo Self Service and the store
value for the marketplace.
client.flowId
It is the ID in Zotlo of the flow added to the sales site.
client.siteId
It is the ID information of the sales site in Zotlo.
client.ip
User's IP Information.
questions
Question details.
questions.questionId
Question ID
questions.questionName
Question name.
questions.question
Quetion title.
questions.settings
Question design settings.
questions.sequence
Question order.
questions.displayedSequence
Question order seen by the user.
questions.required
Value is 1
if answer is required for the question otherwise 0
.
questions.isMultiple
Value is 1
if multiple answers are allowed for the question otherwise 0
.
questions.typeId
Question type, possible values:
0
: Multiple choice
2
: Image chooser
4
: Info page
5
: Date
6
: Time
7
: Single row text
8
: Location
9
: Ending page
10
: file upload
questions.typeName
Question type name.
questions.isLogic
true
if question has a logic false
otherwise.
answers
It is information about the answers answered in the survey. If there is multi-language support, the answers are sent in the language in which the user answered.
answers.answerDate
Answer date.
answers.answer
Answers to the question.
answers.answerOptions.optionId
Option ID if question is a multi select type.
answers.answerOptions.name
Option text if Option ID if question is a multi select type.
answers.answerOptions.type
It is the answer type of the question. It can take image or text values.
answers.answerOptions.image
This is the image of the answer.