oneentry 1.0.159 → 1.0.161

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.
Files changed (222) hide show
  1. package/README.md +2 -0
  2. package/changelog.md +56 -1
  3. package/dist/admins/adminsApi.d.ts +15 -1
  4. package/dist/admins/adminsApi.js +29 -0
  5. package/dist/admins/adminsInterfaces.d.ts +37 -1
  6. package/dist/base/lazySchema.d.ts +15 -0
  7. package/dist/base/lazySchema.js +20 -0
  8. package/dist/discounts/discountsApi.d.ts +14 -1
  9. package/dist/discounts/discountsApi.js +21 -0
  10. package/dist/discounts/discountsInterfaces.d.ts +27 -1
  11. package/dist/filters/filtersInterfaces.d.ts +2 -2
  12. package/dist/filters/filtersSchemas.d.ts +1 -1
  13. package/dist/filters/filtersSchemas.js +4 -1
  14. package/dist/forms-data/formsDataApi.d.ts +14 -1
  15. package/dist/forms-data/formsDataApi.js +21 -0
  16. package/dist/forms-data/formsDataInterfaces.d.ts +74 -1
  17. package/dist/index.d.ts +4 -0
  18. package/dist/index.js +3 -0
  19. package/dist/orders/ordersApi.d.ts +15 -1
  20. package/dist/orders/ordersApi.js +22 -0
  21. package/dist/orders/ordersInterfaces.d.ts +27 -1
  22. package/dist/pages/pagesApi.d.ts +14 -1
  23. package/dist/pages/pagesApi.js +21 -0
  24. package/dist/pages/pagesInterfaces.d.ts +38 -1
  25. package/dist/payments/paymentsInterfaces.d.ts +2 -2
  26. package/dist/products/productsInterfaces.d.ts +1 -1
  27. package/dist/search/searchApi.d.ts +35 -0
  28. package/dist/search/searchApi.js +86 -0
  29. package/dist/search/searchInterfaces.d.ts +94 -0
  30. package/dist/search/searchInterfaces.js +2 -0
  31. package/dist/search/searchSchemas.d.ts +73 -0
  32. package/dist/search/searchSchemas.js +44 -0
  33. package/dist/templates-preview/templatesPreviewInterfaces.d.ts +0 -2
  34. package/dist/templates-preview/templatesPreviewSchemas.d.ts +0 -2
  35. package/dist/templates-preview/templatesPreviewSchemas.js +0 -1
  36. package/dist/types.d.ts +35 -0
  37. package/dist/types.js +2 -0
  38. package/dist/users/usersApi.d.ts +15 -1
  39. package/dist/users/usersApi.js +22 -0
  40. package/dist/users/usersInterfaces.d.ts +39 -1
  41. package/dist/web-socket/lazySocket.d.ts +18 -0
  42. package/dist/web-socket/lazySocket.js +70 -0
  43. package/esm/admins/adminsApi.d.ts +66 -0
  44. package/esm/admins/adminsApi.js +90 -0
  45. package/esm/admins/adminsInterfaces.d.ts +137 -0
  46. package/esm/admins/adminsInterfaces.js +1 -0
  47. package/esm/admins/adminsSchemas.d.ts +48 -0
  48. package/esm/admins/adminsSchemas.js +31 -0
  49. package/esm/attribute-sets/attributeSetsApi.d.ts +67 -0
  50. package/esm/attribute-sets/attributeSetsApi.js +97 -0
  51. package/esm/attribute-sets/attributeSetsInterfaces.d.ts +285 -0
  52. package/esm/attribute-sets/attributeSetsInterfaces.js +1 -0
  53. package/esm/attribute-sets/attributeSetsSchemas.d.ts +84 -0
  54. package/esm/attribute-sets/attributeSetsSchemas.js +66 -0
  55. package/esm/auth-provider/authProviderApi.d.ts +262 -0
  56. package/esm/auth-provider/authProviderApi.js +362 -0
  57. package/esm/auth-provider/authProviderSchemas.d.ts +124 -0
  58. package/esm/auth-provider/authProviderSchemas.js +92 -0
  59. package/esm/auth-provider/authProvidersInterfaces.d.ts +430 -0
  60. package/esm/auth-provider/authProvidersInterfaces.js +1 -0
  61. package/esm/base/asyncModules.d.ts +123 -0
  62. package/esm/base/asyncModules.js +382 -0
  63. package/esm/base/lazySchema.d.ts +15 -0
  64. package/esm/base/lazySchema.js +17 -0
  65. package/esm/base/stateModule.d.ts +35 -0
  66. package/esm/base/stateModule.js +51 -0
  67. package/esm/base/syncModules.d.ts +245 -0
  68. package/esm/base/syncModules.js +555 -0
  69. package/esm/base/timeIntervals.d.ts +95 -0
  70. package/esm/base/timeIntervals.js +317 -0
  71. package/esm/base/utils.d.ts +354 -0
  72. package/esm/base/utils.js +1 -0
  73. package/esm/base/validation.d.ts +98 -0
  74. package/esm/base/validation.js +118 -0
  75. package/esm/blocks/blocksApi.d.ts +252 -0
  76. package/esm/blocks/blocksApi.js +394 -0
  77. package/esm/blocks/blocksInterfaces.d.ts +361 -0
  78. package/esm/blocks/blocksInterfaces.js +1 -0
  79. package/esm/blocks/blocksSchemas.d.ts +213 -0
  80. package/esm/blocks/blocksSchemas.js +40 -0
  81. package/esm/discounts/discountsApi.d.ts +94 -0
  82. package/esm/discounts/discountsApi.js +136 -0
  83. package/esm/discounts/discountsInterfaces.d.ts +293 -0
  84. package/esm/discounts/discountsInterfaces.js +1 -0
  85. package/esm/events/eventsApi.d.ts +108 -0
  86. package/esm/events/eventsApi.js +141 -0
  87. package/esm/events/eventsInterfaces.d.ts +176 -0
  88. package/esm/events/eventsInterfaces.js +1 -0
  89. package/esm/file-uploading/fileUploadingApi.d.ts +91 -0
  90. package/esm/file-uploading/fileUploadingApi.js +127 -0
  91. package/esm/file-uploading/fileUploadingInterfaces.d.ts +116 -0
  92. package/esm/file-uploading/fileUploadingInterfaces.js +1 -0
  93. package/esm/file-uploading/fileUploadingSchemas.d.ts +24 -0
  94. package/esm/file-uploading/fileUploadingSchemas.js +19 -0
  95. package/esm/filters/filtersApi.d.ts +32 -0
  96. package/esm/filters/filtersApi.js +36 -0
  97. package/esm/filters/filtersInterfaces.d.ts +56 -0
  98. package/esm/filters/filtersInterfaces.js +1 -0
  99. package/esm/filters/filtersSchemas.d.ts +32 -0
  100. package/esm/filters/filtersSchemas.js +29 -0
  101. package/esm/forms/formsApi.d.ts +44 -0
  102. package/esm/forms/formsApi.js +54 -0
  103. package/esm/forms/formsInterfaces.d.ts +237 -0
  104. package/esm/forms/formsInterfaces.js +1 -0
  105. package/esm/forms/formsSchemas.d.ts +56 -0
  106. package/esm/forms/formsSchemas.js +32 -0
  107. package/esm/forms-data/formsDataApi.d.ts +124 -0
  108. package/esm/forms-data/formsDataApi.js +210 -0
  109. package/esm/forms-data/formsDataInterfaces.d.ts +670 -0
  110. package/esm/forms-data/formsDataInterfaces.js +1 -0
  111. package/esm/forms-data/formsDataSchemas.d.ts +107 -0
  112. package/esm/forms-data/formsDataSchemas.js +83 -0
  113. package/esm/general-types/generalTypesApi.d.ts +29 -0
  114. package/esm/general-types/generalTypesApi.js +34 -0
  115. package/esm/general-types/generalTypesInterfaces.d.ts +29 -0
  116. package/esm/general-types/generalTypesInterfaces.js +1 -0
  117. package/esm/general-types/generalTypesSchemas.d.ts +68 -0
  118. package/esm/general-types/generalTypesSchemas.js +42 -0
  119. package/esm/index.d.ts +143 -0
  120. package/esm/index.js +124 -0
  121. package/esm/integration-collections/integrationCollectionsApi.d.ts +172 -0
  122. package/esm/integration-collections/integrationCollectionsApi.js +224 -0
  123. package/esm/integration-collections/integrationCollectionsInterfaces.d.ts +317 -0
  124. package/esm/integration-collections/integrationCollectionsInterfaces.js +1 -0
  125. package/esm/integration-collections/integrationCollectionsSchemas.d.ts +84 -0
  126. package/esm/integration-collections/integrationCollectionsSchemas.js +60 -0
  127. package/esm/locales/localesApi.d.ts +28 -0
  128. package/esm/locales/localesApi.js +33 -0
  129. package/esm/locales/localesInterfaces.d.ts +40 -0
  130. package/esm/locales/localesInterfaces.js +1 -0
  131. package/esm/locales/localesSchemas.d.ts +32 -0
  132. package/esm/locales/localesSchemas.js +23 -0
  133. package/esm/menus/menusApi.d.ts +30 -0
  134. package/esm/menus/menusApi.js +35 -0
  135. package/esm/menus/menusInterfaces.d.ts +87 -0
  136. package/esm/menus/menusInterfaces.js +2 -0
  137. package/esm/menus/menusSchemas.d.ts +16 -0
  138. package/esm/menus/menusSchemas.js +25 -0
  139. package/esm/orders/ordersApi.d.ts +213 -0
  140. package/esm/orders/ordersApi.js +288 -0
  141. package/esm/orders/ordersInterfaces.d.ts +763 -0
  142. package/esm/orders/ordersInterfaces.js +1 -0
  143. package/esm/orders/ordersSchemas.d.ts +312 -0
  144. package/esm/orders/ordersSchemas.js +171 -0
  145. package/esm/package.json +4 -0
  146. package/esm/pages/pagesApi.d.ts +173 -0
  147. package/esm/pages/pagesApi.js +414 -0
  148. package/esm/pages/pagesInterfaces.d.ts +344 -0
  149. package/esm/pages/pagesInterfaces.js +1 -0
  150. package/esm/pages/pagesSchemas.d.ts +121 -0
  151. package/esm/pages/pagesSchemas.js +60 -0
  152. package/esm/payments/paymentsApi.d.ts +88 -0
  153. package/esm/payments/paymentsApi.js +122 -0
  154. package/esm/payments/paymentsInterfaces.d.ts +189 -0
  155. package/esm/payments/paymentsInterfaces.js +1 -0
  156. package/esm/payments/paymentsSchemas.d.ts +94 -0
  157. package/esm/payments/paymentsSchemas.js +53 -0
  158. package/esm/product-statuses/productStatusesApi.d.ts +50 -0
  159. package/esm/product-statuses/productStatusesApi.js +68 -0
  160. package/esm/product-statuses/productStatusesInterfaces.d.ts +62 -0
  161. package/esm/product-statuses/productStatusesInterfaces.js +1 -0
  162. package/esm/product-statuses/productStatusesSchemas.d.ts +34 -0
  163. package/esm/product-statuses/productStatusesSchemas.js +27 -0
  164. package/esm/products/productsApi.d.ts +366 -0
  165. package/esm/products/productsApi.js +468 -0
  166. package/esm/products/productsInterfaces.d.ts +723 -0
  167. package/esm/products/productsInterfaces.js +1 -0
  168. package/esm/products/productsSchemas.d.ts +234 -0
  169. package/esm/products/productsSchemas.js +121 -0
  170. package/esm/search/searchApi.d.ts +35 -0
  171. package/esm/search/searchApi.js +47 -0
  172. package/esm/search/searchInterfaces.d.ts +94 -0
  173. package/esm/search/searchInterfaces.js +1 -0
  174. package/esm/search/searchSchemas.d.ts +73 -0
  175. package/esm/search/searchSchemas.js +41 -0
  176. package/esm/sitemap/sitemapApi.d.ts +37 -0
  177. package/esm/sitemap/sitemapApi.js +41 -0
  178. package/esm/sitemap/sitemapInterfaces.d.ts +51 -0
  179. package/esm/sitemap/sitemapInterfaces.js +1 -0
  180. package/esm/subscriptions/subscriptionsApi.d.ts +74 -0
  181. package/esm/subscriptions/subscriptionsApi.js +90 -0
  182. package/esm/subscriptions/subscriptionsInterfaces.d.ts +111 -0
  183. package/esm/subscriptions/subscriptionsInterfaces.js +1 -0
  184. package/esm/subscriptions/subscriptionsSchemas.d.ts +46 -0
  185. package/esm/subscriptions/subscriptionsSchemas.js +38 -0
  186. package/esm/system/systemApi.d.ts +46 -0
  187. package/esm/system/systemApi.js +53 -0
  188. package/esm/system/systemInterfaces.d.ts +29 -0
  189. package/esm/system/systemInterfaces.js +1 -0
  190. package/esm/templates/templatesApi.d.ts +53 -0
  191. package/esm/templates/templatesApi.js +78 -0
  192. package/esm/templates/templatesInterfaces.d.ts +68 -0
  193. package/esm/templates/templatesInterfaces.js +1 -0
  194. package/esm/templates/templatesSchemas.d.ts +48 -0
  195. package/esm/templates/templatesSchemas.js +28 -0
  196. package/esm/templates-preview/templatesPreviewApi.d.ts +40 -0
  197. package/esm/templates-preview/templatesPreviewApi.js +50 -0
  198. package/esm/templates-preview/templatesPreviewInterfaces.d.ts +129 -0
  199. package/esm/templates-preview/templatesPreviewInterfaces.js +1 -0
  200. package/esm/templates-preview/templatesPreviewSchemas.d.ts +79 -0
  201. package/esm/templates-preview/templatesPreviewSchemas.js +43 -0
  202. package/esm/types.d.ts +35 -0
  203. package/esm/types.js +1 -0
  204. package/esm/user-activity/userActivityApi.d.ts +31 -0
  205. package/esm/user-activity/userActivityApi.js +37 -0
  206. package/esm/user-activity/userActivityInterfaces.d.ts +42 -0
  207. package/esm/user-activity/userActivityInterfaces.js +1 -0
  208. package/esm/users/usersApi.d.ts +249 -0
  209. package/esm/users/usersApi.js +312 -0
  210. package/esm/users/usersInterfaces.d.ts +419 -0
  211. package/esm/users/usersInterfaces.js +1 -0
  212. package/esm/users/usersSchemas.d.ts +72 -0
  213. package/esm/users/usersSchemas.js +55 -0
  214. package/esm/web-socket/lazySocket.d.ts +18 -0
  215. package/esm/web-socket/lazySocket.js +67 -0
  216. package/esm/web-socket/wsApi.d.ts +27 -0
  217. package/esm/web-socket/wsApi.js +43 -0
  218. package/esm/web-socket/wsInterfaces.d.ts +16 -0
  219. package/esm/web-socket/wsInterfaces.js +1 -0
  220. package/package.json +47 -2
  221. package/types.d.ts +1 -0
  222. package/types.js +1 -0
