Add a bot to Google Sheets using the official integration.
Open in HubvThe Google Sheets integration allows your bot to access and update Google Sheets data in real-time, automating tasks like CRM updates, inventory management, and survey tracking directly within chat.
Open the left sidebar and go to API & Services > Credentials.
2
Select + Create Credentials > Service Account.
3
Enter a Service account name. The Service Account ID will be automatically generated.
4
The remaining fields are optional. Select Done to create the service account.
5
Select your newly created service account, then go to the Keys tab.
6
Select Add Key > Create new key, choose JSON as the key type, then select Create.A JSON file will be downloaded to your machine. Keep this file secure—you’ll need it to configure the integration.
The downloaded JSON file contains sensitive credentials. Store it securely and never share it publicly. The file structure looks like this:
In Botpress Studio, select Explore Hub in the upper-right corner.
2
Search for the Google Sheets integration, then select Install Integration.
3
In the Configuration menu, select the drop-down and choose Configure manually with a Service Account Key.
Fill in the integration’s configuration fields:
Spreadsheet ID
Open your Google Sheets spreadsheet in your browser.
Copy the ID from the URL. The ID is the string between /d/ and /edit in the URL.
For example, if your URL is https://docs.google.com/spreadsheets/d/1AbCdEfGhIjKlMnOpQrStUvWxYz/edit, the Spreadsheet ID is 1AbCdEfGhIjKlMnOpQrStUvWxYz.
Client Email
Open the JSON file you downloaded in Step 3 and copy the client_email value.
Private Key
Open the JSON file you downloaded in Step 3 and copy the entire private_key value, including the -----BEGIN PRIVATE KEY----- and -----END PRIVATE KEY----- markers.
When you’ve filled in all the fields, select Save Configuration.
You’ve successfully configured the Google Sheets integration!