Configuring agent automation rules

Configuring agent automation rules

Overview

Agent automation rules automatically create customer relationship management (CRM) activities when agents complete interactions. Administrators configure triggers and conditions based on interaction characteristics (such as media type, direction, duration, or custom data) to determine when activities are created.

What agent automation rules do:

  • Create CRM activities (notes, tasks, calls, events) when agents enter wrap state after ending or parking interactions.

  • Populate activity fields with interaction data using automation tags.

  • Record activities against whichever contact is open in Customer 360 when the interaction ends.

  • Assign activities to the agent who handled the interaction by default, or to a different user by setting the user ID in the automation rule layout fields.

  • Automatically link auto-created activities to relevant CRM objects (such as Deals, Accounts, or Cases) using the Link activity via automation feature.

How automation rules trigger:

  • Rules trigger when the agent exits wrap state after ending or parking an interaction.

  • If an interaction involves multiple agents (for example, through transfer or consultation), a separate activity is created for each agent involved.

Agent automation rules are available across all supported CRM systems. Specific capabilities may vary depending on your CRM's application programming interface (API) support.

Prerequisites

Category

Requirement

Category

Requirement

Administrator access

You must have administrator access to the Vonage Contact Center (VCC) Admin Portal. Only users with admin access can create automation rules.

Customer 360 and CRM integration

Customer 360 must be enabled for your account, and your VCC account must be linked with at least one supported CRM system in CRM Admin. For information, see Configuring Customer 360 (Admin).

Layouts created

You must have created at least one custom layout for the activity type you want to automate, or plan to use the Master layout. For information about creating layouts, see Configuring layouts.

Custom data sources (optional)

If you plan to use custom data sources in automation rules, you must first create data sources in the interaction plan and create data source mappings. Unmapped data sources are not available outside the interaction plan and cannot be sent to the CRM. For information, see Data source mappings and Using data sources in interaction plans.

Limitations

Category

Limitation

Category

Limitation

Automation tag format

Automation tags must use the correct format for the CRM field type.

  • Text fields require ${raw.fieldName} format.

  • Numeric fields require raw.fieldName format (without ${}).

If the format is incorrect, the CRM may reject the automation tag, and the activity will fail to create or populate correctly. VCC cannot detect CRM field types automatically; contact your CRM administrator if you are unsure about field type requirements.

Custom data source format

Custom data sources must use the correct format for the CRM field type.

  • Text fields require ${raw.params.CustomDataSource} format.

  • Numeric fields require raw.params.CustomDataSource format (without ${}).

If the format is incorrect, the CRM may reject the data.

Automation rule conditions

Automation rule conditions must use valid interaction field names and values. Invalid conditions may prevent the rule from triggering or cause the activity creation to fail.

Creating an agent automation rule

  1. Navigate to Business Apps > CRM Admin and click Configure next to the desired CRM. Integration Setup opens.

  2. Click Automation. The Automation Rules page appears.

  3. The first time you visit Automation Rules, there may be no rules available. Click + Add to create a new automation rule.

  4. Select a resource type (activity type) from the dropdown (for example, Event, Task, Call). This determines what type of activity will be created when the rule triggers.

  5. In the Fields map layout, select the layout you want to use for the automatically created activity:

    • Select a custom layout you created previously, OR

    • Click the + icon to create a new layout (this opens the Layouts builder; follow the steps in Configuring layouts).

  6. Add one or more conditions that determine when the activity is created. Click + Condition. A new condition row appears.

  7. Configure the condition:

    • In the Interaction field, select the field from the interaction data you want to evaluate (for example, VCC Media type, Direction, Duration, Customer Number).

    • In Operator, select the comparison operator (such as equals, not equals, greater than, less than, or contains).

    • In Value, enter or select the value to compare against (for example, PHONE, INBOUND, 600000 for 10 minutes in milliseconds).

SS_NewAutomationRuleConditionComplete.png
  1. (Optional) Add additional conditions by clicking + Condition and repeating step 7. All conditions must be true for the rule to trigger (conditions use AND logic).

  2. (Optional) In the layout fields, use automation tags to populate activity fields with interaction data.

Tip

By default, VCC assigns activities to the agent who handled the interaction. To assign activities to a different user, set the user ID in the relevant layout field using the appropriate automation tag.

  1. Review the automation rule to ensure the resource type is correct, the layout is selected, all conditions are configured correctly, and automation tags (if used) are formatted correctly for the CRM field type.

  2. Click Save to save the automation rule.

Activity creation timing

Activities appear in the CRM shortly after the agent exits wrap state. There may be a brief delay depending on CRM API performance.

  1. Click Done to close the Automation Rules page and return to Integration Setup.

  2. Repeat steps 2–12 to create additional automation rules for different interaction types or conditions.

