@viu/emporix-sdk 2.16.0 → 2.19.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 +33 -0
- package/README.md +19 -0
- package/dist/availability.cjs.map +1 -1
- package/dist/availability.d.cts +94 -8
- package/dist/availability.d.ts +94 -8
- package/dist/availability.js +1 -1
- package/dist/category.cjs +28 -0
- package/dist/category.cjs.map +1 -1
- package/dist/category.d.cts +10 -0
- package/dist/category.d.ts +10 -0
- package/dist/category.js +2 -1
- package/dist/{chunk-62PCCHZ2.js → chunk-36T4YPQJ.js} +7 -2
- package/dist/chunk-36T4YPQJ.js.map +1 -0
- package/dist/{chunk-GIZS4BY3.js → chunk-6XND7SYV.js} +20 -2
- package/dist/chunk-6XND7SYV.js.map +1 -0
- package/dist/{chunk-5VTBLBXJ.js → chunk-FZMP5NQZ.js} +10 -4
- package/dist/chunk-FZMP5NQZ.js.map +1 -0
- package/dist/{chunk-K3VQLW3P.js → chunk-IVCCGJN5.js} +2 -2
- package/dist/chunk-IVCCGJN5.js.map +1 -0
- package/dist/chunk-S5HEIQDK.js +14 -0
- package/dist/chunk-S5HEIQDK.js.map +1 -0
- package/dist/index.cjs +89 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +216 -27
- package/dist/index.d.ts +216 -27
- package/dist/index.js +60 -14
- package/dist/index.js.map +1 -1
- package/dist/orders.cjs +14 -0
- package/dist/orders.cjs.map +1 -1
- package/dist/orders.d.cts +3 -0
- package/dist/orders.d.ts +3 -0
- package/dist/orders.js +2 -1
- package/dist/product.cjs +14 -2
- package/dist/product.cjs.map +1 -1
- package/dist/product.d.cts +7 -2
- package/dist/product.d.ts +7 -2
- package/dist/product.js +2 -1
- package/dist/query-mLQs2WFr.d.cts +28 -0
- package/dist/query-mLQs2WFr.d.ts +28 -0
- package/dist/segment.d.cts +1 -0
- package/dist/segment.d.ts +1 -0
- package/package.json +1 -1
- package/dist/chunk-5VTBLBXJ.js.map +0 -1
- package/dist/chunk-62PCCHZ2.js.map +0 -1
- package/dist/chunk-GIZS4BY3.js.map +0 -1
- package/dist/chunk-K3VQLW3P.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -27,6 +27,8 @@ import { OrdersService, SalesOrdersService } from './orders.js';
|
|
|
27
27
|
export { GetOrderOptions, ListMyOrdersOptions, Order, OrderEntry, OrderStatus, OrderTransitionOptions, SalesOrder, SalesOrderPatch, Transition, UpdateSalesOrderOptions } from './orders.js';
|
|
28
28
|
import { AvailabilityService } from './availability.js';
|
|
29
29
|
export { Availability, AvailabilityOptions } from './availability.js';
|
|
30
|
+
import { a as QueryFor } from './query-mLQs2WFr.js';
|
|
31
|
+
export { B as BuiltQuery, Q as QueryCapability, r as resolveQuery } from './query-mLQs2WFr.js';
|
|
30
32
|
export { A as AccountLimit, C as ContactAssignment, a as ContactAssignmentCreate, b as ContactAssignmentUpdate, c as ContactDetails, d as CustomerGroup, L as LegalEntity, e as LegalEntityCreate, f as LegalEntityUpdate, g as LegalInfo, h as Location, i as LocationCreate, j as LocationUpdate } from './types.gen-C_wOXYZB.js';
|
|
31
33
|
|
|
32
34
|
/** Base class for every error thrown by the SDK. */
|
|
@@ -419,6 +421,8 @@ declare class RagIndexerService {
|
|
|
419
421
|
* Schedule a full asynchronous re-index for `type` (default `"PRODUCT"`).
|
|
420
422
|
* Resolves once the rebuild is *scheduled* (HTTP 204); there is no progress
|
|
421
423
|
* to await or poll. Costly — avoid calling on a hot path.
|
|
424
|
+
* @deprecated since 2026-06-18, removal 2026-12-01 — use the indexing service:
|
|
425
|
+
* `client.indexing.createReindexJob({ entityType: "PRODUCT", rag: true })`.
|
|
422
426
|
*/
|
|
423
427
|
reindex(type?: RagType, auth?: AuthContext): Promise<void>;
|
|
424
428
|
}
|
|
@@ -986,7 +990,7 @@ type WebhookEvent = {
|
|
|
986
990
|
*/
|
|
987
991
|
type WebhookSubscription$1 = {
|
|
988
992
|
event?: WebhookEvent;
|
|
989
|
-
metadata?: Metadata$
|
|
993
|
+
metadata?: Metadata$8;
|
|
990
994
|
/**
|
|
991
995
|
* Status of the subscription.
|
|
992
996
|
*/
|
|
@@ -1021,7 +1025,7 @@ type WebhookSubscriptionUpdateItem$1 = {
|
|
|
1021
1025
|
/**
|
|
1022
1026
|
* Auditing details.
|
|
1023
1027
|
*/
|
|
1024
|
-
type Metadata$
|
|
1028
|
+
type Metadata$8 = {
|
|
1025
1029
|
/**
|
|
1026
1030
|
* Date and time when the document was created.
|
|
1027
1031
|
*/
|
|
@@ -1555,6 +1559,20 @@ type AgenticRequest = {
|
|
|
1555
1559
|
* The user message to the agent.
|
|
1556
1560
|
*/
|
|
1557
1561
|
message: string;
|
|
1562
|
+
attachments?: Array<{
|
|
1563
|
+
/**
|
|
1564
|
+
* Id of the attachment.
|
|
1565
|
+
*/
|
|
1566
|
+
attachmentId: string;
|
|
1567
|
+
/**
|
|
1568
|
+
* Caption of the attachment.
|
|
1569
|
+
*/
|
|
1570
|
+
caption?: string;
|
|
1571
|
+
/**
|
|
1572
|
+
* Purpose of the attachment.
|
|
1573
|
+
*/
|
|
1574
|
+
purpose?: string;
|
|
1575
|
+
}>;
|
|
1558
1576
|
};
|
|
1559
1577
|
/**
|
|
1560
1578
|
* Type of the agent handling the request.
|
|
@@ -1731,15 +1749,11 @@ type RagEmporixNativeToolConfig = {
|
|
|
1731
1749
|
/**
|
|
1732
1750
|
* This field specifies the fields of the given entityType that are used for filtering the data before performing actual search.
|
|
1733
1751
|
*/
|
|
1734
|
-
filterFields
|
|
1752
|
+
filterFields?: Array<{
|
|
1735
1753
|
/**
|
|
1736
1754
|
* It should contain the description of the field, so LLM is able to know when to use this field in order to filter the data. For enums, possible values should be specified here.
|
|
1737
1755
|
*/
|
|
1738
1756
|
description?: string;
|
|
1739
|
-
/**
|
|
1740
|
-
* It can act as an alias for the field key.
|
|
1741
|
-
*/
|
|
1742
|
-
name?: string;
|
|
1743
1757
|
/**
|
|
1744
1758
|
* Unique value representing the entityType key.
|
|
1745
1759
|
*/
|
|
@@ -1958,6 +1972,68 @@ type TriggerType = 'endpoint' | 'slack';
|
|
|
1958
1972
|
* Type of the trigger.
|
|
1959
1973
|
*/
|
|
1960
1974
|
type CommerceEventsTriggerType = 'commerce_events';
|
|
1975
|
+
/**
|
|
1976
|
+
* Logical operator used to combine multiple filter conditions.
|
|
1977
|
+
*/
|
|
1978
|
+
type CommerceEventTriggerFilterLogicalOperator = '$and' | '$or';
|
|
1979
|
+
/**
|
|
1980
|
+
* Scalar value used in commerce event filter comparisons.
|
|
1981
|
+
*/
|
|
1982
|
+
type CommerceEventTriggerFilterScalarValue = string | number | boolean;
|
|
1983
|
+
/**
|
|
1984
|
+
* Array value used by list-based operators in commerce event filters.
|
|
1985
|
+
*/
|
|
1986
|
+
type CommerceEventTriggerFilterScalarArrayValue = Array<CommerceEventTriggerFilterScalarValue>;
|
|
1987
|
+
/**
|
|
1988
|
+
* Filter condition for unary operators that do not accept `right`.
|
|
1989
|
+
*/
|
|
1990
|
+
type CommerceEventTriggerLeafFilterNoRight = {
|
|
1991
|
+
/**
|
|
1992
|
+
* Dot-notation path to a field in the commerce event payload.
|
|
1993
|
+
*/
|
|
1994
|
+
left: string;
|
|
1995
|
+
op: '$exists' | '$notExists' | '$isEmpty' | '$notEmpty';
|
|
1996
|
+
};
|
|
1997
|
+
/**
|
|
1998
|
+
* Filter condition for scalar comparison operators.
|
|
1999
|
+
*/
|
|
2000
|
+
type CommerceEventTriggerLeafFilterScalarRight = {
|
|
2001
|
+
/**
|
|
2002
|
+
* Dot-notation path to a field in the commerce event payload.
|
|
2003
|
+
*/
|
|
2004
|
+
left: string;
|
|
2005
|
+
op: '$eq' | '$ne';
|
|
2006
|
+
right: CommerceEventTriggerFilterScalarValue;
|
|
2007
|
+
};
|
|
2008
|
+
/**
|
|
2009
|
+
* Filter condition for array membership operators.
|
|
2010
|
+
*/
|
|
2011
|
+
type CommerceEventTriggerLeafFilterArrayRight = {
|
|
2012
|
+
/**
|
|
2013
|
+
* Dot-notation path to a field in the commerce event payload.
|
|
2014
|
+
*/
|
|
2015
|
+
left: string;
|
|
2016
|
+
op: '$in' | '$notIn';
|
|
2017
|
+
right: CommerceEventTriggerFilterScalarArrayValue;
|
|
2018
|
+
};
|
|
2019
|
+
/**
|
|
2020
|
+
* Filter condition applied to a single field in the commerce event payload.
|
|
2021
|
+
*/
|
|
2022
|
+
type CommerceEventTriggerLeafFilter = CommerceEventTriggerLeafFilterNoRight | CommerceEventTriggerLeafFilterScalarRight | CommerceEventTriggerLeafFilterArrayRight;
|
|
2023
|
+
/**
|
|
2024
|
+
* Filter that combines multiple conditions using logical operators.
|
|
2025
|
+
*/
|
|
2026
|
+
type CommerceEventTriggerCompoundFilter = {
|
|
2027
|
+
op: CommerceEventTriggerFilterLogicalOperator;
|
|
2028
|
+
/**
|
|
2029
|
+
* Nested filter conditions combined by the logical operator.
|
|
2030
|
+
*/
|
|
2031
|
+
conditions: Array<CommerceEventTriggerFilter>;
|
|
2032
|
+
};
|
|
2033
|
+
/**
|
|
2034
|
+
* Optional filter expression applied to commerce event payloads. When set, the agent is triggered only if the event payload matches the filter.
|
|
2035
|
+
*/
|
|
2036
|
+
type CommerceEventTriggerFilter = CommerceEventTriggerLeafFilter | CommerceEventTriggerCompoundFilter;
|
|
1961
2037
|
type AgentTrigger = {
|
|
1962
2038
|
type: TriggerType;
|
|
1963
2039
|
} | {
|
|
@@ -1970,6 +2046,7 @@ type AgentTrigger = {
|
|
|
1970
2046
|
* List of events that trigger the agent.
|
|
1971
2047
|
*/
|
|
1972
2048
|
events: string;
|
|
2049
|
+
filter?: CommerceEventTriggerFilter;
|
|
1973
2050
|
};
|
|
1974
2051
|
};
|
|
1975
2052
|
/**
|
|
@@ -2217,7 +2294,7 @@ declare class AiService {
|
|
|
2217
2294
|
chatAsync(input: ChatRequest, auth?: AuthContext): Promise<JobIdResponse[]>;
|
|
2218
2295
|
}
|
|
2219
2296
|
|
|
2220
|
-
type Metadata$
|
|
2297
|
+
type Metadata$7 = {
|
|
2221
2298
|
/**
|
|
2222
2299
|
* Date and time when the object was created.
|
|
2223
2300
|
*/
|
|
@@ -2251,7 +2328,7 @@ type TaxRetrieval = {
|
|
|
2251
2328
|
* List of tax classes applicable in the specified country.
|
|
2252
2329
|
*/
|
|
2253
2330
|
taxClasses?: Array<TaxClass>;
|
|
2254
|
-
metadata?: Metadata$
|
|
2331
|
+
metadata?: Metadata$7;
|
|
2255
2332
|
};
|
|
2256
2333
|
/**
|
|
2257
2334
|
* Single tax class.
|
|
@@ -2424,7 +2501,7 @@ type Location$2 = {
|
|
|
2424
2501
|
countryCode: string;
|
|
2425
2502
|
};
|
|
2426
2503
|
type TaxUpdate = TaxCreation & {
|
|
2427
|
-
metadata: Metadata$
|
|
2504
|
+
metadata: Metadata$7;
|
|
2428
2505
|
};
|
|
2429
2506
|
|
|
2430
2507
|
/**
|
|
@@ -3426,7 +3503,7 @@ type Label$1 = {
|
|
|
3426
3503
|
description?: string | {
|
|
3427
3504
|
[key: string]: string;
|
|
3428
3505
|
};
|
|
3429
|
-
metadata?: Metadata$
|
|
3506
|
+
metadata?: Metadata$6;
|
|
3430
3507
|
};
|
|
3431
3508
|
/**
|
|
3432
3509
|
* If present and `isTrue` is actually true the label should be printed on associated products on the described position.
|
|
@@ -3438,7 +3515,7 @@ type Overlay = {
|
|
|
3438
3515
|
/**
|
|
3439
3516
|
* Metadata
|
|
3440
3517
|
*/
|
|
3441
|
-
type Metadata$
|
|
3518
|
+
type Metadata$6 = {
|
|
3442
3519
|
/**
|
|
3443
3520
|
* The creation date.
|
|
3444
3521
|
*/
|
|
@@ -3492,7 +3569,7 @@ declare class LabelService {
|
|
|
3492
3569
|
deleteLabel(labelId: string, auth?: AuthContext): Promise<void>;
|
|
3493
3570
|
}
|
|
3494
3571
|
|
|
3495
|
-
type Metadata$
|
|
3572
|
+
type Metadata$5 = {
|
|
3496
3573
|
/**
|
|
3497
3574
|
* Date and time when the document was created.
|
|
3498
3575
|
*/
|
|
@@ -3525,7 +3602,7 @@ type Country$1 = {
|
|
|
3525
3602
|
* The field indicating whether the given country is active for the tenant or not. Only active countries are visible in the system.
|
|
3526
3603
|
*/
|
|
3527
3604
|
active?: boolean;
|
|
3528
|
-
metadata?: Metadata$
|
|
3605
|
+
metadata?: Metadata$5;
|
|
3529
3606
|
};
|
|
3530
3607
|
type Region$1 = {
|
|
3531
3608
|
/**
|
|
@@ -3538,7 +3615,7 @@ type Region$1 = {
|
|
|
3538
3615
|
name?: {
|
|
3539
3616
|
[key: string]: string;
|
|
3540
3617
|
};
|
|
3541
|
-
metadata?: Metadata$
|
|
3618
|
+
metadata?: Metadata$5;
|
|
3542
3619
|
};
|
|
3543
3620
|
type CountryUpdate$1 = {
|
|
3544
3621
|
/**
|
|
@@ -3592,7 +3669,7 @@ declare class CountryService {
|
|
|
3592
3669
|
getRegion(regionCode: string, auth?: AuthContext): Promise<Region>;
|
|
3593
3670
|
}
|
|
3594
3671
|
|
|
3595
|
-
type Metadata$
|
|
3672
|
+
type Metadata$4 = {
|
|
3596
3673
|
/**
|
|
3597
3674
|
* Time of document creation.
|
|
3598
3675
|
*/
|
|
@@ -3682,7 +3759,7 @@ type CurrencyRetrieval = {
|
|
|
3682
3759
|
name?: string | {
|
|
3683
3760
|
[key: string]: string;
|
|
3684
3761
|
};
|
|
3685
|
-
metadata?: Metadata$
|
|
3762
|
+
metadata?: Metadata$4;
|
|
3686
3763
|
};
|
|
3687
3764
|
type ExchangeRateUpdateRequest = {
|
|
3688
3765
|
/**
|
|
@@ -3728,7 +3805,7 @@ type ExchangeRateRetrieval = {
|
|
|
3728
3805
|
* The value of the field is represented by a number where the cent part is separated by a dot. For example `1.09`. The cent part is not limited just to two digits. A rate with any precision can be returned. For example: `1.091934212`
|
|
3729
3806
|
*/
|
|
3730
3807
|
rate?: string;
|
|
3731
|
-
metadata?: Metadata$
|
|
3808
|
+
metadata?: Metadata$4;
|
|
3732
3809
|
};
|
|
3733
3810
|
|
|
3734
3811
|
/**
|
|
@@ -5008,6 +5085,9 @@ type SepaJobCreated = JobId;
|
|
|
5008
5085
|
/**
|
|
5009
5086
|
* Emporix SEPA Export Service (`/sepa-export/{tenant}/…`): export jobs and file
|
|
5010
5087
|
* retrieval. Server-side; defaults to the service token.
|
|
5088
|
+
*
|
|
5089
|
+
* @deprecated since 2026-05-25, removal 2026-08-24 — the SEPA Export service is
|
|
5090
|
+
* being sunset by Emporix; all endpoints are no longer maintained.
|
|
5011
5091
|
*/
|
|
5012
5092
|
declare class SepaExportService {
|
|
5013
5093
|
private readonly ctx;
|
|
@@ -5022,6 +5102,44 @@ declare class SepaExportService {
|
|
|
5022
5102
|
createJob(input: SepaJobInput, auth?: AuthContext): Promise<SepaJobCreated>;
|
|
5023
5103
|
}
|
|
5024
5104
|
|
|
5105
|
+
/**
|
|
5106
|
+
* Informs about status of reindex job. `PENDING` means that the maximum number of parallel `IN_PROGRESS` jobs is reached and such job will be processed when one of current `IN_PROGRESS` jobs is released.
|
|
5107
|
+
*/
|
|
5108
|
+
type ReindexJobStatus$1 = 'FAILURE' | 'IN_PROGRESS' | 'PENDING' | 'SUCCESS';
|
|
5109
|
+
type Metadata$3 = {
|
|
5110
|
+
/**
|
|
5111
|
+
* Date and time when the object was created. The value is approved as an ISO-8601 representation of an Instant. For example: `2022-04-30T13:18:02.379Z`
|
|
5112
|
+
*/
|
|
5113
|
+
createdAt?: string;
|
|
5114
|
+
/**
|
|
5115
|
+
* Date and time when the object was last modified. The value is approved as an ISO-8601 representation of an Instant. For example: `2022-04-30T13:18:02.379Z`
|
|
5116
|
+
*/
|
|
5117
|
+
modifiedAt?: string;
|
|
5118
|
+
};
|
|
5119
|
+
/**
|
|
5120
|
+
* Entity type which should be reindexed. For now, it supports only `PRODUCT` and custom schema types.
|
|
5121
|
+
*/
|
|
5122
|
+
type ReindexEntityType$1 = string;
|
|
5123
|
+
type ReindexJob$1 = {
|
|
5124
|
+
/**
|
|
5125
|
+
* Unique identifier of the reindex job.
|
|
5126
|
+
*/
|
|
5127
|
+
id?: string;
|
|
5128
|
+
entityType?: ReindexEntityType$1;
|
|
5129
|
+
/**
|
|
5130
|
+
* In case if reindex job finishes with `FAILURE` status, the message is populated with information what was the reason of the failure.
|
|
5131
|
+
*/
|
|
5132
|
+
message?: string;
|
|
5133
|
+
status?: ReindexJobStatus$1;
|
|
5134
|
+
metadata?: Metadata$3;
|
|
5135
|
+
};
|
|
5136
|
+
type ReindexRequest = {
|
|
5137
|
+
entityType: ReindexEntityType$1;
|
|
5138
|
+
/**
|
|
5139
|
+
* Whether products should be reindexed for RAG. This property is applicable only when `entityType` is `PRODUCT`.
|
|
5140
|
+
*/
|
|
5141
|
+
rag?: boolean;
|
|
5142
|
+
};
|
|
5025
5143
|
type IndexPublicConfiguration = {
|
|
5026
5144
|
/**
|
|
5027
5145
|
* API Key used for search purposes.
|
|
@@ -5078,9 +5196,28 @@ type IndexConfig = IndexConfiguration;
|
|
|
5078
5196
|
type IndexConfigCreated = IndexCreationResponse;
|
|
5079
5197
|
/** A public indexing configuration. */
|
|
5080
5198
|
type IndexPublicConfig = IndexPublicConfiguration;
|
|
5081
|
-
/**
|
|
5199
|
+
/** A reindex job — tracks the progress of a `FULL` reindex. */
|
|
5200
|
+
type ReindexJob = ReindexJob$1;
|
|
5201
|
+
/** Body for `createReindexJob`: `{ entityType, rag? }` (`entityType` required). */
|
|
5202
|
+
type ReindexJobInput = ReindexRequest;
|
|
5203
|
+
/** Entity type to reindex — `"PRODUCT"` or a custom schema type. */
|
|
5204
|
+
type ReindexEntityType = ReindexEntityType$1;
|
|
5205
|
+
/** Lifecycle status of a {@link ReindexJob}. */
|
|
5206
|
+
type ReindexJobStatus = ReindexJobStatus$1;
|
|
5207
|
+
/**
|
|
5208
|
+
* Body for the legacy `reindex` endpoint.
|
|
5209
|
+
* @deprecated since 2026-06-18, removal 2026-12-01 — use {@link ReindexJobInput} with
|
|
5210
|
+
* `IndexingService.createReindexJob`.
|
|
5211
|
+
*/
|
|
5082
5212
|
type ReindexInput = Reindex;
|
|
5083
5213
|
|
|
5214
|
+
/** Options for {@link IndexingService.listReindexJobs}. */
|
|
5215
|
+
interface ListReindexJobsOptions {
|
|
5216
|
+
pageNumber?: number;
|
|
5217
|
+
pageSize?: number;
|
|
5218
|
+
/** Raw Emporix `q` filter string. */
|
|
5219
|
+
q?: string;
|
|
5220
|
+
}
|
|
5084
5221
|
/**
|
|
5085
5222
|
* Emporix Indexing Service (`/indexing/{tenant}/…`): search-index provider
|
|
5086
5223
|
* configurations and reindex. Server-side; defaults to the service token.
|
|
@@ -5104,7 +5241,22 @@ declare class IndexingService {
|
|
|
5104
5241
|
listPublicConfigurations(auth?: AuthContext): Promise<IndexPublicConfig[]>;
|
|
5105
5242
|
/** Get a public configuration by provider name. */
|
|
5106
5243
|
getPublicConfiguration(provider: string, auth?: AuthContext): Promise<IndexPublicConfig>;
|
|
5107
|
-
/**
|
|
5244
|
+
/**
|
|
5245
|
+
* Create a reindex job (replaces {@link reindex}). A `FULL` reindex of the
|
|
5246
|
+
* given `entityType`; set `rag: true` to also rebuild the RAG vector index
|
|
5247
|
+
* (PRODUCT only). Resolves to the created job (`201`) or, when a job for that
|
|
5248
|
+
* `entityType` is already `IN_PROGRESS`, that running job (`200`).
|
|
5249
|
+
*/
|
|
5250
|
+
createReindexJob(input: ReindexJobInput, auth?: AuthContext): Promise<ReindexJob>;
|
|
5251
|
+
/** List reindex jobs (paginated). */
|
|
5252
|
+
listReindexJobs(opts?: ListReindexJobsOptions, auth?: AuthContext): Promise<PaginatedItems<ReindexJob>>;
|
|
5253
|
+
/** Fetch one reindex job by id. */
|
|
5254
|
+
getReindexJob(reindexJobId: string, auth?: AuthContext): Promise<ReindexJob>;
|
|
5255
|
+
/**
|
|
5256
|
+
* Trigger a reindex.
|
|
5257
|
+
* @deprecated since 2026-06-18, removal 2026-12-01 — use {@link createReindexJob}
|
|
5258
|
+
* (`createReindexJob({ entityType: "PRODUCT" })`), which returns a trackable job.
|
|
5259
|
+
*/
|
|
5108
5260
|
reindex(input: ReindexInput, auth?: AuthContext): Promise<void>;
|
|
5109
5261
|
}
|
|
5110
5262
|
|
|
@@ -5755,8 +5907,10 @@ type VendorInput = VendorCreate;
|
|
|
5755
5907
|
type VendorUpdate = VendorUpdate$1;
|
|
5756
5908
|
/** Create response — a resource id. */
|
|
5757
5909
|
type VendorCreated = ResourceId;
|
|
5758
|
-
/** Search body (`POST /vendors/search`). */
|
|
5759
|
-
type VendorSearchQuery = Record<string, unknown
|
|
5910
|
+
/** Search body (`POST /vendors/search`). `q` accepts a raw DSL string or a built filter. */
|
|
5911
|
+
type VendorSearchQuery = Record<string, unknown> & {
|
|
5912
|
+
q?: QueryFor<"VENDOR">;
|
|
5913
|
+
};
|
|
5760
5914
|
/** A vendor location (read shape). */
|
|
5761
5915
|
type VendorLocation = Location$1;
|
|
5762
5916
|
/** List of vendor locations. */
|
|
@@ -5781,7 +5935,7 @@ declare class VendorService {
|
|
|
5781
5935
|
listVendors(query?: Record<string, string | number>, auth?: AuthContext): Promise<VendorList>;
|
|
5782
5936
|
/** Retrieve a vendor by id. */
|
|
5783
5937
|
getVendor(vendorId: string, auth?: AuthContext): Promise<Vendor>;
|
|
5784
|
-
/** Search vendors (`POST /vendors/search`). */
|
|
5938
|
+
/** Search vendors (`POST /vendors/search`). A built filter in `q` is resolved to a string. */
|
|
5785
5939
|
searchVendors(query: VendorSearchQuery, auth?: AuthContext): Promise<VendorList>;
|
|
5786
5940
|
/** Create a vendor. */
|
|
5787
5941
|
createVendor(input: VendorInput, auth?: AuthContext): Promise<VendorCreated>;
|
|
@@ -6246,6 +6400,9 @@ interface RecalculationJobCreated {
|
|
|
6246
6400
|
* orders, assignees, packaging, packing events, and recalculation jobs.
|
|
6247
6401
|
* Server-side; defaults to the service token. Several mutating endpoints return
|
|
6248
6402
|
* an acknowledgement (`{ message?, code? }`).
|
|
6403
|
+
*
|
|
6404
|
+
* @deprecated since 2026-05-25, removal 2026-08-24 — the Pick-Pack service is
|
|
6405
|
+
* being sunset by Emporix; all endpoints are no longer maintained.
|
|
6249
6406
|
*/
|
|
6250
6407
|
declare class PickPackService {
|
|
6251
6408
|
private readonly ctx;
|
|
@@ -6584,8 +6741,10 @@ type AdminCustomerUpdate = CustomerUpdateBySellerDto;
|
|
|
6584
6741
|
type AdminCustomerPatch = CustomerPatchBySellerDto;
|
|
6585
6742
|
/** Create/upsert response — a resource location. */
|
|
6586
6743
|
type AdminCustomerCreated = ResourceLocation;
|
|
6587
|
-
/** Search body (`POST /customers/search`). */
|
|
6588
|
-
type AdminCustomerSearchQuery = Record<string, unknown
|
|
6744
|
+
/** Search body (`POST /customers/search`). `q` accepts a raw DSL string or a built filter. */
|
|
6745
|
+
type AdminCustomerSearchQuery = Record<string, unknown> & {
|
|
6746
|
+
q?: QueryFor<"CUSTOMER">;
|
|
6747
|
+
};
|
|
6589
6748
|
/** A customer address (read). */
|
|
6590
6749
|
type AdminCustomerAddress = Address$1;
|
|
6591
6750
|
/** List of customer addresses. */
|
|
@@ -6609,7 +6768,7 @@ declare class CustomerAdminService {
|
|
|
6609
6768
|
private addressPath;
|
|
6610
6769
|
/** List customers. */
|
|
6611
6770
|
listCustomers(query?: Record<string, string | number>, auth?: AuthContext): Promise<AdminCustomerList>;
|
|
6612
|
-
/** Search customers (`POST /customers/search`). */
|
|
6771
|
+
/** Search customers (`POST /customers/search`). A built filter in `q` is resolved to a string. */
|
|
6613
6772
|
searchCustomers(query: AdminCustomerSearchQuery, auth?: AuthContext): Promise<AdminCustomerList>;
|
|
6614
6773
|
/** Retrieve a customer profile by number. */
|
|
6615
6774
|
getCustomer(customerNumber: string, auth?: AuthContext): Promise<AdminCustomer>;
|
|
@@ -6818,8 +6977,32 @@ type GetApprovalResponse = BasicApproval & {
|
|
|
6818
6977
|
approver?: User;
|
|
6819
6978
|
status?: ApprovalStatus;
|
|
6820
6979
|
expiryDate?: ExpiryDate;
|
|
6980
|
+
legalEntity?: LegalEntity;
|
|
6981
|
+
createdResource?: CreatedResource;
|
|
6821
6982
|
metadata?: Metadata;
|
|
6822
6983
|
};
|
|
6984
|
+
/**
|
|
6985
|
+
* Legal entity (company) the approval belongs to. Set when the approval is created from the customer token.
|
|
6986
|
+
*
|
|
6987
|
+
*/
|
|
6988
|
+
type LegalEntity = {
|
|
6989
|
+
/**
|
|
6990
|
+
* Identifier of the legal entity.
|
|
6991
|
+
*/
|
|
6992
|
+
id: string;
|
|
6993
|
+
};
|
|
6994
|
+
/**
|
|
6995
|
+
* Resource created when the approval flow completes and the approved action is executed. Present once the downstream system has created the linked entity; omitted until then.
|
|
6996
|
+
*
|
|
6997
|
+
* For checkout approvals (`action: CHECKOUT`), `id` is typically the order identifier (for example, from Order Service).
|
|
6998
|
+
*
|
|
6999
|
+
*/
|
|
7000
|
+
type CreatedResource = {
|
|
7001
|
+
/**
|
|
7002
|
+
* Identifier of the created resource (for checkout approvals, typically an order ID).
|
|
7003
|
+
*/
|
|
7004
|
+
id: string;
|
|
7005
|
+
};
|
|
6823
7006
|
/**
|
|
6824
7007
|
* Base schema for approval permitted response.
|
|
6825
7008
|
*/
|
|
@@ -7054,6 +7237,12 @@ type SearchUsersRequest = {
|
|
|
7054
7237
|
* `approval-service` types (single source of truth; faithful required/optional flags).
|
|
7055
7238
|
*
|
|
7056
7239
|
* Every endpoint is CustomerAccessToken-only (B2B cart/quote approval workflows).
|
|
7240
|
+
*
|
|
7241
|
+
* Deprecated upstream (since 2026-05-26, removal 2026-11-30) — these fields carry
|
|
7242
|
+
* `@deprecated` in the generated types; prefer the replacements:
|
|
7243
|
+
* - `totalPrice.amount` / `subTotalPrice.amount` → `netValue` / `grossValue` / `taxValue`
|
|
7244
|
+
* - `itemYrn` → `itemId`
|
|
7245
|
+
* - `itemPrice.amount` → `calculatedPrice` and `unitPrice`
|
|
7057
7246
|
*/
|
|
7058
7247
|
|
|
7059
7248
|
/** An approval document (read shape). */
|
|
@@ -7255,4 +7444,4 @@ declare function createEmporixClient<S extends Record<string, ServiceClass<unkno
|
|
|
7255
7444
|
*/
|
|
7256
7445
|
declare function productIdFromYrn(yrn: string | undefined): string;
|
|
7257
7446
|
|
|
7258
|
-
export { type AddedPoints, type AdminCustomer, type AdminCustomerAddress, type AdminCustomerAddressInput, type AdminCustomerAddressList, type AdminCustomerAddressUpdate, type AdminCustomerCreated, type AdminCustomerInput, type AdminCustomerList, type AdminCustomerPatch, type AdminCustomerSearchQuery, type AdminCustomerUpdate, type Agent, type AgentInput, type AgentPatchOp, type AgentSearchQuery, AiService, type Approval, type ApprovalCreated, type ApprovalInput, type ApprovalList, type ApprovalPatch, type ApprovalPermittedInput, type ApprovalPermittedResult, ApprovalService, type ApprovalUsersQuery, type ApprovalUsersResult, type Assignee, AuthContext, AvailabilityService, type BatchNextIdEntry, type Brand, type BrandInput, type BrandList, BrandService, type BrandUpdate, CartService, type Catalog, type CatalogCreated, type CatalogInput, type CatalogList, type CatalogPatch, CatalogService, type CatalogUpdate, CategoryService, type CgRelation, type CgRelationList, type ChatRequest, type ChatResponse, CheckoutService, ClientConfigService, type ClientConfiguration, ClientContext, CloudFunctionsService, CompaniesService, type CompletionMessage, type CompletionRequest, type CompletionResponse, type Configuration$1 as Configuration, type ConfigurationDraft, ContactsService, type ConversionFactorInput, type ConversionFactorResult, type ConvertUnitInput, type ConvertUnitResult, type Country, type CountryList, CountryService, type CountryUpdate, type Coupon$1 as Coupon, type CouponCreated, type CouponInput, type CouponList, CouponService, type CouponUpdate, type Currency, type CurrencyCreated, type CurrencyInput, type CurrencyList, CurrencyService, type CurrencyUpdate, type CustomEntity, type CustomEntityDraft, type CustomInstance, type CustomInstanceDraft, CustomerAdminService, CustomerGroupsService, CustomerService, type CustomerSummaryBatch, CustomerTokenRefresher, type DeleteAgentOptions, type DeleteConfigOptions, type DeliveryCreated, type DeliveryCycleInput, type DeliverySlot, type DeliverySlotList, type DeliveryTime$1 as DeliveryTime, type DeliveryTimeInput, type DeliveryTimeList, type DeliveryTimeUpdate, type DeliveryWindow$2 as DeliveryWindow, type DeliveryWindowList, type DeliveryWindowValidation, EmporixAuthError, EmporixClient, EmporixConfig, type EmporixCore, EmporixError, EmporixForbiddenError, EmporixInsufficientScopeError, EmporixNetworkError, EmporixNotFoundError, EmporixServerError, EmporixTimeoutError, EmporixValidationError, type ExchangeRate, type ExchangeRateCreated, type ExchangeRateInput, type ExchangeRateList, type ExchangeRateUpdate, type Fee$1 as Fee, type FeeDraft, FeeService, type FindSiteInput, type IndexConfig, type IndexConfigCreated, type IndexPublicConfig, IndexingService, type InstanceSearchBody, type InvokeCloudFunctionOptions, type ItemFee, type ItemFeeDraft, type ItemFeeSearch, type JobIdResponse, type Label, type LabelInput, type LabelList, LabelService, type LabelUpdate, type ListConfigOptions, type ListCustomEntitiesOptions, type ListFeesQuery, type ListInstancesQuery, type ListSchemasQuery, LocationsService, LogLevel, MediaService, type MetadataFilter, type MinimumFee, type NewPointsEntry, type NextIdCommandRequest, type NextIdOptions, type NextIdResponse, type NextIdsBatchRequest, type NextIdsBatchResponse, type OrderCycleList, type OrderEntryEventCreate, type OrderStatusChange, OrdersService, type PackagingProductsChange, type PackingEvent, type PackingEventList, PaginatedItems, PaymentGatewayService, type PickOrder, type PickOrderList, type PickPackAck, PickPackService, type PointsSummary, PriceService, ProductService, type QuoteInput, type QuoteResult, type QuoteSlotInput, RagIndexerService, type RagType, type RecalculationJob, type RecalculationJobCreated, type RecalculationJobInput, type RedeemCouponResult, type RedeemMyPointsInput, type RedeemOption, type RedeemOptionList, type RedeemedPoints, type Redemption, type RedemptionCreated, type RedemptionInput, type ReferralCoupon, type Region, type RegionList, type ReindexInput, ResolvedConfig, type ResourceCreated, type Return, type ReturnCreated, type ReturnInput, type ReturnList, type ReturnPatch, type ReturnUpdate, ReturnsService, RewardPointsService, SalesOrdersService, type Schema, type SchemaAttribute, type SchemaDraft, SchemaService, type SchemaTypeName, type SchemaUpdate, SegmentService, SepaExportService, type SepaJob, type SepaJobCreated, type SepaJobInput, type SequenceSchema, type SequenceSchemaCreate, SequentialIdService, type ServiceClass, ServiceName, type SessionContext, type SessionContextPatch, SessionContextService, type SetItemFeesOptions, type ShippingGroup, type ShippingGroupList, type ShippingMethod, type ShippingMethodList, type ShippingPatch, ShippingService, type ShoppingList, type ShoppingListDraft, type ShoppingListItem, ShoppingListService, type Site$1 as Site, type SiteList, SiteService, type TaxCalculationInput, type TaxCalculationRequest, type TaxCalculationResult, type TaxClass, type TaxConfig, type TaxConfigCreated, type TaxCreation as TaxConfigInput, type TaxUpdate as TaxConfigUpdate, type TaxLocation, TaxService, TenantConfigService, type TextRequest, type TextResponse, TokenProvider, type Unit, type UnitCreated, UnitHandlingService, type UnitInput, type UnitUpdate, type Vendor, type VendorCreated, type VendorInput, type VendorList, type VendorLocation, type VendorLocationInput, type VendorLocationList, type VendorLocationUpdate, type VendorSearchQuery, VendorService, type VendorUpdate, type WebhookConfig, type WebhookConfigCreated, type WebhookConfigDraft, type WebhookConfigPatch, type WebhookDashboardAccess, WebhookService, type WebhookStatistics, type WebhookStatisticsQuery, type WebhookSubscription, type WebhookSubscriptionUpdateItem, type WebhookSubscriptionUpdateResultItem, type Zone, type ZoneList, createCore, createEmporixClient, errorFromResponse, productIdFromYrn };
|
|
7447
|
+
export { type AddedPoints, type AdminCustomer, type AdminCustomerAddress, type AdminCustomerAddressInput, type AdminCustomerAddressList, type AdminCustomerAddressUpdate, type AdminCustomerCreated, type AdminCustomerInput, type AdminCustomerList, type AdminCustomerPatch, type AdminCustomerSearchQuery, type AdminCustomerUpdate, type Agent, type AgentInput, type AgentPatchOp, type AgentSearchQuery, AiService, type Approval, type ApprovalCreated, type ApprovalInput, type ApprovalList, type ApprovalPatch, type ApprovalPermittedInput, type ApprovalPermittedResult, ApprovalService, type ApprovalUsersQuery, type ApprovalUsersResult, type Assignee, AuthContext, AvailabilityService, type BatchNextIdEntry, type Brand, type BrandInput, type BrandList, BrandService, type BrandUpdate, CartService, type Catalog, type CatalogCreated, type CatalogInput, type CatalogList, type CatalogPatch, CatalogService, type CatalogUpdate, CategoryService, type CgRelation, type CgRelationList, type ChatRequest, type ChatResponse, CheckoutService, ClientConfigService, type ClientConfiguration, ClientContext, CloudFunctionsService, CompaniesService, type CompletionMessage, type CompletionRequest, type CompletionResponse, type Configuration$1 as Configuration, type ConfigurationDraft, ContactsService, type ConversionFactorInput, type ConversionFactorResult, type ConvertUnitInput, type ConvertUnitResult, type Country, type CountryList, CountryService, type CountryUpdate, type Coupon$1 as Coupon, type CouponCreated, type CouponInput, type CouponList, CouponService, type CouponUpdate, type Currency, type CurrencyCreated, type CurrencyInput, type CurrencyList, CurrencyService, type CurrencyUpdate, type CustomEntity, type CustomEntityDraft, type CustomInstance, type CustomInstanceDraft, CustomerAdminService, CustomerGroupsService, CustomerService, type CustomerSummaryBatch, CustomerTokenRefresher, type DeleteAgentOptions, type DeleteConfigOptions, type DeliveryCreated, type DeliveryCycleInput, type DeliverySlot, type DeliverySlotList, type DeliveryTime$1 as DeliveryTime, type DeliveryTimeInput, type DeliveryTimeList, type DeliveryTimeUpdate, type DeliveryWindow$2 as DeliveryWindow, type DeliveryWindowList, type DeliveryWindowValidation, EmporixAuthError, EmporixClient, EmporixConfig, type EmporixCore, EmporixError, EmporixForbiddenError, EmporixInsufficientScopeError, EmporixNetworkError, EmporixNotFoundError, EmporixServerError, EmporixTimeoutError, EmporixValidationError, type ExchangeRate, type ExchangeRateCreated, type ExchangeRateInput, type ExchangeRateList, type ExchangeRateUpdate, type Fee$1 as Fee, type FeeDraft, FeeService, type FindSiteInput, type IndexConfig, type IndexConfigCreated, type IndexPublicConfig, IndexingService, type InstanceSearchBody, type InvokeCloudFunctionOptions, type ItemFee, type ItemFeeDraft, type ItemFeeSearch, type JobIdResponse, type Label, type LabelInput, type LabelList, LabelService, type LabelUpdate, type ListConfigOptions, type ListCustomEntitiesOptions, type ListFeesQuery, type ListInstancesQuery, type ListReindexJobsOptions, type ListSchemasQuery, LocationsService, LogLevel, MediaService, type MetadataFilter, type MinimumFee, type NewPointsEntry, type NextIdCommandRequest, type NextIdOptions, type NextIdResponse, type NextIdsBatchRequest, type NextIdsBatchResponse, type OrderCycleList, type OrderEntryEventCreate, type OrderStatusChange, OrdersService, type PackagingProductsChange, type PackingEvent, type PackingEventList, PaginatedItems, PaymentGatewayService, type PickOrder, type PickOrderList, type PickPackAck, PickPackService, type PointsSummary, PriceService, ProductService, QueryFor, type QuoteInput, type QuoteResult, type QuoteSlotInput, RagIndexerService, type RagType, type RecalculationJob, type RecalculationJobCreated, type RecalculationJobInput, type RedeemCouponResult, type RedeemMyPointsInput, type RedeemOption, type RedeemOptionList, type RedeemedPoints, type Redemption, type RedemptionCreated, type RedemptionInput, type ReferralCoupon, type Region, type RegionList, type ReindexEntityType, type ReindexInput, type ReindexJob, type ReindexJobInput, type ReindexJobStatus, ResolvedConfig, type ResourceCreated, type Return, type ReturnCreated, type ReturnInput, type ReturnList, type ReturnPatch, type ReturnUpdate, ReturnsService, RewardPointsService, SalesOrdersService, type Schema, type SchemaAttribute, type SchemaDraft, SchemaService, type SchemaTypeName, type SchemaUpdate, SegmentService, SepaExportService, type SepaJob, type SepaJobCreated, type SepaJobInput, type SequenceSchema, type SequenceSchemaCreate, SequentialIdService, type ServiceClass, ServiceName, type SessionContext, type SessionContextPatch, SessionContextService, type SetItemFeesOptions, type ShippingGroup, type ShippingGroupList, type ShippingMethod, type ShippingMethodList, type ShippingPatch, ShippingService, type ShoppingList, type ShoppingListDraft, type ShoppingListItem, ShoppingListService, type Site$1 as Site, type SiteList, SiteService, type TaxCalculationInput, type TaxCalculationRequest, type TaxCalculationResult, type TaxClass, type TaxConfig, type TaxConfigCreated, type TaxCreation as TaxConfigInput, type TaxUpdate as TaxConfigUpdate, type TaxLocation, TaxService, TenantConfigService, type TextRequest, type TextResponse, TokenProvider, type Unit, type UnitCreated, UnitHandlingService, type UnitInput, type UnitUpdate, type Vendor, type VendorCreated, type VendorInput, type VendorList, type VendorLocation, type VendorLocationInput, type VendorLocationList, type VendorLocationUpdate, type VendorSearchQuery, VendorService, type VendorUpdate, type WebhookConfig, type WebhookConfigCreated, type WebhookConfigDraft, type WebhookConfigPatch, type WebhookDashboardAccess, WebhookService, type WebhookStatistics, type WebhookStatisticsQuery, type WebhookSubscription, type WebhookSubscriptionUpdateItem, type WebhookSubscriptionUpdateResultItem, type Zone, type ZoneList, createCore, createEmporixClient, errorFromResponse, productIdFromYrn };
|
package/dist/index.js
CHANGED
|
@@ -2,23 +2,25 @@ import { LocationsService } from './chunk-DUVIIWFG.js';
|
|
|
2
2
|
export { LocationsService } from './chunk-DUVIIWFG.js';
|
|
3
3
|
import { MediaService } from './chunk-OTG2S2L4.js';
|
|
4
4
|
export { MediaService } from './chunk-OTG2S2L4.js';
|
|
5
|
-
import { OrdersService, SalesOrdersService } from './chunk-
|
|
6
|
-
export { OrdersService, SalesOrdersService } from './chunk-
|
|
5
|
+
import { OrdersService, SalesOrdersService } from './chunk-36T4YPQJ.js';
|
|
6
|
+
export { OrdersService, SalesOrdersService } from './chunk-36T4YPQJ.js';
|
|
7
7
|
import { auth, resolveToken, DefaultTokenProvider, CustomerRefreshRegistry, PaymentGatewayService } from './chunk-PYLWZZC4.js';
|
|
8
8
|
export { CustomerRefreshRegistry, DefaultTokenProvider, PaymentGatewayService, auth, resolveToken } from './chunk-PYLWZZC4.js';
|
|
9
9
|
import { PriceService } from './chunk-A3LYJUD4.js';
|
|
10
10
|
export { PriceService } from './chunk-A3LYJUD4.js';
|
|
11
|
-
import { ProductService } from './chunk-
|
|
12
|
-
export { ProductService } from './chunk-
|
|
11
|
+
import { ProductService } from './chunk-FZMP5NQZ.js';
|
|
12
|
+
export { ProductService } from './chunk-FZMP5NQZ.js';
|
|
13
13
|
import { SegmentService } from './chunk-NE7MIZPR.js';
|
|
14
14
|
export { SegmentService } from './chunk-NE7MIZPR.js';
|
|
15
|
-
import { AvailabilityService } from './chunk-
|
|
16
|
-
export { AvailabilityService } from './chunk-
|
|
15
|
+
import { AvailabilityService } from './chunk-IVCCGJN5.js';
|
|
16
|
+
export { AvailabilityService } from './chunk-IVCCGJN5.js';
|
|
17
17
|
import { CartService } from './chunk-PAT4CS36.js';
|
|
18
18
|
export { CartService } from './chunk-PAT4CS36.js';
|
|
19
|
-
import { CategoryService } from './chunk-
|
|
20
|
-
export { CategoryService } from './chunk-
|
|
19
|
+
import { CategoryService } from './chunk-6XND7SYV.js';
|
|
20
|
+
export { CategoryService } from './chunk-6XND7SYV.js';
|
|
21
21
|
export { iterateAll } from './chunk-GWJ2U2CP.js';
|
|
22
|
+
import { resolveQuery } from './chunk-S5HEIQDK.js';
|
|
23
|
+
export { resolveQuery } from './chunk-S5HEIQDK.js';
|
|
22
24
|
import { CheckoutService } from './chunk-RYQVMR26.js';
|
|
23
25
|
export { CheckoutService } from './chunk-RYQVMR26.js';
|
|
24
26
|
import { CompaniesService } from './chunk-BNX3JULF.js';
|
|
@@ -486,7 +488,7 @@ var HttpClient = class {
|
|
|
486
488
|
};
|
|
487
489
|
|
|
488
490
|
// package.json
|
|
489
|
-
var version = "2.
|
|
491
|
+
var version = "2.19.0";
|
|
490
492
|
|
|
491
493
|
// src/version.ts
|
|
492
494
|
var SDK_VERSION = version;
|
|
@@ -901,6 +903,8 @@ var RagIndexerService = class {
|
|
|
901
903
|
* Schedule a full asynchronous re-index for `type` (default `"PRODUCT"`).
|
|
902
904
|
* Resolves once the rebuild is *scheduled* (HTTP 204); there is no progress
|
|
903
905
|
* to await or poll. Costly — avoid calling on a hot path.
|
|
906
|
+
* @deprecated since 2026-06-18, removal 2026-12-01 — use the indexing service:
|
|
907
|
+
* `client.indexing.createReindexJob({ entityType: "PRODUCT", rag: true })`.
|
|
904
908
|
*/
|
|
905
909
|
async reindex(type = "PRODUCT", auth2 = SERVICE3) {
|
|
906
910
|
await this.ctx.http.request({
|
|
@@ -2861,7 +2865,47 @@ var IndexingService = class {
|
|
|
2861
2865
|
auth: auth2
|
|
2862
2866
|
});
|
|
2863
2867
|
}
|
|
2864
|
-
/**
|
|
2868
|
+
/**
|
|
2869
|
+
* Create a reindex job (replaces {@link reindex}). A `FULL` reindex of the
|
|
2870
|
+
* given `entityType`; set `rag: true` to also rebuild the RAG vector index
|
|
2871
|
+
* (PRODUCT only). Resolves to the created job (`201`) or, when a job for that
|
|
2872
|
+
* `entityType` is already `IN_PROGRESS`, that running job (`200`).
|
|
2873
|
+
*/
|
|
2874
|
+
async createReindexJob(input, auth2 = SERVICE19) {
|
|
2875
|
+
return this.ctx.http.request({
|
|
2876
|
+
method: "POST",
|
|
2877
|
+
path: `${this.base()}/reindex-jobs`,
|
|
2878
|
+
auth: auth2,
|
|
2879
|
+
body: input
|
|
2880
|
+
});
|
|
2881
|
+
}
|
|
2882
|
+
/** List reindex jobs (paginated). */
|
|
2883
|
+
async listReindexJobs(opts = {}, auth2 = SERVICE19) {
|
|
2884
|
+
const pageNumber = opts.pageNumber ?? 1;
|
|
2885
|
+
const pageSize = opts.pageSize ?? 50;
|
|
2886
|
+
const query = { pageNumber, pageSize };
|
|
2887
|
+
if (opts.q !== void 0) query.q = opts.q;
|
|
2888
|
+
const items = await this.ctx.http.request({
|
|
2889
|
+
method: "GET",
|
|
2890
|
+
path: `${this.base()}/reindex-jobs`,
|
|
2891
|
+
query,
|
|
2892
|
+
auth: auth2
|
|
2893
|
+
});
|
|
2894
|
+
return { items, pageNumber, pageSize, hasNextPage: items.length === pageSize };
|
|
2895
|
+
}
|
|
2896
|
+
/** Fetch one reindex job by id. */
|
|
2897
|
+
async getReindexJob(reindexJobId, auth2 = SERVICE19) {
|
|
2898
|
+
return this.ctx.http.request({
|
|
2899
|
+
method: "GET",
|
|
2900
|
+
path: `${this.base()}/reindex-jobs/${encodeURIComponent(reindexJobId)}`,
|
|
2901
|
+
auth: auth2
|
|
2902
|
+
});
|
|
2903
|
+
}
|
|
2904
|
+
/**
|
|
2905
|
+
* Trigger a reindex.
|
|
2906
|
+
* @deprecated since 2026-06-18, removal 2026-12-01 — use {@link createReindexJob}
|
|
2907
|
+
* (`createReindexJob({ entityType: "PRODUCT" })`), which returns a trackable job.
|
|
2908
|
+
*/
|
|
2865
2909
|
async reindex(input, auth2 = SERVICE19) {
|
|
2866
2910
|
await this.ctx.http.request({ method: "POST", path: `${this.base()}/reindex`, auth: auth2, body: input });
|
|
2867
2911
|
}
|
|
@@ -3046,13 +3090,14 @@ var VendorService = class {
|
|
|
3046
3090
|
auth: auth2
|
|
3047
3091
|
});
|
|
3048
3092
|
}
|
|
3049
|
-
/** Search vendors (`POST /vendors/search`). */
|
|
3093
|
+
/** Search vendors (`POST /vendors/search`). A built filter in `q` is resolved to a string. */
|
|
3050
3094
|
async searchVendors(query, auth2 = SERVICE22) {
|
|
3095
|
+
const body = query.q !== void 0 ? { ...query, q: resolveQuery(query.q, { compoundLogicalQuery: false }) } : query;
|
|
3051
3096
|
return this.ctx.http.request({
|
|
3052
3097
|
method: "POST",
|
|
3053
3098
|
path: `${this.base()}/vendors/search`,
|
|
3054
3099
|
auth: auth2,
|
|
3055
|
-
body
|
|
3100
|
+
body
|
|
3056
3101
|
});
|
|
3057
3102
|
}
|
|
3058
3103
|
/** Create a vendor. */
|
|
@@ -3236,9 +3281,10 @@ var CustomerAdminService = class {
|
|
|
3236
3281
|
...Object.keys(query).length ? { query } : {}
|
|
3237
3282
|
});
|
|
3238
3283
|
}
|
|
3239
|
-
/** Search customers (`POST /customers/search`). */
|
|
3284
|
+
/** Search customers (`POST /customers/search`). A built filter in `q` is resolved to a string. */
|
|
3240
3285
|
async searchCustomers(query, auth2 = SERVICE24) {
|
|
3241
|
-
|
|
3286
|
+
const body = query.q !== void 0 ? { ...query, q: resolveQuery(query.q, { compoundLogicalQuery: false }) } : query;
|
|
3287
|
+
return this.ctx.http.request({ method: "POST", path: `${this.base()}/search`, auth: auth2, body });
|
|
3242
3288
|
}
|
|
3243
3289
|
/** Retrieve a customer profile by number. */
|
|
3244
3290
|
async getCustomer(customerNumber, auth2 = SERVICE24) {
|