Activechat Manual
  • What is Activechat?
  • New? Start here
    • The basics
    • Set up your first project
    • Install the chat widget
    • Upload the knowledge
    • Explore the CRM
    • AI-assisted live chat
      • How to set context for AI hints
    • Live chat mobile app
    • Build your first automation
  • Conversational AI
    • For Customer Service Teams
    • For Product Managers
    • For Innovation Teams
    • For Marketers
    • For e-commerce
    • For developers
  • Help Guides
    • Setting up your team
    • Managing conversations
      • Customer attributes
      • User tags and segments
      • Searching for specific users
      • Agent tags (live chat groups and queues)
      • Triggering live chat sessions from the bot
      • Notifications with the TRIGGER block
    • Managing knowledge
      • Uploading business data
      • Question answering and live chat hints
      • Fine-tuning the large language model
    • Natural language automation
    • Building automations visually
      • Customizing your welcome message
      • Adding new skills
      • Navigating skills
      • Copying skills and blocks
      • Handling errors
    • Improving your virtual agent
    • Using live chat AI hints
    • Customizing automatic website page messages
    • Tracking website actions
    • Facebook Ads automation
      • How to set up a Facebook ads bot
      • How to use buttons and quick replies in a Facebook ads chatbot
    • Lead generation
    • Zapier integrations
    • Customizing your project
      • How to customize the chat widget
      • How to customize the Facebook chat widget
      • How to change bot settings
    • Pricing guide
  • Fundamentals
    • Terminology
      • Intents and entities
      • Contexts
      • Skills and events
        • Built-in system skills
          • /start
          • /default
          • /_default_fallback
          • /_start_live_chat
          • /_page_visit
          • /_error
      • Conversation elements
        • Messages
        • Buttons
        • Quick replies
        • Galleries / carousels
    • Messaging channels
      • Website chat widget
        • Installation
        • Customization
        • Voice input
      • Chat widget landing page
      • Facebook Messenger
        • Connect your page
        • 24 hour rule
        • Message tags
        • Persistent menu
      • Telegram
      • Email
      • Twilio SMS automation
    • Intents and bot skills
    • Conversation insights
    • Grow tools
      • Landing pages
      • Messenger links and QR codes
    • Broadcasting
  • Visual builder reference
    • Sending messages
      • TEXT
      • LISTEN
      • IMAGE
      • MEDIA
      • GALLERY
      • FILE
      • EMAIL
      • SMS
      • LEAD
    • Triggering events
      • SEND
      • CATCH
      • TRIGGER
      • LIVE CHAT
    • Manipulating data
      • DATA
      • ADD TAG
      • REMOVE TAG
      • JSON
      • STATUS
      • VALIDATION
    • Conditional logic
      • SWITCH
    • Timers and delays
      • TIMER
      • WAITFOR
      • WAITUNTIL
    • E-commerce blocks
      • CATEGORY
      • PRODUCT
      • VARIATIONS
      • SIMILAR
      • UPSELLS
      • CROSSSELS
      • Shopping carts
        • ADD TO CART
        • UPDATE CART
        • SHOW CART
        • CLEAR CART
        • CREATE ORDER
    • Natural Language
      • NLP
    • System attributes
    • System events
  • Integrations
    • Google services
      • Connect your Google account
      • Google Sheets
        • Searching and updating Google Sheets data
        • Building galleries with Google Sheets data
      • Google Calendar
        • Searching for events
        • Creating and updating events
    • Shopify
    • WooCommerce
    • Dialogflow
      • Building an agent
      • Using entities
      • Slot filling
      • Context management
      • E-commerce NLP
Powered by GitBook
On this page
  • Sheet options
  • Real-time dynamic chatbot gallery generation
  • Real-life example: pizza delivery chatbot with Google Sheets integration

Was this helpful?

  1. Integrations
  2. Google services
  3. Google Sheets

Building galleries with Google Sheets data

PreviousSearching and updating Google Sheets dataNextGoogle Calendar

Last updated 3 years ago

Was this helpful?

