@indxsearch/indx-types 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md ADDED
@@ -0,0 +1,33 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
+
8
+ ## [1.0.0] - 2026-01-21
9
+
10
+ ### Added
11
+ - Initial release of `@indxsearch/indx-types`
12
+ - Complete TypeScript type definitions for IndxCloudApi v1.0.2
13
+ - `CoverageSetup` interface with all current properties
14
+ - `CloudQuery` interface for search requests
15
+ - `Result` and `ScoreEntry` interfaces for search responses
16
+ - `FilterProxy`, `RangeFilterProxy`, `ValueFilterProxy`, `CombinedFilterProxy` for filtering
17
+ - `BoostProxy` interface for search result boosting
18
+ - `SystemStatus` and `LicenseInfo` interfaces for system health
19
+ - `LoginInfo` interface for authentication
20
+ - `SystemState` enum (Hibernated, Created, Loading, Loaded, Indexing, Ready, Error)
21
+ - `BoostStrength` enum (Low, Medium, High)
22
+ - `StringInt32KeyValuePair` utility type
23
+ - Zero runtime dependencies (types-only package)
24
+ - Full ESM and CommonJS support
25
+ - Comprehensive README with usage examples
26
+ - Apache 2.0 license
27
+
28
+ ### Technical Details
29
+ - Based on official Swagger specification from https://cloud.indx.co/swagger/v1/swagger.json
30
+ - All properties correctly typed with optional modifiers matching API spec
31
+ - `documentKey` correctly typed as `number` (Int32)
32
+ - `truncationScore` default value: 255 (byte)
33
+ - `systemState` properly uses `SystemState` enum
package/LICENSE ADDED
@@ -0,0 +1,190 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, trademark, patent,
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ Copyright 2026 Indx Search (Bionic AS)
179
+
180
+ Licensed under the Apache License, Version 2.0 (the "License");
181
+ you may not use this file except in compliance with the License.
182
+ You may obtain a copy of the License at
183
+
184
+ http://www.apache.org/licenses/LICENSE-2.0
185
+
186
+ Unless required by applicable law or agreed to in writing, software
187
+ distributed under the License is distributed on an "AS IS" BASIS,
188
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
189
+ See the License for the specific language governing permissions and
190
+ limitations under the License.
package/README.md ADDED
@@ -0,0 +1,210 @@
1
+ # @indxsearch/indx-types
2
+
3
+ TypeScript type definitions for **IndxCloudApi v1.0.2**. This package provides complete, strongly-typed interfaces for search queries, filters, boosts, results, and system status based on the official [Swagger specification](https://cloud.indx.co/swagger/v1/swagger.json).
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install @indxsearch/indx-types
9
+ ```
10
+
11
+ ## Features
12
+
13
+ - Complete TypeScript type definitions for IndxCloudApi v1.0.2
14
+ - Zero runtime dependencies (types-only package)
15
+ - Matches official Swagger API specification exactly
16
+ - Full IntelliSense support in VS Code and other IDEs
17
+ - Supports both ESM and CommonJS
18
+
19
+ ## Version Compatibility
20
+
21
+ This package (`@indxsearch/indx-types` v1.0.0) provides types for **IndxCloudApi v1.0.2**. The types are generated directly from the Swagger specification to ensure accuracy and completeness.
22
+
23
+ ## Usage
24
+
25
+ ### Basic Query
26
+
27
+ ```typescript
28
+ import type { CloudQuery, Result } from '@indxsearch/indx-types';
29
+
30
+ const query: CloudQuery = {
31
+ text: 'search term',
32
+ maxNumberOfRecordsToReturn: 10,
33
+ enableCoverage: true,
34
+ coverageDepth: 3
35
+ };
36
+
37
+ // Use with your API client
38
+ const result: Result = await apiClient.search(query);
39
+ ```
40
+
41
+ ### Filters
42
+
43
+ ```typescript
44
+ import type {
45
+ RangeFilterProxy,
46
+ ValueFilterProxy,
47
+ CombinedFilterProxy
48
+ } from '@indxsearch/indx-types';
49
+
50
+ // Range filter
51
+ const rangeFilter: RangeFilterProxy = {
52
+ fieldName: 'price',
53
+ lowerLimit: 10,
54
+ upperLimit: 100
55
+ };
56
+
57
+ // Value filter
58
+ const valueFilter: ValueFilterProxy = {
59
+ fieldName: 'category',
60
+ value: 'electronics'
61
+ };
62
+
63
+ // Combined filter
64
+ const combinedFilter: CombinedFilterProxy = {
65
+ a: rangeFilter,
66
+ b: valueFilter,
67
+ useAndOperation: true
68
+ };
69
+ ```
70
+
71
+ ### Boosts
72
+
73
+ ```typescript
74
+ import type { BoostProxy, BoostStrength } from '@indxsearch/indx-types';
75
+
76
+ const boost: BoostProxy = {
77
+ boostStrength: BoostStrength.High,
78
+ filterProxy: {
79
+ hashString: 'filter-hash'
80
+ }
81
+ };
82
+
83
+ const query: CloudQuery = {
84
+ text: 'search term',
85
+ enableBoost: true,
86
+ boosts: [boost]
87
+ };
88
+ ```
89
+
90
+ ### Coverage Setup
91
+
92
+ ```typescript
93
+ import type { CoverageSetup, CloudQuery } from '@indxsearch/indx-types';
94
+
95
+ const coverageSetup: CoverageSetup = {
96
+ coverWholeQuery: true,
97
+ coverWholeWords: true,
98
+ coverFuzzyWords: true,
99
+ minWordSize: 3,
100
+ levenshteinMaxWordSize: 20,
101
+ truncate: true,
102
+ truncationScore: 255
103
+ };
104
+
105
+ const query: CloudQuery = {
106
+ text: 'search term',
107
+ enableCoverage: true,
108
+ coverageSetup
109
+ };
110
+ ```
111
+
112
+ ### System Status
113
+
114
+ ```typescript
115
+ import type { SystemStatus, SystemState } from '@indxsearch/indx-types';
116
+
117
+ const status: SystemStatus = await apiClient.getStatus();
118
+
119
+ if (status.systemState === SystemState.Ready) {
120
+ console.log('System is ready');
121
+ console.log(`Documents indexed: ${status.documentCount}`);
122
+ }
123
+ ```
124
+
125
+ ## API Reference
126
+
127
+ ### Types
128
+
129
+ #### Query Types
130
+ - `CloudQuery` - Main search query interface
131
+ - `CoverageSetup` - Coverage configuration options
132
+
133
+ #### Filter Types
134
+ - `FilterProxy` - Base filter interface
135
+ - `RangeFilterProxy` - Numeric range filter
136
+ - `ValueFilterProxy` - Value-based filter
137
+ - `CombinedFilterProxy` - Combined filter with AND/OR operations
138
+
139
+ #### Result Types
140
+ - `Result` - Search result interface
141
+ - `ScoreEntry` - Individual result entry with score
142
+
143
+ #### Boost Types
144
+ - `BoostProxy` - Search result boost configuration
145
+
146
+ #### Status Types
147
+ - `SystemStatus` - System status and health information
148
+ - `LicenseInfo` - License validation details
149
+
150
+ #### Authentication
151
+ - `LoginInfo` - Login credentials interface
152
+
153
+ ### Enums
154
+
155
+ #### SystemState
156
+ - `Hibernated = -1`
157
+ - `Created = 0`
158
+ - `Loading = 1`
159
+ - `Loaded = 2`
160
+ - `Indexing = 3`
161
+ - `Ready = 4`
162
+ - `Error = 255`
163
+
164
+ #### BoostStrength
165
+ - `Low = 1`
166
+ - `Medium = 2`
167
+ - `High = 3`
168
+
169
+ ## TypeScript Configuration
170
+
171
+ This package is designed to work seamlessly with TypeScript. Add it to your `tsconfig.json`:
172
+
173
+ ```json
174
+ {
175
+ "compilerOptions": {
176
+ "types": ["@indxsearch/indx-types"]
177
+ }
178
+ }
179
+ ```
180
+
181
+ For monorepo development with path mapping:
182
+
183
+ ```json
184
+ {
185
+ "compilerOptions": {
186
+ "paths": {
187
+ "@indxsearch/indx-types": ["../indx-types/src"]
188
+ }
189
+ }
190
+ }
191
+ ```
192
+
193
+ ## Related Packages
194
+
195
+ - [@indxsearch/intrface](https://www.npmjs.com/package/@indxsearch/intrface) - React search UI components
196
+ - [@indxsearch/systm](https://www.npmjs.com/package/@indxsearch/systm) - Core search system
197
+ - [@indxsearch/pixl](https://www.npmjs.com/package/@indxsearch/pixl) - UI component library
198
+
199
+ ## Documentation
200
+
201
+ - [Swagger API Specification](https://cloud.indx.co/swagger/v1/swagger.json)
202
+ - [IndxCloudApi Documentation](https://cloud.indx.co/swagger)
203
+
204
+ ## License
205
+
206
+ Apache-2.0
207
+
208
+ ## Contributing
209
+
210
+ This package is part of the [indx-intrface](https://github.com/indxSearch/indx-intrface) monorepo. See the main repository for contribution guidelines.
package/dist/auth.d.ts ADDED
@@ -0,0 +1,5 @@
1
+ export interface LoginInfo {
2
+ userEmail: string;
3
+ userPassWord: string;
4
+ }
5
+ //# sourceMappingURL=auth.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../src/auth.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,SAAS;IACxB,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,EAAE,MAAM,CAAC;CACtB"}
package/dist/auth.js ADDED
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,7 @@
1
+ import { BoostStrength } from './enums';
2
+ import { FilterProxy } from './filters';
3
+ export interface BoostProxy {
4
+ boostStrength: BoostStrength;
5
+ filterProxy: FilterProxy;
6
+ }
7
+ //# sourceMappingURL=boost.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"boost.d.ts","sourceRoot":"","sources":["../src/boost.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAExC,MAAM,WAAW,UAAU;IACzB,aAAa,EAAE,aAAa,CAAC;IAC7B,WAAW,EAAE,WAAW,CAAC;CAC1B"}
package/dist/boost.js ADDED
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,5 @@
1
+ export interface StringInt32KeyValuePair {
2
+ key: string;
3
+ value: number;
4
+ }
5
+ //# sourceMappingURL=common.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../src/common.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,uBAAuB;IACtC,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;CACf"}
package/dist/common.js ADDED
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,15 @@
1
+ export declare enum SystemState {
2
+ Hibernated = -1,
3
+ Created = 0,
4
+ Loading = 1,
5
+ Loaded = 2,
6
+ Indexing = 3,
7
+ Ready = 4,
8
+ Error = 255
9
+ }
10
+ export declare enum BoostStrength {
11
+ Low = 1,
12
+ Medium = 2,
13
+ High = 3
14
+ }
15
+ //# sourceMappingURL=enums.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"enums.d.ts","sourceRoot":"","sources":["../src/enums.ts"],"names":[],"mappings":"AAAA,oBAAY,WAAW;IACrB,UAAU,KAAK;IACf,OAAO,IAAI;IACX,OAAO,IAAI;IACX,MAAM,IAAI;IACV,QAAQ,IAAI;IACZ,KAAK,IAAI;IACT,KAAK,MAAM;CACZ;AAED,oBAAY,aAAa;IACvB,GAAG,IAAI;IACP,MAAM,IAAI;IACV,IAAI,IAAI;CACT"}
package/dist/enums.js ADDED
@@ -0,0 +1,16 @@
1
+ export var SystemState;
2
+ (function (SystemState) {
3
+ SystemState[SystemState["Hibernated"] = -1] = "Hibernated";
4
+ SystemState[SystemState["Created"] = 0] = "Created";
5
+ SystemState[SystemState["Loading"] = 1] = "Loading";
6
+ SystemState[SystemState["Loaded"] = 2] = "Loaded";
7
+ SystemState[SystemState["Indexing"] = 3] = "Indexing";
8
+ SystemState[SystemState["Ready"] = 4] = "Ready";
9
+ SystemState[SystemState["Error"] = 255] = "Error";
10
+ })(SystemState || (SystemState = {}));
11
+ export var BoostStrength;
12
+ (function (BoostStrength) {
13
+ BoostStrength[BoostStrength["Low"] = 1] = "Low";
14
+ BoostStrength[BoostStrength["Medium"] = 2] = "Medium";
15
+ BoostStrength[BoostStrength["High"] = 3] = "High";
16
+ })(BoostStrength || (BoostStrength = {}));
@@ -0,0 +1,18 @@
1
+ export interface FilterProxy {
2
+ hashString?: string | null;
3
+ }
4
+ export interface RangeFilterProxy {
5
+ fieldName: string;
6
+ lowerLimit: number;
7
+ upperLimit: number;
8
+ }
9
+ export interface ValueFilterProxy {
10
+ fieldName: string;
11
+ value?: any | null;
12
+ }
13
+ export interface CombinedFilterProxy {
14
+ a: FilterProxy;
15
+ b: FilterProxy;
16
+ useAndOperation: boolean;
17
+ }
18
+ //# sourceMappingURL=filters.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"filters.d.ts","sourceRoot":"","sources":["../src/filters.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,WAAW;IAC1B,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B;AAED,MAAM,WAAW,gBAAgB;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,gBAAgB;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,GAAG,GAAG,IAAI,CAAC;CACpB;AAED,MAAM,WAAW,mBAAmB;IAClC,CAAC,EAAE,WAAW,CAAC;IACf,CAAC,EAAE,WAAW,CAAC;IACf,eAAe,EAAE,OAAO,CAAC;CAC1B"}
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,9 @@
1
+ export { SystemState, BoostStrength } from './enums';
2
+ export { LoginInfo } from './auth';
3
+ export { CloudQuery, CoverageSetup } from './query';
4
+ export { FilterProxy, RangeFilterProxy, ValueFilterProxy, CombinedFilterProxy } from './filters';
5
+ export { BoostProxy } from './boost';
6
+ export { Result, ScoreEntry } from './result';
7
+ export { SystemStatus, LicenseInfo } from './status';
8
+ export { StringInt32KeyValuePair } from './common';
9
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAGrD,OAAO,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAC;AAGnC,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAGpD,OAAO,EACL,WAAW,EACX,gBAAgB,EAChB,gBAAgB,EAChB,mBAAmB,EACpB,MAAM,WAAW,CAAC;AAGnB,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAGrC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAG9C,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAGrD,OAAO,EAAE,uBAAuB,EAAE,MAAM,UAAU,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,2 @@
1
+ // Enums
2
+ export { SystemState, BoostStrength } from './enums';
@@ -0,0 +1,33 @@
1
+ import { FilterProxy } from './filters';
2
+ import { BoostProxy } from './boost';
3
+ export interface CoverageSetup {
4
+ coverWholeQuery?: boolean;
5
+ coverWholeWords?: boolean;
6
+ coverFuzzyWords?: boolean;
7
+ coverJoinedWords?: boolean;
8
+ coverPrefixSuffix?: boolean;
9
+ truncate?: boolean;
10
+ includePatternMatches?: boolean;
11
+ minWordSize?: number;
12
+ levenshteinMaxWordSize?: number;
13
+ truncateWordHitLimit?: number;
14
+ truncateWordHitTolerance?: number;
15
+ truncationScore?: number;
16
+ }
17
+ export interface CloudQuery {
18
+ text?: string | null;
19
+ maxNumberOfRecordsToReturn?: number;
20
+ enableCoverage?: boolean;
21
+ coverageDepth?: number;
22
+ coverageSetup?: CoverageSetup | null;
23
+ enableFacets?: boolean;
24
+ enableBoost?: boolean;
25
+ removeDuplicates?: boolean;
26
+ sortAscending?: boolean;
27
+ sortBy?: string | null;
28
+ timeOutLimitMilliseconds?: number;
29
+ filter?: FilterProxy | null;
30
+ boosts?: BoostProxy[] | null;
31
+ logPrefix?: string | null;
32
+ }
33
+ //# sourceMappingURL=query.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"query.d.ts","sourceRoot":"","sources":["../src/query.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAErC,MAAM,WAAW,aAAa;IAC5B,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,UAAU;IACzB,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,0BAA0B,CAAC,EAAE,MAAM,CAAC;IACpC,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,aAAa,CAAC,EAAE,aAAa,GAAG,IAAI,CAAC;IACrC,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,MAAM,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IAC5B,MAAM,CAAC,EAAE,UAAU,EAAE,GAAG,IAAI,CAAC;IAC7B,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC3B"}
package/dist/query.js ADDED
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,15 @@
1
+ import { StringInt32KeyValuePair } from './common';
2
+ export interface ScoreEntry {
3
+ documentKey: number;
4
+ score: number;
5
+ }
6
+ export interface Result {
7
+ records?: ScoreEntry[] | null;
8
+ facets?: {
9
+ [key: string]: StringInt32KeyValuePair[];
10
+ } | null;
11
+ didTimeOut: boolean;
12
+ truncationIndex: number;
13
+ truncationScore: number;
14
+ }
15
+ //# sourceMappingURL=result.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"result.d.ts","sourceRoot":"","sources":["../src/result.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,UAAU,CAAC;AAEnD,MAAM,WAAW,UAAU;IACzB,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,MAAM;IACrB,OAAO,CAAC,EAAE,UAAU,EAAE,GAAG,IAAI,CAAC;IAC9B,MAAM,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,uBAAuB,EAAE,CAAA;KAAE,GAAG,IAAI,CAAC;IAC7D,UAAU,EAAE,OAAO,CAAC;IACpB,eAAe,EAAE,MAAM,CAAC;IACxB,eAAe,EAAE,MAAM,CAAC;CACzB"}
package/dist/result.js ADDED
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,31 @@
1
+ import { SystemState } from './enums';
2
+ export interface LicenseInfo {
3
+ licensed: boolean;
4
+ validLicense: boolean;
5
+ documentLimit: number;
6
+ documentLimitExceeded: boolean;
7
+ expirationDate: string;
8
+ licensedTo?: string | null;
9
+ type?: string | null;
10
+ description?: string | null;
11
+ licenseFileName?: string | null;
12
+ }
13
+ export interface SystemStatus {
14
+ systemState: SystemState;
15
+ documentCount: number;
16
+ searchCounter: number;
17
+ secondsToIndex: number;
18
+ invalidDataSetName: boolean;
19
+ invalidState: boolean;
20
+ invalidArgument: boolean;
21
+ reIndexRequired: boolean;
22
+ tooLongClientText: boolean;
23
+ tooLongSearchText: boolean;
24
+ unknownConfigurationError: boolean;
25
+ licenseInfo: LicenseInfo;
26
+ errorMessage?: string | null;
27
+ version?: string | null;
28
+ timeOfInstanceCreation: string;
29
+ timeOfLastIndexBuild: string;
30
+ }
31
+ //# sourceMappingURL=status.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"status.d.ts","sourceRoot":"","sources":["../src/status.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAEtC,MAAM,WAAW,WAAW;IAC1B,QAAQ,EAAE,OAAO,CAAC;IAClB,YAAY,EAAE,OAAO,CAAC;IACtB,aAAa,EAAE,MAAM,CAAC;IACtB,qBAAqB,EAAE,OAAO,CAAC;IAC/B,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACjC;AAED,MAAM,WAAW,YAAY;IAC3B,WAAW,EAAE,WAAW,CAAC;IACzB,aAAa,EAAE,MAAM,CAAC;IACtB,aAAa,EAAE,MAAM,CAAC;IACtB,cAAc,EAAE,MAAM,CAAC;IACvB,kBAAkB,EAAE,OAAO,CAAC;IAC5B,YAAY,EAAE,OAAO,CAAC;IACtB,eAAe,EAAE,OAAO,CAAC;IACzB,eAAe,EAAE,OAAO,CAAC;IACzB,iBAAiB,EAAE,OAAO,CAAC;IAC3B,iBAAiB,EAAE,OAAO,CAAC;IAC3B,yBAAyB,EAAE,OAAO,CAAC;IACnC,WAAW,EAAE,WAAW,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,sBAAsB,EAAE,MAAM,CAAC;IAC/B,oBAAoB,EAAE,MAAM,CAAC;CAC9B"}
package/dist/status.js ADDED
@@ -0,0 +1 @@
1
+ export {};
package/package.json ADDED
@@ -0,0 +1,49 @@
1
+ {
2
+ "name": "@indxsearch/indx-types",
3
+ "version": "1.0.0",
4
+ "description": "TypeScript type definitions for IndxCloudApi v1.0.2. Provides complete types for search queries, filters, boosts, results, and system status based on the official Swagger specification.",
5
+ "keywords": [
6
+ "indx",
7
+ "typescript",
8
+ "types",
9
+ "type-definitions",
10
+ "api",
11
+ "search",
12
+ "cloud-api",
13
+ "swagger"
14
+ ],
15
+ "author": "Indx Search",
16
+ "license": "Apache-2.0",
17
+ "repository": {
18
+ "type": "git",
19
+ "url": "https://github.com/indxSearch/indx-intrface.git",
20
+ "directory": "packages/indx-types"
21
+ },
22
+ "type": "module",
23
+ "main": "./dist/index.js",
24
+ "module": "./dist/index.js",
25
+ "types": "./dist/index.d.ts",
26
+ "files": [
27
+ "dist",
28
+ "README.md",
29
+ "LICENSE",
30
+ "CHANGELOG.md"
31
+ ],
32
+ "scripts": {
33
+ "build": "tsc",
34
+ "dev": "tsc --watch"
35
+ },
36
+ "devDependencies": {
37
+ "typescript": "^5.8.3"
38
+ },
39
+ "exports": {
40
+ ".": {
41
+ "types": "./dist/index.d.ts",
42
+ "import": "./dist/index.js",
43
+ "require": "./dist/index.js"
44
+ }
45
+ },
46
+ "publishConfig": {
47
+ "access": "public"
48
+ }
49
+ }