Search API

Abstract
REST API for searching in OMN (Online Media Net): full-text and combined queries, type-ahead, suggestions, stored searches and index management.

Access

  • Bearer Authentication

Endpoints

Documents

PATCH /api/v1/search/documents

Update documents

Description

Processes document updates for a specific index

Parameters
Body Parameter
Name Description Required Default Pattern

DocumentUpdateRequestDto

Document update request containing the documents to be updated DocumentUpdateRequestDto

X

Return Type

-

Responses
Table 1. HTTP Response Codes
Code Message Datatype

200

Documents updated successfully

POST /api/v1/search/documents/wait

Wait for documents

Description

Waits for document updates to be processed with configurable timeout

Parameters
Body Parameter
Name Description Required Default Pattern

DocumentWaitRequestDto

Document wait request containing the documents to wait for and timeout configuration DocumentWaitRequestDto

X

Return Type

-

Responses
Table 2. HTTP Response Codes
Code Message Datatype

200

Documents processed successfully

404

Documents not found or processing timed out

History

POST /api/v1/search/history

Add history entry

Description

Adds a new entry to the search history

Parameters
Body Parameter
Name Description Required Default Pattern

HistoryAddDto

History add request containing the entry to be added to search history HistoryAddDto

X

Return Type
Content Type
  • application/json

Responses
Table 3. HTTP Response Codes
Code Message Datatype

200

History entry added successfully

HistoryAddResultDto

DELETE /api/v1/search/history

Delete history entries

Description

Deletes history entries based on user and context

Parameters
Body Parameter
Name Description Required Default Pattern

HistoryDeleteDto

History delete request containing parameters for deleting history entries HistoryDeleteDto

X

Content Type
  • application/json

Responses
Table 4. HTTP Response Codes
Code Message Datatype

200

History entries deleted successfully

HistoryDeleteResultDto

POST /api/v1/search/history/query

Query history entries

Description

Retrieves history entries based on the provided query parameters

Parameters
Body Parameter
Name Description Required Default Pattern

HistoryQueryDto

History query request containing parameters for retrieving history entries HistoryQueryDto

X

Return Type
Content Type
  • application/json

Responses
Table 5. HTTP Response Codes
Code Message Datatype

200

History entries retrieved successfully

HistoryQueryResultDto

Index

POST /api/v1/search/index

Process index command

Description

Processes an index command and returns the result

Parameters
Body Parameter
Name Description Required Default Pattern

IndexCommandDto

Index command request containing the command to be processed IndexCommandDto

X

Return Type
Content Type
  • application/json

Responses
Table 6. HTTP Response Codes
Code Message Datatype

200

Successful operation

IndexResultDto

GET /api/v1/search/index/state

List index states

Description

Returns a list of all index states

Return Type
Content Type
  • application/json

Responses
Table 7. HTTP Response Codes
Code Message Datatype

200

Successful operation

IndexStateItemDto[[AnyType]]

GET /api/v1/search/index

List indices

Description

Returns a list of all available indices

Return Type
Content Type
  • application/json

Responses
Table 8. HTTP Response Codes
Code Message Datatype

200

Successful operation

IndexItemDto[[AnyType]]

StoredSearch

DELETE /api/v1/search/storedsearch/{id}

Delete stored search

Description

Deletes a stored search by ID

Parameters
Path Parameters
Name Description Required Default Pattern

id

ID of the stored search to delete

X

Return Type

-

Responses
Table 12. HTTP Response Codes
Code Message Datatype

204

Stored search deleted successfully

404

Stored search not found

GET /api/v1/search/storedsearch/{id}

Load stored search by ID

Description

Retrieves a specific stored search by its ID

Parameters
Path Parameters
Name Description Required Default Pattern

id

ID of the stored search to retrieve

X

Return Type
Content Type
  • application/json

Responses
Table 13. HTTP Response Codes
Code Message Datatype

200

Stored search retrieved successfully

SearchDto

404

Stored search not found

SearchDto

GET /api/v1/search/storedsearch

Load stored searches

Description

Retrieves stored searches based on optional index type and configuration ID

Parameters
Query Parameters
Name Description Required Default Pattern

index

Index type to filter stored searches

-

configId

Configuration ID to filter stored searches

-

Content Type
  • application/json

Responses
Table 14. HTTP Response Codes
Code Message Datatype

