> For the complete documentation index, see [llms.txt](https://docs.ownchat.app/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ownchat.app/bot/ask-action/ask-phone-number.md).

# Ask Phone Number

The **Ask Phone Number** action allows the chatbot to collect a **valid phone number from users** during a conversation.

This action ensures that the user enters a properly formatted phone number, which can be used for contact verification, follow-ups, or customer records.

The collected phone number is stored in a variable and can later be used for automation, CRM updates, or customer communication workflows.

{% embed url="<https://app.supademo.com/demo/cmm91ikwt5pufdtfhirnyaxdk?utm_source=link>" %}

### **When to Use Ask Phone Number**

Use the **Ask Phone Number** action when the chatbot needs to collect a **customer's contact number**.

**Common Use Cases**

* Customer contact collection
* Appointment confirmation
* Order verification
* Lead generation
* Support request follow-up

Example interaction:

Bot: We need your phone number to confirm your appointment.\
Please enter it with the country code.\
\
User: 919876543210

The chatbot captures and stores the phone number for later use.

### **How to Add Ask Phone Number**

Follow these steps to add the Ask Phone Number action in your bot workflow.

* Open **Bot Builder**
* Click **Add Node**

{% embed url="<https://app.supademo.com/demo/cmp6ias5u01as1q0j2u43puuw?utm_source=link>" %}

* Select the **Ask** tab
* Choose **Ask Phone Number**

{% embed url="<https://app.supademo.com/demo/cmp6ichej01au1q0jtbgem90i?utm_source=link>" %}

* Configure the required fields
* Click **Create**

The chatbot will pause at this step until the user enters a valid phone number.

### **Ask Phone Number Configuration**

When creating an Ask Phone Number action, several fields must be configured.

#### **Action Name**

The **Action Name** identifies the action within the bot workflow.

This name is visible only inside the bot builder.

{% embed url="<https://app.supademo.com/demo/cmp6idjbg000czy0j92kl0no2?utm_source=link>" %}

Example:

Collect Phone Number\
Customer Contact Input\
Verify Phone Number

#### **Message**

The **Message** field contains the prompt shown to the user.

{% embed url="<https://app.supademo.com/demo/cmp6ien7z01b01q0j1yigyufq?utm_source=link>" %}

Example:

Hello 👋\
\
We need your phone number to confirm your appointment.\
Please enter it in the format: 919876543210

The message supports:

* Dynamic variables
* Text formatting
* Emojis

Variables can be inserted using the **Add Variable** option.

#### **Adding Variables**

The **Add Variable** option allows dynamic values to be included in the message.

Examples include:

* Customer name
* Phone number
* Email
* Contact details

Example:

Hi {{customer.name}}

This helps personalize the interaction.

#### **Error Attempt**

The **Error Attempt** field defines the number of invalid attempts allowed.

{% embed url="<https://app.supademo.com/demo/cmp6igwyh01b21q0jl8zp21o1?utm_source=link>" %}

Example:

Error Attempt: 2

If the user enters an invalid response multiple times, the chatbot will follow the configured **Action on Invalid**.

#### **Error Message**

The **Error Message** is displayed when the user provides an invalid phone number.

{% embed url="<https://app.supademo.com/demo/cmp6ihy8c000zzy0jhmhwait7?utm_source=link>" %}

Example:

Please provide a proper phone number so we can continue.\
Example: 919876543210

This helps guide users to enter the correct format.

#### **Action on Invalid**

This setting defines the behavior when the user exceeds the allowed error attempts.

{% embed url="<https://app.supademo.com/demo/cmp6ij5nl01iezx0jernk1dme?utm_source=link>" %}

Available options include:

**End the Flow**

Stops the chatbot conversation.

**Skip the Question**

Allows the chatbot to continue without collecting the phone number.

**Fall Back Flow**

Redirects the user to another predefined chatbot flow.

#### **Validation Settings**

The **Validation Setting** ensures the phone number meets the required length.

{% embed url="<https://app.supademo.com/demo/cmp6ik78e01b41q0jmbukhui5?utm_source=link>" %}

When enabled, you can define:

**Minimum Characters**

Example:

Min Characters: 10

**Maximum Characters**

Example:

Max Characters: 12

These limits help ensure the user enters a valid phone number format.

{% embed url="<https://app.supademo.com/demo/cmp6imdwf01b81q0jgenpnkw8?utm_source=link>" %}

### **Store Response in Variable**

The **Store Response in Variable** field saves the collected phone number.

{% embed url="<https://app.supademo.com/demo/cmp6io2o201bh1q0jed8qy40c?utm_source=link>" %}

Example variable:

phonenumber\_collect

This stored value can be used for:

* Customer records
* Marketing campaigns
* WhatsApp broadcasts
* Follow-up communication

### Save and Deploy &#x20;

After configuring the action:

1. Click **Create** to add the action to the flow

{% embed url="<https://app.supademo.com/demo/cmp6io2o201bh1q0jed8qy40c?utm_source=link>" %}

1. Connect the node appropriately
2. Click **Publish** to deploy the configuration

#### **Example Ask Phone Number Interaction**

Example chatbot conversation:

Bot: Hello 👋\
We need your phone number to confirm your appointment.\
Please enter it in the format: 919876543210\
\
User: 919876543210

The chatbot stores the number in the variable:

phonenumber\_collect

and continues the workflow.

### **Best Practices**

Follow these recommendations when using Ask Phone Number.

**Provide clear formatting instructions**

Tell users whether to include the country code.

**Use validation settings**

Ensure phone numbers meet the expected length.

**Provide helpful error messages**

Guide users when incorrect input is entered.

**Store phone numbers securely**

Use variables for later automation or CRM integration.

**Personalize messages**

Include dynamic variables when possible.

### **Summary**

The **Ask Phone Number** action enables chatbots to collect **valid phone numbers from users** during conversations.

{% embed url="<https://app.supademo.com/demo/cmp6irjw90016zy0j74ehopsh?utm_source=link>" %}

With Ask Phone Number, you can:

* Capture customer contact numbers
* Validate phone number format
* Limit incorrect input attempts
* Store phone numbers in variables
* Use collected data for automation and communication

This feature helps ensure **accurate contact data collection for business workflows and customer engagement**.
