--- title: "Transaction Reattempts" slug: "payments-use-cases-transaction-reattempts" updated: 2023-10-06T15:07:16Z published: 2023-10-06T15:07:16Z canonical: "docs.blackthorn.io/payments-use-cases-transaction-reattempts" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.blackthorn.io/llms.txt > Use this file to discover all available pages before exploring further. # Transaction Reattempt Notifications ## Failed Transaction Follow Up Automation When Transactions fail and are reattempted, it is a good practice to follow up with the customer to notify them and update their card or bank account information if the Transaction continues to fail. For the use case below, we will be creating a Process in Process Builder to send out an automated Email Alert to the customer on the second reattempt and then notify the Transaction owner via a Chatter Post on the third reattempt. ## Step One - Create an Email Template and an Email Alert *These two records will be referenced later in Process Builder.* ### Create an Email Template 1. From Setup, navigate to: - Lightning: Email > Classic Email Templates - Classic: Administration Setup > Communication Templates > Classic Email Templates 2. Click **New Template** 3. Under "Choose the type of email template you would like to create," select "Text". 4. Click **Next**. 5. Under "Available Merge Fields" set **Select Field Type** = "Transaction Fields". Be sure to only use merge fields from the Transaction object for this template. Merged fields from other objects will not populate. 1. Select the folder where you want to store your Email Template. 2. **Available For Use** checkbox should be checked 3. Enter an **Email Template Name** and **Template Unique Name**. 4. Enter a **Description**. 5. Enter a **Subject** and an **Email Body** using a combination of text and Transaction merge fields ![G_01_03 reattempt notifications pic 1](https://cdn.document360.io/f977eec0-500f-40a3-b663-724a51f78075/Images/Documentation/G_01_03%20reattempt%20notifications%20pic%201.png) --- ### Create an Email Alert 1. From Setup, navigate to: - Lightning: Process Automation > Workflow Actions > Email Alerts - Classic: Create > Workflow & Approvals > Email Alerts 2. Click **New Email Alert**. 3. Enter a **Description** and **Unique Name**. 4. For **Object**, select "Transaction". 5. For **Email Template**, find and select your template from the prior step. If you cannot locate your Email Template, please go back to the Template and make sure `Available for Use` is checked. 1. For **Recipient Type**, select "Email Field". 2. In the **Available Recipients** column, select "Email Field: Payment Method Billing Email" and use the Add/Remove buttons to move the value into the **Selected Recipients** column. 3. If desired, enter any **Additional Emails**. 4. Select the correct **From Email Address**. 5. Click **Save**. ![G_01_03 reattempt notifications pic 2](https://cdn.document360.io/f977eec0-500f-40a3-b663-724a51f78075/Images/Documentation/G_01_03%20reattempt%20notifications%20pic%202.png) ## Step Two: Build the Process Using Process Builder Create a Process with the Process Builder to automatically send out an Email Alert to notify the Customer of a second reattempt, as well as post to Chatter to notify the Transaction owner after the third reattempt. ### Create a New Process 1. From Setup, navigate to: - Lightning: Process Automation > Process Builder - Classic: Create > Workflow & Approvals > Process Builder 2. Click **New**. 3. Enter the **Process Name**, **API Name**, and **Description**. 4. Set **The process starts when** to "A record changes." ![G_01_03 reattempt notifications pic 3](https://cdn.document360.io/f977eec0-500f-40a3-b663-724a51f78075/Images/Documentation/G_01_03%20reattempt%20notifications%20pic%203.png) --- ### Select the Object for the Process 1. On the canvas, click **Add Object**. 2. For the **Object** field, select "Transaction". 3. Under **Start the Proces**, select "when a record is created or edited". 4. Click **Save**. ![G_01_03 reattempt notifications pic 4](https://cdn.document360.io/f977eec0-500f-40a3-b663-724a51f78075/Images/Documentation/G_01_03%20reattempt%20notifications%20pic%204.png) --- ### Define the Criteria that Triggers the Process and Define your Actions #### Second Reattempt Criteria 1. On the canvas, click **+ Add Criteria**. 2. Enter the **Criteria Name**. 3. Set **Criteria for Executing Actions** to"Conditions are met". 4. Under Set Conditions, complete the following fields. - **Field** = "Reattempt Number" - **Operator** = "Equals" - **Type** = "Number" - **Value** = "2" 5. Set **Conditions** to "All of the conditions are met (AND)". 6. Click **Save**. ![G_01_03 reattempt notifications pic 5](https://cdn.document360.io/f977eec0-500f-40a3-b663-724a51f78075/Images/Documentation/G_01_03%20reattempt%20notifications%20pic%205.png) #### Second Reattempt Action 1 1. On the canvas under IMMEDIATE ACTIONS, click **+ Add Action**. 2. For **Action Type**, select "Email Alerts". 3. Enter an **Action Name**. 4. Enter the Email Alert created in Step One in the **Email Alert** field. 5. Click **Save**. ![G_01_03 reattempt notifications pic 6](https://cdn.document360.io/f977eec0-500f-40a3-b663-724a51f78075/Images/Documentation/G_01_03%20reattempt%20notifications%20pic%206.png) #### Third Reattempt Criteria 1. Under your last element on the canvas, click **+ Add Criteria**. 2. Enter the **Criteria Name**. 3. Under **Criteria for Executing Actions**, select "Conditions are Met". 4. Under Set Conditions, complete the following fields - **Field** = "Reattempt Number" - **Operator** = "Equals" - **Type** = "Number" - **Value** = "3" 5. Set **Conditions** to "All of the conditions are met (AND)". 6. Click **Save**. ![G_01_03 reattempt notifications pic 7](https://cdn.document360.io/f977eec0-500f-40a3-b663-724a51f78075/Images/Documentation/G_01_03%20reattempt%20notifications%20pic%207.png) #### Third Reattempt Action 1 1. On the canvas under IMMEDIATE ACTIONS, click **+ Add Action**. 2. For **Action Type**, select "Post to Chatter". 3. Enter an **Action Name**. 4. Under **Post to**, select "This Record". Feed Tracking The "Post to Chatter" option is only visible if the feed for Transaction object is enabled. Setup > Search for Feed Tracking > Select Transaction > Enable Feed Tracking > Save. 1. In the **Message** field, enter your custom message. *Example Message: @[{![bt_stripe__Transaction__c].OwnerId}] Contact the customer on this Transaction. Their Payment Method is incorrect and needs to be updated in order for the Transaction to process. An email has already been sent with a PayLink to update their Payment Method.* 2. Click **Save**. 3. Click **Activate**. ![G_01_03 reattempt notifications pic 8](https://cdn.document360.io/f977eec0-500f-40a3-b663-724a51f78075/Images/Documentation/G_01_03%20reattempt%20notifications%20pic%208.png) ![G_01_03 reattempt notifications pic 9](https://cdn.document360.io/f977eec0-500f-40a3-b663-724a51f78075/Images/Documentation/G_01_03%20reattempt%20notifications%20pic%209.png) *On the third reattempt, a Chatter post will automatically be created and the Transaction owner notified.* ## Additional Use Cases If you have any suggestions for a use case with Blackthorn Payments please contact [Blackthorn Support](https://community.blackthorn.io/s/support) and provide details on your use case. We always appreciate hearing the solutions our customers create and love sharing that with our other customers!