Eedesy
Book Demo
HomeProductsContact
Zapbot
  • Introduction
  • Overview
  • Graph Editor
  • Variables
  • Publish
  • Share
  • Context Menu
  • Export & Import
  • Overview
  • Text Bubble
  • Image Bubble
  • Video Bubble
  • Audio Bubble
  • Embed Bubble
  • Text Input
  • Number Input
  • Email Input
  • Phone Input
  • Date Input
  • Buttons
  • Picture Choice
  • Rating
  • File Upload
  • Payment
  • Set Variable
  • Condition
  • Redirect
  • Script
  • Zapbot Link
  • Wait
  • Jump
  • A/B Test
  • Webhook
  • Google Sheets
  • HTTP Request
  • OpenAI
  • Anthropic Claude
  • ElevenLabs
  • Google Analytics
  • Meta Pixel
  • Zapier
  • Make.com
  • Chatwoot
  • Zendesk
  • Send Email
  • Overview
  • HTML & JavaScript
  • React
  • Next.js
  • WordPress
  • Webflow
  • iFrame
  • Custom Domain
  • WhatsApp
  • Theme Overview
  • Custom Fonts
  • Bot Settings
  • Remember User
  • Overview
  • Analytics
  • How to Get Help
  • Creating Loops
  • UTM Tracking
  • Multiple Avatars
  • RTL Support
  • FAQ

Related Products

  • AI Voice Agent
  • AI Voice Assistant
  • Try Free
Zapbot
  • Introduction
  • Overview
  • Graph Editor
  • Variables
  • Publish
  • Share
  • Context Menu
  • Export & Import
  • Overview
  • Text Bubble
  • Image Bubble
  • Video Bubble
  • Audio Bubble
  • Embed Bubble
  • Text Input
  • Number Input
  • Email Input
  • Phone Input
  • Date Input
  • Buttons
  • Picture Choice
  • Rating
  • File Upload
  • Payment
  • Set Variable
  • Condition
  • Redirect
  • Script
  • Zapbot Link
  • Wait
  • Jump
  • A/B Test
  • Webhook
  • Google Sheets
  • HTTP Request
  • OpenAI
  • Anthropic Claude
  • ElevenLabs
  • Google Analytics
  • Meta Pixel
  • Zapier
  • Make.com
  • Chatwoot
  • Zendesk
  • Send Email
  • Overview
  • HTML & JavaScript
  • React
  • Next.js
  • WordPress
  • Webflow
  • iFrame
  • Custom Domain
  • WhatsApp
  • Theme Overview
  • Custom Fonts
  • Bot Settings
  • Remember User
  • Overview
  • Analytics
  • How to Get Help
  • Creating Loops
  • UTM Tracking
  • Multiple Avatars
  • RTL Support
  • FAQ
  1. Docs
  2. Zapbot
  3. Guides
  4. Creating Loops

Creating Loops

Learn how to implement dynamic loops to collect repeated information from users in your chatbot.

Creating Loops

Video tutorial available in the Zapbot dashboard

In this guide, we demonstrate how to implement a dynamic loop to collect guest names for a restaurant reservation chatbot.

Overview

We walk through setting up the chatbot to request the number of guests, and then, using JavaScript, create a list based on this number.

How It Works

  1. Ask for count: Request the number of guests from the user
  2. Create a list: Use the 'Shift' set variable value to iterate through this list
  3. Collect information: Store each guest's name through the loop

Implementation

Despite the lack of a specific loop block in the platform, you can create loop-like behavior through custom code using the Set Variable block.

Key Concepts

  • Use JavaScript in the Set Variable block to manage iteration
  • The 'Shift' operation removes and returns the first element of an array
  • Connect blocks to create the looping behavior
  • Use conditions to check when the loop should end

Example: Guest Name Collection

  1. Ask "How many guests will be attending?"
  2. Store the number in a variable
  3. Create an array with that many empty slots
  4. Loop through each slot, asking for a guest name
  5. Store all names in a results array
Previous
How to Get Help
Next
UTM Tracking

On this page

  • Overview
  • How It Works
  • Implementation
  • Key Concepts
  • Example: Guest Name Collection

Stay Updated

Get the latest updates on AI voice technology, product releases, and exclusive resources.

Get Started

Try our products for free
AI Voice Agent
Build voice AI for calls
WhatsApp AI Bot
Automate WhatsApp chats
Website Chatbot
AI chat for websites
Edesy CRM
Manage leads & customers
Book a DemoCall UsEmail Us
Eedesy

Your all-in-one platform for digital innovation. We build AI-powered solutions that transform how businesses operate.

[email protected]+91 95475 31359

Products

  • AI Voice Assistant
  • WhatsApp Voice AI
  • WhatsApp Bot Builder
  • AI Website Chatbot
  • AI-SDR
  • Number Masking
  • Shopify Apps
  • View All Products

Solutions

  • For E-commerce
  • For Healthcare
  • For Real Estate
  • For Restaurants
  • For Appointments
  • View All Use Cases

Services

  • AI Chatbot Development
  • Voice AI Development
  • Shopify Development
  • SaaS Development
  • WhatsApp API Integration
  • View All Services

Resources

  • Documentation
  • Voice Agent Docs
  • API Reference
  • Number Masking API Docs
  • Blog
  • Changelog
  • Book a Demo

Company

  • About Us
  • Contact
  • Careers
  • Privacy Policy
  • Terms of Service

Products

  • AI Voice Assistant
  • WhatsApp Voice AI
  • WhatsApp Bot Builder
  • AI Website Chatbot
  • AI-SDR
  • Number Masking
  • Shopify Apps
  • View All Products

Solutions

  • For E-commerce
  • For Healthcare
  • For Real Estate
  • For Restaurants
  • For Appointments
  • View All Use Cases

Services

  • AI Chatbot Development
  • Voice AI Development
  • Shopify Development
  • SaaS Development
  • WhatsApp API Integration
  • View All Services

Resources

  • Documentation
  • Voice Agent Docs
  • API Reference
  • Number Masking API Docs
  • Blog
  • Changelog
  • Book a Demo

Company

  • About Us
  • Contact
  • Careers
  • Privacy Policy
  • Terms of Service
  • AI Voice Assistant
  • WhatsApp Voice AI
  • WhatsApp Bot Builder
  • AI Website Chatbot
  • AI-SDR
  • Number Masking
  • Shopify Apps
  • View All Products
  • For E-commerce
  • For Healthcare
  • For Real Estate
  • For Restaurants
  • For Appointments
  • View All Use Cases
  • AI Chatbot Development
  • Voice AI Development
  • Shopify Development
  • SaaS Development
  • WhatsApp API Integration
  • View All Services
  • Documentation
  • Voice Agent Docs
  • API Reference
  • Number Masking API Docs
  • Blog
  • Changelog
  • Book a Demo
  • About Us
  • Contact
  • Careers
  • Privacy Policy
  • Terms of Service

Popular Free Tools

Compress PDFMerge PDFPDF to WordGST CalculatorEMI CalculatorSIP CalculatorJSON FormatterBase64 EncoderImage CompressorQR Code GeneratorVoice AI ROI CalculatorAmazon FBA CalculatorAI Email WriterVideo to GIFPrivacy Policy GeneratorCRM ROI CalculatorMeeting Cost Calculator
Categories:PDF ToolsDeveloper ToolsFinance CalculatorsImage ToolsVideo ToolsAI Writing ToolsAudio ToolsWhatsApp ToolsDocument GeneratorsVoice AI ToolsE-commerce ToolsView All Tools

© 2026 Edesy Technology Labs Pvt Ltd

SSL Secured
99.9% Uptime