---
title: "Cancel SignNow Invite"
url: "https://docs.signnow.com/docs/apex-cancel-invite"
type: "page"
section: "Integrations"
slug: "apex-cancel-invite"
---

# Cancel SignNow Invite

# Apex action: Cancel SignNow Invite

> Before configuring this Apex action, review the [prerequisites](/docs/salesforce-apex-actions#prerequisites) for SignNow Apex actions and complete the required setup steps.

The **Cancel SignNow Invite** action allows users to cancel the signature invite based on Salesforce events.

For example, let’s cancel the invite to send an agreement once the Opportunity is marked as lost.

## Step 1. Configure the flow trigger

- Select the object which record triggers the flow. For our example, it is **Opportunity**.
- Select when the flow should be triggered. For our example, it is `A record is updated`.
- Set entry conditions (condition requirements, record field, operator, and value). For our example, the condition field is `Stage`, the condition operator is `Equals` , and the value is `Closed Lost`.
- Select how often the flow should run.

![apex_cancel_invite_trigger.png](/reference-assets/images/SignNow_Salesforce/apex_actions/apex_cancel_invite_trigger.png)

## Step 2. Configure the SignNow action

- Enter an action label and brief description to locate the flow.
- Specify the input values for the SignNow action. In our example, only the SignNow invite ID is required.

For the example flow, the `SignNow Invite ID` field is connected to the `Next Step` field of the Opportunity. The `Next Step` field has been configured to store the invite ID as described in the [SignNow Invite Status Update](/docs/apex-invite-status-update-event) flow.

> The SignNow action accepts only numeric values. Since `Next Step` is a text field, use the resource formula `VALUE({!$Record.NextStep})` to convert the text to a number.

![apex_cancel_invite_action.png](/reference-assets/images/SignNow_Salesforce/apex_actions/apex_cancel_invite_action.png)

> A signature invite with the **Signed** status cannot be canceled.

## Result 

When the Opportunity is marked as Closed Lost, the agreement invite sent from the Opportunity is automatically canceled.

---

View the full list of [SignNow Apex actions](/docs/salesforce-apex-actions).

---
*Full page: https://docs.signnow.com/docs/apex-cancel-invite*
