Loading
Upcoming Mandatory Changes to Public Key Infrastructure (PKI)Read More
Salesforce Enforces New Security Requirements in Summer 2026Read More
Vlocity Contract Lifecycle Management
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Map Rich Text Tokens in the Omnistudio Data Mappers

          Map Rich Text Tokens in the Omnistudio Data Mappers

          Using rich text tokens in the Microsoft Word document templates, you can insert rich text content in the generated .docx and .pdf files. The rich text token format is {{RTB_<richtexttokenname>}}, for example, {{RTB_Header}}.

          1. Create a Microsoft Word document with rich text tokens.

            For more information, see Tokens in Microsoft Word or Microsoft PowerPoint Documents.

            You can place rich text tokens anywhere within the document template, such as in a paragraph, table, text box, header, or footer. The rich text field allows you to format text using different fonts, colors, ordered and unordered lists, and hyperlinks. Rich text tokens must be placed in a new line in the document template. Here's an example of a .docx document with rich text tokens.

            This image shows image tokens being used in the header and within a table in a document template.
          2. Create a Microsoft Word template.
            1. From the Token Mapping Method, select Data Mapper.
            2. Enter a Mapping Data Mapper Bundle Name. The Data Mapper Transform maps the field with the Id to the token in the document template. The Data Mapper Transform then transforms the tokens with actual data in the document.
            3. Enter a Data Extract Data Mapper Bundle Name. The Data Mapper Extract retrieves the field with the Id that identifies the image to be used in tokens.
          3. Click Link icon. icon next to the Data Extract Data Mapper Bundle Name field to open the Data Mapper Extract in a new browser tab.
            1. Create a Data Mapper Extract. For more information, see Data Mapper Extract Overview.
            2. Define the Initial Extraction. For more information, see Define the Initial Extraction.
              This image shows the extract tab of the Data Mapper Extract where we have specified contract as the object to be queried and Id as the filter.
            3. Define Data Mapper Extract Output. For more information, see Data Mapper Extract Output.
            4. In the Extract JSON Path field, select the source field for extraction.
            5. In the Output JSON Path field, specify the desired output path.
              This image shows the data mapping from the extraction step JSON to the output JSON in the Output tab.
            6. Repeat the steps d and e to add all the rich text tokens source fields.
            7. In the Preview tab, enter the Salesforce object Id and execute to verify that the response pane displays a JSON structure containing the desired output.
              This image shows the Preview tab where the mapping you provided for the rich text has been executed.
            8. Go to the Output tab, copy the Current JSON Output, and save to use it later in your Data Mapper Transform. The Current JSON Output pane displays the structure that your output mappings specify.
          4. Click Link icon. icon next to the Mapping Data Mapper Bundle Name field to open the Data Mapper Transform in a new tab.
            Note
            Note

            You can map data on the Transforms tab in one of two ways: If the input and output names match, Use Quick Match to Map Data, else specify each mapping individually. For more information see Data Mapper Transform Data Mappings.

            1. Create a Data Mapper Transform. For more information, see Data Mapper Transform Overview.
            2. In the Transform tab, paste the Current JSON Output code that you copied from the Data Mapper Extract into the Input JSON panel.
            3. Click Quick Match. The fields in the Input Mappings column come from the JSON code (Current JSON Output of the extractor). The fields in the Output Mappings column come from the tokens in the document template.
              This image shows two columns Input Mappings and Output Mappings. The fields in the Input Mappings column come from the JSON code (Current JSON Output of the extractor). The fields in the Output Mappings column come from the tokens in the document template.
            4. Click Auto Match to match the input and output fields.If fields don’t match automatically, drag fields from the Input column to the Output column.
              This image shows column Matched Mapping populated when the fields from the Input column to the Output column are matched.
            5. Click Save.
          5. Verify that the Data Mappers pull the information from the sObject and populate the document template.
            1. In the Document Template Designer, click Test Template.
            2. In the Object ID box, enter the object ID from where you want to pull the information and then click Next. The document is generated and the tokens are replaced with the rich text content.
              The image shows that the generated document has the tokens are replaced with the rich text content.

              You can download the generated document either in .docx, or .pdf format by using the Download Word, or Download PDF button, respectively.

           
          Loading
          Salesforce Help | Article