Snag Docs logo

Update an existing question

This endpoint allows you to update an existing question.

POSThttps://admin.snagsolutions.io/api/loyalty/questions/{id}

This endpoint allows you to update an existing question.

Loading code example
Loading code example

Authorizations

apiKeyAuthstringheaderrequired

API key passed in the header.

Path Parameters

idstringrequired

Body

Body

questionTextstringrequired

The text of the question

loyaltyQuestionAnswersarray<object>required

Array of choices for the question

loyaltyQuestionAnswers.idstring<uuid>

UUID of the choice (optional for new choices)

loyaltyQuestionAnswers.textstringrequired

The text of the choice

loyaltyQuestionAnswers.isCorrectbooleanrequired

Whether this choice is correct

loyaltyQuestionAnswers.sortIdentifiernumberrequired

The order in which to display the choice

Response

application/json

200

idstring<uuid>required
textstringrequired
loyaltyQuestionChoicesarray<object>required
loyaltyQuestionChoices.idstring<uuid>required
loyaltyQuestionChoices.textstringrequired
loyaltyQuestionChoices.sortIdentifiernumberrequired