@@ -158,6 +158,32 @@ interface IOrdersApi {
158
158
  * @throws {IError} When isShell=false and an error occurs during the fetch
159
159
  */
160
160
  cancelRefundRequest(id: number): Promise<boolean | IError>;
161
+ /**
162
+ * Semantic (vector) search for the current user's orders.
163
+ * @handleName getOrdersByVectorSearch
164
+ * @param {IOrdersVectorSearch} body - Vector search body. Example: `{ queryText: "winter jacket" }`.
165
+ * @param {string} [langCode] - Language code. Default: "en_US".
166
+ * @param {number} [offset] - Parameter for pagination. Default: 0.
167
+ * @param {number} [limit] - Parameter for pagination. Default: 30.
168
+ * @returns {Promise<IOrdersByMarkerEntity | IError>} Returns an object with an array of found orders and total count.
169
+ * @throws {IError} When isShell=false and an error occurs during the fetch
170
+ */
171
+ getOrdersByVectorSearch(body: IOrdersVectorSearch, langCode?: string, offset?: number, limit?: number): Promise<IOrdersByMarkerEntity | IError>;
172
+ }
173
+ /**
174
+ * Body for semantic (vector) order search.
175
+ * @interface IOrdersVectorSearch
176
+ * @property {string} queryText - Natural-language search query. Example: "winter jacket".
177
+ * @property {number} [vectorDistanceThreshold] - Override of the cosine distance threshold (0..2). Example: 0.3.
178
+ * @property {number} [maxHits] - Top-K candidates fetched before pagination. Default: 100. Max: 500. Example: 10.
179
+ * @property {boolean} [debug] - When true, each returned item gets a `distance` field. Example: false.
180
+ * @description Body for the orders vector/search endpoint.
181
+ */
182
+ interface IOrdersVectorSearch {
183
+ queryText: string;
184
+ vectorDistanceThreshold?: number;
185
+ maxHits?: number;
186
+ debug?: boolean;
161
187
  }
