---
schema_version: "1"
id: 483a8a52b9b58a1028d3daf02601f0fea65526d8c4c892cdbedf9971edea2ea8
title: Get Slots Action
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/health_cloud_object_reference/actions_obj_get_slots.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.health_cloud_object_reference.meta/health_cloud_object_reference/actions_obj_get_slots.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: e09681d45db655d5ab8c362a68dc61b74330bfb9c8405c50df377330f83454e5
description: Retrieve available appointment slots for one or more resources.
---
# Get Slots Action

Retrieve available appointment slots for one or more resources.

This action is available in API version 65.0 and later.

## Supported REST HTTP Methods

**URI**: /services/data/vXX.X/connect/health/appointment-management/slots

Where XX.X is the latest API version.

**Formats**: JSON, XML

**HTTP Methods**: POST

**Authentication**: Authorization: Bearer TOKEN

Where TOKEN is your OAuth access token.

## Inputs

<table class="featureTable sort_table" summary="">



          <thead class="thead sorted" align="left">
            <tr>
              <th class="featureTableHeader  " id="d308218e96">Input</th>

              <th class="featureTableHeader  " id="d308218e99">Type</th>

              <th class="featureTableHeader  " id="d308218e102">Description</th>

            </tr>

          </thead>

          <tbody class="tbody">
            <tr>
              <td class="entry" headers="d308218e96" data-title="Input">
                <span class="keyword parmname">appointmentTypes</span>
              </td>

              <td class="entry" headers="d308218e99" data-title="Type">Array</td>

              <td class="entry" headers="d308218e102" data-title="Description">Types of appointments to search such as
                <var class="keyword varname">Follow-up</var>. Required, if none of
                the following are provided:<ul class="ul bulletList">
                  <li class="li"><span class="keyword parmname">workTypeId</span></li>

                  <li class="li"><span class="keyword parmname">serviceTypes</span></li>

                  <li class="li">
                    <span class="keyword parmname">serviceCategories</span>.
                  </li>

                </ul>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d308218e96" data-title="Input">
                <span class="keyword parmname">channelId</span>
              </td>

              <td class="entry" headers="d308218e99" data-title="Type">String</td>

              <td class="entry" headers="d308218e102" data-title="Description">ID of the engagement channel associated with the
                appointment. Required, if an engagement channel is
                configured for a Work Type.</td>

            </tr>

            <tr>
              <td class="entry" headers="d308218e96" data-title="Input">
                <span class="keyword parmname">endDate</span>
              </td>

              <td class="entry" headers="d308218e99" data-title="Type">String</td>

              <td class="entry" headers="d308218e102" data-title="Description">End date and time for the slot search range.</td>

            </tr>

            <tr>
              <td class="entry" headers="d308218e96" data-title="Input">
                <span class="keyword parmname">resources</span>
              </td>

              <td class="entry" headers="d308218e99" data-title="Type">Array</td>

              <td class="entry" headers="d308218e102" data-title="Description">Array of resource objects to find slots for.</td>

            </tr>

            <tr>
              <td class="entry" headers="d308218e96" data-title="Input">
                <span class="keyword parmname">serviceCategories</span>
              </td>

              <td class="entry" headers="d308218e99" data-title="Type">Array</td>

              <td class="entry" headers="d308218e102" data-title="Description">Category of service to find slots for. Required, if none
                of the following are provided: <a name="ul_zkv_5qs_pgc"><!-- --></a>
                <ul class="ul bulletList" id="ul_zkv_5qs_pgc">
                  <li class="li"><span class="keyword parmname">workTypeId</span></li>

                  <li class="li"><span class="keyword parmname">serviceTypes</span></li>

                  <li class="li">
                    <span class="keyword parmname">appointmentTypes</span>.
                  </li>

                </ul>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d308218e96" data-title="Input">
                <span class="keyword parmname">serviceTypes</span>
              </td>

              <td class="entry" headers="d308218e99" data-title="Type">Array</td>

              <td class="entry" headers="d308218e102" data-title="Description">Services types to find slots for. Required, if none of
                the following: <a name="ul_wvq_yqs_pgc"><!-- --></a>
                <ul class="ul bulletList" id="ul_wvq_yqs_pgc">
                  <li class="li"><span class="keyword parmname">workTypeId</span></li>

                  <li class="li"><span class="keyword parmname">serviceCategories</span></li>

                  <li class="li">
                    <span class="keyword parmname">appointmentTypes</span>.
                  </li>

                </ul>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d308218e96" data-title="Input">
                <span class="keyword parmname">sourceSystem</span>
              </td>

              <td class="entry" headers="d308218e99" data-title="Type">String</td>

              <td class="entry" headers="d308218e102" data-title="Description">Description of the external system defined in
                Salesforce, such as <var class="keyword varname">cerner</var>. Required,
                if <span class="keyword parmname">workTypeId</span> is not provided.</td>

            </tr>

            <tr>
              <td class="entry" headers="d308218e96" data-title="Input">
                <span class="keyword parmname">startDate</span>
              </td>

              <td class="entry" headers="d308218e99" data-title="Type">String</td>

              <td class="entry" headers="d308218e102" data-title="Description">Required.<p class="p">Start date and time for the slot search range.</p>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d308218e96" data-title="Input">
                <span class="keyword parmname">workTypeId</span>
              </td>

              <td class="entry" headers="d308218e99" data-title="Type">String</td>

              <td class="entry" headers="d308218e102" data-title="Description">ID of the Work Type associated with the desired
                appointment. Required, if none of the following are
                provided:<a name="ul_gc4_drs_pgc"><!-- --></a>
                <ul class="ul bulletList" id="ul_gc4_drs_pgc">
                  <li class="li"><span class="keyword parmname">serviceTypes</span></li>

                  <li class="li"><span class="keyword parmname">serviceCategories</span></li>

                  <li class="li">
                    <span class="keyword parmname">appointmentTypes</span>.
                  </li>

                </ul>
              </td>

            </tr>

          </tbody>

        </table>

