Image showing a cartoonish image about using Agentforce to search for lead data

Lead Enrichment with Python and SerpAPI

Enriching Salesforce Leads based on PlaceID I built a Python-driven automation that enriches Salesforce leads using Place IDs as a stable, unique identifier for every business on Google Maps. The Three Ingredients of the Automation 1. Salesforce Lead Object Configuration To prepare Salesforce for this Lead enrichment, I added a few custom fields to the Lead object. This includes a custom PlaceID field to serve as our unique key, along with fields for Google Rating, Review Count and a few more. These fields provide the landing spot for the external data, ensuring it is structured and ready for sales reps to use. ...

April 11, 2026 · Tarek Mustafa
Image showing a cartoonish image about using Agentforce to search for lead data

Searching for Leads in Salesforce

Using Salesforce Agentforce to Search for Leads Building on my lead enrichment automation, I wanted to create a more intuitive way for sellers to interact with their data. Instead of scrolling through list views, I built a custom Agentforce Agent that allows sellers to find high-value prospects simply by asking. The Three Ingredients of the Automation 1. Custom Fields & Logic To make the search meaningful, I added custom industry-specific fields like Estimated Monthly Orders, Average Order Value, and Cuisine. I then built a Lead Score Flow that calculates a priority score using this formula: ...

April 7, 2026 · Tarek Mustafa
Image showing a cartoonish image about using a Salesforce for Lead Data Enhancement

Basic lead enrichment in Salesforce

Using Automation for basic Lead enrichment in Salesforce To gain more hands-on experience with Salesforce, I used a Developer Edition org to build an AI-driven automation that triggers whenever a new Lead is created. Using Agentforce, the system automatically finds and populates the phone number, email, and website for that lead. The Three Ingredients of the Automation 1. The Instructions (Flex Prompt Template) To guide the AI, I created a Flex Prompt Template. It takes the company name and location as inputs and instructs the AI to return the corresponding phone number, email, and website in a clean JSON format. ...

December 26, 2025 · Tarek Mustafa