---
schema_version: "1"
id: c2fddab393b41ebe385990196e977ed4f5020b2b188fd9312c106d62e8dd0670
title: BriefcaseDefinition
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/api_meta/meta_briefcasedefinition.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_briefcasedefinition.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: 6eefd34abee5c97579c654f6b97f736624ab72928761234ecfaac8af466ef356
description: Represents a briefcase definition. A briefcase makes selected records available for specific users and groups to view when they’re offline in the Salesforce Field Service mobile app for iOS and Android. This type extends the Metadata metadata type and inherits its fullName field.
---
# BriefcaseDefinition

Represents a briefcase definition. A briefcase makes selected records available for specific users and groups to view when they’re offline in the Salesforce Field Service mobile app for iOS and Android. This type extends the Metadata metadata type and inherits its fullName field.

![Important](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/images/icon_note_important.png)

#### Important

Where possible, we changed noninclusive terms to align with our company value of Equality. We maintained certain terms to avoid any effect on customer implementations.

## File Suffix and Directory Location

BriefcaseDefinition components have the suffix .briefcaseDefinition and are stored in the briefcaseDefinitions folder.

## Version

BriefcaseDefinition components are available in API version 50.0 and later.

## Fields

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



          <thead class="thead sorted" align="left">
            <tr>
              <th class="featureTableHeader  " id="d210363e91">Field Name</th>

              <th class="featureTableHeader  " id="d210363e94">Field Type</th>

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

            </tr>

          </thead>

          <tbody class="tbody">
            <tr>
              <td class="entry" headers="d210363e91" data-title="Field Name"><span class="keyword parmname">briefcaseRules</span></td>

              <td class="entry" headers="d210363e94" data-title="Field Type">BriefcaseRule[]</td>

              <td class="entry" headers="d210363e97" data-title="Description">A list of rules that specify which records are included in the
                briefcase.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e91" data-title="Field Name"><span class="keyword parmname">description</span></td>

              <td class="entry" headers="d210363e94" data-title="Field Type">string</td>

              <td class="entry" headers="d210363e97" data-title="Description">Description of the briefcase.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e91" data-title="Field Name"><span class="keyword parmname">isActive</span></td>

              <td class="entry" headers="d210363e94" data-title="Field Type">boolean</td>

              <td class="entry" headers="d210363e97" data-title="Description">Required. Indicates whether the briefcase is active by default (<samp class="codeph nolang">true</samp>) or inactive (<samp class="codeph nolang">false</samp>). Activate a briefcase to make the selected records available to
                assignees.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e91" data-title="Field Name"><span class="keyword parmname">masterLabel</span></td>

              <td class="entry" headers="d210363e94" data-title="Field Type">string</td>

              <td class="entry" headers="d210363e97" data-title="Description">Required. Label for the briefcase name that appears in the Salesforce user
                interface.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e91" data-title="Field Name"><span class="keyword parmname">type</span></td>

              <td class="entry" headers="d210363e94" data-title="Field Type">
                <samp class="codeph nolang">BriefcaseType</samp> (<a class="xref" href="https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_objects_intro.htm#enumeration_title">enumeration</a> of type
                string)
              </td>

              <td class="entry" headers="d210363e97" data-title="Description">Applies if multiple briefcase types are available in your org. Valid values
                include: <a name="ul_l3j_tmr_jgc"><!-- --></a>
                <ul class="ul bulletList" id="ul_l3j_tmr_jgc">
                  <li class="li">
                    <samp class="codeph nolang">Standard</samp>: Standard briefcase that can be
                    used with priming APIs.
                  </li>

                  <li class="li">
                    <samp class="codeph nolang">HighVolume</samp>: Increased capacity briefcase
                    that’s used with performance priming in the Salesforce Field Service mobile app.
                  </li>

                  <li class="li">
                    <samp class="codeph nolang">MobileAppSync</samp>: Automatically generated
                    briefcase that’s used for performance priming in the Salesforce Field Service
                    mobile app.
                  </li>

                </ul>
              </td>

            </tr>

          </tbody>

        </table>

## BriefcaseRule