162
188
  /**
163
189
  * Interface for the orders storage object.
@@ -734,4 +760,4 @@ interface ICreateRefundRequest {
734
760
  products: Record<string, IRefundProduct>;
735
761
  note?: string;
736
762
  }
737
- export type { IBaseOrdersEntity, IBaseOrdersEntityResponse, ICreateOrderPreview, ICreateRefundRequest, IOrderByMarkerEntity, IOrderData, IOrderDiscountBonus, IOrderDiscountConfig, IOrderDiscountSettings, IOrderPreviewItem, IOrderPreviewResponse, IOrderProductData, IOrderProducts, IOrdersApi, IOrdersByMarkerEntity, IOrdersEntity, IOrdersFormData, IOrderSplit, IOrderSplitStage, IOrderStatus, IPaymentAccountIdentifiers, IPicture, IPreviewOrderProduct, IRefundProduct, IRefundRequest, };
763
+ export type { IBaseOrdersEntity, IBaseOrdersEntityResponse, ICreateOrderPreview, ICreateRefundRequest, IOrderByMarkerEntity, IOrderData, IOrderDiscountBonus, IOrderDiscountConfig, IOrderDiscountSettings, IOrderPreviewItem, IOrderPreviewResponse, IOrderProductData, IOrderProducts, IOrdersApi, IOrdersByMarkerEntity, IOrdersEntity, IOrdersFormData, IOrderSplit, IOrderSplitStage, IOrderStatus, IOrdersVectorSearch, IPaymentAccountIdentifiers, IPicture, IPreviewOrderProduct, IRefundProduct, IRefundRequest, };
@@ -1,7 +1,7 @@
1
1
  import AsyncModules from '../base/asyncModules';
2
2
  import type StateModule from '../base/stateModule';
3
3
  import type { IError } from '../base/utils';
4
- import type { IPageConfig, IPagesApi, IPageSearchResult, IPagesEntity, IPositionBlock } from './pagesInterfaces';
4
+ import type { IPageConfig, IPagesApi, IPageSearchResult, IPagesEntity, IPagesResponse, IPagesVectorSearch, IPositionBlock } from './pagesInterfaces';
5
5
  /**
6
6
  * Controllers for working with page objects, including catalog pages
7
7
  * @handle /api/content/pages
@@ -102,6 +102,19 @@ export default class PagesApi extends AsyncModules implements IPagesApi {
102
102
  * @see {@link https://js-sdk.oneentry.cloud/docs/pages/searchPage searchPage} documentation.
103
103
  */
