Build with

Use your application’s verified identity to find a returning customer’s help-desk record. The worked example retrieves a Zendesk user by their verified email, then retains the provider ID for authorized support tasks. Finding an email match does not authenticate the person chatting.

Before you begin

  • An application sign-in or other identity-verification process, and an existing test customer in the help desk.
  • A backend mapping for your authenticated customer ID, verified email and provider record ID. Keep the provider ID separate from Voiceflow’s runtime userID.
  • The Zendesk ticket-tool connection or the relevant provider’s customer-read setup.

The example uses Maya Chen and maya@northstar.example. These are illustrative records, not credentials or identity evidence.

Studio

Open Agent studio and choose the test project. In More → Variables, create the variable you will use for the verified email with an empty default. Your application must supply it after verifying the customer and before the lookup; do not ask the agent to treat any typed email as verified.

Code

Use a Voiceflow bearer credential with access to the test project and Environment. Keep it on your backend or development machine. Set:

Install the current Voiceflow CLI if you choose CLI. Both examples below use VF_TOKEN. Standalone tool execution uses the Environment’s Draft; it does not attach a tool to an agent or publish it.

Match the customer record

1

Resolve identity in your application

Use the authenticated customer’s ID to obtain the verified email from your backend. For a returning customer with a stored provider ID, validate that mapping before reuse. If identity is not established, offer general support information or your sign-in path; do not expose saved cases.

When passing values to a conversation, populate them through your trusted integration before the lookup. Merely creating a Voiceflow session does not populate your customer variables. Follow runtime action variables for your client and customer-variable binding for the project.

2

Find and validate the help-desk customer

Studio

Add Zendesk → Find user to the agent’s Global tools or relevant Playbook. Bind email to the verified-email variable supplied by your application. The capture identifies the email input; open it to set the verified variable for the deployed path.

Test Find user with a known customer, then bind the verified identity. Photo:

Run a test lookup and inspect the returned user ID and email. Use Capture response only after checking the actual result paths.

Code

Require success: true, error: null and truncated: false before using output.data. An HTTP 200 alone does not establish that the provider action succeeded.

The lookup returns the first matching user. Compare output.data.email and the expected account association with your verified customer; do not accept a different result merely because a search returned it. Retain output.data.id only after that check.

3

Use the mapping for the next support task

Store the verified provider user ID with your application customer ID. Use the smallest permitted set of fields for personalization, such as the customer’s display name. For ticket history, retrieve only request IDs your backend has associated with that customer, then perform the request access check before reading them.

The Zendesk Find user action does not list the customer’s tickets. Do not promise a full support history from that one result. Pass the permitted customer and request context to Human agent hand-off when escalation is needed.

Verify customer isolation

Test a known customer, a customer with no matching provider record and an attempted lookup of another customer’s record. Confirm that only the known authorized customer receives personalized data, and that failed matches expose no ticket history.

For another help desk, use its identity model and identifiers: Intercom contacts, Gorgias customers, Chatwoot contacts or Freshchat users. Provider tokens authorize system access; they do not establish the end customer’s identity.

The email matches but the customer association is uncertain

Stop personalization until your application can establish the mapping.

Check duplicate or changed email records with your support administrator. Do not let the model choose a person from similar search results. Repair the backend association, repeat the known-customer test and retain the resulting provider ID only after validation.

Use the up and down arrow keys to select a result, Enter to open it, and Escape to close the search.