Your automation rules are now active. When agents complete interactions that meet the configured conditions and enter wrap state, activities will be automatically created in the CRM and recorded against whichever contact was open in Customer 360 when the interaction ended.

Incorrect tag format

If the automation tag format is incorrect for the CRM field type, the CRM may reject the automation tag, and the activity will fail to create or populate correctly.

Link activity via automation

This feature enhances Customer 360 (C360) Automation by automatically populating the Related To field when CRM activities are created. CRM activities (such as Tasks, Calls, or Cases) generated during or after an interaction are automatically linked to relevant CRM objects (such as Deals, Accounts, or Cases) based on the interaction context.

How the activity links:

  1. During the interaction, the system tracks context, including linked objects, created objects, click-to-dial origin, and interactive voice response (IVR) data.

  2. When the activity is auto-created, the system:

    • Identifies relevant CRM objects based on the tracked context.

    • Validates relationships against your CRM schema.

    • Automatically populates the Related To field.

For configuration steps, see Link activity via automation in Configuring layouts.

Automation tags in agent automation rules

Automation tags are placeholders that VCC replaces with actual interaction data when creating CRM activities.

Automation tag format by field type:

CRM field type

Format

Example

CRM field type

Format

Example

Text fields (words or letters)

${raw.automationTag}

${raw.dispositionNotes} or ${raw.customerNumber}

Numeric fields (numbers only)

raw.automationTag (without ${})

raw.duration or raw.agentId

Used in

Automation tag and text

Result

Used in

Automation tag and text

Result

CRM activity title

${raw.mediaType} ${raw.direction} with ${raw.customerNumber}

Phone OUTBOUND with +12025550123

CRM activity notes

Agent ${raw.vccUsername} needs to call ${raw.customerNumber} regarding  ${raw.params.CampaignName} 

Agent JSmith needs to call +12025550123 regarding SummerPromo2025

Recording and transcript URLs in CRM activities

CRM auto activities can include clickable URLs that link directly to voice recordings, chat transcripts, and email threads in Conversation Analyzer. This allows agents and supervisors to access the complete conversation history with one click from the CRM.

Ensure your CRM users who need to access recordings and transcripts have appropriate Conversation Analyzer permissions configured in VCC User Admin.

Who can access recording and transcript URLs:

Who cannot access the recording and transcript URLs:

Who can access recording and transcript URLs:

Who cannot access the recording and transcript URLs:

  • The agent who handled the interaction (interaction owner).

  • Supervisors with Conversation Analyzer permissions.

  • Users explicitly granted access to specific interactions.

  • CRM users without a VCC Conversation Analyzer license or permissions.

  • External users (customers, partners).

  • Unauthorized third parties.

Configuring recording and transcript URLs in agent automation rules

  1. In the Automation Rules page, create a new automation rule or edit an existing rule.

  2. In the layout fields for the activity (such as Notes, Description, or a custom URL field), add the ${raw.interactionURL} tag. Examples:

CRM Field

What to enter

Result in CRM

CRM Field

What to enter

Result in CRM

Notes

Recording: ${raw.interactionURL}

Recording: https://apac.newvoicemedia.com/CallCentre/portal/conversation-viewer/01896a22-7839-4b91-b74d6-8bd6d90a3df4.

Description

The agent handled the call. View conversation: ${raw.interactionURL}

The agent handled the call. View conversation: https://apac.newvoicemedia.com/CallCentre/portal/conversation-viewer/01896a22-7839-4b91-b74d6-8bd6d90a3df4.

  1. Save the automation rule.

  2. When the automation rule triggers and creates a CRM activity, the ${raw.interactionURL} tag is replaced with the actual Conversation Analyzer URL for that specific interaction.

Best practices

  • Use a clear label like "Recording URL:" or "View conversation:" before the tag so CRM users understand what the link is for.

  • Add the URL to fields that are easily visible in the CRM activity view (such as Description or Notes) so agents and supervisors can find it quickly without expanding hidden fields.

Automation tags reference table

Use the following automation tags in automation rules and automatically created activities:

Automation tag

Description

Example value

Automation tag

Description

Example value

${raw.dispositionCode}

You can use this tag to insert the disposition code selected by the agent at the end of the interaction.

  • Complete

  • ProductQuestion

${raw.dispositionNotes}

You can use this tag to insert the disposition notes entered during the wrap-up period.

The customer asked for follow-up next week.

${raw.customerNumber}

You can use this tag to insert an external customer number.

+441234567890

${raw.contactWorldNumber}

You can use this tag to insert an internal contact center number.

+440987654321

${raw.channelId}

You can use this tag to insert the unique ID for a specific agent's session within an interaction. The ID is created when the agent is connected to the customer and remains active until the agent completes their wrap-up.

740109c1-12d5-430f-9543-131fe5c4edcb

${raw.interactionId}

You can use this tag to insert the unique ID that identifies the entire customer interaction.