104
104
  searchPage(name: string, url?: string, langCode?: string): Promise<IPagesEntity[] | IPageSearchResult[] | IError>;
105
+ /**
106
+ * Semantic (vector) search for pages.
107
+ * @handleName getPagesByVectorSearch
108
+ * @param {IPagesVectorSearch} body - Vector search body. Example: `{ queryText: "winter sale" }`.
109
+ * @param {string} [langCode] - Language code. Default: "en_US".
110
+ * @param {number} [offset] - Parameter for pagination. Default: 0.
111
+ * @param {number} [limit] - Parameter for pagination. Default: 30.
112
+ * @returns {Promise<IPagesResponse | IError>} Returns an object with an array of found pages and total count.
113
+ * @throws {IError} When isShell=false and an error occurs during the fetch
114
+ * @description This method performs a semantic (vector) search for pages.
115
+ * @see {@link https://js-sdk.oneentry.cloud/docs/pages/getPagesByVectorSearch getPagesByVectorSearch} documentation.
116
+ */
117
+ getPagesByVectorSearch(body: IPagesVectorSearch, langCode?: string, offset?: number, limit?: number): Promise<IPagesResponse | IError>;
105
118
  /**
106
119
  * Add template data to pages
107
120
  * @handleName addTemplateToPages
@@ -267,6 +267,27 @@ class PagesApi extends asyncModules_1.default {
267
267
  // short cards carry no templateIdentifier, so there is nothing to attach a template to
268
268
  return this._normalizeData(data, langCode);
269
269
  }
270
+ /**
271
+ * Semantic (vector) search for pages.
272
+ * @handleName getPagesByVectorSearch
273
+ * @param {IPagesVectorSearch} body - Vector search body. Example: `{ queryText: "winter sale" }`.
274
+ * @param {string} [langCode] - Language code. Default: "en_US".
275
+ * @param {number} [offset] - Parameter for pagination. Default: 0.
276
+ * @param {number} [limit] - Parameter for pagination. Default: 30.
277
+ * @returns {Promise<IPagesResponse | IError>} Returns an object with an array of found pages and total count.
278
+ * @throws {IError} When isShell=false and an error occurs during the fetch
279
+ * @description This method performs a semantic (vector) search for pages.
280
+ * @see {@link https://js-sdk.oneentry.cloud/docs/pages/getPagesByVectorSearch getPagesByVectorSearch} documentation.
281
+ */
282
+ async getPagesByVectorSearch(body, langCode = this.state.lang, offset = 0, limit = 30) {
283
+ const query = {
284
+ langCode,
285
+ offset,
286
+ limit,
287
+ };
288
+ const result = await this._fetchPost(`/vector/search?` + this._queryParamsToString(query), body);
289
+ return this._normalizeData(result, langCode);
290
+ }
270
291
  /**
271
292
  * Add template data to pages
272
293
  * @handleName addTemplateToPages
@@ -86,6 +86,43 @@ interface IPagesApi {
86
86
  * @description This method performs a quick search for page objects with limited output. With traficLimit enabled the raw quick search response is returned as short cards; otherwise full page entities are fetched for the found ids.
87
87
  */
88
88
  searchPage(name: string, url?: string, langCode?: LangType): Promise<IPagesEntity[] | IPageSearchResult[] | IError>;
89
+ /**
90
+ * Semantic (vector) search for pages.
91
+ * @handleName getPagesByVectorSearch
92
+ * @param {IPagesVectorSearch} body - Vector search body. Example: `{ queryText: "winter sale" }`.
93
+ * @param {string} [langCode] - Language code. Default: "en_US".
94
+ * @param {number} [offset] - Parameter for pagination. Default: 0.
95
+ * @param {number} [limit] - Parameter for pagination. Default: 30.
96
+ * @returns {IPagesResponse} A promise that resolves to a pages response (items + total) or an error.
97
+ * @throws {IError} - If there is an error during the fetch operation, it will return an error object.
98
+ * @description This method performs a semantic (vector) search for pages.
99
+ */
100
+ getPagesByVectorSearch(body: IPagesVectorSearch, langCode?: string, offset?: number, limit?: number): Promise<IPagesResponse | IError>;
101
+ }
102
+ /**
103
+ * Body for semantic (vector) page search.
104
+ * @interface IPagesVectorSearch
105
+ * @property {string} queryText - Natural-language search query. Example: "winter sale".
106
+ * @property {number} [vectorDistanceThreshold] - Override of the cosine distance threshold (0..2). Example: 0.3.
107
+ * @property {number} [maxHits] - Top-K candidates fetched before pagination. Default: 100. Max: 500. Example: 10.
108
+ * @property {boolean} [debug] - When true, each returned item gets a `distance` field. Example: false.
109
+ * @description Body for the pages vector/search endpoint.
110
+ */
111
+ interface IPagesVectorSearch {
112
+ queryText: string;
113
+ vectorDistanceThreshold?: number;
114
+ maxHits?: number;
115
+ debug?: boolean;
116
+ }
117
+ /**
118
+ * @interface IPagesResponse
119
+ * @property {IPagesEntity[]} items - Array of found page objects.
120
+ * @property {number} total - Total number of found records. Example: 100.
121
+ * @description This interface defines the structure of a response containing multiple page entities, including the total count and an array of page items.
122
+ */
123
+ interface IPagesResponse {
124
+ items: IPagesEntity[];
125
+ total: number;
89
126
  }
