@spscommerce/asst-api 1.0.1 → 1.2.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.
@@ -1,4 +1,4 @@
1
- import * as ky_universal from 'ky-universal';
1
+ import * as ky from 'ky';
2
2
  import { Options } from 'ky';
3
3
  import { z } from 'zod';
4
4
 
@@ -36,12 +36,12 @@ declare class AsstClient {
36
36
  * @returns Function to unsubscribe to config changes
37
37
  */
38
38
  subscribeToConfigChange(listener: Listener): () => boolean;
39
- get(url: Input, options?: AsstClientOptions): ky_universal.ResponsePromise;
40
- post(url: Input, options?: AsstClientOptions): ky_universal.ResponsePromise;
41
- put(url: Input, options?: AsstClientOptions): ky_universal.ResponsePromise;
42
- patch(url: Input, options?: AsstClientOptions): ky_universal.ResponsePromise;
43
- head(url: Input, options?: AsstClientOptions): ky_universal.ResponsePromise;
44
- delete(url: Input, options?: AsstClientOptions): ky_universal.ResponsePromise;
39
+ get(url: Input, options?: AsstClientOptions): ky.ResponsePromise;
40
+ post(url: Input, options?: AsstClientOptions): ky.ResponsePromise;
41
+ put(url: Input, options?: AsstClientOptions): ky.ResponsePromise;
42
+ patch(url: Input, options?: AsstClientOptions): ky.ResponsePromise;
43
+ head(url: Input, options?: AsstClientOptions): ky.ResponsePromise;
44
+ delete(url: Input, options?: AsstClientOptions): ky.ResponsePromise;
45
45
  }
46
46
 