One of the most powerful features of Activechat’s chatbot integration is the ability to build dynamic Google Sheets chatbot galleries, displaying the data in your spreadsheets based on specific search criteria. There is a whole bunch of possible use cases – product galleries in e-commerce chatbots, events of company directories, team member profiles, etc. As always with Activechat, imagination is the limit.

Example of a dynamic chatbot gallery built from Google Sheets data

Use GS-SEARCH block to build these dynamic galleries, setting up specific search criteria to limit the data displayed. There is quite a number of settings for this block, so let’s look into it in more detail.

There is a number of sections in GS-GALLERY block editor settings, let’s walk them through one by one.

Sheet options

Search

Gallery

Attributes

Attach attribute values to each of your dynamic gallery cards. When a user clicks on a button in one of the cards, these attributes will be available as $_selected_gallery_<attribute_name> in your chatbot (more on this later).

IMPORTANT: do not use whitespaces in attribute names, and use only column indices (A to XX) as values!

In the example above, there will be two attributes (“price” and “weight”) attached to each gallery card, with values from columns E and F respectively. When a user clicks the card, these will be available as $_selected_gallery_price and $_selected_gallery_weight.

Pagination

Sorting

Choose the sorting order and column to sort your results by. If there’s no column specified, the gallery will be sorted in the order of rows found.

Buttons

Real-time dynamic chatbot gallery generation

When GS-GALLERY block is executed in your chatbot conversation, Activechat will perform a search on your Google Sheet and display a dynamic gallery built from the information that is available in the Google Sheet columns. There will be a couple of attributes set after each execution so that you can build your conversation correctly:

  • $_gs_total_results will contain the total number of rows that fit your search criteria (i.e. the number of cards that this block can display)

  • $_gs_total_pages will contain the total number of rows found, divided by 10 and rounded to the next bigger integer. Actually, this will be the number of pages (10 cards each) that your dynamic gallery will contain. Use it for pagination (see real-life example below for more details).

Once the chatbot user clicks a button in one of the gallery cards, the conversation flow will continue to the skill or block associated with that button, and another set of attributes will be set to help you identify which card was clicked:

  • $_selected_gallery_title will contain the title of the card that was chosen by the user in the dynamic gallery

  • $_selected_gallery_subtitle will contain the subtitle (description) of the card that was chosen by the user

  • $_selected_gallery_image will contain the URL of the image used in this card

  • $_selected_gallery_<attribute name> will contain attribute values for the card that was set in the “Attributes” section of the GS-GALLERY block. This is useful if you need to send more data to the follow-up conversation than it’s available in title, subtitle or image fields (like price and weight for the specific product, for example).

Real-life example: pizza delivery chatbot with Google Sheets integration

Choose your spreadsheet and worksheet here. Similar to . Do not forget to first!

Set your search criteria to limit the number of gallery cards shown Again, similar to . You can combine up to three criteria for three different columns here.

Choose which columns to use for your dynamic gallery card’s title, image, and description. are not supported yet, so upload your images to a website and use direct URLs in the image column.

Indicate the page number for galleries that contain over 10 cards. The total number of Google Sheet rows that fit your search criteria will be available upon block execution as $_gs_total_results, and the total number of pages – as $_gs_total_pages . See the real-life pizza delivery chatbot below for a detailed example of using multiple-page galleries.

Finally, add up to three to each of the cards in your dynamic gallery. These can be event buttons to trigger and run when clicked, URL buttons to open specific website pages (quick hint: you can use card attributes to insert dynamic links from a specific column of your Google Sheet to URL buttons), or direct link buttons to connect other for simple tasks.

GS-GALLERY block can seem quite complex for novice chatbot developers, so we’ve made a post in our blog, describing the complete real-life example of a Google Sheets chatbot integration. Please check it here –

GS-SEARCH and GS-UPDATE blocks
connect your Google account
GS-SEARCH and GS-UPDATE blocks
Embedded Google Sheets images
system attributes
Building an advanced restaurant delivery chatbot with Google Sheets integration
chatbot events
skills
chatbot building blocks
buttons
Google Sheets
GS-GALLERY block settings (click to enlarge)