File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -90,6 +90,12 @@ export interface GetSearchRequest {
9090
9191export type Hit < T > = T & { _formatted ?: T }
9292
93+ export type CategoriesDistribution = {
94+ [ category : string ] : number
95+ }
96+
97+ export type Facet = string
98+
9399// The second generic P is used to capture the SearchParams type
94100export interface SearchResponse < T , P extends SearchParams < T > > {
95101 // P represents the SearchParams
@@ -101,7 +107,7 @@ export interface SearchResponse<T, P extends SearchParams<T>> {
101107 offset : number
102108 limit : number
103109 processingTimeMs : number
104- facetsDistribution ?: object
110+ facetsDistribution ?: Record < Facet , CategoriesDistribution >
105111 exhaustiveFacetsCount ?: boolean
106112 query : string
107113 nbHits : number
You can’t perform that action at this time.
0 commit comments