200

Stored searches retrieved successfully

StoredSearchListResultDto

POST /api/v1/search/storedsearch

Store a search

Description

Creates a new stored search

Parameters
Body Parameter
Name Description Required Default Pattern

StoredSearchInsertDto

Stored search insert request containing the search to be stored StoredSearchInsertDto

X

Content Type
  • application/json

Responses
Table 15. HTTP Response Codes
Code Message Datatype

201

Search stored successfully

StoredSearchOperationResultDto

PATCH /api/v1/search/storedsearch/{id}

Update stored search

Description

Updates an existing stored search by ID

Parameters
Path Parameters
Name Description Required Default Pattern

id

ID of the stored search to update

X

Body Parameter
Name Description Required Default Pattern

StoredSearchDto

Stored search update request containing the updated search data StoredSearchDto

X

Content Type
  • application/json

Responses
Table 16. HTTP Response Codes
Code Message Datatype

200

Stored search updated successfully

StoredSearchOperationResultDto

404

Stored search not found

StoredSearchOperationResultDto

Suggest

POST /api/v1/search/suggest

Get suggestions

Description

Retrieves search suggestions based on the provided criteria

Parameters
Body Parameter
Name Description Required Default Pattern

SuggestDto

Suggest request containing the criteria for retrieving suggestions SuggestDto

X

Return Type
Content Type
  • application/json

Responses
Table 17. HTTP Response Codes
Code Message Datatype

200

Suggestions retrieved successfully

SuggestResultDto

TypeAhead

POST /api/v1/search/type-ahead

Get type-ahead suggestions

Description

Retrieves type-ahead suggestions based on the provided text and parameters

Parameters
Body Parameter
Name Description Required Default Pattern

TypeAheadDto

Type ahead request containing the text and parameters for retrieving type-ahead suggestions TypeAheadDto

X

Return Type
Content Type
  • application/json

Responses
Table 18. HTTP Response Codes
Code Message Datatype

200

Suggestions retrieved successfully

TypeAheadResultDto

Version

GET /api/v1/search/omn-search-version

Get OMN Search API version

Description

Returns the current version information of the OMN Search API

Return Type
Content Type
  • application/json

Responses
Table 19. HTTP Response Codes
Code Message Datatype

200

Successful operation

VersionDto

Models

CombinedQueryDto

Field Name Required Nullable Type Description Format

queryType

[String]

Enum: FULLTEXT, FIELD, COMBINED, TYPEAHEAD,

customProperty

String

queries

List of [CombinedQueryDto_allOf_queries]

operator

[String]

Enum: AND, OR,

CombinedQueryDtoAllOfQueries

Field Name Required Nullable Type Description Format

queryType

[String]

Enum: FULLTEXT, FIELD, COMBINED, TYPEAHEAD,

customProperty

String

queries

List of [CombinedQueryDto_allOf_queries]

operator

[String]

Enum: AND, OR,

name

String

value

String

comparator

[String]

Enum: EQ, NOT_EQ, LIKE, NOT_LIKE, GT, GE, LT, LE, TERM_STARTS_WITH, TERM_NOT_STARTS_WITH, TERM_ENDS_WITH, TERM_NOT_ENDS_WITH, TERM_WILDCARD, TERM_NOT_WILDCARD, IN, NOT_IN, IS_EMPTY, IS_NOT_EMPTY,

keyword

Boolean

language

String

text

String

count

Integer

int32

slop

Integer

int32

ConfigSearchDto

Field Name Required Nullable Type Description Format

searchType

[String]

Enum: CONFIG, INDEX,

configId

Long

int64

configIdentifier

String

labelLocalization

String

ContextDto

Field Name Required Nullable Type Description Format

searchType

[String]

Enum: CONFIG, INDEX,

DocumentUpdateItmDto

Field Name Required Nullable Type Description Format

id

Long

int64

guid

String

event

[String]

Enum: CREATE, UPDATE, DELETE,

DocumentUpdateRequestDto

Field Name Required Nullable Type Description Format

index

[String]

Enum: ASSET, PRODUCT, CHANNEL, GLOBAL, HISTORY, FS_TABLE_WFL, CHANNEL_2_PRODUCT,

documents

List of DocumentUpdateItmDto

DocumentWaitRequestDto

