Newer Version Available

This content describes an older version of this product. View Latest

ServiceAISetupField

Represents a field on cases or knowledge articles that Einstein uses to identify relevant articles in Einstein Article Recommendations. This type extends the Metadata metadata type and inherits its fullName field.

File Suffix and Directory Location

ServiceAISetupField components have the suffix .serviceAiSetupField and are stored in the serviceAiSetupFields folder.

Version

ServiceAISetupField components are available in API version 51.0 and later.

Special Access Rules

This type is available only if Einstein Article Recommendations is enabled in your org and the Main Services Agreement has been accepted.

Fields

Field Name Field Type Description
entity string Required. The Case or KnowledgeArticle object for the field.
field string Required. The API name of the field.
fieldMappingType ServiceAISetupFieldType (enumeration of type string) Required. The field type. Valid values are:
  • CASE_DESC
  • CASE_SUBJ
  • ARTICLE_TITLE
  • ARTICLE_CONTENT
  • ARTICLE_SUMMARY
fieldPosition int Required. A positive number used to rank the field’s importance. The value 1 is most important; higher numbers indicate less important fields. Einstein considers fields in the order of importance.
name string Required. A reference to the field.
setupDefinition string Required. A reference to the parent ServiceAISetupDefinition.

Declarative Metadata Sample Definition

The following is an example of a ServiceAISetupField component.

1<?xml version="1.0" encoding="UTF-8"?>
2<ServiceAISetupField xmlns="http://soap.sforce.com/2006/04/metadata">
3    <entity>Case</entity>
4    <field>Subject</field>
5    <fieldMappingType>CASE_SUBJ</fieldMappingType>
6    <fieldPosition>1</fieldPosition>
7    <name>SF16039900475920</name>
8    <setupDefinition>4hQRM0000004CDK</setupDefinition>
9</ServiceAISetupField>

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>ServiceAISetupField</name>
6    </types>
7</Package>

Usage

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.