Contact Us

December 30, 2024

May 13, 2026 1:27 pm

Adding a Custom Send Button to Employee Agent in Agentforce

Share with

Understanding the Requirement

The requirement is to add a custom button to the Employee Agent, which will allow users to send the drafted email with a single click. This button should be similar to the default “Draft or Revise Email” action, but with a custom implementation.

Technical Approach

To achieve this, we need to create a custom Lightning Web Component (LWC) that will contain the custom Send button. This LWC will be configured to work with the Employee Agent, allowing users to send the drafted email.

Once the LWC is created, we need to configure it for use with the Employee Agent. This involves setting up the necessary permissions and configurations to allow the LWC to interact with the Employee Agent.

Implementation Steps

The implementation involves creating a custom LWC and configuring it for use with the Employee Agent. Here are the high-level steps:

createLWC.js

import { LightningElement, api } from 'lwc';

This code snippet shows the basic structure of an LWC, which can be used as a starting point for creating the custom Send button.

The root cause of this challenge is the lack of a built-in Send button in the Employee Agent. By creating a custom LWC, we can overcome this limitation and provide a seamless user experience.

Best Practices and Considerations

When implementing the custom Send button, it is essential to follow best practices and consider the following factors:

Implementation Checklist

  • Create a custom Lightning Web Component (LWC) for the Send button
  • Configure the LWC for use with the Employee Agent
  • Set up necessary permissions and configurations
  • Test the custom Send button thoroughly
  • Deploy the LWC to production
  • Monitor user feedback and iterate on the implementation

By following these best practices and considerations, we can ensure a successful implementation of the custom Send button.

Frequently Asked Questions

What is the purpose of creating a custom LWC?

The purpose of creating a custom LWC is to provide a custom Send button that can be used with the Employee Agent.

How do I configure the LWC for use with the Employee Agent?

To configure the LWC, you need to set up the necessary permissions and configurations to allow the LWC to interact with the Employee Agent.

What are the benefits of using a custom LWC?

The benefits of using a custom LWC include providing a seamless user experience, overcoming limitations of the built-in Send button, and allowing for custom implementation.

How do I test the custom Send button?

To test the custom Send button, you need to deploy the LWC to a test environment and verify that it works as expected.

Genetrix Technology · Salesforce Marketing Cloud Partner

Need help shipping this in production?

Genetrix builds and untangles Salesforce Marketing Cloud and Agentforce setups for teams that want it done right the first time. If anything in this post sounds familiar, talk to us before it ships.

Get in Touch with Genetrix →

Blogs for the

Business-Savvy!​

Let’s Connect

A 30 min no cost strategy session
with cloud support expert

Let’s Connect

A 30 min no cost strategy session
with cloud support expert