DELETE: https://{{env}}.survey2connect.com/v2/api/surveys/{{survey_id}}/pages/{{page_id}}/questions/{{question_id}}
The value of environment {{env}} variable depends upon your datacenter. Refer to the Environment page for more details.
"Content-Type": "application/json"
type: Api Key Key: x-api-key token: value from portal
Path Parameter
{{survey_id}}: Unique Survey ID. {{page_id}}: Unique Page ID. {{question_id}}: Unique Question ID.
Request Sample
curl --location --request DELETE 'https://az1.survey2connect.com/v2/api/surveys/survey_id/pages/page_id/questions/question_id' \
--header 'Authorization: Bearer eyJraWQiOiJzM3E1OWF2cFdIcXVKa0I0MjRpcFpqQVN0dXAzQzFkZEhVM3k2TjNZSXRjPSIsImFs' \
--header 'Content-Type: application/json' \
var myHeaders = new Headers(); myHeaders.append("Authorization", "Bearer eyJraWQiOiJzM3E1OWF2cFdIcXVKa0I0MjRpcFpqQVN0dXAzQzFkZEhVM3k2TjNZSXRjPSIsImFs”); myHeaders.append("Content-Type", "application/json"); var requestOptions = { method: DELETE, headers: myHeaders, redirect: 'follow' }; fetch("https://az1.survey2connect.com/v2/api/surveys/survey_id/pages/page_id/questions/question_id", requestOptions) .then(response => response.text()) .then(result => console.log(result)) .catch(error => console.log('error', error));
Responses
Note: Please do not share your tokens in publicly accessible areas or to anyone. Also, this token generated is valid for 24 hours only. After its expiry, you can regenerate the access token from the same API endpoint by passing the username and password or from the refresh token API with the help of refresh token.