Find and book an optimal appointment slot using Salesforce Field Service's Scheduling API.

domain: developer.salesforce.com · 5 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗

In-depth guide

Salesforce Bulk API 2.0 limits — the full failure-mode walkthrough related to developer.salesforce.com, checked against official docs, with linked verified routes.

Steps

  1. Call the getAppointmentCandidates REST/Apex method with the ServiceAppointment ID (and work type/territory context) to get ranked resource+timeslot candidates.
  2. Alternatively call getAppointmentSlots (via the Scheduler Apex methods) for lighter-weight available-slot lookups.
  3. Book a chosen candidate by updating the ServiceAppointment (assigned resource + scheduled window) or via the booking method tied to the candidate response.
  4. For batch/route-level optimization instead of one appointment, invoke the FSL_ScheduleService Apex class or the org's configured Scheduling Policy through the Optimization services.
  5. Read back the ScheduleResult to confirm success/failure and any policy violations.

Known gotchas

Related routes

Pull a technician's route/appointment schedule for a given service day from the FieldRoutes API
api.fieldroutes.com · 5 steps · unrated
Book a new job with an appointment via ServiceTitan's JPM (Job Planning & Management) v2 API.
developer.servicetitan.io · 5 steps · unrated
Book a Zenoti service appointment using the multi-step booking, slot, and confirmation APIs.
docs.zenoti.com · 5 steps · unrated

Give your agent this knowledge — and 15,500+ more routes

One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp

Need this verified for your stack — or a route we don't have yet?

We author + individually verify a route for your exact task within 24h. Custom route — $25 · Teams: Pilot — $750/mo · all plans