90
127
  /**
91
128
  * @interface IPageConfig
@@ -304,4 +341,4 @@ interface IPageSearchResult {
304
341
  id: number;
305
342
  title: string;
306
343
  }
307
- export type { IPageConfig, IPagesApi, IPageSearchResult, IPagesEntity, IPositionBlock, IPositionForm, PageType, };
344
+ export type { IPageConfig, IPagesApi, IPageSearchResult, IPagesEntity, IPagesResponse, IPagesVectorSearch, IPositionBlock, IPositionForm, PageType, };
@@ -131,7 +131,7 @@ interface IIntent {
131
131
  * @property {number} id - Object identifier. Example: 12345.
132
132
  * @property {ILocalizeInfo} localizeInfos - Json description of the payment account object.
133
133
  * @property {string} identifier - Text identifier for the recording field. Example: "payment_12345".
134
- * @property {'stripe' | 'custom'} type - Type may be 'stripe' or 'custom'. Example: 'stripe'.
134
+ * @property {'stripe' | 'yookassa' | 'midtrans' | 'xendit' | 'custom'} type - Payment provider type. Example: 'stripe'.
135
135
  * @property {boolean} isVisible - Visibility indicator of the payment account. Example: true.
136
136
  * @property {boolean} isUsed - Usage indicator of the payment account. Example: false.
137
137
  * @property {boolean} testMode - Indicates whether the payment account is in test mode. Example: true.
@@ -144,7 +144,7 @@ interface IAccountsEntity {
144
144
  id: number;
145
145
  localizeInfos: ILocalizeInfo;
146
146
  identifier: string;
147
- type: 'stripe' | 'custom';
147
+ type: 'stripe' | 'yookassa' | 'midtrans' | 'xendit' | 'custom';
148
148
  isVisible: boolean;
149
149
  isUsed: boolean;
150
150
  testMode: boolean;
@@ -377,7 +377,7 @@ type IProductsQuery = IProductsQueryBase;
377
377
  */