1371f451-116a-4abc-8869-bc678ef67070

${raw.mediaType}

You can use this tag to insert the channel through which the customer and agent communicated. Available channels are: 

  • PHONE.

  • WEBCHAT.

  • SMS.

  • EMAIL.

  • WHATSAPP.

  • PHONE

  • SMS

${raw.direction}

You can use this tag to insert the direction of an interaction. Available options are:

  • Inbound: incoming to your contact center.

  • Outbound: outgoing to the customer.

INBOUND

${raw.duration}

You can use this tag to insert an interaction's duration in milliseconds (1000 ms = 1 second).

345000 (5 minutes 45 seconds)

${raw.endedReason}

You can use this tag to insert the reason an interaction ended. Possible options are:

  • Released: the agent/customer intentionally ended the call (hung up or clicked Release).

  • Busy: the agent's/customer’s line was already in use and the call couldn’t be connected.

  • NoAnswer: the agent/customer didn’t pick up within the allowed time.

  • Unreachable: the agent’s/customer’s device couldn’t be reached.

  • Rejected: the agent/customer actively declined the call.

  • Failed: the call failed to connect due to an unexpected technical or configuration problem.

  • ConnectionUnavailable: the call couldn’t connect because the agent’s required media channel wasn’t available.

  • Released

  • Busy

${raw.vccAccountId}

You can use this tag to insert the name of your contact center's VCC account.

AcmeCustomerService

${raw.vccUsername}

You can use this tag to insert the name of the agent who handled the interaction.

JSmith

${raw.agentId}

You can use this tag to insert the internal ID assigned to the agent in VCC.

1111

${raw.interactionURL}

Automatically adapts to interaction type: voice calls open recordings, chats open transcripts, emails open threaded conversations. Only users with appropriate Conversation Analyzer permissions can access the URL content.

https://apac.newvoicemedia.com/CallCentre/portal/conversation-viewer/1371f451-116a-4abc-8869-bc678ef67070

${raw.params.CustomDataSource}

You can use this tag to insert your custom data source value, e.g., ${raw.params.CampaignName}.

SummerPromo2025

Configuring custom data sources for use in automation

Custom data sources allow you to capture interaction-specific information (such as campaign name, call priority, or ticket ID) from your interaction plans and include it in automatically created CRM activities.

To use custom data sources in automation rules, you must first create the data sources in your interaction plan, map them in Data Source Mappings, and then reference them in automation rule fields using the correct format.

Custom data source format by field type:

Field type

The format you should use

Example

Field type

The format you should use

Example

Text fields (words or letters)

${raw.params.CustomDataSource}

${raw.params.CampaignName} → SummerPromo2025

Numeric fields (numbers only)

raw.params.CustomDataSource

raw.params.TicketID → 12345

  1. Create data sources in the interaction plan:

    • In the Interaction Plans Manager or Interaction Plans Architect, open the interaction plan where you want to capture custom data.

    • Create a data source for each piece of information you want to save (for example, Priority, CustomerType, CallReason, CampaignName, TicketID).

    • Populate the data source with a value using applets (such as Set Data Source, API Call, or Database Lookup) or by passing it from an external system.

    • For more information, see Set Data Source applet and Using data sources in interaction plans.

  2. Create data source mappings:

    • Navigate to Admin Portal > Data Source Mappings.

    • Create a data source mapping for every data source you plan to send to the CRM. Data sources can only be used outside the interaction plan when they are mapped.

    • For information, see Data source mappings and Using data source mappings.

  3. Link custom data sources to the CRM:

    • Navigate to Business Apps > CRM Admin and click Configure next to the desired CRM. Integration Setup opens.

    • Click Automation. The Automation Rules page appears.

    • Create or edit an automation rule (see Creating an agent automation rule section earlier on this page).

  4. Reference custom data sources in automation rule fields:

    • In the layout fields for the activity (such as Title, Notes, Description), reference your custom data source using the appropriate format:

      • Text fields: ${raw.params.CustomDataSourceName}

      • Numeric fields: raw.params.CustomDataSourceName (without ${})

    • Replace CustomDataSourceName with your actual data source name (for example, ${raw.params.CampaignName} or raw.params.TicketID).

  5. Verify that the custom data source format matches the CRM field type:

    • If the CRM field expects text, use ${raw.params.CustomDataSourceName}.

    • If the CRM field expects a number, use raw.params.CustomDataSourceName (without ${}).

  6. Save the automation rule and click Done to close the Automation Rules page.

Your custom data sources are now configured for use in automation. When interactions with mapped data sources trigger the automation rule, the custom data will be included in the automatically created CRM activities.

Support and documentation feedback

For general assistance, please contact Customer Support.

For help using this documentation, please send an email to docs_feedback@vonage.com. We're happy to hear from you. Your contribution helps everyone at Vonage! Please include the name of the page in your email.