Add/Edit Body Mapping

When Coveo Cloud V2 indexes an item, it also retrieves the item metadata, i.e., values of item fields such as filetype, date, and author, and maps them to a Coveo index field. This makes the item metadata searchable.

The mapping process is similar for the item body, i.e., actual content, which is mapped to the body Coveo index field whenever possible. The content is indexed, made searchable, and visible from the Content Browser in the Item Properties panel, under the Quick View tab, as well as from the search interface, via the Quick View button (see Item Properties - Panel).

When you index a PDF file, the file body contains all the text visible when you print the PDF.

For standard sources, the indexing pipeline Crawling stage creates a representative body for the item content. This default body is displayed in the Quick View (see Coveo Cloud V2 Indexing Pipeline).

However, Coveo Cloud V2 may not be able to automatically create item bodies to display in the Quick View when there is no standard item content layout, or when the item body is an assembly of values from all or some key records. Records are typically mapped to specific fields. The assembled Quick View may therefore not contain the relevant data or not present it in an appropriate format.

  • A Jira source issue item consists of a collection of fields defining the issue, such as Summary, Reporter, Assignee, Description, Comments, Creation date, and Modification date. The Jira source crawler automatically creates a default body made up of the key fields that is available in the Quick View.

  • A source indexes a contact database. Each item is one contact consisting in several records such as the contact’s first name, last name, gender, title, email address, phone number, etc. Every item record is mapped to a specific field. There is no standard UI arrangement for all the item records that a user can view, and the database crawler can therefore not create an item body to display in the Quick View.

When you have the required privileges, you can add custom body mappings and edit Coveo default body mappings. You can define the desired body with static HTML and metadata placeholders to be replaced with item metadata values. The resulting customized item body is then displayed in the Quick View.

The indexing pipeline handles the body field in a slightly different way from other fields, since body is the only field that modifies search results in the free text of an indexed item. This allows you to customize search results and to update the corresponding Quick View. However, this works with fairly simple body mappings only. To implement a more advanced customization, you must rather leverage indexing pipeline extensions (see Extensions - Page).

Since the body mapping applies at preconversion only, only metadata extracted at the Crawling stage or by a preconversion extension can be mapped (see Coveo Cloud V2 Indexing Pipeline). Metadata extracted at the conversion stage or by a postconversion extension cannot appear in a custom item body.

What’s Next?

Ensure that your body mapping works as expected in the content browser (see Quick View Tab).