## Outputs

| Output | Type | Description |
| --- | --- | --- |
| resourceSlotDetails | Array | List of resources and their corresponding available slots. |

## Example

**POST**

This sample request is for the Get Slots action.

{
    "inputs": \[
        {
            "startDate": "2025-07-14T00:12:00.7912",
            "endDate": "2025-07-15T06:59:59.000Z",
            "channelId": "0eFxx000000Mexx2AK",
            "workTypeId": "08qxx0000009cxxYAA",
            "sourceSystem": "Salesforce",
            "resources": \[
                {
                    "resourceId": "0bSxx0000004pxx2AA",
                    "serviceTerritoryId": "0Hhxx000000Efxx0AK",
                    "serviceResourceId": "0Hnxx000000DAxx0AG",
                    "resourceType": "Provider",
                    "assetCategory": ""
                }
            \],
            "appointmentTypes": \[\],
            "serviceCategories": \[\],
            "serviceTypes": \[\]
        }
    \]
}

This sample response is for the Get Slots action.

\[
    {
        "resourceSlotDetails": \[
            {
                "resourceId": "0bSxx0000004pxx2AA",
                "availableSlots": \[
                    {
                        "slotId": "slot-xyz-1",
                        "slotStartDate": "2025-07-14T11:00:00.000Z",
                        "slotEndDate": "2025-07-14T11:30:00.000Z",
                        "sourceSystem": "Salesforce"
                    },
                    {
                        "slotId": "slot-xyz-2",
                        "slotStartDate": "2025-07-14T14:30:00.000Z",
                        "slotEndDate": "2025-07-14T15:00:00.000Z",
                        "sourceSystem": "Salesforce"
                    }
                \]
            }
        \]
    }
\]