Integrate Salesforce and Gong with ChatGPT: A Developer's Guide to Powerful GPT Actions
Unlock the potential of ChatGPT by connecting it to your Salesforce and Gong accounts. This guide provides developers with the instructions and resources needed to build middleware that bridges these powerful platforms. By leveraging Salesforce GPT actions, you can empower users to access critical customer data and conversation insights directly within ChatGPT, saving time and improving decision-making. This will make it easier than ever to set up Salesforce GPT actions.
Why Integrate Salesforce and Gong with ChatGPT?
- Maximize Sales Efficiency: Instantly retrieve account details and call transcripts for better meeting preparation.
- Improve Customer Understanding: Get AI-powered summaries and insights based on proven sales methodologies.
- Streamline Workflows: Access essential information without switching between multiple applications.
Example Business Use Case: Preparing for a Customer Meeting with Salesforce GPT action
Imagine a sales representative preparing for a crucial customer meeting. Integrating Salesforce and Gong with ChatGPT allows them to:
- Quickly retrieve relevant account details from Salesforce.
- Access recent Gong call transcripts.
- Receive AI-generated summaries and insights structured around sales methodologies like MEDPICC or SPICED.
This process provides a clear, actionable understanding of the customer's needs and lays the foundation for successful sales strategies.
Prerequisites Before Building Salesforce GPT action
Before you begin, make sure you have the following in place:
- Familiarity with GPT Actions: Understand the basics of building and using GPT Actions.
- Salesforce Access: Access to a Salesforce account.
- Gong API Key: A valid API key for accessing Gong data.
- Middleware Environment: Set up an environment for deploying a serverless function (AWS, Azure Functions, or Google Cloud Function).
Step-by-Step Guide to Building Your Integration
1. Setting up the Salesforce GPT Action
Refer to the "GPT Actions library - Salesforce" for detailed instructions on creating a GPT Action for Salesforce. Pay close attention to:
- Application Information: Understand the core concepts within Salesforce relevant to the integration.
- Authentication: Learn how to create a Connected App in Salesforce and configure OAuth for secure communication between Salesforce and ChatGPT.
2. Crafting the Middleware GPT Action
The middleware facilitates data exchange between ChatGPT and Gong. Refer to any of the following cookbooks for setting up your middleware:
- GPT Actions library (Middleware) - AWS
- GPT Actions library (Middleware) - Azure Functions
- GPT Actions library (Middleware) - Google Cloud Function
Example: Azure Functions Implementation
Here's a sample Azure Function (JavaScript) to retrieve call transcripts from Gong:
Ensure your package.json
includes the necessary dependencies:
3. Configuring ChatGPT with Custom Actions
- Custom GPT Instructions: Provide clear instructions to your Custom GPT, guiding it to interact with Salesforce and the middleware.
- Salesforce Custom Action Schema: Define the OpenAPI schema for the Salesforce action.
4. Defining OpenAPI Schema for Salesforce and Gong Actions
- Salesforce:
- Middleware (Gong):
ChatGPT Instruction Examples
Here are some example instructions you can provide to ChatGPT:
# Trigger: User enters the name of an account that they want to prepare for
# Steps:
-
Retrieve Account Names - Make a call to the
executeSOSLSearch
custom action searching for a Salesforce Account with that name (SOSL). Retrieve up to 5 accounts.Example Query:
FIND {Acme} IN ALL FIELDS RETURNING Account(Id, Name) LIMIT 5
-
Show the accounts in this format -
Account Name - salesforceID
. Ask the user to confirm which account they are interested in. -
Get Gong Call IDs for the account - For the confirmed account, make a call to
executeSOQLQuery
to get all the Gong Call IDs.Example Query:
SELECT XXX, YYY, ZZZ FROM Gong__Gong_Call__c WHERE Gong__Primary_Account__c = '<AccountId>' ORDER BY Gong__Call_Start__c DESC LIMIT 2
-
Pass in the callIds to
getTranscriptsByCallIds
Summarize Call Example
# Trigger User says "Summarize call"
# Steps
Use both the transcripts and provide the following output
## Account Name
Print out the account name
## Details of calls
Please list the calls for which you retrieved the transcripts along with their dates and attendees in this table format:
Headers: , , ,
## Recommended Meeting Focus Areas:
Analyze the transcripts to identify themes, challenges, and opportunities. Based on this, generate a list of recommended focus areas for the next meeting. These should be actionable and specific to the client’s needs. Explain why each item should be a meeting focus.
For each of the following insights, specify which call and date you sourced the insight from:
- Metrics: Quantifiable outcomes the customer is trying to achieve.
- Economic Buyer: Identify if the true economic decision-maker was mentioned or involved.
- Decision Criteria: What are the key factors the customer will use to evaluate solutions?
- Decision Process: Describe how the customer plans to make the buying decision.
- Paper Process: Any mention of legal, procurement, compliance, or contract-related steps.
- Identify Pain: Highlight the core business challenges the customer is facing.
- Champion: Is there someone internally who is championing our solution?
- (Optional) Competition: Mention any competing vendors, internal builds, or alternative solutions discussed.
Customization
Replace the query in step 3 to retrieve the Gong Call IDs from your custom Salesforce object. Remember to create two separate actions - one connecting to Salesforce and the other connecting to the middleware that calls the Gong APIs.
Conclusion
By integrating Salesforce and Gong with ChatGPT, you can revolutionize how sales teams access and utilize critical customer information. This guide provides a comprehensive overview of the development process, empowering you to build powerful and efficient GPT Actions that drive business success.