Field Name Required Nullable Type Description Format

index

[String]

Enum: ASSET, PRODUCT, CHANNEL, GLOBAL, HISTORY, FS_TABLE_WFL, CHANNEL_2_PRODUCT,

modifiedAt

Long

int64

maxWait

Long

int64

documents

List of [long]

int64

FacetDto

Field Name Required Nullable Type Description Format

facetType

[String]

Enum: NAMED, RANGED,

attribute

String

label

String

type

String

value

X

oas_any_type_not_mapped

count

Integer

int32

from

String

to

String

children

List of FacetDto

FacetGroupDto

Field Name Required Nullable Type Description Format

name

String

facets

List of FacetDto

FieldCfgDto

Field Name Required Nullable Type Description Format

fieldName

String

label

String

fieldType

String

aggregatable

Boolean

sortable

Boolean

multilingual

Boolean

attrIdentifier

String

nestedFields

List of FieldCfgDto

allowedOperators

List of [string]

FieldInfoRequestDto

Field Name Required Nullable Type Description Format

index

[String]

Enum: ASSET, PRODUCT, CHANNEL, GLOBAL, HISTORY, FS_TABLE_WFL, CHANNEL_2_PRODUCT,

showAllowedOperators

Boolean

fields

List of [string]

FieldQueryDto

Field Name Required Nullable Type Description Format

queryType

[String]

Enum: FULLTEXT, FIELD, COMBINED, TYPEAHEAD,

customProperty

String

name

String

value

X

oas_any_type_not_mapped

comparator

[String]

Enum: EQ, NOT_EQ, LIKE, NOT_LIKE, GT, GE, LT, LE, TERM_STARTS_WITH, TERM_NOT_STARTS_WITH, TERM_ENDS_WITH, TERM_NOT_ENDS_WITH, TERM_WILDCARD, TERM_NOT_WILDCARD, IN, NOT_IN, IS_EMPTY, IS_NOT_EMPTY,

keyword

Boolean

language

String

FulltextQueryDto

Field Name Required Nullable Type Description Format

queryType

[String]

Enum: FULLTEXT, FIELD, COMBINED, TYPEAHEAD,

customProperty

String

value

String

HighlightDto

Field Name Required Nullable Type Description Format

name

String

value

List of [string]

HistoryAddDto

Field Name Required Nullable Type Description Format

text

String

user

String

context

String

HistoryAddResultAllOfAddedDto

Field Name Required Nullable Type Description Format

id

Long

int64

text

String

user

String

context

String

HistoryAddResultDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

added

HistoryAddResultAllOfAddedDto

HistoryDeleteDto

Field Name Required Nullable Type Description Format

user

String

context

String

HistoryDeleteResultAllOfDeletedDto

Field Name Required Nullable Type Description Format

user

String

context

String

count

Long

int64

HistoryDeleteResultDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

deleted

HistoryDeleteResultAllOfDeletedDto

HistoryQueryDto

Field Name Required Nullable Type Description Format

text

String

user

String

context

String

count

Integer

int32

HistoryQueryResultDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

histories

List of [string]

IndexCommandDto

Field Name Required Nullable Type Description Format

index

[String]

Enum: ASSET, PRODUCT, CHANNEL, GLOBAL, HISTORY, FS_TABLE_WFL, CHANNEL_2_PRODUCT,

command

[String]

Enum: REBUILD, STATE, ENABLE_INCREMENTAL_UPDATES, DISABLE_INCREMENTAL_UPDATES,

IndexItemDto

Field Name Required Nullable Type Description Format

index

String

outdated

Boolean

createdAt

String

IndexResultDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

index

String

event

[String]

Enum: PREPARE, CREATE_INDEX, ADD_DOCUMENTS, SET_ALIAS, PROCESS_DELTA, DELETE_OLD_INDEX, END, ERROR, BUSY,

documentsProcessed

Long

int64

totalDocuments

Long

int64

command

String

IndexSearchDto

Field Name Required Nullable Type Description Format

searchType

[String]

Enum: CONFIG, INDEX,

index

[String]

Enum: ASSET, PRODUCT, CHANNEL, GLOBAL, HISTORY, FS_TABLE_WFL, CHANNEL_2_PRODUCT,

IndexStateItemDto

Field Name Required Nullable Type Description Format

index

String

mappingState

