Update a question
PATCH/v5/questions/{question_id}
Update a question’s display name.
Only the name is mutable through this endpoint; a question’s type, prompt,
and type-specific configuration are fixed at creation and cannot be changed
here. Updating an archived question is rejected with a client error, so restore
it first if it needs to be edited. The update is scoped to the caller’s account.
Update a question
curl https://api.egp.scale.com/v5/questions/$QUESTION_ID \
-X PATCH \
-H 'Content-Type: application/json' \
-H "x-api-key: $SGP_API_KEY" \
-d '{
"name": "x"
}'{
"id": "id",
"configuration": {
"choices": [
"string"
],
"dropdown": true,
"multi": true
},
"created_at": "2019-12-27T18:11:19.117Z",
"created_by": {
"id": "id",
"type": "user",
"object": "identity"
},
"name": "name",
"prompt": "prompt",
"archived_at": "2019-12-27T18:11:19.117Z",
"conditions": [
{
"foo": "bar"
}
],
"object": "question",
"question_type": "categorical"
}Returns Examples
{
"id": "id",
"configuration": {
"choices": [
"string"
],
"dropdown": true,
"multi": true
},
"created_at": "2019-12-27T18:11:19.117Z",
"created_by": {
"id": "id",
"type": "user",
"object": "identity"
},
"name": "name",
"prompt": "prompt",
"archived_at": "2019-12-27T18:11:19.117Z",
"conditions": [
{
"foo": "bar"
}
],
"object": "question",
"question_type": "categorical"
}