---
title: Auto Approval Configuration Guide
description: "Package: Contract Butler Version: 1.14 Last Updated: 02 Mar 2026 ### **1. Overview** This document describes how to configure Auto Approval using Salesforce Flows for the Contract Butler. Auto Approval allows automatic submission and approval of records based on predefined…"
url: "https://pdfbutler.com/academy/contract-butler-academy/contract-butler/auto-approval-configuration-guide/"
updated: "2026-03-05"
category: CONTRACT BUTLER
---

# Auto Approval Configuration Guide

Package: Contract Butler
 Version: 1.14
 Last Updated: 02 Mar 2026

### **1. Overview**

This document describes how to configure Auto Approval using Salesforce Flows for the Contract Butler.
 Auto Approval allows automatic submission and approval of records based on predefined business rules without manual user interaction.

### 2. Step 1 – Enable Custom Approval in Package Settings

1. Open Setup in Salesforce.
2. In the Quick Find box, enter Custom Settings.
3. Select Custom Settings from the results.
4. Locate Contract Setting General in the list.
5. Click Manage next to Contract Setting General.
6. Click Edit.
7. Enable the checkbox ☑ Use Custom Approval?.
8. Click Save.

### 3. Step 2 – Create Flows

##### 3.1. Create Flow: Contract Save New Version

1. Open Setup.
2. Navigate to Flows.
3. Click New Flow.
4. Select Screen Flow

**Contract Save New Version** is a screen flow designed for custom save new contract version:

![](https://pdfbutler.com/wp-content/uploads/2026/03/1-262x300.png)

Flow: Agreement Submit

The Flow performs the following steps:

1. **Retrieves the latest Contract Version** related to the current Contract.
2. **Executes the Contract Lifecycle Apex Action** with actions `SAVE_NEW_VERSION` and `ACTIVATE`.
3. **Evaluates the result** of the operation.
4. If successful, the Flow automatically finishes using the **Contract Flow Auto Finish** LWC component.
5. If an error occurs, the Flow displays an error screen with the returned message

#### 3.1.1. Get Records - Get Last Contract Version Id

![](https://pdfbutler.com/wp-content/uploads/2026/03/2-300x243.png)

 

**Label:** Get Last Contract Version Id
 **Purpose:** Retrieve the latest Contract Version related to the Contract.

- Object: Contract Version
- Filter:

  - Contract Instance = `{!$Record.Id}`
- Sort Order: Descending - VersionNumber__c
- Store: Only the first record
- Store field: Id

#### 3.1.2. Apex Action - Contract Lifecycle Action

![](https://pdfbutler.com/wp-content/uploads/2026/03/3-281x300.png)

**Label:** Contract Lifecycle Action
 **Type:** Apex Action

**Parameters:**

1. **Actions** → `SAVE_NEW_VERSION`
2. **Contract Id** → `{!$Record.Id}`
3. **Contract Version Id** → `{!Get_Last_Contract_Version.Id}`

**Purpose:**
 Creates a new version and approve clauses.

**Output:**

- Applied Action (Text)
- Contract Id (Text)
- Message (Text)
- New Version Id (Text)
- Source Version Id (Text)
- Success(Boolean)

#### 3.1.3. Decision - Save Successful

![](https://pdfbutler.com/wp-content/uploads/2026/03/4-300x259.png)

 

**Label:** Save Successful

**Outcome:** Save New Version

**Condition:**

- `Success Equals True`

**Default Outcome:**

- Error

**Purpose:**

- Branch flow depending on Apex execution result.

#### 3.1.4. Screen - Auto Finish Screen

![](https://pdfbutler.com/wp-content/uploads/2026/03/5-300x127.png)

**Label:** Auto Finish Screen

**Component:**

- Search in Components: Contract Flow Auto Finish
- Drag and drop component onto the Screen.

**Configure:**

- Enter **Label**
- Enter **API Name**

**Purpose:**
 Automatically closes the Flow after successful execution.

#### 3.1.5. Screen - Error Screen

![](https://pdfbutler.com/wp-content/uploads/2026/03/6-300x128.png)**Label:** Error Screen

**Component:**Message

**Message Content:** {!Message} (Output from Apex Action)

**Purpose:**
 Display error details when Save New Version fails.

### 3.2. Create Flow: Contract Activate

The Contract Activate Flow is created in the same manner as the Save New Version Flow.

**Key Difference**

This Flow executes the Contract Lifecycle Apex Action with a parameter:

- Action: ACTIVATE

**Flow Behavior**

The Flow:

1. Retrieves the latest Contract Version.
2. Executes the Contract Lifecycle Apex Action with:
    - Action: ACTIVATE
    - Contract Id
    - Contract Version Id
3. Evaluates the execution result.
4. Displays:
    - Auto Finish Screen if successful.
    - Error Screen if activation fails.

This Flow is used to activate an existing Contract Version without creating a new version.

### 4. Step 3 - Adding Actions to a Record Page

#### 4.1 Create Save New Version and Activate Quick actions

#### ![](https://pdfbutler.com/wp-content/uploads/2026/03/7-300x156.png)

1. Open the **Agreement** object in **Object Manager**.
2. Go to **Buttons, Links, and Actions** and click **New Action**.
3. For **Action Type**, select **Flow**.
4. In **Flow**, choose the target flow (e.g., *Contract Save New Version, Contract Activate*).
5. Enter the **Label** and **Name**.
6. Click **Save**.

#### 4.2 Add Highlight Panel with Save New Version and Activate actions

Open the **Record Page** in the Lightning App Builder

![](https://pdfbutler.com/wp-content/uploads/2026/03/251c785e-83c6-48e4-9eb3-4a22c4206922-300x83.jpg)

1. Find the **Highlights Panel** standard component.
2. Drag and drop the **Highlights Panel** component into the **Header** section of the page.
3. Click **Add Action**.
4. Search for the Quick Action by name (e.g., *Save New Version* or *Activate*).
5. Select the action and click **Done**.
6. Click **Save** to save the page.

 

 
