Skip to main content
View as Markdown

Search Item (`searchItems`) Deep Dive - Content Management

Search Item (searchItems) Deep Dive​

These objects define what you're searching for within the searchOperator.searchItems array.

Common Search Item Types:

  • KalturaESearchUnifiedItem: Searches across multiple standard fields (name, description, tags, captions, etc.). Ideal for general keyword searches.
  • KalturaESearchEntryItem: Targets specific fields within a KalturaMediaEntry or KalturaBaseEntry.
  • KalturaESearchCaptionItem: Searches specifically within caption content.
  • KalturaESearchEntryMetadataItem: Searches within custom metadata fields linked to entries.
  • KalturaESearchCuePointItem: Searches within data fields of cue points linked to entries.
  • (Similar items exist for Category, User, Group searches, e.g., KalturaESearchCategoryItem)

Key Properties for Search Items:

  • objectType (String): Required. The specific Kaltura class name (e.g., "KalturaESearchUnifiedItem").
  • searchTerm (String): The keyword, phrase, or value to search for. Ignored if itemType is EXISTS or RANGE.
  • itemType (Enum KalturaESearchItemType): Required. Defines the matching strategy:
    • 1 (EXACT_MATCH): Matches the exact term (case-insensitive, tokenized).
    • 2 (PARTIAL): Allows partial word matches and utilizes synonym expansion (e.g., 'delicious' finds 'yummy').
    • 3 (STARTS_WITH): Matches terms that begin with the searchTerm.
    • 4 (EXISTS): Checks if the specified fieldName has any value.
    • 5 (RANGE): Performs a range query using the range property.
  • fieldName (Enum): Required for non-Unified items. Specifies the target field (e.g., KalturaESearchEntryFieldName::NAME, KalturaESearchCaptionFieldName::CONTENT).
  • addHighlight (Boolean, optional): Default false. Set to true to receive highlighted snippets in the response showing where matches occurred.
  • range (Object KalturaESearchRange): Required if itemType is RANGE. Defines the boundaries:
    • greaterThanOrEqual (Integer)
    • lessThanOrEqual (Integer)
    • greaterThan (Integer)
    • lessThan (Integer)
    • (Use epoch timestamps in seconds for date fields like created_at).
  • metadataProfileId (Integer, for Metadata items): ID of the metadata profile to search within.
  • xpath (String, optional for Metadata items): Targets a specific XML path within the metadata. If omitted, searches all fields in the profile.