ServiceProcess

Represents a process created in Service Process Studio and its associated attributes.

Parent Type 

This type extends Metadata and inherits its fields.

File Suffix and Directory Location 

ServiceProcess components have the suffix .serviceprocess and are stored in the .serviceprocess folder.

Version 

Introduced in API version 57.0.

Special Access Rules 

Access to the ServiceProcess type requires the AccessToServiceProcess permission.

Fields 

description 

  • Type: string
  • Required: No
  • Description: A meaningful explanation of the service process.

processLabel 

  • Type: string

  • Required: Yes

  • Description: Required.

    A meaningful name for the service process.

serviceProcessAttributes 

  • Type: ServiceProcessAttribute[]
  • Required: No
  • Description: Custom attributes that store the data associated with the service process.

serviceProcessDependencies 

  • Type: ServiceProcessDependency[]
  • Required: No
  • Description: Dependent components of the service process, such as OmniScripts or flows.

serviceProcessItemGroups 

shortDescription 

  • Type: string
  • Required: No
  • Description: A brief meaningful explanation of the service process.

shouldHideEmptyAttributes 

  • Type: boolean
  • Required: No

usageType 

  • Type: SvcCatalogItemUsageType (enumeration of type string)

  • Required: Yes

  • Description: Required.

    The Cloud that uses this service process.

    Values are:

  • Possible values:

    • CustomerService
    • Employee
    • FinancialServices
    • Industry (available in version 58.0 and later)

ServiceProcessAttribute Type 

A custom attribute that stores data associated with a service process. For example, a service process that reverses a fee can have a Fee Type attribute.

Fields 

attributeType 

  • Type: SvcCtlgItemAttrAttributeType (enumeration of type string)

  • Required: No

  • Description: A Base attribute corresponds to a SvcCatalogRequest field, which is subject to field-level security. An Extended attribute is only a ServiceProcessAttribute object record, which isn’t subject to field-level security.

    Values are:

    The default is Extended.

  • Possible values:

    • Base
    • Extended

baseObjectApiName 

  • Type: string
  • Required: No

dataType 

  • Type: SvcCatalogItemAttrDataType (enumeration of type string)

  • Required: No

  • Description: The data type of the attribute.

    Values are:

    The default is Text.

  • Possible values:

    • Attachment
    • Checkbox
    • Currency
    • Date
    • Datetime
    • DisplayText
    • Email
    • IPAddress
    • Integer
    • ListOfAttachment — (available in API version 65.0 and later)
    • ListOfBoolean
    • ListOfDouble
    • ListOfInteger
    • ListOfMaps
    • ListOfString
    • Lookup
    • Map
    • MultilineText
    • MultiSelectPicklist — (available in API version 65.0 and later)
    • Number
    • NumericScale
    • Password — (available in API version 65.0 and later)
    • Percentage
    • Picklist
    • Queue
    • RadioButton — (available in API version 65.0 and later)
    • SingleCheckbox — (available in API version 59.0 and later)
    • SinglelineText
    • Text
    • Toggle — (available in API version 59.0 and later)
    • Url

Selecting Currency doesn’t cause an error, but currency conversions aren’t supported.

Note

description 

  • Type: string
  • Required: No
  • Description: A meaningful explanation of the attribute.

developerName 

  • Type: string

  • Required: Yes

  • Description: Required.

    A system name for the attribute.

fieldIdentifier 

  • Type: string
  • Required: No
  • Description: For a Base attribute, the Developer Name of the SvcCatalogRequest field. This field can be standard or custom.

groupApiName 

  • Type: string
  • Required: Yes
  • Description: The apiName of the ServiceProcessItemGroup to which this attribute belongs.

inputVariableValue 

  • Type: string
  • Required: No
  • Description: The default value of the attribute.

isAttrValueDerivAtRuntime 

  • Type: boolean
  • Required: No

isRequired 

  • Type: boolean
  • Required: No
  • Description: Specifies whether the attribute is required. The default is false.

label 

  • Type: string

  • Required: Yes

  • Description: Required.

    A meaningful name for the attribute.

