Create a new question
This endpoint allows you to create a new question.
POST
This endpoint allows you to create a new question.
Loading code example
Loading code example
Authorizations
apiKeyAuthstringheaderrequired
API key passed in the header.
Body
Body
loyaltyRuleIdstring<uuid>requiredUUID of the loyalty rule
questionTextstringrequiredThe text of the question
allowMultipleAttemptsbooleanWhether the question allows multiple attempts
Default:
falseloyaltyQuestionAnswersarray<object>requiredArray of choices for the question
loyaltyQuestionAnswers.idstring<uuid>UUID of the choice (optional for new choices)
loyaltyQuestionAnswers.textstringrequiredThe text of the choice
loyaltyQuestionAnswers.isCorrectbooleanrequiredWhether this choice is correct
loyaltyQuestionAnswers.sortIdentifiernumberrequiredThe order in which to display the choice
Response
application/json
201
idstring<uuid>requiredtextstringrequiredloyaltyQuestionChoicesarray<object>requiredloyaltyQuestionChoices.idstring<uuid>requiredloyaltyQuestionChoices.textstringrequiredloyaltyQuestionChoices.sortIdentifiernumberrequired