IndexStateItemMappingStateDto

indexingState

IndexStateItemIndexingStateDto

IndexStateItemIndexingStateDto

Field Name Required Nullable Type Description Format

state

[String]

Enum: PREPARE, CREATE_INDEX, ADD_DOCUMENTS, SET_ALIAS, PROCESS_DELTA, DELETE_OLD_INDEX, END, ERROR, BUSY,

documentsProcessed

Long

int64

totalDocuments

Long

int64

IndexStateItemMappingStateDto

Field Name Required Nullable Type Description Format

outdated

Boolean

createdAt

String

JoinDto

Field Name Required Nullable Type Description Format

joinOn

String

search

SearchDto

QueryDto

Field Name Required Nullable Type Description Format

queryType

[String]

Enum: FULLTEXT, FIELD, COMBINED, TYPEAHEAD,

customProperty

String

ResultAttributeDto

Field Name Required Nullable Type Description Format

name

String

label

String

type

String

value

X

oas_any_type_not_mapped

ResultItemDto

Field Name Required Nullable Type Description Format

id

Long

int64

attributes

List of ResultAttributeDto

highlights

List of HighlightDto

SearchDto

Field Name Required Nullable Type Description Format

context

[SearchDto_context]

query

[CombinedQueryDto_allOf_queries]

maxResults

Integer

int32

pageIndex

Integer

int32

pageSize

Integer

int32

sortOptions

List of SortOptionDto

aggregationEnabled

Boolean

aggregateEmptyValueEnabled

Boolean

aggregationMaxResults

Integer

int32

resultAttributes

List of [string]

storedFields

List of [string]

aggregationAttributes

List of [string]

join

JoinDto

language

String

customProperty

String

SearchDtoContext

Field Name Required Nullable Type Description Format

searchType

[String]

Enum: CONFIG, INDEX,

configId

Long

int64

configIdentifier

String

labelLocalization

String

index

[String]

Enum: ASSET, PRODUCT, CHANNEL, GLOBAL, HISTORY, FS_TABLE_WFL, CHANNEL_2_PRODUCT,

SearchResultDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

resultCount

Integer

int32

totalHitCount

Long

int64

exactHitCount

Boolean

items

List of ResultItemDto

facets

List of FacetGroupDto

suggest

SuggestResultDto

SortOptionDto

Field Name Required Nullable Type Description Format

attribute

String

direction

[String]

Enum: ASC, DESC,

language

String

StoredSearchDto

Field Name Required Nullable Type Description Format

name

String

searchObject

SearchDto

StoredSearchEntryDto

Field Name Required Nullable Type Description Format

id

Long

int64

index

String

name

String

pluginConfigurationId

Long

int64

pluginIdentifier

String

StoredSearchInsertDto

Field Name Required Nullable Type Description Format

name

String

searchObject

SearchDto

StoredSearchListResultDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

storedSearchEntries

List of StoredSearchEntryDto

StoredSearchOperationResultDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

id

Long

int64

name

String

SuggestDto

Field Name Required Nullable Type Description Format

index

[String]

Enum: ASSET, PRODUCT, CHANNEL, GLOBAL, HISTORY, FS_TABLE_WFL, CHANNEL_2_PRODUCT,

text

String

count

Integer

int32

SuggestResultDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

suggestions

List of [string]

TypeAheadDto

Field Name Required Nullable Type Description Format

index

[String]

Enum: ASSET, PRODUCT, CHANNEL, GLOBAL, HISTORY, FS_TABLE_WFL, CHANNEL_2_PRODUCT,

name

String

text

String

count

Integer

int32

slop

Integer

int32

TypeAheadQueryDto

Field Name Required Nullable Type Description Format

queryType

[String]

Enum: FULLTEXT, FIELD, COMBINED, TYPEAHEAD,

customProperty

String

name

String

text

String

count

Integer

int32

slop

Integer

int32

TypeAheadResultDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

suggestions

List of [string]

advSuggestions

List of TypeAheadSuggestionDto

corrections

List of [string]

TypeAheadSuggestionDto

Field Name Required Nullable Type Description Format

text

String

from

String

VersionDto

Field Name Required Nullable Type Description Format

apiVersion

String

processingTimeMillis

Long

int64

majorVersion

String

minorVersion

String

patchVersion

String

qualifier

String

buildDate

String