Skip to content

Is There a Way to Pass Dynamic Attributes to an AWS Connect Campaign Before Dialing?

0

We are facing a significant latency issue with AWS Connect Campaigns because we cannot find a way to set per-contact attributes before a call is dialed. This forces our contact flow to perform a data lookup during the call, resulting in 10-15 seconds of silence for the customer.

When creating a single outbound call, we can pass attributes in the initial request. This makes all data instantly available to the contact flow.

response = client.start_outbound_voice_contact(
    destination_phone_number=customer_phone_number,
    contact_flow_id=contact_flow_id,
    instance_id=instance_id,
    source_phone_number=source_phone_number,
    attributes=attributes
  )

With Campaigns API connect_campaign_v2_client.create_campaign, the call is initiated without these attributes, creating a poor customer experience:

  1. The campaign dials the number.
  2. The contact flow starts and triggers a Lambda to fetch data for that phone number.
  3. The customer answers quickly.
  4. The customer waits in silence while the data lookup completes.

How can we pass a unique set of attributes to contact flow for each contact in a campaign dialing list before the call is initiated?

1 Answer
0

For outbound calls initiated from Amazon Connect Campaigns, contact attributes are typically set only after the call is established. This differs from single outbound calls where you can pass attributes in the initial request.

Currently, there isn't a direct way to pass dynamic attributes to an AWS Connect Campaign before dialing for each contact in the campaign list. For outbound calls, contact attributes are usually populated once the call transitions to the "Connected" state, which explains the latency you're experiencing.

To address your latency issue, you have a few potential workarounds:

  1. Pre-store customer data in a more quickly accessible location (like DynamoDB) to reduce Lambda lookup time.

  2. Use the caller ID number dynamically in your flow to help identify the customer. You can set the outbound caller ID number using an attribute in the Call phone number block. This attribute can be defined in a Set contact attributes block or returned from a Lambda function. The value must be a phone number from your instance in E.164 format.

  3. For the dialed number identification, you can use the System attribute "Channel.Address" in your contact flow to identify which number was dialed, and then use a Check contact attributes block to route based on this information.

  4. Consider implementing a caching mechanism in your Lambda function to speed up data retrieval.

The fundamental limitation is that for campaign-based outbound calls, the attributes are only available after connection, unlike single outbound calls where you can pass attributes in the initial API call. This behavior difference between campaign calls and single outbound calls is a known characteristic of Amazon Connect's architecture.
Sources
Contact Attributes not loading before call gets connected for outbound calling | AWS re:Post
Set up outbound caller ID in Amazon Connect - Amazon Connect
Question related to amazon connect flow | AWS re:Post

answered a year ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.