47
47
  declare const importSchema: z.ZodObject<{
@@ -212,6 +212,7 @@ declare const exportSchema: z.ZodObject<{
212
212
  emailAddresses: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
213
213
  subjectLine: z.ZodOptional<z.ZodString>;
214
214
  additionalLocales: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
215
+ availableAttributeList: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
215
216
  }, "strip", z.ZodTypeAny, {
216
217
  exportName: string;
217
218
  exportDescription: string;
@@ -234,6 +235,7 @@ declare const exportSchema: z.ZodObject<{
234
235
  emailAddresses?: string[] | undefined;
235
236
  subjectLine?: string | undefined;
236
237
  additionalLocales?: string[] | undefined;
238
+ availableAttributeList?: string[] | undefined;
237
239
  }, {
238
240
  exportName: string;
239
241
  exportDescription: string;
@@ -256,6 +258,7 @@ declare const exportSchema: z.ZodObject<{
256
258
  emailAddresses?: string[] | undefined;
257
259
  subjectLine?: string | undefined;
258
260
  additionalLocales?: string[] | undefined;
261
+ availableAttributeList?: string[] | undefined;
259
262
  }>;
260
263
  type Export = z.infer<typeof exportSchema>;
261
264
 
@@ -3120,6 +3123,271 @@ declare const itemErrorDetailsResultSchema: z.ZodObject<{
3120
3123
  }>;
3121
3124
  type ItemErrorDetailsResult = z.infer<typeof itemErrorDetailsResultSchema>;
3122
3125
 
3126
+ declare const itemErrorSummaryResultV2Schema: z.ZodObject<{
3127
+ hasNext: z.ZodBoolean;
3128
+ errors: z.ZodArray<z.ZodObject<{
3129
+ itemInfoId: z.ZodNumber;
3130
+ upc: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3131
+ isbn: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3132
+ gtin: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3133
+ ean: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3134
+ partnumber: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3135
+ colorfamily: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3136
+ fit: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3137
+ productcolordescription: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3138
+ distributioncentercode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3139
+ accountnumber: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3140
+ erpid: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3141
+ totalErrors: z.ZodNumber;
3142
+ tradingPartners: z.ZodArray<z.ZodString, "many">;
3143
+ tradingPartnerIds: z.ZodArray<z.ZodNumber, "many">;
3144
+ phases: z.ZodArray<z.ZodString, "many">;
3145
+ tradingPartnerStages: z.ZodArray<z.ZodObject<{
3146
+ companyId: z.ZodNumber;
3147
+ companyName: z.ZodString;
3148
+ stage: z.ZodOptional<z.ZodNullable<z.ZodEnum<["CORE", "CORE_PLUS", "CORE_ADVANCED", "ENRICHED"]>>>;
3149
+ isValid: z.ZodBoolean;
3150
+ }, "strip", z.ZodTypeAny, {
3151
+ companyId: number;
3152
+ companyName: string;
3153
+ isValid: boolean;
3154
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3155
+ }, {
3156
+ companyId: number;
3157
+ companyName: string;
3158
+ isValid: boolean;
3159
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3160
+ }>, "many">;
3161
+ validatedDate: z.ZodOptional<z.ZodNullable<z.ZodPipeline<z.ZodNumber, z.ZodDate>>>;
3162
+ }, "strip", z.ZodTypeAny, {
3163
+ itemInfoId: number;
3164
+ tradingPartnerStages: {
3165
+ companyId: number;
3166
+ companyName: string;
3167
+ isValid: boolean;
3168
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3169
+ }[];
3170
+ phases: string[];
3171
+ totalErrors: number;
3172
+ tradingPartners: string[];
3173
+ tradingPartnerIds: number[];
3174
+ gtin?: string | null | undefined;
3175
+ upc?: string | null | undefined;
3176
+ ean?: string | null | undefined;
3177
+ isbn?: string | null | undefined;
3178
+ partnumber?: string | null | undefined;
3179
+ productcolordescription?: string | null | undefined;
3180
+ colorfamily?: string | null | undefined;
3181
+ fit?: string | null | undefined;
3182
+ distributioncentercode?: string | null | undefined;
3183
+ accountnumber?: string | null | undefined;
3184
+ erpid?: string | null | undefined;
3185
+ validatedDate?: Date | null | undefined;
3186
+ }, {
3187
+ itemInfoId: number;
3188
+ tradingPartnerStages: {
3189
+ companyId: number;
3190
+ companyName: string;
3191
+ isValid: boolean;
3192
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3193
+ }[];
3194
+ phases: string[];
3195
+ totalErrors: number;
3196
+ tradingPartners: string[];
3197
+ tradingPartnerIds: number[];
3198
+ gtin?: string | null | undefined;
3199
+ upc?: string | null | undefined;
3200
+ ean?: string | null | undefined;
3201
+ isbn?: string | null | undefined;
3202
+ partnumber?: string | null | undefined;
3203
+ productcolordescription?: string | null | undefined;
3204
+ colorfamily?: string | null | undefined;
3205
+ fit?: string | null | undefined;
3206
+ distributioncentercode?: string | null | undefined;
3207
+ accountnumber?: string | null | undefined;
3208
+ erpid?: string | null | undefined;
3209
+ validatedDate?: number | null | undefined;
3210
+ }>, "many">;
3211
+ }, "strip", z.ZodTypeAny, {
3212
+ errors: {
3213
+ itemInfoId: number;
3214
+ tradingPartnerStages: {
3215
+ companyId: number;
3216
+ companyName: string;
3217
+ isValid: boolean;
3218
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3219
+ }[];
3220
+ phases: string[];
3221
+ totalErrors: number;
3222
+ tradingPartners: string[];
3223
+ tradingPartnerIds: number[];
3224
+ gtin?: string | null | undefined;
3225
+ upc?: string | null | undefined;
3226
+ ean?: string | null | undefined;
3227
+ isbn?: string | null | undefined;
3228
+ partnumber?: string | null | undefined;
3229
+ productcolordescription?: string | null | undefined;
3230
+ colorfamily?: string | null | undefined;
3231
+ fit?: string | null | undefined;
3232
+ distributioncentercode?: string | null | undefined;
3233
+ accountnumber?: string | null | undefined;
3234
+ erpid?: string | null | undefined;
3235
+ validatedDate?: Date | null | undefined;
3236
+ }[];
3237
+ hasNext: boolean;
3238
+ }, {
3239
+ errors: {
3240
+ itemInfoId: number;
3241
+ tradingPartnerStages: {
3242
+ companyId: number;
3243
+ companyName: string;
3244
+ isValid: boolean;
3245
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3246
+ }[];
3247
+ phases: string[];
3248
+ totalErrors: number;
3249
+ tradingPartners: string[];
3250
+ tradingPartnerIds: number[];
3251
+ gtin?: string | null | undefined;
3252
+ upc?: string | null | undefined;
3253
+ ean?: string | null | undefined;
3254
+ isbn?: string | null | undefined;
3255
+ partnumber?: string | null | undefined;
3256
+ productcolordescription?: string | null | undefined;
3257
+ colorfamily?: string | null | undefined;
3258
+ fit?: string | null | undefined;
3259
+ distributioncentercode?: string | null | undefined;
3260
+ accountnumber?: string | null | undefined;
3261
+ erpid?: string | null | undefined;
3262
+ validatedDate?: number | null | undefined;
3263
+ }[];
3264
+ hasNext: boolean;
3265
+ }>;
3266
+ type ItemErrorSummaryResultV2 = z.infer<typeof itemErrorSummaryResultV2Schema>;
3267
+
3268
+ declare const itemErrorDetailsResultV2Schema: z.ZodObject<{
3269
+ itemInfoId: z.ZodNumber;
3270
+ upc: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3271
+ isbn: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3272
+ gtin: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3273
+ partnumber: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3274
+ ean: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3275
+ colorfamily: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3276
+ fit: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3277
+ productcolordescription: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3278
+ distributioncentercode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3279
+ accountnumber: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3280
+ erpid: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3281
+ itemName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3282
+ itemErrorDetails: z.ZodArray<z.ZodObject<{
3283
+ errorMessage: z.ZodString;
3284
+ attributeName: z.ZodString;
3285
+ attributeDbNames: z.ZodArray<z.ZodString, "many">;
3286
+ tradingPartnerNames: z.ZodArray<z.ZodString, "many">;
3287
+ phases: z.ZodSet<z.ZodEnum<["CORE", "CORE_PLUS", "CORE_ADVANCED", "ENRICHED"]>>;
3288
+ tradingPartnerStages: z.ZodArray<z.ZodObject<{
3289
+ companyId: z.ZodNumber;
3290
+ companyName: z.ZodString;
3291
+ stage: z.ZodOptional<z.ZodNullable<z.ZodEnum<["CORE", "CORE_PLUS", "CORE_ADVANCED", "ENRICHED"]>>>;
3292
+ isValid: z.ZodBoolean;
3293
+ }, "strip", z.ZodTypeAny, {
3294
+ companyId: number;
3295
+ companyName: string;
3296
+ isValid: boolean;
3297
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3298
+ }, {
3299
+ companyId: number;
3300
+ companyName: string;
3301
+ isValid: boolean;
3302
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3303
+ }>, "many">;
3304
+ repeatableGroupId: z.ZodString;
3305
+ }, "strip", z.ZodTypeAny, {
3306
+ attributeName: string;
3307
+ tradingPartnerStages: {
3308
+ companyId: number;
3309
+ companyName: string;
3310
+ isValid: boolean;
3311
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3312
+ }[];
3313
+ errorMessage: string;
3314
+ tradingPartnerNames: string[];
3315
+ phases: Set<"CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED">;
3316
+ attributeDbNames: string[];
3317
+ repeatableGroupId: string;
3318
+ }, {
3319
+ attributeName: string;
3320
+ tradingPartnerStages: {
3321
+ companyId: number;
3322
+ companyName: string;
3323
+ isValid: boolean;
3324
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3325
+ }[];
3326
+ errorMessage: string;
3327
+ tradingPartnerNames: string[];
3328
+ phases: Set<"CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED">;
3329
+ attributeDbNames: string[];
3330
+ repeatableGroupId: string;
3331
+ }>, "many">;
3332
+ }, "strip", z.ZodTypeAny, {
3333
+ itemInfoId: number;
3334
+ itemErrorDetails: {
3335
+ attributeName: string;
3336
+ tradingPartnerStages: {
3337
+ companyId: number;
3338
+ companyName: string;
3339
+ isValid: boolean;
3340
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3341
+ }[];
3342
+ errorMessage: string;
3343
+ tradingPartnerNames: string[];
3344
+ phases: Set<"CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED">;
3345
+ attributeDbNames: string[];
3346
+ repeatableGroupId: string;
3347
+ }[];
3348
+ gtin?: string | null | undefined;
3349
+ upc?: string | null | undefined;
3350
+ ean?: string | null | undefined;
3351
+ isbn?: string | null | undefined;
3352
+ partnumber?: string | null | undefined;
3353
+ productcolordescription?: string | null | undefined;
3354
+ itemName?: string | null | undefined;
3355
+ colorfamily?: string | null | undefined;
3356
+ fit?: string | null | undefined;
3357
+ distributioncentercode?: string | null | undefined;
3358
+ accountnumber?: string | null | undefined;
3359
+ erpid?: string | null | undefined;
3360
+ }, {
3361
+ itemInfoId: number;
3362
+ itemErrorDetails: {
3363
+ attributeName: string;
3364
+ tradingPartnerStages: {
3365
+ companyId: number;
3366
+ companyName: string;
3367
+ isValid: boolean;
3368
+ stage?: "CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED" | null | undefined;
3369
+ }[];
3370
+ errorMessage: string;
3371
+ tradingPartnerNames: string[];
3372
+ phases: Set<"CORE" | "CORE_PLUS" | "CORE_ADVANCED" | "ENRICHED">;
3373
+ attributeDbNames: string[];
3374
+ repeatableGroupId: string;
3375
+ }[];
3376
+ gtin?: string | null | undefined;
3377
+ upc?: string | null | undefined;
3378
+ ean?: string | null | undefined;
3379
+ isbn?: string | null | undefined;
3380
+ partnumber?: string | null | undefined;
3381
+ productcolordescription?: string | null | undefined;
3382
+ itemName?: string | null | undefined;
3383
+ colorfamily?: string | null | undefined;
3384
+ fit?: string | null | undefined;
3385
+ distributioncentercode?: string | null | undefined;
3386
+ accountnumber?: string | null | undefined;
3387
+ erpid?: string | null | undefined;
3388
+ }>;
3389
+ type ItemErrorDetailsResultV2 = z.infer<typeof itemErrorDetailsResultV2Schema>;
3390
+
3123
3391
  declare const companyBriefByOrgSchema: z.ZodObject<{
3124
3392
  companyId: z.ZodNumber;
3125
3393
  name: z.ZodString;
@@ -3156,4 +3424,4 @@ declare const companyBriefByOrgSchema: z.ZodObject<{
3156
3424
  }>;
3157
3425
  type CompanyBriefByOrg = z.infer<typeof companyBriefByOrgSchema>;
3158
3426
 
3159
- export { AsstClient as A, BASE_URLS as B, type CompanyBriefByOrg as C, attributeValidValuesSchema as D, type Export as E, itemSearchViewSchema as F, itemDetailViewSchema as G, localeSchema as H, type ImportErrors as I, spreadsheetTemplateSchema as J, tradingPartnerAccessByCompanyIdSchema as K, type Locale as L, companyRelationshipUpsertBodySchema as M, userAccountSchema as N, itemErrorDetailsResultSchema as O, companyBriefByOrgSchema as P, type SpreadsheetTemplate as S, type TradingPartnerAccessByCompanyId as T, type UserAccount as U, type VendorPartnerAttGroups as V, type Import as a, type ImportsStatus as b, type ItemCategoriesSearch as c, attrProdTypeSchema as d, type CompanyRelationshipUpsertBody as e, type ItemErrorDetailsResult as f, type ItemSearchView as g, type ItemDetailView as h, type AttributeMetaData as i, type AttributesByCompany as j, type AttributeDefinition as k, type AttributeValidValues as l, type AttrProdType as m, envSchema as n, type AsstClientOptions as o, type AsstUrl as p, type Env as q, importErrorsSchema as r, importSchema as s, importsStatusSchema as t, exportSchema as u, vendorPartnerAttGroupsSchema as v, itemCategoriesSearchSchema as w, attributeDefinitionSchema as x, attributeMetaDataSchema as y, attributesByCompanySchema as z };
3427
+ export { AsstClient as A, BASE_URLS as B, type CompanyBriefByOrg as C, attributeMetaDataSchema as D, type Export as E, attributesByCompanySchema as F, attributeValidValuesSchema as G, itemSearchViewSchema as H, type ImportErrors as I, itemDetailViewSchema as J, localeSchema as K, type Locale as L, spreadsheetTemplateSchema as M, tradingPartnerAccessByCompanyIdSchema as N, companyRelationshipUpsertBodySchema as O, userAccountSchema as P, itemErrorDetailsResultSchema as Q, itemErrorDetailsResultV2Schema as R, type SpreadsheetTemplate as S, type TradingPartnerAccessByCompanyId as T, type UserAccount as U, type VendorPartnerAttGroups as V, itemErrorSummaryResultV2Schema as W, companyBriefByOrgSchema as X, type Import as a, type ImportsStatus as b, type ItemCategoriesSearch as c, attrProdTypeSchema as d, type CompanyRelationshipUpsertBody as e, type ItemErrorDetailsResult as f, type ItemErrorSummaryResultV2 as g, type ItemErrorDetailsResultV2 as h, type ItemSearchView as i, type ItemDetailView as j, type AttributeMetaData as k, type AttributesByCompany as l, type AttributeDefinition as m, type AttributeValidValues as n, type AttrProdType as o, envSchema as p, type AsstClientOptions as q, type AsstUrl as r, type Env as s, importErrorsSchema as t, importSchema as u, importsStatusSchema as v, vendorPartnerAttGroupsSchema as w, exportSchema as x, itemCategoriesSearchSchema as y, attributeDefinitionSchema as z };
@@ -11,6 +11,8 @@ import {
11
11
  itemCategoriesSearchSchema,
12
12
  itemDetailViewSchema,
13
13
  itemErrorDetailsResultSchema,
14
+ itemErrorDetailsResultV2Schema,
15
+ itemErrorSummaryResultV2Schema,
14
16
  itemHierarchyResponseSchema,
15
17
  itemSearchViewSchema,
16
18
  itemStatusResponseSchema,
@@ -21,7 +23,7 @@ import {
21
23
  userAccountSchema,
22
24
  vendorPartnerAttGroupsSchema,
23
25
  z
24
- } from "./chunk-6FFDMMN5.js";
26
+ } from "./chunk-CUVSWUIQ.js";
25
27
 
26
28
  // lib/imports/index.ts
27
29
  var BASE_URL = "imports";
@@ -408,7 +410,7 @@ function createItemsApi(client) {
408
410
  };
409
411
  }
410
412
 
411
- // lib/errors/index.ts
413
+ // lib/errors/v1/index.ts
412
414
  var BASE_URL14 = "errors";
413
415
  function createErrorsApi(client) {
414
416
  async function getInvalidItemErrorDetails(itemInfoId, signal) {
@@ -422,11 +424,44 @@ function createErrorsApi(client) {
422
424
  };
423
425
  }
424
426
 
427
+ // lib/errors/v2/index.ts
428
+ var BASE_URL15 = "errors/v2";
429
+ function createErrorsApiV2(client) {
430
+ async function getItemErrorSummary(params, signal) {
431
+ const searchParams = new URLSearchParams();
432
+ if (params.searchField)
433
+ searchParams.append("searchField", params.searchField);
434
+ if (params.searchText)
435
+ searchParams.append("searchText", params.searchText);
436
+ if (params.tradingPartnerIds) {
437
+ params.tradingPartnerIds.forEach((id) => searchParams.append("tradingPartnerIds", id.toString()));
438
+ }
439
+ if (params.offset)
440
+ searchParams.append("offset", params.offset.toString());
441
+ if (params.limit)
442
+ searchParams.append("limit", params.limit.toString());
443
+ if (params.docInEventId)
444
+ searchParams.append("docInEventId", params.docInEventId);
445
+ if (params.importId)
446
+ searchParams.append("importId", params.importId);
447
+ const data = await client.get(`${BASE_URL15}/summary`, { signal, searchParams }).json();
448
+ return itemErrorSummaryResultV2Schema.parse(data);
449
+ }
450
+ async function getItemErrorDetails(itemInfoId, signal) {
451
+ const data = await client.get(`${BASE_URL15}/items/${itemInfoId}`, { signal }).json();
452
+ return itemErrorDetailsResultV2Schema.parse(data);
453
+ }
454
+ return {
455
+ getItemErrorSummary,
456
+ getItemErrorDetails
457
+ };
458
+ }
459
+
425
460
  // lib/uniqueCriteria/index.ts
426
- var BASE_URL15 = "uniquecriteria";
461
+ var BASE_URL16 = "uniquecriteria";
427
462
  function createUniqueCriteriaApi(client) {
428
463
  async function getUniqueCriteriaByOrg(params, signal) {
429
- const data = await client.get(`${BASE_URL15}/org`, {
464
+ const data = await client.get(`${BASE_URL16}/org`, {
430
465
  searchParams: params,
431
466
  signal
432
467
  }).json();
@@ -436,10 +471,10 @@ function createUniqueCriteriaApi(client) {
436
471
  }
437
472
 
438
473
  // lib/companies/index.ts
439
- var BASE_URL16 = "companys";
474
+ var BASE_URL17 = "companys";
440
475
  function createCompaniesApi(client) {
441
476
  async function getCompanyBriefInfoByOrg(params, signal) {
442
- const data = await client.get(`${BASE_URL16}/brief`, {
477
+ const data = await client.get(`${BASE_URL17}/brief`, {
443
478
  searchParams: params,
444
479
  signal
445
480
  }).json();
@@ -480,6 +515,8 @@ export {
480
515
  BASE_URL14,
481
516
  createErrorsApi,
482
517
  BASE_URL15,
518
+ createErrorsApiV2,
519
+ BASE_URL16,
483
520
  createUniqueCriteriaApi,
484
521
  createCompaniesApi
485
522
  };
@@ -4107,7 +4107,8 @@ var exportSchema = z.object({
4107
4107
  spreadsheetTemplateId: z.optional(z.number()),
4108
4108
  emailAddresses: z.optional(z.array(z.string())),
4109
4109
  subjectLine: z.optional(z.string()),
4110
- additionalLocales: z.optional(z.array(z.string()))
4110
+ additionalLocales: z.optional(z.array(z.string())),
4111
+ availableAttributeList: z.optional(z.array(z.string()))
4111
4112
  });
4112
4113
 
4113
4114
  // lib/exports/models/DownloadItemsParams.ts
@@ -4794,7 +4795,7 @@ var userAccountSchema = z.object({
4794
4795
  attributeRegistryViewer: z.boolean()
4795
4796
  });
4796
4797
 
4797
- // lib/errors/models/ItemErrorDetails.ts
4798
+ // lib/errors/v1/models/ItemErrorDetails.ts
4798
4799
  var itemErrorDetailsSchema = z.object({
4799
4800
  errorMessage: z.string(),
4800
4801
  attributeName: z.string().nullable(),
@@ -4805,7 +4806,7 @@ var itemErrorDetailsSchema = z.object({
4805
4806
  repeatableGroupId: z.string().nullish()
4806
4807
  });
4807
4808
 
4808
- // lib/errors/models/ItemErrorDetailsResult.ts
4809
+ // lib/errors/v1/models/ItemErrorDetailsResult.ts
4809
4810
  var itemErrorDetailsResultSchema = z.object({
4810
4811
  itemInfoId: z.number(),
4811
4812
  upc: z.string().nullish(),
@@ -4817,6 +4818,135 @@ var itemErrorDetailsResultSchema = z.object({
4817
4818
  itemErrorDetails: z.array(itemErrorDetailsSchema)
4818
4819
  });
4819
4820
 
4821
+ // lib/items/v2/models/Stage.ts
4822
+ var stageSchema = z.enum([
4823
+ "CORE",
4824
+ "CORE_PLUS",
4825
+ "CORE_ADVANCED",
4826
+ "ENRICHED"
4827
+ ]);
4828
+
4829
+ // lib/items/v2/models/OrgSummary.ts
4830
+ var orgSummarySchema = z.object({
4831
+ ref: z.string(),
4832
+ id: z.string(),
4833
+ name: z.string()
4834
+ });
4835
+
4836
+ // lib/items/v2/models/ItemOrgStageDetails.ts
4837
+ var itemOrgStageDetailsSchema = z.object({
4838
+ /**
4839
+ * When called as retailer, the vendor, else when vendor, the retailer.
4840
+ * */
4841
+ orgSummary: orgSummarySchema,
4842
+ /**
4843
+ * The company id of the retailer or vendor used for matching ItemOrgStageDetails to TradingPartnerStage for ErrorService
4844
+ */
4845
+ companyId: z.number().nullish(),
4846
+ /**
4847
+ * "Standard Requirements" (null) UNLESS the retailer of the item is MSIS Enabled
4848
+ * OTHERWISE the retailer default Stage UNLESS there's a currently active vendor-specific Stage defined
4849
+ * OTHERWISE the trading partnership Stage UNLESS there's a currently active Item Level override defined
4850
+ * OTHERWISE the item level override */
4851
+ stage: stageSchema.nullish(),
4852
+ /**
4853
+ * If the item is valid for the active stage. Note that for "Standard Requirements" or
4854
+ * "Enriched" this cam come directly from the item_doc table, but anything else requires validation
4855
+ */
4856
+ isValid: z.boolean(),
4857
+ /**
4858
+ * Not null if there's an item level policy override for this trading partnership
4859
+ */
4860
+ itemPolicyId: z.string().nullish(),
4861
+ /**
4862
+ * Start date for the Item level Stage if applicable
4863
+ */
4864
+ startDate: z.number().transform((num) => new Date(num * 1e3)).nullish(),
4865
+ /**
4866
+ * End date for the Item level Stage if applicable
4867
+ */
4868
+ endDate: z.number().transform((num) => new Date(num * 1e3)).nullish()
4869
+ });
4870
+
4871
+ // lib/items/v2/models/ItemStatusV2.ts
4872
+ var itemStatusV2Schema = z.object({
4873
+ itemId: z.string(),
4874
+ mostRestrictiveRetailerStage: stageSchema.nullable(),
4875
+ itemOrgStageDetails: z.array(itemOrgStageDetailsSchema)
4876
+ });
4877
+
4878
+ // lib/items/v2/models/ItemStatusV2Response.ts
4879
+ var itemStatusV2ResponseSchema = z.object({
4880
+ itemStatuses: z.array(itemStatusV2Schema)
4881
+ });
4882
+
4883
+ // lib/errors/v2/models/TradingPartnerStage.ts
4884
+ var tradingPartnerStageV2Schema = z.object({
4885
+ companyId: z.number(),
4886
+ companyName: z.string(),
4887
+ stage: stageSchema.nullish(),
4888
+ isValid: z.boolean()
4889
+ });
4890
+
4891
+ // lib/errors/v2/models/ItemErrorSummary.ts
4892
+ var itemErrorSummaryV2Schema = z.object({
4893
+ itemInfoId: z.number(),
4894
+ upc: z.string().nullish(),
4895
+ isbn: z.string().nullish(),
4896
+ gtin: z.string().nullish(),
4897
+ ean: z.string().nullish(),
4898
+ partnumber: z.string().nullish(),
4899
+ colorfamily: z.string().nullish(),
4900
+ fit: z.string().nullish(),
4901
+ productcolordescription: z.string().nullish(),
4902
+ distributioncentercode: z.string().nullish(),
4903
+ accountnumber: z.string().nullish(),
4904
+ erpid: z.string().nullish(),
4905
+ totalErrors: z.number(),
4906
+ tradingPartners: z.array(z.string()),
4907
+ tradingPartnerIds: z.array(z.number()),
4908
+ // These are the stages assigned to the TradingPartners, not the stages of the errors
4909
+ phases: z.array(z.string()),
4910
+ // Same thing for the stage property in here: it's the stage of the Item & TradingPartner, not the stage of the error
4911
+ tradingPartnerStages: z.array(tradingPartnerStageV2Schema),
4912
+ validatedDate: z.number().pipe(z.coerce.date()).nullish()
4913
+ });
4914
+
4915
+ // lib/errors/v2/models/ItemErrorSummaryResult.ts
4916
+ var itemErrorSummaryResultV2Schema = z.object({
4917
+ hasNext: z.boolean(),
4918
+ errors: z.array(itemErrorSummaryV2Schema)
4919
+ });
4920
+
4921
+ // lib/errors/v2/models/ItemErrorDetails.ts
4922
+ var itemErrorDetailsV2Schema = z.object({
4923
+ errorMessage: z.string(),
4924
+ attributeName: z.string(),
4925
+ attributeDbNames: z.array(z.string()),
4926
+ tradingPartnerNames: z.array(z.string()),
4927
+ phases: z.set(stageSchema),
4928
+ tradingPartnerStages: z.array(tradingPartnerStageV2Schema),
4929
+ repeatableGroupId: z.string()
4930
+ });
4931
+
4932
+ // lib/errors/v2/models/ItemErrorDetailsResult.ts
4933
+ var itemErrorDetailsResultV2Schema = z.object({
4934
+ itemInfoId: z.number(),
4935
+ upc: z.string().nullish(),
4936
+ isbn: z.string().nullish(),
4937
+ gtin: z.string().nullish(),
4938
+ partnumber: z.string().nullish(),
4939
+ ean: z.string().nullish(),
4940
+ colorfamily: z.string().nullish(),
4941
+ fit: z.string().nullish(),
4942
+ productcolordescription: z.string().nullish(),
4943
+ distributioncentercode: z.string().nullish(),
4944
+ accountnumber: z.string().nullish(),
4945
+ erpid: z.string().nullish(),
4946
+ itemName: z.string().nullish(),
4947
+ itemErrorDetails: z.array(itemErrorDetailsV2Schema)
4948
+ });
4949
+
4820
4950
  // lib/companies/models/CompanyBriefByOrg.ts
4821
4951
  var companyBriefByOrgSchema = z.object({
4822
4952
  companyId: z.number(),
@@ -4881,6 +5011,12 @@ export {
4881
5011
  downLoadItemsParamsSchema,
4882
5012
  itemErrorDetailsSchema,
4883
5013
  itemErrorDetailsResultSchema,
5014
+ itemStatusV2ResponseSchema,
5015
+ tradingPartnerStageV2Schema,
5016
+ itemErrorSummaryV2Schema,
5017
+ itemErrorSummaryResultV2Schema,
5018
+ itemErrorDetailsV2Schema,
5019
+ itemErrorDetailsResultV2Schema,
4884
5020
  companyBriefByOrgSchema,
4885
5021
  attributeDetailSchema,
4886
5022
  categoryEnumSchema,
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
- import { A as AsstClient, C as CompanyBriefByOrg } from './CompanyBriefByOrg-HsKxilwl.js';
2
+ import { A as AsstClient, C as CompanyBriefByOrg } from './CompanyBriefByOrg-57oGCtjK.js';
3
3
 
4
4
  declare const retailerTradingPartnerStages: z.ZodArray<z.ZodEnum<["Core", "Core Plus", "Core Advanced", "Enriched", "Standard Requirements"]>, "many">;
5
5
  type RetailerTradingPartnerStages = z.infer<typeof retailerTradingPartnerStages>;