---
schema_version: "1"
id: 1033f036a6bee4e5b311f9e891a4e384f73f79af3b4079abc8a55ecc7bccb4ab
title: Get Service Resource ID
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/platform/264-0-0/ls_get_service_resource_id.md
canonical_url: https://help.salesforce.com/s/articleView?id=platform.ls_get_service_resource_id.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: ce7ea1a997fcb70689878e28629a65c3d85f95b13789b6a7d4b83bb5ec848910
description: Retrieve the service resource ID from the Assigned Resource object.
products:
  - Scheduler
  - Salesforce Platform
release: "264"
---
# Get Service Resource ID

Retrieve the service resource ID from the Assigned Resource object.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: Lightning Experience.</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: <strong>Enterprise</strong> and <strong>Unlimited</strong> Editions</td></tr></tbody></table>

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small permission">
        <colgroup>
          <col style="width:50%">
          <col style="width:50%">
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="colgroup" class="slds-cell-wrap" colspan="2" style="text-align:center;vertical-align:top;" id="d26290e66">User Permissions
              Needed</th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d26290e66 ">To open, edit, or create a flow in Flow Builder:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d26290e66 ">Manage Flow</td>

          </tr>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d26290e66 ">To run a flow:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d26290e66 ">Run Flows</td>

          </tr>
        </tbody>
      </table>

1. From the Elements panel, drag **Get Records** onto the canvas.
2. Enter a name, such as Get Assigned Resource, and an API name, such as Get\_Assigned\_Resource for the element.
3. In the Object field, select **Assigned Resource**.
4. From the Condition Requirements dropdown, select **All Conditions Are Met (AND)**.
5. Add these conditions:
    
    | Field | Operator | Value |
    | --- | --- | --- |
    | ServiceAppointmentId | Equals | {!$Record.Id} |
    | IsRequiredResource | Equals | {!$GlobalConstant.True} |
6. For How Many Records to Store, select **Only the first record**.
7. For How to Store Record Data, select **Choose fields and assign variables (advanced)**.
8. Under Select Variable to Store Lead, in the Record field, click **\+ New Resource**.
9. In the New Resource dialog:
    1. From the Resource Type dropdown list, select **Variable**.
    2. Enter an API name, such as ServiceResource for the record.
    3. From the Data Type dropdown list, select **Record**.
    4. In the Object field, select **AssignedResource**, and then click **Done**.
10. In the Field field, select **ServiceResourceId**.
11. Select **When no records are returned, set specified variables to null**, and then click **Done**.
12. Connect the Get Lead Email element with this Get Records element.

Add a Get Records element to retrieve service resource name.