# Interface IAnalyticsClient

## Index

### Methods

- getCurrentVisitIdPromise
- getTopQueries
- isActivated
- logClickEvent
- logCustomEvent
- logSearchAsYouType
- logSearchEvent
- setOriginContext

## Methods

### getCurrentVisitIdPromise

- getCurrentVisitIdPromise(): Promise<string>

- - Defined in ui/Analytics/AnalyticsClient.ts :145

  #### Returns Promise<string>

### getTopQueries

- getTopQueries(params: ITopQueries): Promise<string[]>

- - Defined in ui/Analytics/AnalyticsClient.ts :139

  #### Parameters

  - ##### params: ITopQueries

  #### Returns Promise<string[]>

### isActivated

- isActivated(): boolean

- - Defined in ui/Analytics/AnalyticsClient.ts :22

  #### Returns boolean

### logClickEvent

- logClickEvent<TMeta>(actionCause: IAnalyticsActionCause, meta: TMeta, result: IQueryResult, element: HTMLElement): Promise<IAPIAnalyticsEventResponse>

- - Defined in ui/Analytics/AnalyticsClient.ts :98

  #### Type parameters

  - #### TMeta

  #### Parameters

  - ##### actionCause: IAnalyticsActionCause

  - ##### meta: TMeta

  - ##### result: IQueryResult

  - ##### element: HTMLElement

  #### Returns Promise<IAPIAnalyticsEventResponse>

### logCustomEvent

- logCustomEvent<TMeta>(actionCause: IAnalyticsActionCause, meta: TMeta, element: HTMLElement, result?: IQueryResult): Promise<IAPIAnalyticsEventResponse>

- - Defined in ui/Analytics/AnalyticsClient.ts :128

  #### Type parameters

  - #### TMeta

  #### Parameters

  - ##### actionCause: IAnalyticsActionCause

  - ##### meta: TMeta

  - ##### element: HTMLElement

  - ##### Optional result: IQueryResult

  #### Returns Promise<IAPIAnalyticsEventResponse>

### logSearchAsYouType

- logSearchAsYouType<TMeta>(actionCause: IAnalyticsActionCause, meta: TMeta): void

- - Defined in ui/Analytics/AnalyticsClient.ts :73

  #### Type parameters

  - #### TMeta

  #### Parameters

  - ##### actionCause: IAnalyticsActionCause

  - ##### meta: TMeta

  #### Returns void

### logSearchEvent

- logSearchEvent<TMeta>(actionCause: IAnalyticsActionCause, meta: TMeta): void

- - Defined in ui/Analytics/AnalyticsClient.ts :46

  #### Type parameters

  - #### TMeta

  #### Parameters

  - ##### actionCause: IAnalyticsActionCause

  - ##### meta: TMeta

  #### Returns void

### setOriginContext

- setOriginContext(originContext: string): any

- - Defined in ui/Analytics/AnalyticsClient.ts :162

  #### Parameters

  - ##### originContext: string

  #### Returns any

### Hierarchy

- IAnalyticsClient