parentAttribute 

  • Type: string
  • Required: No
  • Description: The parent attribute of this attribute. For example, a Latitude attribute can have GeoLocation as a parent.

referenceObjectApiName 

  • Type: string
  • Required: No

sortOrder 

  • Type: int
  • Required: No
  • Description: The position of the attribute in the payload relative to other attributes having no parent or the same parent.

ServiceProcessDependency Type 

A dependent component of the service process, which can be a flow, an OmniScript, an Integration Definition, or a preprocessor Apex class.

Fields 

dependencyReference 

  • Type: string

  • Required: Yes

  • Description: Required.

    The Developer Name of the flow, OmniScript, Integration Definition, or preprocessor Apex class.

processStepName 

  • Type: SvcCtlgItemDpndProcType (enumeration of type string)

  • Required: No

  • Description: Name of the step in a service process.

    Values are:

  • Possible values:

    • FulfillmentFlow
    • IntegrationDefinition
    • Preprocessor
    • RequestForm

type 

  • Type: SvcCatalogItemDependencyType (enumeration of type string)

  • Required: Yes

  • Description: Required.

    The type of dependent component.

    Values are:

  • Possible values:

    • FlowDefinition
    • IntegrationProviderDef
    • OmniScriptConfig
    • PreprocessorApexClass

ServiceProcessItemGroup Type 

A group of related ServiceProcessAttribute records.

Fields 

apiName 

  • Type: string

  • Required: Yes

  • Description: Required.

    The API Name of the group.

groupName 

  • Type: string

  • Required: Yes

  • Description: Required.

    The name of the group.

sortOrder 

  • Type: int

  • Required: Yes

  • Description: Required.

    The group display order.

Declarative Metadata Sample Definition 

The following is an example of a ServiceProcess component.

1<?xml version="1.0" encoding="UTF-8"?>
2<ServiceProcess xmlns="http://soap.sforce.com/2006/04/metadata">
3   <processLabel>EmailUpdate</processLabel>
4   <usageType>FinancialServices</usageType>
5   <serviceProcessAttributes>
6      <label>EmailAddress</label>
7      <developerName>EmailAddress</developerName>
8      <dataType>Text</dataType>
9      <groupApiName>Info</groupApiName>
10   </serviceProcessAttributes>
11   <serviceProcessDependencies>
12      <dependencyReference>EmailPreprocessor</dependencyReference>
13      <type>PreprocessorApexClass</type>
14   </serviceProcessDependencies>
15   <serviceProcessItemGroups>
16        <apiName>Info</apiName>
17        <groupName>Info</groupName>
18        <sortOrder>1</sortOrder>
19    </serviceProcessItemGroups>
20</ServiceProcess>

The following is an example package.xml that references the previous definition.

1<?xml version="1.0" encoding="UTF-8"?>
2<Package xmlns="http://soap.sforce.com/2006/04/metadata">
3    <types>
4        <members>*</members>
5        <name>ServiceProcess</name>
6    </types>
7    <version>57.0</version>
8</Package>

Wildcard Support in the Manifest File 

This metadata type supports the wildcard character * (asterisk) in the package.xml manifest file. For information about using the manifest file, see Deploying and Retrieving Metadata with the Zip File.

Deployment Considerations 

We recommend that you review these considerations before you retrieve or deploy service process metadata.

  • If you deploy metadata with the same name as the definition when your service process definition is active, you get an error message. Deactivate the service process definition and try again.
  • When your service process definition is inactive, consider these guidelines.
  • If a service process definition contains service catalog requests and service catalog request extended attribute values and you deploy metadata with the same name as the definition, you get an error message. You can’t delete or change a service process that has service catalog requests with attribute values in it. Make sure that all records are deleted in service catalog requests and service catalog request extended attribute values before you deploy the metadata.
  • If a service process definition contains service catalog requests but doesn’t contain service catalog request extended attribute values and you deploy the metadata with the same name, the deployment works as expected.
  • If a service process definition doesn’t contain service catalog requests and you deploy the metadata with the same name, the deployment works as expected.