Skip to main content

Create and Implement an Opt Contact In Action Tool for AI Agents in Whippy

Set up an Opt Contact In action tool and configure your AI agent to update a contact’s consent status.

Maria Cairns avatar
Written by Maria Cairns
Updated this week

Why it matters

Opting a contact in updates their consent status so they are eligible to receive messages according to your communication settings and compliance requirements.

Because consent impacts messaging eligibility and compliance, you must clearly define when and why a contact should be opted in. Creating the tool alone is not enough. You must assign the tool to the agent and define in the agent instructions when it should be triggered.

Key Concepts

Action Tool: A tool created using the Execute Actions tool type that allows an agent to perform structured system actions such as updating contact consent status.

Execute Actions Tool Type: A tool type that enables you to configure one or more actions inside a single tool. Multiple actions can run when the tool is triggered.

Opt Contact In Action: An action that updates the contact’s status to opted in when executed.

Consent Status: The contact’s communication permission state. This determines whether the contact can receive outbound messages.

Agent Instructions: The configuration where you define when the agent should trigger the tool and what conditions must be met before updating consent.

Step-by-Step: Create an Opt Contact In Action Tool

  1. Navigate to Agents in the left-hand menu.

  2. Click Tools (jigsaw icon).

  3. Click Create Tool in the top right corner.

  4. Select Execute Actions from the Tool Type dropdown.

  5. Enter a Tool Name and click Save Tool.

Configure Basic Info

  1. Enter the Label. Use only letters, numbers, underscores, or hyphens. Maximum 64 characters.

  2. Add a clear Description explaining when a contact should be opted in.

  3. Click Save.

Configure Tool Settings

  1. Set the Timeout (milliseconds). Default is 5000 ms.

  2. Toggle Speak After Execution if the agent should confirm the opt-in.

  3. Toggle Speak During Execution if required.

  4. Add execution speech if enabled, for example confirming consent has been recorded.

  5. Click Save.

Add the Opt Contact In Action

  1. In the Actions section, click Add Action.

  2. Select Opt Contact In from the Action Type dropdown.

  3. Review the confirmation message indicating the contact will be opted in when executed.

  4. Click Create Action.

When the tool is triggered, the contact’s status will be updated to opted in.

You can add additional actions to the same tool if needed, such as sending a confirmation message.

Implement the Tool in an Agent

Creating the tool does not automatically make the agent use it.

To implement it:

  1. Open the relevant Agent.

  2. Select the newly created Opt Contact In tool to give the agent access.

  3. Update the Agent Instructions to clearly define:

    • The exact wording or confirmation required from the contact.

    • When the tool should be triggered.

    • Any confirmation message the agent should send.

You must both assign the tool to the agent and define its trigger logic in the instructions. Without explicit conditions, the agent may opt contacts in incorrectly or fail to record valid consent.

Tips and Best Practices

  • Only trigger opt-in after clear, explicit consent from the contact.

  • Define exact phrases or confirmation logic in the agent instructions.

  • Consider sending a confirmation message after opt-in.

  • Test the workflow in a controlled conversation before deploying.

  • Review compliance requirements relevant to your region.

Troubleshooting

Issue

Possible Cause

Fix

Contact not opted in

Tool not assigned to agent

Enable the tool in the agent settings

Agent opts in without consent

Trigger logic too broad

Refine Agent Instructions with explicit consent conditions

Tool not triggering

No clear instruction to use the tool

Update Agent Instructions to define when to run it

Messaging still blocked

Other compliance settings applied

Review contact status and messaging configuration

Did this answer your question?