---
title: "Update Recorder Questions"
method: POST
path: "/recorder/questions/{recorderId}"
tags: ["Recorder/Survey"]
---

# Update Recorder Questions

`POST /recorder/questions/{recorderId}`

## Request

- Base URL: `https://api.speakai.co/v1`
- URL: `https://api.speakai.co/v1/recorder/questions/{recorderId}`
- Auth: API key in header `x-speakai-key` and API key in header `x-access-token`

**Update a recorder questions:**

`questions` - Speak offer different set of questions to create and ask to your clients.

Here're the few examples with value:

1. Single Line - "single"
2. Multi Line - "multiple"
3. Checkbox\* - "checkbox"
4. Radio Button\* - "radiobutton"
5. Dropdown\* - "dropdownlist"
6. Date - "date"
7. Date & Time - "datetime"


Checkbox, Radio Button, Dropdown offers "Include Others" option.

Checkbox Sample:

``` json
{
"question":"My Checkbox question",
"isRequired":true,
"answerType":"checkbox",
"options":["Option A","Option B"],
"includeOther":false
}

```

Dropdown Sample with Include Other:

``` json
{
 "question": "My Dropdown Question with Include Others",
 "isRequired": true,
 "answerType": "dropdownlist",
 "options": [
 "Value 1",
 "Value 2"
 ],
 "includeOther": true
}

```

## Path parameters

- `recorderId` string, required

## Request body

- object
  - `id` string: Send the id of an existing question to edit it. Leave it out to add a new question. Optional. Accepts an empty string and null, both of which are treated as 'add a new question'. If you send an id that no question on the recorder matches, the request still returns 200 but nothing changes and questionData comes back empty.
  - `question` string, required: Write the question text a respondent sees. Required. An empty or whitespace-only value is rejected.
  - `isRequired` boolean, required: Make the respondent answer this question before they can submit. Required. There is no fallback, so you have to send it on every call, including edits.
  - `answerType` string, required: Set the kind of answer control the question uses. Required. An empty or whitespace-only value is rejected. This route puts no.valid constraint on the value, so the server stores whatever string you send. The recorder reads these values from the RecorderAnswerType enum in @speakai/shared: single, multiple, checkbox, radiobutton, dropdownlist, date, time, datetime. The public submission route does enforce that enum with.valid, so a value outside the set is stored here and then rejected when a respondent submits an answer.
  - `options` string[]: List the choices for a question that offers a fixed set of answers. Optional. Each item is a non-empty string. There is no cap on the number of items.
  - `includeOther` boolean: Add an 'Other' choice alongside the options you listed. Optional. No fallback, so it is stored as undefined when you leave it out.
  - `fieldId` string: Map the answers to one of your custom fields. Optional. Accepts an empty string and null.

## Response `200`

OK

- object
  - `status` string
  - `data` object
    - `message` string
    - `recorderId` string

---

[API](https://skmtc.dev/speakai/apis/speak-ai-api.md) · [All operations](https://skmtc.dev/speakai/apis/speak-ai-api/llms.txt) · [OpenAPI document](https://skmtc.dev/speakai/apis/speak-ai-api/revisions/52d777e6d46e?raw)
