Skip to contentSkip to navigationSkip to topbar
On this page

Manage Conversations Addresses for Google Business Messages (Public Beta)


(error)

End of Life

Google Business Messages (GBM) will be turned off on July 31, 2024. The Twilio GBM API and Google Business Profiles chat will no longer work after that point.

Learn more about the GBM End of Life from Google(link takes you to an external page).

(information)

Info

Not a HIPAA Eligible Service
Google Business Messages for Flex is not a HIPAA Eligible Service and cannot be used in Flex workflows that are subject to HIPAA.


Overview

overview page anchor

This guide describes how to add Google Business Messages (GBM) as a Conversations channel in Flex. Once added, customers can start chats with Flex agents directly from Google Search and Google Maps. Customers must message you first, as agent-initiated outbound messages are not supported.

To learn more about supported functionality, see Google Business Messages.

Limitations

limitations page anchor

For limitations, see File Attachments and API Limits and Known Issues.


Add Google Business Messages to Flex

add-google-business-messages-to-flex page anchor
  • Twilio Console(link takes you to an external page) account with Admin access
  • Flex UI v2.4.x or later
  • Google Business Profile

Step 1: Create a sender in the Twilio Console

step-1-create-a-sender-in-the-twilio-console page anchor
  1. In the Twilio Console(link takes you to an external page) , from the Develop sidebar, click Explore Products .
  2. Under Marketplace , click Channels . Tip : To pin Channels to the sidebar for access later, click the pin icon.
  3. In the sidebar, click Google Business Messages .
  4. Click Get Started.
  5. In the Your first sender window, enter a brand, sender, and email address.

    • The brand is usually the name of your company. This is visible to you, Twilio, and Google, but isn't shown to end users. Twilio recommends using only one brand per Twilio account SID or Subaccount SID. If you create more senders in the future, you can reuse the same brand.
    • A sender is the address used to interact with the business. The sender name is visible to end users. Note that Google calls the sender an "agent."
    Google_Business_Messages_New_Sender.
  6. Click Submit . Your sender is created in Twilio so you can test it right away, but it isn't connected to your Google Business Messages yet.

Step 2: Create a Conversations address

step-2-create-a-conversations-address page anchor

To receive and respond to messages in Flex, you can create a Conversations address for Google Business Messages from the Console or with the Conversations API.

Console

console page anchor
  1. In the sidebar, click Flex > Manage > Messaging .
  2. Click Create New Address .
  3. From the Address Type list, select Google Business Messages.

    Google_Business_Messages_New_Address.
  4. From the Sender name , select your sender.
  5. From the Integration type list, select how you'd like conversations to pass to Flex, via Studio or Webhook .
    - If you selected Studio , from the Studio Flow list, you can select the out-of-box Messaging Flow , unless you have removed or reconfigured your studio flow.
    - To learn more about configuring Studio Flows, see Configure pre-agent workflow with Studio and Set up a Studio Flow chatbot to respond to GBM messages. Twilio recommends setting up a chatbot to provide prompt responses and clear escalation paths to end users.
  6. Click Create Address .

You can programmatically create and manage a GBM address using the Conversations API's Address Configuration Resource.

Create a Google Business Messages Address via the APILink to code sample: Create a Google Business Messages Address via the API
1
// Download the helper library from https://www.twilio.com/docs/node/install
2
const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";
3
4
// Find your Account SID and Auth Token at twilio.com/console
5
// and set the environment variables. See http://twil.io/secure
6
const accountSid = process.env.TWILIO_ACCOUNT_SID;
7
const authToken = process.env.TWILIO_AUTH_TOKEN;
8
const client = twilio(accountSid, authToken);
9
10
async function createConfigurationAddress() {
11
const addressConfiguration =
12
await client.conversations.v1.addressConfigurations.create({
13
address: "gbm:<sender_id>",
14
"autoCreation.enabled": true,
15
"autoCreation.studioFlowSid": "FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
16
"autoCreation.type": "studio",
17
type: "gbm",
18
});
19
20
console.log(addressConfiguration.sid);
21
}
22
23
createConfigurationAddress();

Output

1
{
2
"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
3
"sid": "IGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
4
"address": "gbm:<sender_id>",
5
"type": "gbm",
6
"friendly_name": "My Test Configuration",
7
"address_country": "CA",
8
"auto_creation": {
9
"enabled": true,
10
"type": "webhook",
11
"conversation_service_sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
12
"webhook_url": "https://example.com",
13
"webhook_method": "POST",
14
"webhook_filters": [
15
"onParticipantAdded",
16
"onMessageAdded"
17
]
18
},
19
"date_created": "2016-03-24T21:05:50Z",
20
"date_updated": "2016-03-24T21:05:50Z",
21
"url": "https://conversations.twilio.com/v1/Configuration/Addresses/IGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
22
}

Step 3: Test your setup with a mobile device

step-3-test-your-setup-with-a-mobile-device page anchor

Twilio creates sender test links for iOS and Android, so you can test your sender and see what your customers will experience on a mobile device.

  1. In the Console, go to Channels > Google Business Messages , and select the Sender .
  2. From Sender Test Links, click Android or iOS. You can send the copied link to yourself in an email or WhatsApp message, for example, so you have access to the link on your mobile device.

    Google_Business_Messages_Test_Links.
  3. On your mobile device, open the link to send a message as a customer.
  4. Open the Flex UI and log in as an agent.
  5. Set your status to Available .
  6. Accept the Incoming chat request and type a reply. The reply appears in Google Business Messages.

    Google_Business_Messages_Agent_and_User.

Step 4: Complete verification

step-4-complete-verification page anchor
  1. In Channels > Google Business Messages , select the Sender .
  2. Review the sender details and click Verify Sender . The sender shows as Pending verification in the Console.
  3. To complete verification, follow steps 3-5 in Google's Business Messages .

Need some help?

Terms of service

Copyright © 2024 Twilio Inc.