How can we help?

Using the Identity Voice Biometrics Opt-In API to automatically ask users consent in the IVR

Follow

With Voice Biometrics Opt-In API, it is possible to get the consent status of a given contact so that the enrollment is triggered accordingly, without the need for human intervention.

 

Obtaining an OAuth client to call the API

image14.png

In order to get access to any Talkdesk API, please follow the instructions provided on  Creating a new OAuth client.

Note: If you don’t have the app, the above article also explains how to request access.

 

Below, you can find a screenshot with the settings for the OAuth client needed to access the Identity Voice Biometrics Opt-In API.

print.png

Note: In the “Grant Type”, only the “Client credentials” and “Refresh token” checkboxes are selected. You will need to select the “voicebiometrics-consent:write” scope if you intend to set the consent status, and/or the “voicebiometrics-consent:read” if you intend to read it.

After saving the new OAuth client, make sure to save the Client ID and Client Secret information, since it will be required in the next steps.

 

Configuring an Integration

In order to be able to use the API in the Studio flow, you first need to configure an integration:

image7.png

1. On Admin [1], go to Integrations [2] and click Add integration [3].

 

image8.png

2. Select the Custom Integration [4] option and choose Add integration [5].

3. Fill in the integration details as per the following screenshot:

 

image4.png

  • Basic information [6] :
    •  “Name”: pasteIdentity Voice Bio Opt-In API”.
    • “Description: paste “Identity Voice Biometrics Opt-In API to read and set the user consent status”.
  •  Copy and paste on the Base path [7] field: api.talkdeskapp.<region>/voicebiometrics/contacts.
  • Select the Authentication type [8].
  • Insert the OAuth “Client ID” [9].
  • Place the OAuth “Client Secret” [10].
  • “Access Token URL”: Place your_org.mytalkdesk.<region>/oauth/token and replace <your_org> (including the <>) with your account name [11]. You can check your account name in your browser URL: https://your_org.mytalkdesk.<region>/.
  • Choose the “OpenID Auth Scheme” [12].

Tip: Adjust the URL domains to your regional cloud domain (replace <region> with com, eu, ca, etc.) on BOTH the Base Path URL and the Access Token URL. Make sure that both “Base path” and “Access Token URL” are set to “https://”.

  • Click Save in the top right corner of the page.

 

Configuring an action to set the opt-in status

image3.png

1. Go to the Actions section [1] and click on Add action [2].

 

image6.png

2. Fill in the “Basic information” [3] for the action with:

  • Name: “Set Opt-in Status”.
  • Description: “Sets the opt-in status for Voice Biometrics”.

image11.png

  1. Add the URL details with the values by copy/pasting: 
  • “Relative path” [4]: /{{contact_id}}/consent
  • “Display name” [5]: contact_id
  • Set the relative path method to PUT [6].

image1.png

4. In the “Inputs and Outputs” section, fill in the “Input Schema” [7] with the following values:

{
  "$schema": "http://json-schema.org/draft-04/schema#",

 "type": "object",

"properties": {


"status": {

"title": "status",


"type": "string"


}

},

"required": [

"status"


],

"additionalProperties": false

}

5. On the top right of the page, select Save as Draft.

6. Go back to the “Actions” tab and click on the newly created action.

7. On the top right of the Action page, select Test Action.

8. Fill in a random contact_id (any number of your choice, “123” for example) and in the “Input JSON” paste the code in the screenshot.

{

"status": “CONSENTED”
}

 

image2.png

9.  To test the action, click Execute.

10. You can now publish the action by selecting the Publish button in the top right corner of the page.

 

Configuring an action to read the opt-in status

image3.png

1. Go to the Actions [1] section and click Add action[2].

 

image9.png

 

 2. Fill in the “Basic information” [3] for the action with:

  • Name: “Read Opt-in Status”.
  • Description: “Reads the opt-in status for Voice Biometrics”.

image13.png

  1. Add the URL details with the values by copy/pasting: 
  • “Relative path” [4]: /{{contact_id}}/consent
  • “Display name” [5]: contact_id
  • Set the relative path method to GET [6].

image12.png

4. In the “Inputs and Outputs” section, fill in the “Output Schema” [7] with the following values:

{

  "$schema": "http://json-schema.org/draft-07/schema#",

"type": "object",

"title": "HTTP connector",

"required": [],

"properties": {


"status": {

"title": "status",


"type": "string"
}

}
}
  1. On the top right of the page, click Save as Draft.
  2. Go back to the Actions tab, and select the newly created action.
  3. On the top right of the action page, choose Test Action.

image9.png

  1. Fill in a random contact_id (any number of your choice, “123” for example). To test the action, click Execute. You should see the API output without any errors.
  2. Click on the Publish button in the top right corner of the page.

 

Using the Integration in Studio to set the consent

The “Execute Action” component in Studio allows you to use an integration in a studio flow. Please see the component documentation here.

To set up the component to set the consent to enroll in voice biometrics, please follow these steps:

image5.png

1. Add a new “Execute Action” component, by clicking Add step [1].

 

image10.png

2. Select the Connection [2] and Action [3] created in the previous step. Put in the Voice Biometrics ID (in this case the source phone number) and the “CONSENTED keyword [4] as “status”.

This component can now be used to confirm that the user consented that their voice was collected for voice authentication. You can use it, with an input IVR, to automatically ask the user if he wants to enroll and route to this component.

 

Using the Integration in Studio to get the consent status

You might need to understand if a user already gave their consent. To set up an execute action component, please follow these steps:

image15.png

1. Add a “Execute Action” component, like in the previous point, but place “Get Voice Biometrics Opt-In” in the “Step Name”.

2. Select the “Connection” [1] and “Action” [2] created in the previous step and the “Read opt-in status” action. Put in the Voice Biometrics ID (in this case the source phone number) as the contact_id [3].

3. You can now map the consent status to an output variable (consent_status in this case) [4]. If the variable content is equal to “CONSENTED” it means that the user already gave their consent for his voice to be used for Voice Biometrics Authentication.

 

 

All Articles ""
Please sign in to submit a request.