Retrieve active version
To retrieve the active version of type of a questionnaire the following endpoints can be used (available only for ADMIN):
Verified Buyers
GET request:
https://pistis-market.eu/srv/intention-analytics/api/questionnaire/active-version/verified-buyers
Server response
Example of the response containing the retrieved active questionnaire version for verified buyers:
{
"id": "ff2b7476-4f19-472a-8f89-faad6f6247be",
"version": "7",
"title": "Questionnaire title",
"description": "Questionnaire description",
"questions": [
{
"id": "2f4b8756-4203-486f-90ee-25dd296d6283",
"type": "Text",
"title": "Text question",
"isRequired": true,
"options": []
},
{
"id": "bc88d655-5684-4645-8c99-aa3e2f81b43e",
"type": "Checkbox",
"title": "Checkbox question",
"isRequired": true,
"options": [
{
"text": "Option 1",
"description": ""
},
{
"text": "Option 2",
"description": ""
}
]
}
]
}
Non Verified Buyers (General Users)
GET request:
https://pistis-market.eu/srv/intention-analytics/api/questionnaire/active-version/general-users
Server response for General Users
Example of the response containing the retrieved active questionnaire version for general users:
{
"id": "e96f396b-10ba-4164-96be-e432056e2114",
"version": "9",
"title": "new general users questionnaire",
"description": "test description",
"questions": [
{
"id": "b2733441-3c78-4384-b62f-ac78b14da27f",
"type": "Text",
"title": "Text Q",
"isRequired": true,
"options": []
},
{
"id": "16e15fa3-f745-4b7f-8953-91969209c96a",
"type": "Checkbox",
"title": "Test Checkbox question",
"isRequired": true,
"options": [
{
"text": "Option 1",
"description": ""
},
{
"text": "Option 2",
"description": ""
}
]
}
]
}
