1. @sitecore-cloudsdk/search/server

SearchEventEntity

Version:

Type

Interface

Import path

@sitecore-cloudsdk/search/server

Data about the index documents the site visitor interacts with in the search results.

Signature

export interface SearchEventEntity {
  id: string;
  entity: string;
  entityType?: string;
  uri?: string;
  attributes?: Record<string, string>;
  sourceId?: string;
}

Properties

Name

Type

Description

Value

id

string

Required.

The unique identifier of the entity.

"id_123"

entity

string

Required.

The index document the site visitor interacts with.

For example, the blog post the site visitor clicks in the search results.

  • "content"

  • "category"

  • "product"

  • "store"

  • "video"

entityType

string

Optional.

The subtype of the entity.

For example, for the "content" entity, this value could be "blog entry" or "article". For the "category" entity, this value could be "electronics", "smartphones", or "video games".

  • "blog entry"

  • "smartphones"

uri

string

Optional.

The URI of the entity.

"https://www.sitecore.com/resources/article/id_123"

attributes

Record<string, string>

Optional.

Attributes for the entity that the site visitor interacts with.

Set this value to an attribute or attributes defined in Sitecore Search.

To find attributes in Sitecore Search, click Administration > Domain Settings > Attributes.

  • "name"

  • "description"

  • "brand"

  • "image_URL"

  • "price"

sourceId

string

Optional.

The ID of the source of the entity.

"sourceId123"

If you have suggestions for improving this article, let us know!