Amazon Connect Outbound Campaign is a feature of cloud-based contact center Amazon Connect by Amazon Web Services (AWS) that allows businesses to proactively reach out to customers.
Using Amazon Connect Outbound Campaign, businesses can create automated outbound campaigns to connect with their customers for various use cases, such as appointment reminders, service notifications, marketing offers, and customer surveys.
Amazon Connect Outbound Campaign can be configured to be used with agents or agentless.
Below solution showcases how to use 'Amazon Connect Agentless Outbound Campaign' using AWS Step Functions.
Note: This solution uses low-code AWS Step Functions to orchestrate the process and API calls for implementing agentless amazon connect outbound campaign to minimize the coding skill required
Below are the services that are required for deploying the solution.
Follow the below steps to deploy this solution;
- Java 11 or later. If missing install Amazon Corretto Java 11 from here.
java -version
- Maven 3.8 or later. If missing install Maven from here.
- Note: Java version showed in the below output should be 11 or later.
mvn -version
- AWS CLI. If missing install AWS CLI from here.
aws --version
- Node.js 18.x or later. If missing install Node.js from here.
node -v
- AWS CDK - Install the AWS CDK Toolkit globally using the following command:
npm install -g aws-cdk
cdk --version
-
Important Note:
-
CDK Bootstrap - Bootstrap your AWS account for CDK. This only needs to be done once per account/region.
cdk bootstrap aws://<account>/<region>
Clone the repository and navigate to the project directory.
git clone <repo-url>
cd amazon-connect-agentless-outbound-campaign
Run below build command from the root directory of the project.
mvn clean install
Change to the Infra directory of the project.
cd Infra
Run the below command to deploy this solution.
cdk deploy
Below is the sample output of the CDK deploy command.
Below is the sample output of the Cloudformation Stack created by CDK.
Navigate to the Amazon Connect instance, and enable the feature as shown below; This feature is required by check-call-progress Flow block used for Automatic Machine Detection(AMD).
-
Navigate to Amazon Connect Portal by clicking on "Emergency Access" as shown on the screenshot below;
- Note: You can create User for any future access to Amazon Connect Portal.
- Please follow the steps on how to create User. here
-
CDK will claim a toll-free phone number in order to make outbound calls.
-
Navigate to Queues and click on 'Basic Queue' to modify the Default Outbound Caller ID name and number. here
-
Modify the Default Outbound Caller ID name and number as shown in the below screenshot.
Navigate to your Amazon S3 bucket with unprocessed folder as shown in the below screenshot.
- Download this sample CSV file Sample CSV File
- Open in Text Editor (Don't open in Excel as it will change the format of the file)
- Replace the phone number with your valid number E164 format. Example: +12345678901
- Upload the sample CSV file(contact_example_import.csv) to the unprocessed folder with your valid number.
Important Note:
- Make sure you are uploading numbers that you own or have permission to call.
- Both Amazon S3 and Amazon DynamoDB where Data is stored are encrypted by this solution.
- Amazon Connect Outbound Campaign Voice calling is available only in the these countries.
- File name (contact_example_import.csv) should not be changed. If you want to change the filename then don't forget to change the filename in the Step Function Intake process as well.
Below is the detail of the AmazonConnectAgentlessOutboundCampaign-Contacts table created by CDK.
- This will be used to store the contact list imported from the S3 bucket.
- | Attribute Name | Attribute Type | Key Type |
- | phoneNumber | String | Primary Key |
- | userLanguage | String | Sort Key |
Below is the detail of the AmazonConnectAgentlessOutboundCampaign table created by CDK.
- This will be used to store the campaign execution details.
- | Attribute Name | Attribute Type | Key Type |
- | campaignExecutionId | String | Primary Key |
- | phoneNumber | String | Sort Key |
This step will import the contacts from the S3 bucket to the DynamoDB table created by CDK.
Navigate to the Step Functions Console and click on the Step Function created by CDK.
Click on the Step Function name which ends with '-Intake-CDK' and click on View details -> Start Execution.
Once the execution is completed successfully as shown below;
Now all the contacts should be imported to the DynamoDB table.
Navigate to Amazon DynamoDB Console and click on the table name which ends with '-Contacts' and click on Items to verify the import.
This step will make outbound calls using Amazon Connect and capture the execution details in the DynamoDB table created by CDK.
Navigate to the Step Functions Console and click on the Step Function created by CDK.
Click on the Step Function name which ends with '-Outreach-CDK' and click on View details -> Start Execution.
Once the execution is completed successfully as shown below;
If you are using your mobile number in the contact list, you should receive a call from the Amazon Connect instance.
Navigate to Amazon DynamoDB Console and click on the table name which ends with 'AmazonConnectAgentlessOutboundCampaign' and click on Items to verify the execution information.
Step 4 [Optional] : Create an EventBridge Rule for triggering the Step Function Intake Process when a new file is uploaded to the S3 bucket
Step 5 [Optional] : Create an EventBridge Schedule for triggering the Step Function Outreach Process at regular intervals
Run the below command to delete this solution.
cdk destroy
Note: Most of the resources created by this solution will be deleted.
- KMS Keys will be marked for deletion in 7 days.
- Cloudwatch Log Groups of some of the resources may need manual deletion.