Modify an Anonymous Appointment
This use case explains how to change the service resource of an existing anonymous service appointment by using Salesforce Scheduler APIs.
Typically, anonymous appointments are scheduled when users who don’t belong to your organization request for appointments. For example, a subscriber of your app requests for an appliance maintenance appointment from your service app. After a service appointment is scheduled by using the anonymous mechanism, the service resource for the appointment can mark themselves unavailable. In that scenario, as an administrator or an appointment orchestrator for your organization, ensure that you modify the anonymous service appointment and assign a different resource to the appointment.
For the procedure to be successful, ensure that each unavailable resource marks themselves as absent in Salesforce Scheduler. Otherwise, the API request to retrieve the list of service resources continues to include the resources that are currently unavailable or absent.
This flowchart provides an overview of the procedure:

-
Authenticate with a Connected App
The first step in an API-based integration is to connect to Salesforce and get an access token by using OAuth. OAuth access token authentication is the most secure way to authenticate SOAP and REST API calls.
-
Get Service Appointments
The AssignedResource object represents a service resource who is assigned to a service appointment in Salesforce Scheduler. Retrieve service appointment IDs of all scheduled appointments associated with specific resources by using the query request on the AssignedResource object.
-
Get Service Appointment Details
A service appointment represents an appointment that’s booked via Salesforce Scheduler. Use a GET method to fetch the details of a service appointment record.
-
Get Available Resources
Retrieve the resources that are available for an anonymous appointment.
-
Update Service Appointments
A service appointment represents an appointment that is booked via Salesforce Scheduler. To update the appointment, run a PATCH request on the service-appointments Connect API.