The integration of Google Sheets into your bot can help to simplify reading and writing mass data  from a structured file as answers, for example. To integrate Google Sheets, follow the instruction 🙂

You can structure an answer in a classical way as a sequence of text boxes/buttons/etc., e.g.:

But if your bot is of a very complicated structure, then you may want to connect your bot to Google Sheets to import test for answers, for example. Let’s structure an alternative answer, using import from Google Sheets.

Please note that you have strict rules how to create a Google sheet to import data or to write them in. These rules are written when you add the feature of integration to your answer:

In general, as an example, your Google sheet should look like that:

  1. To do that, you need to open an answer and to add Google Sheets integration:
  2. You need to give an access to your Google drive to Odus:
  3. And then to choose a Google sheet from the list:
  4. Then you fill in the form below. For the case of reading data from the file, you choose first a type of ID dependent of what you wrote down in the first column of a file as Odus_ID. You can choose User ID from History section, values of tags, shortcodes you used in the bot or custom values as Odus_ID: For example, in the file numbers as custom values are used as IDs: If you use custom values as Odus ID, you need to input a custom value for a row you want to return as an answer in the integration form for Google Sheets:
  5. Or they can be changed to values of tags since tags are used in this bot: So, you choose ID from the list:
  6. Then you choose the column you want to input data from (the column “Questions” in the Google Sheet is stated just for information to define the question an answer is referred to):
  7. In the last row here you need to give a name to a value you inout as an answer. This name is called a shortcode in the context of Google Sheet integration:
  8. To complete filling in an answer, you need to write a shortcode for the value of input into the text space in the answer: You are done! Now your bot will return a value from the integrated Google Sheet as an answer 🙂

The second option you can do with integrated Google Sheets is writing an answer in a table. The writing option allows you to write into your Google sheet table the intent that led a user to this answer. To do this, you follow exactly the same logic: you choose “Writing” as an option of integration, then define Odus_ID as an identification key from the same options (User_ID, values or tags, shortcodes you used in the bot or custom values) and then you specify the column where you want to write down the intent. The example of the set up of the integration for the example above is in the picture: