---
schema_version: "1"
id: d67ba8a43ce41692a382259111706da667198b3c265abff996c5a5dbc7c7fe8d
title: Object Field Mapping (Managed Package)
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/xcloud/264-0-0/os_object_field_mapping.md
canonical_url: https://help.salesforce.com/s/articleView?id=xcloud.os_object_field_mapping.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 69d02e2ed96cff0f74c647f4f528ff038724601266f417e90026bba7656b81ac
description: For the managed package runtime, on the Fields tab, you map data from the Omnistudio Data Mapper Load input JSON to the target Salesforce object and field. You can also handle data types, attributes, and default values.
products:
  - Omnistudio
release: "264"
---
# Object Field Mapping (Managed Package)

For the managed package runtime, on the Fields tab, you map data from the Omnistudio Data Mapper Load input JSON to the target Salesforce object and field. You can also handle data types, attributes, and default values.

![Managed Package app icon](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-omnistudio_for_managed_packages-264-0-0-production-enus/aa2554ec-624a-4ee6-8da4-6435670e6e62/resources-global/_corporate/images/managedpackageicon.png) This information is for Omnistudio for Managed Packages. For Omnistudio on standard runtime, see [Omnistudio Help](https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_standard.htm&language=en_US).

For each field, click **+** and configure these settings:

- **Input JSON Path** — The key of the JSON node containing the data you want to write to Salesforce.
- **Domain Object Field** — The field in the sObject that you want to update.
    
    In fields that contain JSON data, you can't map JSON nodes individually. Stringify all JSON nodes that have values to ensure that no JSON data is lost. For example:
    
    ```
    "JsonField": "{"JsonNode1":"Text", "JsonNode2":100, "JsonNode3":true}"
    ```

If you’re updating multiple Salesforce objects, the designer displays a separate tab for the mappings of each target object. See [Multiple Related Object Loads (Link Mappings) (Managed Package)](https://help.salesforce.com/s/articleView?id=xcloud.os_multiple_related_object_loadslink_mappings.htm&release=264.0.0&type=5 "For the managed package runtime, when loading data into a sequence of objects, you can propagate data directly from one object to another related object. For example, you can use an Omnistudio Data Mapper Load to support an Omniscript that creates an Account and a Contact for the Account.").

## Mapping Options

To control how the update is performed, you can configure the following optional settings:

- **Is Disabled** — Prevents the field from being loaded.
- **Upsert Key** — Specifies that the field is a key for the Salesforce object being loaded. The Data Mapper uses the value to determine whether it updates an existing record or inserts a new one. If the **Upsert** property is enabled for multiple field mappings, the result is a multi-field upsert key. Data Mapper uses this key to check the object for unique values to determine whether to create or update an object. Don’t use an ID as the upsert key. If the input contains an ID, the Data Mapper updates the record. If the input doesn’t contain an ID, Data Mapper creates a record.
- **Is Required for Upsert** — Prevents an object record from being updated if this field is null.
- **Is Lookup** — Uses the field value to query for the specified Salesforce data, and writes the result to the output field.
- **Output Data Type** — Must be compatible with the data type of the target field.
    
    The Output Data Type setting must be compatible with the target field in Salesforce. If you configure incompatible types, the load operation can fail. For a list of valid output types, see [Omnistudio Data Mapper Output Data Types (Managed Package)](https://help.salesforce.com/s/articleView?id=xcloud.os_dataraptor_output_data_types.htm&release=264.0.0&type=5 "For the managed package runtime, many data types can be assigned to data in the Output JSON, including boolean, currency, string, various number and list types, and date formats.").
- **Default Value** — Value to be loaded if the field in the Data Mapper output JSON is null. To specify an empty string for string fields that are null, enter a pair of double quotes (""). Omit if **Is Required for Upsert** is enabled.

## Attribute Data Loads

To change the value of an object attribute using a Data Mapper Load, specify the attribute using its code (not its name) preceded by @. (An attribute is assigned a GUID value when created, but you can edit the code to specify a human-readable value. Outside of Data Mapper Designer, Salesforce displays the GUID, regardless of whether you override it.) To add a profile attribute to an object, enable **Upsert Key** for the object Id.Overview of Attributes

In Spring '20 and later releases, in the **Domain Object Field**, type-ahead is supported for up to 500 attributes. For example, you can type @C to display attributes beginning with the letter C and select from the dropdown list instead of typing the entire attribute name manually.

For example, to assign Gold Star Status to an account, set the corresponding attribute to `on` as follows:

Mappings:

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small ">
        <colgroup>
          <col>
          <col>
          <col>
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="col" class="slds-cell-wrap" style="vertical-align:top;" id="d210701e206">
              <p style="margin-bottom:0;">Input JSON Path</p>
            </th>
            <th scope="col" class="slds-cell-wrap" style="vertical-align:top;" id="d210701e212">
              <p style="margin-bottom:0;">Domain Object Field</p>
            </th>
            <th scope="col" class="slds-cell-wrap" style="vertical-align:top;" id="d210701e218">
              <p style="margin-bottom:0;">Upsert Key</p>
            </th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="Input JSON Path" class="slds-cell-wrap" style="vertical-align:top;" headers="d210701e206 ">
              <p style="margin-bottom:0;">GoldStarAccount</p>
            </td>

            <td data-label="Domain Object Field" class="slds-cell-wrap" style="vertical-align:top;" headers="d210701e212 ">
              <p style="margin-bottom:0;">@GoldStarAccount</p>
            </td>

            <td data-label="Upsert Key" class="slds-cell-wrap" style="vertical-align:top;" headers="d210701e218 ">
              <p style="margin-bottom:0;">(unchecked)</p>
            </td>

          </tr>
          <tr class="">
            <td data-label="Input JSON Path" class="slds-cell-wrap" style="vertical-align:top;" headers="d210701e206 ">
              <p style="margin-bottom:0;">Id</p>
            </td>

            <td data-label="Domain Object Field" class="slds-cell-wrap" style="vertical-align:top;" headers="d210701e212 ">
              <p style="margin-bottom:0;">Id</p>
            </td>

            <td data-label="Upsert Key" class="slds-cell-wrap" style="vertical-align:top;" headers="d210701e218 ">
              <p style="margin-bottom:0;">(checked)</p>
            </td>

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

Input JSON:

```
{
	"Id": "0016100001Ey84K",
	"GoldStarAccount": "on"
}		
```

When assigning values to attributes, specify values that are data-type-compatible as follows:

- On-Off: To apply the attribute to the object, specify `"On"`, `true`, or `"true"`. To remove the attribute from the object, specify `"Off"`, `false`, or `"false"`.
- Three-state: Specify a negative value, a positive value, or 0.
- 1 to 5: Specify a value from 1 to 5. Values less than 1 are treated as 1, and values greater than 5 are treated as 5.
- TextComment: String data

Product attributes can’t be added to or modified for the Product object using Data Mapper Loads. You can modify product attributes for the following objects:

- Asset
- CompiledAttributeOverride\_\_c
- ContractLineItem\_\_c
- FulfilmentRequestLine\_\_c
- InventoryItem\_\_c
- OpportunityLineItem
- OrderItem
- ProgramEnrollment\_\_c
- QuoteLineItem

![Important](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-omnistudio_for_managed_packages-264-0-0-production-enus/aa2554ec-624a-4ee6-8da4-6435670e6e62/images/icon_important.png)

Important

A Data Mapper Load can’t create a Product Attribute for a Line Item. It can only modify existing Product Attributes for existing Line Items.

![Note](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-omnistudio_for_managed_packages-264-0-0-production-enus/aa2554ec-624a-4ee6-8da4-6435670e6e62/images/icon_note.png)

Note

For ​Salesforce Industries Communications, Media, and Energy customers who use Industries Order Management, attribute mappings using the JSONAttribute v2 Schema aren’t supported for the vlocity\_cmt\_\_FulfilmentRequestLine\_\_c object.

## What's Next