Represents a rule that specifies records to be included in the BriefcaseDefinition.

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



          <thead class="thead sorted" align="left">
            <tr>
              <th class="featureTableHeader  " id="d210363e225">Field Name</th>

              <th class="featureTableHeader  " id="d210363e228">Field Type</th>

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

            </tr>

          </thead>

          <tbody class="tbody">
            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">briefcaseRuleFilters</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">
                <a class="xref" href="#BriefcaseRuleFilter">BriefcaseRuleFilter</a>[]
              </td>

              <td class="entry" headers="d210363e231" data-title="Description">A list of filters on a rule.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">filterLogic</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">string</td>

              <td class="entry" headers="d210363e231" data-title="Description">The filter logic for record selection, for example, <samp class="codeph nolang">1 AND 2</samp> where 1 and 2 correspond to filter 1 and filter 2. Filter logic
                operators include <samp class="codeph nolang">AND</samp> and <samp class="codeph nolang">OR</samp>.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">isAscendingOrder</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">boolean</td>

              <td class="entry" headers="d210363e231" data-title="Description">Indicates whether the records should be sorted in ascending order (<samp class="codeph nolang">true</samp>) or descending order (<samp class="codeph nolang">false</samp>).</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">isRelatedFilesRule</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">boolean</td>

              <td class="entry" headers="d210363e231" data-title="Description">Indicates whether the briefcase rule is part of a hierarchical set of rules
                that configure the offline priming of file attachments. Available only for the
                Offline App (Salesforce Mobile App Plus).<p class="p">To configure the offline priming of file
                  attachments, create a set of four hierarchical briefcase rules:</p>
                <ul class="ul bulletList">
                  <li class="li">A rule with <span class="keyword parmname">targetEntity</span> set to the object with the file
                    attachments at the first level</li>

                  <li class="li">A rule with <span class="keyword parmname">targetEntity</span> set to <samp class="codeph nolang">ContentDocumentLink</samp> at the second level</li>

                  <li class="li">A rule with <span class="keyword parmname">targetEntity</span> set to <samp class="codeph nolang">ContentDocument</samp> at the third level</li>

                  <li class="li">A rule with <span class="keyword parmname">targetEntity</span> set to <samp class="codeph nolang">ContentVersion</samp> at the fourth level</li>

                </ul>

                <p class="p">See the Declarative Metadata Sample Definition section for an example briefcase
                  definition that configures the offline priming of file attachments.</p>

                <p class="p">The <samp class="codeph nolang">ContentDocumentLink</samp>, <samp class="codeph nolang">ContentDocument</samp>, and <samp class="codeph nolang">ContentVersion</samp> rules must all have
                  <span class="keyword parmname">isRelatedFilesRule</span> set to <samp class="codeph nolang">true</samp>. To delete a briefcase configuration for file attachments, you
                  must delete the <samp class="codeph nolang">ContentDocumentLink</samp> rule and
                  all of its nested rules. You can’t delete a single rule within the hierarchy of
                  <samp class="codeph nolang">ContentDocumentLink</samp>, <samp class="codeph nolang">ContentDocument</samp>, and <samp class="codeph nolang">ContentVersion</samp> rules.
                </p>
                <p class="p">When
                  <span class="keyword parmname">isRelatedFilesRule</span> is set to true, you must use the
                  <span class="keyword parmname">recordLimit</span> field to limit the number of file attachments
                  returned by a briefcase rule. Apply the same <span class="keyword parmname">recordLimit</span>
                  value across the <samp class="codeph nolang">ContentDocumentLink</samp>, <samp class="codeph nolang">ContentDocument</samp>, and <samp class="codeph nolang">ContentVersion</samp> rules. You can optionally filter file attachments by
                  file size and file type through Briefcase Builder in Setup.
                </p>
                After you set a
                value for <span class="keyword parmname">isRelatedFilesRule</span>, you can no longer modify the
                field. The value that you set persists for the life of the rule.<p class="p">Removed in API
                  version 63.0 and later.</p>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">orderBy</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">string</td>

              <td class="entry" headers="d210363e231" data-title="Description">The field to order the records by, which determines how the records can be
                sorted. For example, Account Name or Created By.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">queryScope</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">
                <samp class="codeph nolang">FilterScope</samp> (<a class="xref" href="https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_objects_intro.htm#enumeration_title">enumeration</a> of type
                string)
              </td>

              <td class="entry" headers="d210363e231" data-title="Description">A group of records to restrict the scope of this rule. Valid values include:<ul class="ul bulletList">
                  <li class="li"><samp class="codeph nolang">Everything</samp></li>

                  <li class="li"><samp class="codeph nolang">AssignedToMe</samp></li>

                  <li class="li"><samp class="codeph nolang">Mine</samp></li>

                </ul>
                <p class="p">The <samp class="codeph nolang">AssignedToMe</samp> scope is supported for
                  the ServiceAppointment object only.</p>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">recordLimit</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">int</td>

              <td class="entry" headers="d210363e231" data-title="Description">The maximum number of records for an object on the briefcase rule. The maximum
                is 50,000 records that meet the criteria. However, the records returned by one
                briefcase rule must fit within the maximum limit of 50,000 records across active
                briefcases. If there are more records that match the criteria than the record limit
                allows, the <span class="keyword parmname">orderBy</span> field determines which records are
                returned.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">relatedRules</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">BriefcaseRule[]</td>

              <td class="entry" headers="d210363e231" data-title="Description">A list of rules that are related to the current rule.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">relationshipField</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">string</td>

              <td class="entry" headers="d210363e231" data-title="Description">Required for <span class="keyword parmname">relatedRules</span>. Defines the Salesforce object
                field that relates the <span class="keyword parmname">relatedRules</span> field to another
                <span class="keyword parmname">relatedRules</span> field or the <span class="keyword parmname">briefcaseRules</span>
                field on the BriefcaseDefinition metadata type that it's nested in. For example, an
                Account object rule can be related to a Contact object rule using the Account ID
                object field. In this example, the value for the related rule's
                <span class="keyword parmname">relationshipField</span> is <samp class="codeph nolang">AccountID</samp>.
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">relationshipType</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">
                <samp class="codeph nolang">BriefcaseRuleRelationshipType</samp> (<a class="xref" href="https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_objects_intro.htm#enumeration_title">enumeration</a> of type
                string)
              </td>

              <td class="entry" headers="d210363e231" data-title="Description">Required for <span class="keyword parmname">relatedRules</span>. Defines the relationship
                between the <span class="keyword parmname">relatedRules</span> field and another
                <span class="keyword parmname">relatedRules</span> field or the <span class="keyword parmname">briefcaseRules</span>
                field on the BriefcaseDefinition metadata type that it's nested in. Valid values include:<ul class="ul bulletList">
                  <li class="li"><samp class="codeph nolang">ParentToChild</samp></li>

                  <li class="li"><samp class="codeph nolang">ChildToParent</samp></li>

                </ul>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e225" data-title="Field Name"><span class="keyword parmname">targetEntity</span></td>

              <td class="entry" headers="d210363e228" data-title="Field Type">string</td>

              <td class="entry" headers="d210363e231" data-title="Description">Required. The API name of the standard object, custom object, or custom
                metadata type that the briefcase rule selects records from.<p class="p">If the
                  <span class="keyword parmname">targetEntity</span> is a custom metadata type, the briefcase rule
                  can’t include any other fields. You can add only one briefcase rule for the same
                  custom metadata type in a briefcase. Custom metadata types are supported as the
                  <span class="keyword parmname">targetEntity</span> for top-level rules only–you can’t create a
                  related rule with <span class="keyword parmname">targetEntity</span> as a custom metadata type.
                </p>
              </td>

            </tr>

          </tbody>

        </table>

## BriefcaseRuleFilter

Specifies filter criteria for a BriefcaseRule.

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



          <thead class="thead sorted" align="left">
            <tr>
              <th class="featureTableHeader  " id="d210363e613">Field Name</th>

              <th class="featureTableHeader  " id="d210363e616">Field Type</th>

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

            </tr>

          </thead>

          <tbody class="tbody">
            <tr>
              <td class="entry" headers="d210363e613" data-title="Field Name"><span class="keyword parmname">filterOperator</span></td>

              <td class="entry" headers="d210363e616" data-title="Field Type">
                <samp class="codeph nolang">BriefcaseFilterOperator</samp> (<a class="xref" href="https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_objects_intro.htm#enumeration_title">enumeration</a> of type
                string)
              </td>

              <td class="entry" headers="d210363e619" data-title="Description">Required. The comparison operator for this rule filter. Capitalization matters
                with date filter operators. Be sure to specify date literals in uppercase. Some
                valid date literals include TODAY, YESTERDAY and TOMORROW. <div class="p">Valid values include:<ul class="ul bulletList">
                    <li class="li">
                      <samp class="codeph nolang">d</samp>—Ends with
                    </li>

                    <li class="li">
                      <samp class="codeph nolang">e</samp>—Equals
                    </li>

                    <li class="li">
                      <samp class="codeph nolang">g</samp>—Greater than
                    </li>

                    <li class="li">
                      <samp class="codeph nolang">h</samp>—Greater than or equal
                    </li>

                    <li class="li">
                      <samp class="codeph nolang">l</samp>—Less than
                    </li>

                    <li class="li">
                      <samp class="codeph nolang">m</samp>—Less than or equal
                    </li>

                    <li class="li">
                      <samp class="codeph nolang">n</samp>—Not equals. This value is
                      applicable only when <span class="keyword parmname">filterValue</span> is empty.
                    </li>

                    <li class="li">
                      <samp class="codeph nolang">s</samp>—Starts with
                    </li>

                  </ul>
                </div>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e613" data-title="Field Name"><span class="keyword parmname">filterSeqNumber</span></td>

              <td class="entry" headers="d210363e616" data-title="Field Type">int</td>

              <td class="entry" headers="d210363e619" data-title="Description">Required. The filter number. When you apply multiple filters, the filters are
                numbered sequentially, 1, 2, 3, and so on.</td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e613" data-title="Field Name"><span class="keyword parmname">filterValue</span></td>

              <td class="entry" headers="d210363e616" data-title="Field Type">string</td>

              <td class="entry" headers="d210363e619" data-title="Description">The value that the field and criteria evaluate. For example, <samp class="codeph nolang">true</samp> or <samp class="codeph nolang">false</samp>
                for a boolean field whose criteria or filter operator is Equals.<p class="p">Be sure to
                  specify date literals in uppercase. Some valid date literals include TODAY,
                  YESTERDAY and TOMORROW.</p>
                <p class="p">For <span class="keyword parmname">targetEntityField</span> values
                  that accept a user ID, such as <samp class="codeph nolang">OwnerId</samp> or
                  <samp class="codeph nolang">CreatedById</samp>, enter <samp class="codeph nolang">$User.Id</samp> to pass the ID of the user making the
                  request.
                </p>
                <p class="p">To evaluate <span class="keyword parmname">targetEntityField </span>by whether the
                  field is empty or not empty, leave <span class="keyword parmname">filterValue</span> blank and set
                  <span class="keyword parmname">filterOperator </span>to <samp class="codeph nolang">e</samp>
                  (equals) or <samp class="codeph nolang">n</samp> (not equals).
                </p>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d210363e613" data-title="Field Name"><span class="keyword parmname">targetEntityField</span></td>

              <td class="entry" headers="d210363e616" data-title="Field Type">string</td>

              <td class="entry" headers="d210363e619" data-title="Description">Required. The API name of the field to filter by. This field is from the
                <span class="keyword parmname">targetEntity</span> on BriefcaseRule. Compound fields aren't
                supported. Fields encrypted with deterministic encryption can be used in filters
                with equals and not equals operators.
              </td>

            </tr>

          </tbody>

        </table>

## Declarative Metadata Sample Definition

The following is an example of a BriefcaseDefinition component for account records.

The following is an example definition of a briefcase definition. If you include a rule filter, you must include a filter logic.

<?xml version="1.0" encoding="UTF-8"?>
<BriefcaseDefinition xmlns="http://soap.sforce.com/2006/04/metadata">
    <briefcaseRules\>
        <briefcaseRuleFilters\>
           <filterOperator\>g</filterOperator\>
           <filterSeqNumber\>1</filterSeqNumber\>
           <filterValue\>50000.00</filterValue\>
           <targetEntityField\>AnnualRevenue</targetEntityField\>
        </briefcaseRuleFilters\>
        <briefcaseRuleFilters\>
            <filterOperator\>l</filterOperator\>
            <filterSeqNumber\>2</filterSeqNumber\>
            <filterValue\>50</filterValue\>
            <targetEntityField\>NumberOfEmployees</targetEntityField\>
        </briefcaseRuleFilters\>
        <filterLogic\>1 AND 2</filterLogic\>
        <isAscendingOrder\>false</isAscendingOrder\>
        <orderBy\>NumberOfEmployees</orderBy\>
        <queryScope\>Everything</queryScope\>
        <recordLimit\>1000</recordLimit\>
        <targetEntity\>Account</targetEntity\>
    </briefcaseRules\>
    <description\>Account Briefcase</description\>
    <isActive\>true</isActive\>
    <masterLabel\>Account With Standard Fields</masterLabel\>
