> Fetch clean Markdown by appending `.md` to any page URL under https://signalwire.com/docs or requesting it with the HTTP header `Accept: text/markdown`. The root index at https://signalwire.com/docs/llms.txt lists the available documentation indexes. # Gather Input > Call Flow Builder node to gather input from the caller. This node is used to gather input from the caller using DTMF or speech recognition. During the gather period, the call can use an audio file or text-to-speech to prompt the caller to enter the input. Multiple input options can be configured to gather multiple pieces of information from the caller using the `Add option` button. Additionally, actions can be taken based on the input received. For every input option you can configure, an output node connection will be created to handle the input received. ## **Output Node Connectors** **`Input Option`** `string` The output node connector for the first input option configured. This connector will be used when the input received matches the input option. Additional output node connectors will be created for each input option configured. --- **`Unknown`** `string` The output node connector for when the `input received does not match` any of the input options configured. --- **`No Input`** `string` The output node connector for when `no input` is received from the caller. --- ## **Node Settings** **`Text to Speech`** `object` Configure the text-to-speech settings for the gather input node. See [Text to Speech Settings](#text-to-speech-settings). --- **`Audio File`** `object` Configure the audio file settings for the gather input node. See [Audio File Settings](#audio-file-settings). --- ### Text to Speech Settings **`Language`** `string` The language to use for the text-to-speech. --- **`Gender`** `string` The gender of the voice to use for the text-to-speech. --- **`Voice`** `string` The voice to use for the text-to-speech. --- **`Text`** `string` The text to convert to speech. --- **`Wait for Input`** `integer` The amount of time to wait for the caller to enter input.\ \ **Possible Values:** A number between `1-99` is required. --- **`Wait for Digits`** `integer` The amount of time to wait for the caller to enter input.\ \ **Possible Values:** A number between `1-99` is required. --- **`Input Options`** `array` The input options to gather from the caller. Additional options can be added through the `Add option` button inside the node. See [Input Options](#input-options-2). --- ### Audio File Settings **`Audio File`** `string` The URL of a audio file to play to the caller. --- **`Input Options`** `array` The input options to gather from the caller. Additional options can be added through the `Add option` button inside the node. See [Input Options](#input-options-2). --- ### Input Options **`Caller presses`** `string` The DTMF key that the caller must press to select this input option.\ \ **Possible Values:** A value of `0-9`, `*`, or `#` is required. --- **`Or says`** `string` The speech recognition value that the caller must say to select this input option. --- ## **Examples** ### Simple Input You can choose to accept both Speech and DTMF tones with your IVR. The caller in this example can either press 1 or say “sales” to connect with the sales line. Flow topology: **Handle Call** → **Answer Call** → **Gather Input**. Option 1 (press `1` or say `sales`) routes to **Forward to Phone** at `sip:sales@example.com`; Option 2 (press `2` or say `support`) routes to `sip:support@example.com`. **Unknown** and **No Input** remain separate outputs. ### Input with infinite loop prevention If you plan to loop your “No Input” route, you probably want to disconnect a call if the Gather Input node attempts to loop the call more than 2 times. You can do that with a combination of a [Set Variables](/docs/call-flow-builder/reference/set-variables) node and a [Conditions](/docs/call-flow-builder/reference/conditions) node. If a caller dials your number and sits on the line in silence, your Flow will disconnect the call after a couple of loops. Flow topology: **Handle Call** → **Answer Call** → **Gather Input**. Route **Unknown** through a “could you repeat that?” TTS and back to **Gather Input**. Route **No Input** directly to **Set Variables** (`count = %{count} + 1`), then **Conditions** (`%{count} > 2`). The true branch goes to **Hang Up Call**; **Else** loops through a “didn't hear a response” TTS and back to **Gather Input**. ### Accept any speech option The “Unknown” route from the Gather Input node can be useful if you want to accept any and all speech recognition from your caller. A word or phrase is required in your Option 1 “Or Says” field so that your Gather Input node knows it is collecting speech. You can route that option to the same flow as the “Unknown” route so all speech options continue the same path. The variable `%{prompt_value}` can then be used in any node and will contain all speech that was detected. Flow topology: **Handle Call** → **Gather Input**. Route both **Option 1** and **Unknown** to **Play Audio or TTS** with `You just said %{prompt_value}`, then to **Hang Up Call**. Giving Option 1 an **Or says** value enables speech collection while the **Unknown** path accepts other speech. > Call Flow Builder node to gather input from the caller.