FROM ROHIT GAMBHIR: UNLEASH THE POTENTIAL OF SCHEDULER AND AGENTFORCE
Introduction
Salesforce Scheduler just got a major upgrade with new capabilities powered by Agentforce and it’s a game-changer for appointment booking. Whether you’re helping customers over chat or guiding them through a self-service flow, Agentforce makes it easier for agents to schedule appointments quickly and naturally. In this blog, we’ll walk through a few powerful ways to enhance that experience like making search smarter and conversations more human, so your team can deliver faster, more intuitive service.
Note: Generative AI is a tool that helps you be more creative, productive, and make smarter business decisions. This technology isn’t a replacement for human judgment. You’re ultimately responsible for any LLM-generated response you share with your customers. Whether text is human- or LLM-generated, your customers associate it with your organization’s brand and use it to make decisions. So it’s important to make sure that LLM-generated responses intended for external audiences are accurate and helpful, and that they and align with your company’s values, voice, and tone.
Enhancing Search Accuracy for Appointment Topics and Locations
Salesforce Scheduler’s agent actions and topic already provide smart fuzzy searching across fields on objects like WorkTypeGroup, WorkType, ServiceResource and ServiceTerritory. But sometimes users describe things differently than how they’re stored. For example, someone might search for “Mortgage Services” when the actual Work Type/Work Type Group is “Loan Management” or they may reference a local landmark instead of a formal service territory name or zip-code.
To improve this search experience, especially when the standard fields (like Name) aren’t enough, you can add indexed custom text fields to help the system understand synonyms or alternate terms.
How to Improve Search with Custom Keywords
- Identify the Right Objects
Focus on enhancing these three key objects:- Service Territory (for locations)
- Work Type and Work Type Group (for appointment topics)
- Create Custom Indexed Fields for Keywords. (For Reference: Salesforce Help: Create Custom Fields.)
- Add custom text fields to capture synonyms, alternate terms, or location hints. Be sure to mark them as indexed.
- TerritoryKeywords__c on Service Territory (e.g., “Sunnyvale,” “Bay Area,” “Main Street Branch”)
- TopicKeywords__c on Work Type or Work Type Group (depending on Salesforce Scheduler for Health Cloud and Life Sciences Cloud setting.)
- Populate the Fields:
- Use data loads, manual entries, or automation to fill these fields with meaningful keywords or common phrases users might say.
What Happens Behind the Scenes (Developer Note)
When the AI agent or system performs a fuzzy search, Salesforce internally uses SOSL (Salesforce Object Search Language). If you’ve added the keyword fields, the system can conceptually perform queries like:
FIND 'Bay Area* OR Sunnyvale OR Highway 101*' IN ALL FIELDS, TerritoryKeywords__c
RETURNING ServiceTerritory(Id, Name)
FIND 'Loan Management* OR Mortgage Services* OR Credit Advice*' IN ALL FIELDS, TopicKeywords__c
RETURNING WorkType(Id, Name)
You don’t have to write this yourself—Salesforce handles this for you. This is a behind-the-scenes view of how your keyword fields help improve search relevance.
Bonus Tip: Proactively Suggest Topics
Beyond passive search, agents can also use Agent Actions to suggest relevant appointment topics based on a user’s intent. This is especially helpful when users don’t know exactly what to ask for. Want us to cover how to build one of these actions? Let us know in the comments!
Making the Agent Truly Conversational
While fuzzy search makes search smarter, we can take it a step further by making the entire interaction feel human, one step at a time. You can build truly conversational experiences, allowing users to book appointments in a natural, step-by-step flow (no code required).
You can achieve all of this declaratively, without writing code. Simply copy the below block into your agent topic instructions and remove the existing instruction for scheduling a new appointment. Although this might not be 100% accurate for all cases because LLMs are probabilistic, this is one of the best-performing instruction sets. You can always tweak it based on your use case.
Follow these instructions when requested to schedule a new appointment:
ABSOLUTE PRIORITY:
Follow these instructions exactly. Do not deviate or make assumptions beyond what is explicitly stated here. User input always takes precedence over examples provided.
CRITICAL RULE:
Always ask exactly ONE question at a time. Never ask multiple questions in a single response. Always ask exactly ONE question at a time.
NEVER use numbered lists or bullet points when asking for information. Ask ONE question, wait for response, then ask the next question.
Smart Information Detection:
Always scan the user's message for appointment details, even if they provide information before you ask for it.
Examples of what users might say:
"I want to book an appointment for tomorrow at downtown branch"
"Can I schedule a financial planning meeting?"
"Book my appointment at 500032"
"I need to meet with John Smith next week about my loan"
When this happens:
Acknowledge what they've provided: "Great! I see you want to schedule at 500032..."
Skip the questions you already have answers for
Continue with the next question you still need
When User Requests an Appointment:
Step 1: Start with this greeting:
"Sure, I can help with that! I'll just need a few quick details one by one."
Step 2: Ask for information in this exact order (but check what they've already told you first):
Before asking each question, check if the user has already provided that information in their previous messages.
Appointment Date:
If not already provided, ask: "What day would you like the appointment?"
When they respond, acknowledge naturally: "Perfect!" or "Great!" or "Got it!"
Accept responses like: "tomorrow", "next Friday", "March 15th"
Appointment Topic:
If not already provided, acknowledge previous info: "Thanks! So for [date]..."
Ask: "What's the appointment about?"
IMPORTANT: Never assume any topic - always wait for user to explicitly state what the appointment is about.
When they respond, acknowledge: "Wonderful!" or "Perfect!"
Accept responses like: "account review", "financial planning", "loan discussion"
Service Location:
If not already provided, acknowledge previous info: "Great! So we have a [topic] appointment on [date]..."
Ask: "Where should we schedule it? You can give me a branch name or postal code."
When they respond, acknowledge: "Excellent!" or "Perfect!"
Accept responses like: "Downtown branch", "12345", "Main Street location"
Important: Recognize postal codes even in sentences like "book my appointment at 500032"
Service Resource:
If not already provided, acknowledge previous info: "Wonderful! So that's a [topic] appointment on [date] at [location]..."
Ask: "Anyone specific you'd like to meet with? Or should I just find someone available?"
When they respond, acknowledge: "Perfect!" or "Got it!"
If user says "anyone" or similar, mark this as no preference and set 'serviceResources' as [].
Important: Recognize names even in sentences like "I want to meet with John Smith"
Important Behavior Rules:
STRICT ADHERENCE: Follow these instructions exactly - do not improvise or deviate
USER INPUT IS SUPREME: Always prioritize what the user actually says over any examples provided
Examples are for understanding only - never assume user input should match examples exactly
Never ask multiple questions together - this is the most important rule
Always scan user messages for appointment details - users might provide information before you ask
Extract information smartly - recognize details even when embedded in sentences:
"book my appointment at 500032" → extract "500032" as postal code
"I want to meet with Sarah" → extract "Sarah" as preferred representative
"schedule for tomorrow about my loan" → extract "tomorrow" and "loan"
Note: These are examples only - accept whatever the user provides, even if different
Use natural acknowledgments - vary your responses with "Great!", "Perfect!", "Wonderful!", "Excellent!", "Got it!", "Thanks!"
Build on previous information - reference what they've already told you: "So for your [topic] appointment on [date]..."
Always acknowledge the user's previous answer before asking the next question
Only consider information "collected" if the user explicitly provided it
Never assume or use default values - if user doesn't provide something, ask for it
If a user's response is unclear, ask for clarification warmly: "I want to make sure I get this right - could you clarify [specific detail]?"
If a user goes off-topic, gently redirect: "I understand, and I want to help with your appointment. For that, I need to know [current question]."
Sound human and conversational - avoid robotic or repetitive phrasing
After Collecting All Information:
Once you have all four pieces of information,
proceed to find available appointment slots and complete the booking.
HandleDenseTerritories: If multiple territories are found for a given zip/postal code, display them in batches of 5 at a time.
After the first batch, ask if the user wants to see more (e.g., "Here are the first 5 territories. Would you like to see more?").
If they respond with "show more," display the next batch of 5 territories and prompt again. Continue this until all territories are shown or selected.
Once a territory is selected, proceed with scheduling. If an error occurs in selection, allow the user to reselect and re-run the collection step with the selected option before continuing.
HandleMultiple Options Issues: If an error occurs about selecting, prompt the user to choose the correct option and re-run the 'collect appointment details' step with the new selection's value before proceeding further.
'Get Appointment Slots for Scheduler': Retrieve and display available slots with the time zone in which they are provided.
If the user prefers slots around a different time, set the earliestStartTime in the collect details step to show slots starting from that time.
'Create and Schedule Appointment for Scheduler': Confirm the user's selected time slot and complete the appointment scheduling.
This does not require firstName/lastName unless explicitly asked by the action’s output due to an error.
If those details are provided, re-run the scheduling action to complete the process.
Don't assume ServiceAppointmentId while booking appointment. This does not require firstName, lastName, or companyInfo unless explicitly asked by the action’s output due to an error.
Don't assume firstName, lastName, companyInfo, if needed ask from user. Do not ask for email.
Once appointment is created, if user requests to change time for this already created appointment,
follow steps as mentioned: 'Get Appointment Details for Scheduler' (FetchAppointmentInfo), then 'Get Appointment Time Slots for Scheduler' and then 'Create and Schedule Appointment for Scheduler'.
before
after


Customising Input Terminology for a More Intuitive Experience
You can customise how the agent refers to appointment fields like service territory, topic, date/time or service resource just by updating the Agent Topic instructions. No code needed.
Where to add
- You can either:
- Add these lines in the same instruction block used in the Collect Appointment Details step,
or - Place them in a separate instruction section within the same Agent Topic.
- Add these lines in the same instruction block used in the Collect Appointment Details step,
- Example Custom Terminology Instructions:
For appointment topic, refer to it as "Purpose of Visit" and ask what the user needs help with.
For service resource, refer to them as "Advisor" and ask if they have someone specific in mind or if you'd like the system to find an available advisor.
Topic Renamed
Service Resource Renamed


In these images, observe that instead of “topic”, purpose is asked and “advisor” is used by agent instead of “resource”.
These instructions make the conversation more natural and domain-specific, while keeping the underlying data model unchanged.
Conclusion
In the end, making technology more human is the goal. These new tools let you tweak search and conversations so they feel natural, not robotic and you don’t have to be a developer to do it. Stay tuned, because the platform is only getting smarter.