</BriefcaseDefinition\>

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

<?xml version="1.0" encoding="UTF-8"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">
    <types\>
        <members\>AccountWithCustomFields</members\>
        <name\>BriefcaseDefinition</name\>
    </types\>
    <version\>49.0</version\>
</Package\>

This example briefcase definition configures the offline priming of file attachments for the WorkOrder object. Files Priming is available only for the Offline App (Salesforce Mobile App Plus).

<?xml version="1.0" encoding="UTF-8"?>
<BriefcaseDefinition xmlns="http://soap.sforce.com/2006/04/metadata" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <briefcaseRules\>
       <isAscendingOrder\>false</isAscendingOrder\>
       <orderBy\>SystemModstamp</orderBy\>
       <queryScope\>Everything</queryScope\>
       <recordLimit\>25</recordLimit\>
       <targetEntity\>WorkOrder</targetEntity\>
       <relatedRules\>
           <targetEntity\>ContentDocumentLink</targetEntity\>
           <relationshipField\>LinkedEntityId</relationshipField\>
           <relationshipType\>ParentToChild</relationshipType\>
           <isAscendingOrder\>false</isAscendingOrder\>
           <isRelatedFilesRule\>true</isRelatedFilesRule\>
           <queryScope\>Everything</queryScope\>
           <recordLimit\>2</recordLimit\>
           <relatedRules\>
               <targetEntity\>ContentDocument</targetEntity\>
               <relationshipField\>ContentDocumentId</relationshipField\>
               <relationshipType\>ChildToParent</relationshipType\>
               <isAscendingOrder\>false</isAscendingOrder\>
               <isRelatedFilesRule\>true</isRelatedFilesRule\>
               <queryScope\>Everything</queryScope\>
               <recordLimit\>2</recordLimit\>
               <relatedRules\>
                   <targetEntity\>ContentVersion</targetEntity\>
                   <relationshipField\>ContentDocumentId</relationshipField\>
                   <relationshipType\>ParentToChild</relationshipType\>
                   <isAscendingOrder\>false</isAscendingOrder\>
                   <isRelatedFilesRule\>true</isRelatedFilesRule\>
                   <queryScope\>Everything</queryScope\>
                   <recordLimit\>2</recordLimit\>
               </relatedRules\>
           </relatedRules\>
       </relatedRules\>
   </briefcaseRules\>
   <description xsi:nil="true"/>
   <isActive\>true</isActive\>
   <masterLabel\>WorkOrder with Related Files</masterLabel\>
</BriefcaseDefinition\>

## 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](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/file_based_zip_file.htm "The deploy() and retrieve() calls are used to deploy and retrieve a .zip file. Within the .zip file is a project manifest (package.xml) that lists what to retrieve or deploy, and one or more XML components that are organized into folders.").

## Usage

Briefcase objects are available in orgs that have Briefcase Builder and Field Service enabled.