ServiceResource

Represents a service technician or service crew in Field Service and Salesforce Scheduler, or an agent in Workforce Engagement.

Introduced in API version 38.0.

create(), describeLayout(), describeSObjects(), getDeleted(), getUpdated(), query(), retrieve(), search(), update(), upsert()

  • Field Service or Workforce Engagement must be enabled.
  • Type: reference

  • Properties: Create, Filter, Group, Nillable, Sort, Update

  • Introduced: API version 44.0

  • Relationship name: Account

  • Relationship type: relationship

  • Refers to: Account

  • Type: reference

  • Properties: Create, Filter, Group, Nillable, Sort, Update

  • Introduced: API version 46.0

  • Relationship name: Asset

  • Relationship type: relationship

  • Refers to: Asset

  • Type: textarea
  • Properties: Create, Nillable, Update
  • Description: The description of the resource.
  • Type: string
  • Properties: Create, Filter, Group, Nillable, Sort, Update
  • Introduced: API version 68.0
  • Type: double
  • Properties: Create, Filter, Nillable, Sort, Update
  • Introduced: API version 65.0
  • Type: boolean

  • Properties: Create, Defaulted on create, Filter, Group, Sort, Update

  • Description:

    When selected, this option means that the resource can be assigned to work orders. For service tracking purposes, resources can’t be deleted, so deactivating a resource is the best way to send them into retirement.

    Deactivating a user doesn’t deactivate the related service resource. You can’t create a service resource that is linked to an inactive user.

  • Default value: false

  • Type: boolean
  • Properties: Create, Defaulted on create, Filter, Group, Sort, Update
  • Description: Capacity-based resources are limited to a certain number of hours or appointments in a specified time period. The Capacities related list shows a resource’s capacity.
  • Default value: false
  • Type: boolean
  • Properties: Create, Defaulted on create, Filter, Group, Sort, Update
  • Description: This field is reserved for Field Service and the managed package. Create a custom field instead of using this field to include a service resource in optimization.
  • Default value: false
  • Type: boolean

  • Properties: Create, Defaulted on create, Filter, Group, Sort, Update

  • Introduced: API version 57.0

  • Default value: false

  • Type: double
  • Properties: Create, Filter, Sort, Update
  • Description: The latitude of the last known location.
  • Type: location
  • Properties: Nillable
  • Description: The service resource’s last known location. You can configure this field to display data collected from a custom mobile app. This field isn’t visible in the user interface, but you can expose it on service resource page layouts or set up field tracking to be able to view a resource’s location history.
  • Type: datetime
  • Properties: Filter, Nillable, Sort, Update
  • Description: The date and time of the last known location.
  • Type: double
  • Properties: Create, Filter, Sort, Update
  • Description: The longitude of the last known location.
  • Type: string
  • Properties: Nillable
  • Type: reference

  • Properties: Create, Filter, Group, Nillable, Sort, Update

  • Introduced: API version 39.0

  • Description:

    The location associated with the service resource. For example, a service vehicle driven by the service resource.

    LocationId is a relationship field.

  • Relationship name: Location

  • Relationship type: relationship

  • Refers to: Location

  • Type: string
  • Properties: Create, Filter, Group, idLookup, Sort, Update
  • Description: The resource’s name, for example the name or title of the associated user or service crew.
  • Type: reference

  • Properties: Create, Filter, Group, Nillable, Sort, Update

  • Introduced: API version 66.0

  • Relationship name: PayGroup

  • Relationship type: relationship

  • Refers to: PayGroup

  • Type: int
  • Properties: Create, Filter, Group, Nillable, Sort, Update
  • Introduced: API version 65.0
  • Type: reference

  • Properties: Create, Filter, Group, Nillable, Sort, Update

  • Description:

    The associated user. Its label in the UI is User. If the service resource represents a service crew rather than a user, leave the User field blank and select the related crew in the ServiceCrewId field.

    RelatedRecordId is a relationship field.

  • Relationship name: RelatedRecord

  • Relationship type: relationship

  • Refers to: User

  • Type: picklist

  • Properties: Create, Defaulted on create, Filter, Group, Nillable, Restricted picklist, Sort, Update

  • Description:

    Indicates whether the resource is a Technician (T), Dispatcher (D), Crew (C), Asset (S), Agent (A), or Planner (P). The default value is Technician (T). Resources who are dispatchers can’t be capacity-based or included in scheduling optimization. Only users with the Field Service Dispatcher permission-set license can be dispatchers. You can’t add additional resource types.

    To create a dependent lookup filter with ServiceResource.ResourceType, use only the first letter of the picklist value, for example T for Technician.

  • Type: reference

  • Properties: Create, Filter, Group, Nillable, Sort, Update

  • Introduced: API version 50.0

  • Relationship name: SchedulingConstraint

  • Relationship type: relationship

  • Refers to: SchedulingConstraint

  • Type: reference
  • Properties: Create, Filter, Group, Nillable, Sort, Update
  • Introduced: API version 41.0
  • Description: The associated service crew. If the service resource represents a crew, select the crew. This field is hidden for all users by default. To use it, update its field-level security settings in Setup and add it to your service resource page layouts.
  • Relationship name: ServiceCrew
  • Relationship type: relationship
  • Refers to: ServiceCrew
  • Type: int
  • Properties: Create, Filter, Group, Nillable, Sort, Update
  • Introduced: API version 65.0

This object has the following associated objects. If the API version isn’t specified, they’re available in the same API versions as this object. Otherwise, they’re available in the specified API version.