378
378
  interface IFilterParams {
379
379
  attributeMarker: string;
380
- conditionMarker?: 'in' /** 'in' - Contains */ | 'nin' /** 'nin' - Does not contain */ | 'eq' /** 'eq' - Equal */ | 'neq' /** 'neq' - Not equal */ | 'mth' /** 'mth' - Greater than */ | 'lth' /** 'lth' - Less than */ | 'exs' /** 'exs' - Exists */ | 'nexs' /** 'nexs' - Does not exist */ | null;
380
+ conditionMarker?: 'in' /** 'in' - Contains */ | 'nin' /** 'nin' - Does not contain */ | 'eq' /** 'eq' - Equal */ | 'neq' /** 'neq' - Not equal */ | 'mth' /** 'mth' - Greater than */ | 'lth' /** 'lth' - Less than */ | 'exs' /** 'exs' - Exists */ | 'nexs' /** 'nexs' - Does not exist */ | 'pat' /** 'pat' - Matches pattern */ | 'same' /** 'same' - Matches the value exactly */ | 'same_part' /** 'same_part' - Matches a part of the value exactly */ | null;
381
381
  conditionValue: number | string | null;
382
382
  pageUrl?: string | null;
383
383
  pageUrls?: string[] | null;
@@ -0,0 +1,35 @@
1
+ import AsyncModules from '../base/asyncModules';
2
+ import type StateModule from '../base/stateModule';
3
+ import type { IError } from '../base/utils';
4
+ import type { IGlobalSearchResponse, ISearchApi, TGlobalSearchEntityType } from './searchInterfaces';
5
+ /**
6
+ * Controllers for the public cross-entity search.
7
+ * @handle /api/content/search
8
+ * @class SearchApi
9
+ * @augments AsyncModules
10
+ * @implements {ISearchApi}
11
+ * @description This class provides a public search over names and attribute values of visible records.
12
+ */
13
+ export default class SearchApi extends AsyncModules implements ISearchApi {
14
+ protected state: StateModule;
15
+ protected _url: string;
16
+ /**
17
+ * Constructor for SearchApi class.
18
+ * @param {StateModule} state - The state module.
19
+ */
20
+ constructor(state: StateModule);
21
+ /**
22
+ * Public search across titles and attribute values of visible records.
23
+ * @handleName globalSearch
24
+ * @param {string} query - Search query. Example: "winter".
25
+ * @param {TGlobalSearchEntityType[]} [types] - Entity types to search in, sent comma-separated. Searches every type when omitted.
26
+ * @param {'all' | 'visible' | 'hidden'} [visibility] - Visibility filter of the searched records. Default: "all".
27
+ * @param {number} [offset] - Drilldown mode offset. Pass it only together with a single accessible type in `types`.
28
+ * @param {number} [limit] - Drilldown mode page size. Pass it only together with a single accessible type in `types`, otherwise the API answers 400 "Drilldown mode (limit/offset) requires exactly one accessible type in `types`". Without it every group is returned in full.
29
+ * @returns {Promise<IGlobalSearchResponse | IError>} Returns the query and the found records grouped by entity type.
30
+ * @throws {IError} When isShell=false and an error occurs during the fetch
31
+ * @description Searches names and attribute values of visible records across entity types.
32
+ * @see {@link https://js-sdk.oneentry.cloud/docs/search/globalSearch globalSearch} documentation.
33
+ */
34
+ globalSearch(query: string, types?: TGlobalSearchEntityType[], visibility?: 'all' | 'visible' | 'hidden', offset?: number, limit?: number): Promise<IGlobalSearchResponse | IError>;
35
+ }
@@ -0,0 +1,86 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ var __importDefault = (this && this.__importDefault) || function (mod) {
36
+ return (mod && mod.__esModule) ? mod : { "default": mod };
37
+ };
38
+ Object.defineProperty(exports, "__esModule", { value: true });
39
+ const asyncModules_1 = __importDefault(require("../base/asyncModules"));
40
+ const lazySchema_1 = __importDefault(require("../base/lazySchema"));
41
+ const schema = (0, lazySchema_1.default)(() => Promise.resolve().then(() => __importStar(require('./searchSchemas'))));
42
+ /**
43
+ * Controllers for the public cross-entity search.
44
+ * @handle /api/content/search
45
+ * @class SearchApi
46
+ * @augments AsyncModules
47
+ * @implements {ISearchApi}
48
+ * @description This class provides a public search over names and attribute values of visible records.
49
+ */
50
+ class SearchApi extends asyncModules_1.default {
51
+ /**
52
+ * Constructor for SearchApi class.
53
+ * @param {StateModule} state - The state module.
54
+ */
55
+ constructor(state) {
56
+ super(state);
57
+ this._url = state.url + '/api/content/search';
58
+ }
59
+ /**
60
+ * Public search across titles and attribute values of visible records.
61
+ * @handleName globalSearch
62
+ * @param {string} query - Search query. Example: "winter".
63
+ * @param {TGlobalSearchEntityType[]} [types] - Entity types to search in, sent comma-separated. Searches every type when omitted.
64
+ * @param {'all' | 'visible' | 'hidden'} [visibility] - Visibility filter of the searched records. Default: "all".
65
+ * @param {number} [offset] - Drilldown mode offset. Pass it only together with a single accessible type in `types`.
66
+ * @param {number} [limit] - Drilldown mode page size. Pass it only together with a single accessible type in `types`, otherwise the API answers 400 "Drilldown mode (limit/offset) requires exactly one accessible type in `types`". Without it every group is returned in full.
67
+ * @returns {Promise<IGlobalSearchResponse | IError>} Returns the query and the found records grouped by entity type.
68
+ * @throws {IError} When isShell=false and an error occurs during the fetch
69
+ * @description Searches names and attribute values of visible records across entity types.
70
+ * @see {@link https://js-sdk.oneentry.cloud/docs/search/globalSearch globalSearch} documentation.
71
+ */
72
+ async globalSearch(query, types, visibility, offset, limit) {
73
+ // `types` is sent comma-separated — the array stringifies to exactly that.
74
+ const params = {
75
+ q: query,
76
+ types,
77
+ visibility,
78
+ offset,
79
+ limit,
80
+ };
81
+ const data = await this._fetchGet(`?` + this._queryParamsToString(params));
82
+ const validated = await this._validateResponse(data, schema('GlobalSearchResponseSchema'));
83
+ return this._normalizeData(validated);
84
+ }
85
+ }
86
+ exports.default = SearchApi;
@@ -0,0 +1,94 @@
1
+ import type { IError } from '../base/utils';
2
+ /**
3
+ * Interface for the Search API module.
4
+ * @interface ISearchApi
5
+ * @description This interface defines methods for the public cross-entity search.
6
+ */
7
+ interface ISearchApi {
8
+ /**
9
+ * Public search across titles and attribute values of visible records.
10
+ * @handleName globalSearch
11
+ * @param {string} query - Search query. Example: "winter".
12
+ * @param {TGlobalSearchEntityType[]} [types] - Entity types to search in, sent comma-separated. Searches every type when omitted.
13
+ * @param {'all' | 'visible' | 'hidden'} [visibility] - Visibility filter of the searched records. Default: "all".
14
+ * @param {number} [offset] - Drilldown mode offset. Pass it only together with a single accessible type in `types`.
15
+ * @param {number} [limit] - Drilldown mode page size. Pass it only together with a single accessible type in `types`, otherwise the API answers 400 "Drilldown mode (limit/offset) requires exactly one accessible type in `types`". Without it every group is returned in full.
16
+ * @returns {Promise<IGlobalSearchResponse | IError>} Returns the query and the found records grouped by entity type.
17
+ * @throws {IError} When isShell=false and an error occurs during the fetch
18
+ * @description Searches names and attribute values of visible records across entity types.
19
+ */
20
+ globalSearch(query: string, types?: TGlobalSearchEntityType[], visibility?: 'all' | 'visible' | 'hidden', offset?: number, limit?: number): Promise<IGlobalSearchResponse | IError>;
21
+ }
22
+ /**
23
+ * Entity type a global search group or item belongs to.
24
+ * @description Entity type a global search group or item belongs to.
25
+ */
26
+ type TGlobalSearchEntityType = 'products' | 'pages' | 'blocks' | 'slides' | 'templates' | 'discounts' | 'user_groups' | 'users' | 'admins' | 'menus' | 'forms' | 'attributes_sets' | 'attributes' | 'orders' | 'workflows' | 'events' | 'subscriptions' | 'collections';
27
+ /**
28
+ * How a global search item matched the query.
29
+ * @description Ranking kind of the match: exact value, title, attribute name or attribute value.
30
+ */
31
+ type TGlobalSearchMatchKind = 'exact' | 'title' | 'attributeName' | 'attributeValue';
32
+ /**
33
+ * Concrete field a global search item matched on.
34
+ * @description Field that produced the match; independent from the matchKind ranking.
35
+ */
36
+ type TGlobalSearchMatchedField = 'id' | 'title' | 'identifier' | 'url' | 'attributeName' | 'attributeValue' | 'importId' | 'nodeName';
37
+ /**
38
+ * A single record found by the global search.
39
+ * @interface IGlobalSearchItem
40
+ * @property {TGlobalSearchEntityType} type - Entity type of the found record. Example: "products".
41
+ * @property {number | string} id - Entity id; a string for workflows and attributes. Example: 12345.
42
+ * @property {string} [title] - Display title; absent when the record has no own name (orders, users without login). Example: "Winter jacket".
43
+ * @property {string} [identifier] - Machine identifier (marker) of the record. Example: "winter_jacket".
44
+ * @property {string} [subtitle] - Secondary line (url, storage, node). Example: "catalog/winter".
45
+ * @property {TGlobalSearchMatchKind} matchKind - How the record matched the query. Example: "title".
46
+ * @property {TGlobalSearchMatchedField} matchedField - Concrete field that matched the query. Example: "title".
47
+ * @property {Record<string, unknown>} [matchedAttribute] - Attribute the match occurred in.
48
+ * @property {string} [fragment] - Plain-text context around the match, no markup. Example: "warm winter jacket".
49
+ * @property {string} [langCode] - Language code of the matched value. Example: "en_US".
50
+ * @property {boolean} [isVisible] - Visibility of the found record. Example: true.
51
+ * @property {Record<string, unknown>} [parent] - Owning record for entities without their own page (slides to block, orders to storage).
52
+ * @property {number} [attributeSetId] - Owning attribute set id; only for type=attributes. Example: 12.
53
+ * @description A single record found by the global search, with the context of how it matched.
54
+ */
55
+ interface IGlobalSearchItem {
56
+ type: TGlobalSearchEntityType;
57
+ id: number | string;
58
+ title?: string;
59
+ identifier?: string;
60
+ subtitle?: string;
61
+ matchKind: TGlobalSearchMatchKind;
62
+ matchedField: TGlobalSearchMatchedField;
63
+ matchedAttribute?: Record<string, unknown>;
64
+ fragment?: string;
65
+ langCode?: string;
66
+ isVisible?: boolean;
67
+ parent?: Record<string, unknown>;
68
+ attributeSetId?: number;
69
+ }
70
+ /**
71
+ * Global search results of a single entity type.
72
+ * @interface IGlobalSearchGroup
73
+ * @property {TGlobalSearchEntityType} type - Entity type of the group. Example: "products".
74
+ * @property {IGlobalSearchItem[]} items - Records found within this entity type.
75
+ * @property {boolean} hasMore - Whether more records of this type are available beyond the requested page. Example: false.
76
+ * @description Global search results of a single entity type.
77
+ */
78
+ interface IGlobalSearchGroup {
79
+ type: TGlobalSearchEntityType;
80
+ items: IGlobalSearchItem[];
81
+ hasMore: boolean;
82
+ }
83
+ /**
84
+ * Response of the global search endpoint.
85
+ * @interface IGlobalSearchResponse
86
+ * @property {string} query - The query the results were produced for. Example: "winter".
87
+ * @property {IGlobalSearchGroup[]} groups - Found records grouped by entity type.
88
+ * @description Response of the global search endpoint: the query and the found records grouped by entity type.
89
+ */
90
+ interface IGlobalSearchResponse {
91
+ query: string;
92
+ groups: IGlobalSearchGroup[];
93
+ }
94
+ export type { IGlobalSearchGroup, IGlobalSearchItem, IGlobalSearchResponse, ISearchApi, TGlobalSearchEntityType, TGlobalSearchMatchedField, TGlobalSearchMatchKind, };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,73 @@
1
+ /**
2
+ * Validation schemas for Search module
3
+ * @description Zod schemas for validating search-related API responses (raw API data, before normalization)
4
+ */
5
+ import { z } from 'zod';
6
+ /**
7
+ * Global search item schema
8
+ * @description Schema for a single record found by the global search
9
+ */
10
+ export declare const GlobalSearchItemSchema: z.ZodObject<{
11
+ type: z.ZodString;
12
+ id: z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>;
13
+ title: z.ZodOptional<z.ZodString>;
14
+ identifier: z.ZodOptional<z.ZodString>;
15
+ subtitle: z.ZodOptional<z.ZodString>;
16
+ matchKind: z.ZodString;
17
+ matchedField: z.ZodString;
18
+ matchedAttribute: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
19
+ fragment: z.ZodOptional<z.ZodString>;
20
+ langCode: z.ZodOptional<z.ZodString>;
21
+ isVisible: z.ZodOptional<z.ZodBoolean>;
22
+ parent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
23
+ attributeSetId: z.ZodOptional<z.ZodNumber>;
24
+ }, z.core.$strip>;
25
+ /**
26
+ * Global search group schema
27
+ * @description Schema for the results of a single entity type
28
+ */
29
+ export declare const GlobalSearchGroupSchema: z.ZodObject<{
30
+ type: z.ZodString;
31
+ items: z.ZodArray<z.ZodObject<{
32
+ type: z.ZodString;
33
+ id: z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>;
34
+ title: z.ZodOptional<z.ZodString>;
35
+ identifier: z.ZodOptional<z.ZodString>;
36
+ subtitle: z.ZodOptional<z.ZodString>;
37
+ matchKind: z.ZodString;
38
+ matchedField: z.ZodString;
39
+ matchedAttribute: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
40
+ fragment: z.ZodOptional<z.ZodString>;
41
+ langCode: z.ZodOptional<z.ZodString>;
42
+ isVisible: z.ZodOptional<z.ZodBoolean>;
43
+ parent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
44
+ attributeSetId: z.ZodOptional<z.ZodNumber>;
45
+ }, z.core.$strip>>;
46
+ hasMore: z.ZodBoolean;
47
+ }, z.core.$strip>;
48
+ /**
49
+ * Global search response schema
50
+ * @description Schema for the response returned by globalSearch
51
+ */
52
+ export declare const GlobalSearchResponseSchema: z.ZodObject<{
53
+ query: z.ZodString;
54
+ groups: z.ZodArray<z.ZodObject<{
55
+ type: z.ZodString;
56
+ items: z.ZodArray<z.ZodObject<{
57
+ type: z.ZodString;
58
+ id: z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>;
59
+ title: z.ZodOptional<z.ZodString>;
60
+ identifier: z.ZodOptional<z.ZodString>;
61
+ subtitle: z.ZodOptional<z.ZodString>;
62
+ matchKind: z.ZodString;
63
+ matchedField: z.ZodString;
64
+ matchedAttribute: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
65
+ fragment: z.ZodOptional<z.ZodString>;
66
+ langCode: z.ZodOptional<z.ZodString>;
67
+ isVisible: z.ZodOptional<z.ZodBoolean>;
68
+ parent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
69
+ attributeSetId: z.ZodOptional<z.ZodNumber>;
70
+ }, z.core.$strip>>;
71
+ hasMore: z.ZodBoolean;
72
+ }, z.core.$strip>>;
73
+ }, z.core.$strip>;
@@ -0,0 +1,44 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GlobalSearchResponseSchema = exports.GlobalSearchGroupSchema = exports.GlobalSearchItemSchema = void 0;
4
+ /**
5
+ * Validation schemas for Search module
6
+ * @description Zod schemas for validating search-related API responses (raw API data, before normalization)
7
+ */
8
+ const zod_1 = require("zod");
9
+ /**
10
+ * Global search item schema
11
+ * @description Schema for a single record found by the global search
12
+ */
13
+ exports.GlobalSearchItemSchema = zod_1.z.object({
14
+ type: zod_1.z.string(),
15
+ id: zod_1.z.union([zod_1.z.number(), zod_1.z.string()]),
16
+ title: zod_1.z.string().optional(),
17
+ identifier: zod_1.z.string().optional(),
18
+ subtitle: zod_1.z.string().optional(),
19
+ matchKind: zod_1.z.string(),
20
+ matchedField: zod_1.z.string(),
21
+ matchedAttribute: zod_1.z.record(zod_1.z.string(), zod_1.z.unknown()).optional(),
22
+ fragment: zod_1.z.string().optional(),
23
+ langCode: zod_1.z.string().optional(),
24
+ isVisible: zod_1.z.boolean().optional(),
25
+ parent: zod_1.z.record(zod_1.z.string(), zod_1.z.unknown()).optional(),
26
+ attributeSetId: zod_1.z.number().optional(),
27
+ });
28
+ /**
29
+ * Global search group schema
30
+ * @description Schema for the results of a single entity type
31
+ */
32
+ exports.GlobalSearchGroupSchema = zod_1.z.object({
33
+ type: zod_1.z.string(),
34
+ items: zod_1.z.array(exports.GlobalSearchItemSchema),
35
+ hasMore: zod_1.z.boolean(),
36
+ });
37
+ /**
38
+ * Global search response schema
39
+ * @description Schema for the response returned by globalSearch
40
+ */
41
+ exports.GlobalSearchResponseSchema = zod_1.z.object({
42
+ query: zod_1.z.string(),
43
+ groups: zod_1.z.array(exports.GlobalSearchGroupSchema),
44
+ });
@@ -71,7 +71,6 @@ interface ITemplatesPreviewApi {
71
71
  * @property {number} version - The version number of the object. Example: 1.
72
72
  * @property {number} position - The position of the object. Example: 1.
73
73
  * @property {boolean} isUsed - Indicates whether the template preview is used. Example: true.
74
- * @property {string | null} [attributeSetIdentifier] - Text identifier used for a set of attributes. Example: "attribute_set_1".
75
74
  * @description This interface defines the structure of a template preview entity, including its identifiers, attributes, proportions, and title.
76
75
  */
77
76
  interface ITemplatesPreviewEntity {
@@ -82,7 +81,6 @@ interface ITemplatesPreviewEntity {
82
81
  version: number;
83
82
  position: number;
84
83
  isUsed: boolean;
85
- attributeSetIdentifier?: string | null;
86
84
  }
87
85
  /**
88
86
  * @interface ITemplatesPreviewProportions
@@ -47,7 +47,6 @@ export declare const TemplatePreviewEntitySchema: z.ZodObject<{
47
47
  version: z.ZodNumber;
48
48
  position: z.ZodNumber;
49
49
  isUsed: z.ZodBoolean;
50
- attributeSetIdentifier: z.ZodOptional<z.ZodNullable<z.ZodString>>;
51
50
  }, z.core.$strip>;
52
51
  /**
53
52
  * Template previews response schema (array of template previews)
@@ -77,5 +76,4 @@ export declare const TemplatePreviewsResponseSchema: z.ZodArray<z.ZodObject<{
77
76
  version: z.ZodNumber;
78
77
  position: z.ZodNumber;
79
78
  isUsed: z.ZodBoolean;
80
- attributeSetIdentifier: z.ZodOptional<z.ZodNullable<z.ZodString>>;
81
79
  }, z.core.$strip>>;
@@ -39,7 +39,6 @@ exports.TemplatePreviewEntitySchema = zod_1.z.object({
39
39
  version: zod_1.z.number(),
40
40
  position: zod_1.z.number(),
41
41
  isUsed: zod_1.z.boolean(),
42
- attributeSetIdentifier: zod_1.z.string().nullable().optional(),
43
42
  });
44
43
  /**
45
44
  * Template previews response schema (array of template previews)
@@ -0,0 +1,35 @@
1
+ /**
2
+ * OneEntry SDK public types.
3
+ * @description Aggregates every public interface and type of the SDK in a single entry point,
4
+ * so consumers can import them from 'oneentry' or 'oneentry/types' instead of deep paths
5
+ * like 'oneentry/dist/attribute-sets/attributeSetsInterfaces'.
6
+ */
7
+ export type * from './admins/adminsInterfaces';
8
+ export type * from './attribute-sets/attributeSetsInterfaces';
9
+ export type * from './auth-provider/authProvidersInterfaces';
10
+ export type * from './base/utils';
11
+ export type * from './blocks/blocksInterfaces';
12
+ export type * from './discounts/discountsInterfaces';
13
+ export type * from './events/eventsInterfaces';
14
+ export type * from './file-uploading/fileUploadingInterfaces';
15
+ export type * from './filters/filtersInterfaces';
16
+ export type * from './forms/formsInterfaces';
17
+ export type * from './forms-data/formsDataInterfaces';
18
+ export type * from './general-types/generalTypesInterfaces';
19
+ export type * from './integration-collections/integrationCollectionsInterfaces';
20
+ export type * from './locales/localesInterfaces';
21
+ export type * from './menus/menusInterfaces';
22
+ export type * from './orders/ordersInterfaces';
23
+ export type * from './pages/pagesInterfaces';
24
+ export type * from './payments/paymentsInterfaces';
25
+ export type * from './product-statuses/productStatusesInterfaces';
26
+ export type * from './products/productsInterfaces';
27
+ export type * from './search/searchInterfaces';
28
+ export type * from './sitemap/sitemapInterfaces';
29
+ export type * from './subscriptions/subscriptionsInterfaces';
30
+ export type * from './system/systemInterfaces';
31
+ export type * from './templates/templatesInterfaces';
32
+ export type * from './templates-preview/templatesPreviewInterfaces';
33
+ export type * from './user-activity/userActivityInterfaces';
34
+ export type * from './users/usersInterfaces';
35
+ export type * from './web-socket/wsInterfaces';
package/dist/types.js ADDED
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,7 +1,7 @@
1
1
  import AsyncModules from '../base/asyncModules';
2
2
  import type StateModule from '../base/stateModule';
3
3
  import type { IError } from '../base/utils';
4
- import type { ICartAddItem, ICartResponse, ICartSet, IUserBody, IUserEntity, IUsersApi, IWishlistAddItem, IWishlistResponse, IWishlistSet } from './usersInterfaces';
4
+ import type { ICartAddItem, ICartResponse, ICartSet, IUserBody, IUserEntity, IUsersApi, IUsersResponse, IUsersVectorSearch, IWishlistAddItem, IWishlistResponse, IWishlistSet } from './usersInterfaces';
5
5
  /**
6
6
  * Controllers for working with users
7
7
  * @handle /api/content/users
@@ -232,4 +232,18 @@ export default class UsersApi extends AsyncModules implements IUsersApi {
232
232
  * @see {@link https://js-sdk.oneentry.cloud/docs/users/removeWishlistItem removeWishlistItem} documentation.
233
233
  */
234
234
  removeWishlistItem(productId: number): Promise<IWishlistResponse | IError>;
235
+ /**
236
+ * Semantic (vector) search for users.
237
+ * @handleName getUsersByVectorSearch
238
+ * @param {IUsersVectorSearch} body - Vector search body. Example: `{ queryText: "john" }`.
239
+ * @param {string} [langCode] - Language code. Default: "en_US".
240
+ * @param {number} [offset] - Parameter for pagination. Default: 0.
241
+ * @param {number} [limit] - Parameter for pagination. Default: 30.
242
+ * @returns {Promise<IUsersResponse | IError>} Returns an object with an array of found users and total count.
243
+ * @throws {IError} When isShell=false and an error occurs during the fetch
244
+ * @description This method performs a semantic (vector) search for users. It requires user authorization.
245
+ * @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
246
+ * @see {@link https://js-sdk.oneentry.cloud/docs/users/getUsersByVectorSearch getUsersByVectorSearch} documentation.
247
+ */
248
+ getUsersByVectorSearch(body: IUsersVectorSearch, langCode?: string, offset?: number, limit?: number): Promise<IUsersResponse | IError>;
235
249
  }