Configurar el servicio de inicio de sesión único (SSO) de Google con Twilio Flex
Twilio está lanzando una nueva consola. Algunas capturas de pantalla de esta página pueden mostrar la consola heredada y, por lo tanto, es posible que ya no sean precisas. Estamos trabajando para actualizar todas las capturas de pantalla a fin de reflejar la nueva experiencia de la consola. Obtén más información acerca de la nueva consola.
¿Ya has configurado SSO con el punto final preview.twilio.com
? Aprende a actualizar tu configuración existente con la Guía de migración de SSO de Flex. Además, Twilio todavía no admite flujos de SSO iniciados por SP con SSO de Google. En este momento, solo se admiten flujos de SSO iniciados por el IdP.
Google SSO (Single Sign-On) allows users to use their existing Google account to authorize third-party applications. This allows users to easily login to applications without needing to set up a new account, or create a new set of credentials. In this guide, you will learn how to configure Google SSO with Twilio Flex.
Prepare your Google App environment
Before we connect Google to your Flex Instance, you have to configure a few steps in the Google Admin Console to ensure your app runs smoothly.
To log in a Flex user, you must pass three mandatory attributes to Flex in the SAML. Google provides email as an attribute out of the box but does not provide the roles or full_name attributes. You will need to configure these attributes yourself.
Toda la información que el proveedor de identidad proporcione a Twilio se almacena dentro de los atributos de trabajador de Twilio TaskRouter. Considera las normativas locales para almacenar datos y proporciona solamente aquellos que sean relevantes para el uso de Flex. Obtén más información sobre la política de privacidad de Twilio aquí.
- Navigate to the User Schema page in your Google Admin Console.
- Click on ADD CUSTOM ATTRIBUTE.
- Enter “Flex Details” for Category.
- Create the "Roles" and "Full Name" attributes below.
- Click Add to save your custom attributes.
Optionally, you can add more attributes to accommodate the attributes needed by WFO (Workforce Optimization).
Create a custom SAML app
SAML apps allow you to use Single Sign-On to authenticate once with a single set of credentials. You can then access different secured applications without needing to authenticate with different credentials each time.
- Navigate to Google Admin Console and click on Apps.
- Click Web and mobile apps
- Click on Add app > Add custom SAML app
- Enter the App name, then click Continue.
- Copy your
SSO URL
andEntity ID
and save them somewhere - you’ll need these later. - Download your Certificate.
- Click Continue to proceed over to the Service provider details step.
Service Provider details
A continuación, debemos configurar los detalles del proveedor de servicios. En este caso, Twilio Flex es el proveedor de servicios.
Ajuste | Valor |
ACS URL (URL de ACS) | https://iam.twilio.com/v1/Accounts/ACxxxx/saml2
Asegúrate de reemplazar el Account SID (SID de cuenta) (ACxxxx) con tu Account SID real. |
Entity ID (ID de entidad) |
Asegúrate de reemplazar el Account SID (SID de cuenta) (ACxxxx) con tu Account SID real. |
Start URL (URL de inicio) |
Este enlace de inicio de sesión está disponible en la página de configuración de SSO de la consola de Twilio. |
Signed Response (Respuesta firmada) | ¡Verificado! |
Name ID Format (Formato de ID de nombre) | CORREO ELECTRÓNICO |
Name ID (ID de nombre) | Basic Information > Primary Email |
Attribute mapping
Now we need to add attributes that will be passed from the SAML to Flex. Create the three required attributes (case sensitive) to pass to Flex and map them to the appropriate fields.
Note You need to ensure that you configured the Full Name and Roles attribute from Prepare your Google App environment. Otherwise, these attributes will not appear under the Google Directory attributes.
Add the mapped roles to your G Suite Users
- Navigate to Google Admin Console and click on Users.
- Select a user and click on their User information section
- Scroll to Flex Details, the category name you set for the custom attributes during Step 4 in Prepare your Google App environment.
- Click on the edit icon and add your roles. The current options are
agent
,admin
, andsupervisor
.
Completar la configuración
Now that you’ve configured your app, you must:
- Verify your domain if you haven’t already. See Verify domain ownership.
- Enable your SAML app. See the Turn on your SAML app section on Set up your own custom SAML application.
Configure Flex with your Google SSO settings
Grab the URLs you copied from Step 5 in Create a custom SAML app, and configure SSO on the Flex Console Single Sign-on settings page. Be sure that the Twilio SSO URL field matches the value you provided in Google for ACS URL. To learn more about migrating from the preview.twilio.com
URL to iam.twilio.com
see our migration guide.
Ajuste | Valor |
Friendly Name (Nombre descriptivo) | Cualquier cosa que quieras |
x.509 Certificate (Certificado X.509) | Abre el archivo .pem que descargaste anteriormente en tu editor de texto favorito y copia/pega todo el contenido del archivo, incluidos todos los guiones. |
Identity Provider Issuer (Emisor del proveedor de identidad) | ID de entidad de Google (ver más arriba) |
Single Sign-On URL (URL de inicio de sesión único) | URL de SSO de Google (ver más arriba) |
Default Redirect URL (URL de redirección predeterminada) |
Este enlace de inicio de sesión está disponible en la parte superior de la página de configuración de SSO activa. |
Inmediatamente después de haber configurado tu IdP para usar la URL iam.twilio.com
, debes actualizar la URL de SSO de Twilio para tu cuenta; para ello, selecciona el botón de opción USES IAM.TWILIO.COM
.
Additional SSO configuration
Nuestra página de configuración de SSO ofrece información adicional sobre cómo iniciar sesión desde tu proveedor de identidades, cómo iniciar sesión en un dominio autoalojado y detalles sobre los atributos que se pueden definir para cada identidad.
Testing Google SSO
Navigate to the Google SSO IdP URL (see above) in incognito mode, login, and you should be redirected to Flex.
Congrats! You now know how to configure Google SSO with Twilio Flex. You can now authenticate yourself into Twilio Flex using your Google account!
¿Necesitas ayuda?
Todos la necesitamos a veces; la programación es difícil. Obtén ayuda ahora de nuestro equipo de soporte, o recurre a la sabiduría de la multitud visitando Stack Overflow Collective de Twilio o navegando por la etiqueta de Twilio en Stack Overflow.