Scheduler API page
The Scheduler API page gives your development team the example requests, parameters, and URLs needed to integrate with an organization-level API endpoint.
Here, you can:
- Review the endpoint name and endpoint definition.
- Learn which parameter(s) are used for each endpoint.
- View and copy endpoint URLs.
- View and copy example code for each endpoint.
API Endpoints
See our API documentation for more information.
Quick Access: Scheduler > API > API Endpoints
The Callback Status and Widget Status API endpoints share Scheduler widget availability and the status of callbacks with integrators to offer a more seamless experience to the end-user when presenting callback options via SMS messages, web widgets, or phone systems.
The Cancel Callback Request API endpoint gives your customers another way to cancel a callback request. Now, with an integration with the Cancel Callback Request endpoint, your customers can cancel a callback request with a simple text message or via a simple API call from your website.
Use the following table as a guide to using the information in this window.
Field | Description |
---|---|
Parameters | For both the GET and POST requests, the Parameters fields list the parameters that can be passed along in an API request, including a definition of each parameter. |
URL | The URL fields contain the unique endpoints that can be used to invoke the API via GET or POST requests. |
Example cURL | The Example cURL fields provide example statements that can be used to reach the GET or POST endpoints via cURL. |
You can use the copy buttons to the right of each field to quickly copy the contents to your clipboard to paste them into your command-line environment.
API parameters
Parameters can be passed into a POST request. These parameters allow you to request and receive information from other Mindful applications and take actions based on that information.
Available endpoints and methods
The following table describes the available API endpoints and their definitions:
Method and endpoint | Definition |
---|---|
POST /api/organization/:id/cancel_callback | Cancels an existing callback request for a customer's contact number. |
POST /api/organization/:id/callback_status | Returns the current status of any pending callback associated with the given contact number. |
GET /api/organization/:id/widget_status | Returns the status of all active widgets and conveys which are currently accepting callbacks. |
Use Cases
The endpoints available in Scheduler are designed to integrate with Mindful applications. In these examples, we see a customer interacting with API endpoints via SMS automations.
Use case 1 - Customer cancels a callback request
- The customer has received a Confirmation notification via SMS after registering a callback. The customer then sends an "@cancel" reply.
- Mindful talks to Scheduler using the Callback Status endpoint. It checks to see if the customer has an existing callback request and responds in the SMS conversation with a confirmation of that request. Mindful then asks the customer to confirm the cancellation request.
- The customer confirms via text.
- The customer's "Yes" triggers Mindful to engage the Cancel Callback Request endpoint in the Scheduler API.
Once the callback request is canceled, Mindful sends a message confirming that the callback has been canceled and advises the customer on how to re-engage at a later time.
Use case 2 - Customer requests a callback
- The customer initiates a new SMS interaction by texting "@callme".
- Mindful talks to Scheduler using the Widget Status endpoint. Scheduler returns a list of all Widgets and their status for receiving callback requests. Mindful extends a callback offer for the available callback types (ASAP or scheduled) on the available Call Targets. In this example, the available Call Targets are "billing" and "service".
- The customer selects the Call Target (associated with the widget) for their callback. In this example, it is "billing".
- Once the Call Target is selected, Mindful replies to the customer with the API Message configured in the Mindful UI. In this example, the configured API Message is "We can call you in approximately 7 minutes", using dynamic text replacement to calculate the expected wait time.
- The customer follows the prompts to request the callback on the selected Call Target.
Assigning an Access Control Policy (ACP)
On the Scheduler API page, you can apply organization-level Access Control Policies (ACPs) and view information about global API endpoints for additional functionality. After you've created at least one Access Control Policy, you can apply one at the organization level on this page.
Quick Access: Scheduler > API
- On the Scheduler API page, click the Access Control Policy drop-down menu.
- Select the ACP you want to use. This automatically applies the ACP to your Organization.