@congminh1254/shopee-sdk 0.9.0 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +178 -36
- package/lib/fetch.js +13 -0
- package/lib/fetch.js.map +1 -1
- package/lib/managers/add-on-deal.manager.d.ts +140 -0
- package/lib/managers/add-on-deal.manager.js +240 -0
- package/lib/managers/add-on-deal.manager.js.map +1 -0
- package/lib/managers/ads.manager.d.ts +217 -1
- package/lib/managers/ads.manager.js +312 -0
- package/lib/managers/ads.manager.js.map +1 -1
- package/lib/managers/bundle-deal.manager.d.ts +106 -0
- package/lib/managers/bundle-deal.manager.js +178 -0
- package/lib/managers/bundle-deal.manager.js.map +1 -0
- package/lib/managers/discount.manager.d.ts +102 -0
- package/lib/managers/discount.manager.js +167 -0
- package/lib/managers/discount.manager.js.map +1 -0
- package/lib/managers/fbs.manager.d.ts +115 -0
- package/lib/managers/fbs.manager.js +145 -0
- package/lib/managers/fbs.manager.js.map +1 -0
- package/lib/managers/first-mile.manager.d.ts +150 -0
- package/lib/managers/first-mile.manager.js +264 -0
- package/lib/managers/first-mile.manager.js.map +1 -0
- package/lib/managers/follow-prize.manager.d.ts +108 -0
- package/lib/managers/follow-prize.manager.js +152 -0
- package/lib/managers/follow-prize.manager.js.map +1 -0
- package/lib/managers/global-product.manager.d.ts +664 -0
- package/lib/managers/global-product.manager.js +904 -0
- package/lib/managers/global-product.manager.js.map +1 -0
- package/lib/managers/index.d.ts +17 -1
- package/lib/managers/index.js +17 -1
- package/lib/managers/index.js.map +1 -1
- package/lib/managers/livestream.manager.d.ts +377 -0
- package/lib/managers/livestream.manager.js +529 -0
- package/lib/managers/livestream.manager.js.map +1 -0
- package/lib/managers/logistics.manager.d.ts +267 -1
- package/lib/managers/logistics.manager.js +544 -0
- package/lib/managers/logistics.manager.js.map +1 -1
- package/lib/managers/media-space.manager.d.ts +179 -0
- package/lib/managers/media-space.manager.js +220 -0
- package/lib/managers/media-space.manager.js.map +1 -0
- package/lib/managers/media.manager.d.ts +226 -0
- package/lib/managers/media.manager.js +274 -0
- package/lib/managers/media.manager.js.map +1 -0
- package/lib/managers/merchant.manager.d.ts +100 -0
- package/lib/managers/merchant.manager.js +144 -0
- package/lib/managers/merchant.manager.js.map +1 -0
- package/lib/managers/order.manager.d.ts +213 -1
- package/lib/managers/order.manager.js +305 -0
- package/lib/managers/order.manager.js.map +1 -1
- package/lib/managers/payment.manager.d.ts +186 -1
- package/lib/managers/payment.manager.js +288 -0
- package/lib/managers/payment.manager.js.map +1 -1
- package/lib/managers/product.manager.d.ts +346 -1
- package/lib/managers/product.manager.js +718 -0
- package/lib/managers/product.manager.js.map +1 -1
- package/lib/managers/returns.manager.d.ts +200 -0
- package/lib/managers/returns.manager.js +300 -0
- package/lib/managers/returns.manager.js.map +1 -0
- package/lib/managers/sbs.manager.d.ts +112 -0
- package/lib/managers/sbs.manager.js +149 -0
- package/lib/managers/sbs.manager.js.map +1 -0
- package/lib/managers/shop-category.manager.d.ts +207 -0
- package/lib/managers/shop-category.manager.js +258 -0
- package/lib/managers/shop-category.manager.js.map +1 -0
- package/lib/managers/shop-flash-sale.manager.d.ts +242 -0
- package/lib/managers/shop-flash-sale.manager.js +321 -0
- package/lib/managers/shop-flash-sale.manager.js.map +1 -0
- package/lib/managers/shop.manager.d.ts +173 -0
- package/lib/managers/shop.manager.js +217 -0
- package/lib/managers/shop.manager.js.map +1 -0
- package/lib/managers/top-picks.manager.d.ts +62 -0
- package/lib/managers/top-picks.manager.js +91 -0
- package/lib/managers/top-picks.manager.js.map +1 -0
- package/lib/schemas/add-on-deal.d.ts +390 -0
- package/lib/schemas/add-on-deal.js +45 -0
- package/lib/schemas/add-on-deal.js.map +1 -0
- package/lib/schemas/ads.d.ts +437 -0
- package/lib/schemas/bundle-deal.d.ts +300 -0
- package/lib/schemas/bundle-deal.js +27 -0
- package/lib/schemas/bundle-deal.js.map +1 -0
- package/lib/schemas/discount.d.ts +334 -0
- package/lib/schemas/discount.js +15 -0
- package/lib/schemas/discount.js.map +1 -0
- package/lib/schemas/fbs.d.ts +117 -0
- package/lib/schemas/fbs.js +2 -0
- package/lib/schemas/fbs.js.map +1 -0
- package/lib/schemas/first-mile.d.ts +551 -0
- package/lib/schemas/first-mile.js +2 -0
- package/lib/schemas/first-mile.js.map +1 -0
- package/lib/schemas/follow-prize.d.ts +198 -0
- package/lib/schemas/follow-prize.js +27 -0
- package/lib/schemas/follow-prize.js.map +1 -0
- package/lib/schemas/global-product.d.ts +1127 -0
- package/lib/schemas/global-product.js +2 -0
- package/lib/schemas/global-product.js.map +1 -0
- package/lib/schemas/index.d.ts +13 -0
- package/lib/schemas/index.js +17 -0
- package/lib/schemas/index.js.map +1 -1
- package/lib/schemas/livestream.d.ts +649 -0
- package/lib/schemas/livestream.js +2 -0
- package/lib/schemas/livestream.js.map +1 -0
- package/lib/schemas/logistics.d.ts +979 -0
- package/lib/schemas/logistics.js +13 -0
- package/lib/schemas/logistics.js.map +1 -1
- package/lib/schemas/media-space.d.ts +189 -0
- package/lib/schemas/media-space.js +2 -0
- package/lib/schemas/media-space.js.map +1 -0
- package/lib/schemas/media.d.ts +230 -0
- package/lib/schemas/media.js +2 -0
- package/lib/schemas/media.js.map +1 -0
- package/lib/schemas/merchant.d.ts +236 -0
- package/lib/schemas/merchant.js +2 -0
- package/lib/schemas/merchant.js.map +1 -0
- package/lib/schemas/order.d.ts +431 -0
- package/lib/schemas/payment.d.ts +397 -0
- package/lib/schemas/product.d.ts +1157 -0
- package/lib/schemas/returns.d.ts +632 -0
- package/lib/schemas/returns.js +63 -0
- package/lib/schemas/returns.js.map +1 -0
- package/lib/schemas/sbs.d.ts +484 -0
- package/lib/schemas/sbs.js +2 -0
- package/lib/schemas/sbs.js.map +1 -0
- package/lib/schemas/shop-category.d.ts +176 -0
- package/lib/schemas/shop-category.js +2 -0
- package/lib/schemas/shop-category.js.map +1 -0
- package/lib/schemas/shop-flash-sale.d.ts +473 -0
- package/lib/schemas/shop-flash-sale.js +43 -0
- package/lib/schemas/shop-flash-sale.js.map +1 -0
- package/lib/schemas/shop.d.ts +250 -0
- package/lib/schemas/shop.js +2 -0
- package/lib/schemas/shop.js.map +1 -0
- package/lib/schemas/top-picks.d.ts +99 -0
- package/lib/schemas/top-picks.js +2 -0
- package/lib/schemas/top-picks.js.map +1 -0
- package/lib/sdk.d.ts +34 -0
- package/lib/sdk.js +34 -0
- package/lib/sdk.js.map +1 -1
- package/package.json +7 -4
|
@@ -0,0 +1,1127 @@
|
|
|
1
|
+
import { FetchResponse } from "./fetch.js";
|
|
2
|
+
import { BaseResponse } from "./base.js";
|
|
3
|
+
import { Attribute } from "./attribute.js";
|
|
4
|
+
/**
|
|
5
|
+
* Global category information
|
|
6
|
+
*/
|
|
7
|
+
export interface GlobalCategory {
|
|
8
|
+
/** ID for category */
|
|
9
|
+
category_id: number;
|
|
10
|
+
/** ID for parent category */
|
|
11
|
+
parent_category_id: number;
|
|
12
|
+
/** English category name */
|
|
13
|
+
original_category_name: string;
|
|
14
|
+
/** Display category name based on selected language */
|
|
15
|
+
display_category_name: string;
|
|
16
|
+
/** Whether this category has active children category */
|
|
17
|
+
has_children: boolean;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Parameters for getting global category list
|
|
21
|
+
*/
|
|
22
|
+
export type GetGlobalCategoryParams = {
|
|
23
|
+
/** Language for category names. Should be one of "zh-hans", "en" */
|
|
24
|
+
language?: string;
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
* Response for getting global category list
|
|
28
|
+
*/
|
|
29
|
+
export interface GetGlobalCategoryResponse extends FetchResponse<{
|
|
30
|
+
/** List of categories */
|
|
31
|
+
category_list: GlobalCategory[];
|
|
32
|
+
}> {
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Parameters for getting global item list
|
|
36
|
+
*/
|
|
37
|
+
export type GetGlobalItemListParams = {
|
|
38
|
+
/** Specifies the starting entry of data to return. If data is more than one page, offset can be used for next call */
|
|
39
|
+
offset?: string;
|
|
40
|
+
/** The size of one page. Limit is [1,50] */
|
|
41
|
+
page_size: number;
|
|
42
|
+
/** The starting date range for retrieving items (based on item update time) */
|
|
43
|
+
update_time_from?: number;
|
|
44
|
+
/** The ending date range for retrieving items (based on item update time) */
|
|
45
|
+
update_time_to?: number;
|
|
46
|
+
};
|
|
47
|
+
/**
|
|
48
|
+
* Global item in list
|
|
49
|
+
*/
|
|
50
|
+
export interface GlobalItemListItem {
|
|
51
|
+
/** Shopee's unique identifier for a global item */
|
|
52
|
+
global_item_id: number;
|
|
53
|
+
/** Timestamp that indicates the last time there was a change in value of the item */
|
|
54
|
+
update_time: number;
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Response for getting global item list
|
|
58
|
+
*/
|
|
59
|
+
export interface GetGlobalItemListResponse extends FetchResponse<{
|
|
60
|
+
/** List of global items */
|
|
61
|
+
global_item_list: GlobalItemListItem[];
|
|
62
|
+
/** Total global item count */
|
|
63
|
+
total_count: number;
|
|
64
|
+
/** Whether the item list is more than one page */
|
|
65
|
+
has_next_page: boolean;
|
|
66
|
+
/** Next page offset if has_next_page is true */
|
|
67
|
+
offset?: string;
|
|
68
|
+
}> {
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Global item attribute
|
|
72
|
+
*/
|
|
73
|
+
export interface GlobalItemAttribute {
|
|
74
|
+
/** Attribute ID */
|
|
75
|
+
attribute_id: number;
|
|
76
|
+
/** List of attribute values */
|
|
77
|
+
attribute_value_list: {
|
|
78
|
+
/** Attribute value ID */
|
|
79
|
+
value_id?: number;
|
|
80
|
+
/** Original attribute value name */
|
|
81
|
+
original_value_name?: string;
|
|
82
|
+
/** Value unit */
|
|
83
|
+
value_unit?: string;
|
|
84
|
+
}[];
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* Global item image
|
|
88
|
+
*/
|
|
89
|
+
export interface GlobalItemImage {
|
|
90
|
+
/** List of image URLs */
|
|
91
|
+
image_url_list: string[];
|
|
92
|
+
/** List of image IDs */
|
|
93
|
+
image_id_list: string[];
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* Global item video info
|
|
97
|
+
*/
|
|
98
|
+
export interface GlobalItemVideoInfo {
|
|
99
|
+
/** List of video URLs */
|
|
100
|
+
video_url_list: string[];
|
|
101
|
+
/** List of thumbnail URLs */
|
|
102
|
+
thumbnail_url_list: string[];
|
|
103
|
+
/** Video duration */
|
|
104
|
+
duration: number;
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* Global item price info
|
|
108
|
+
*/
|
|
109
|
+
export interface GlobalItemPriceInfo {
|
|
110
|
+
/** Currency used for the price */
|
|
111
|
+
currency: string;
|
|
112
|
+
/** Original price of the item */
|
|
113
|
+
original_price: number;
|
|
114
|
+
/** Current price of the item */
|
|
115
|
+
current_price: number;
|
|
116
|
+
}
|
|
117
|
+
/**
|
|
118
|
+
* Global item stock info
|
|
119
|
+
*/
|
|
120
|
+
export interface GlobalItemStockInfo {
|
|
121
|
+
/** Stock type: 1-shop stock, 2-shopee stock */
|
|
122
|
+
stock_type: number;
|
|
123
|
+
/** Current stock */
|
|
124
|
+
current_stock: number;
|
|
125
|
+
/** Normal stock */
|
|
126
|
+
normal_stock: number;
|
|
127
|
+
/** Reserved stock */
|
|
128
|
+
reserved_stock: number;
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Global item dimension
|
|
132
|
+
*/
|
|
133
|
+
export interface GlobalItemDimension {
|
|
134
|
+
/** Package length in CM */
|
|
135
|
+
package_length: number;
|
|
136
|
+
/** Package width in CM */
|
|
137
|
+
package_width: number;
|
|
138
|
+
/** Package height in CM */
|
|
139
|
+
package_height: number;
|
|
140
|
+
}
|
|
141
|
+
/**
|
|
142
|
+
* Global item pre-order info
|
|
143
|
+
*/
|
|
144
|
+
export interface GlobalItemPreOrder {
|
|
145
|
+
/** Whether the item is pre-order */
|
|
146
|
+
is_pre_order: boolean;
|
|
147
|
+
/** Days to ship */
|
|
148
|
+
days_to_ship: number;
|
|
149
|
+
}
|
|
150
|
+
/**
|
|
151
|
+
* Global item brand info
|
|
152
|
+
*/
|
|
153
|
+
export interface GlobalItemBrand {
|
|
154
|
+
/** Brand ID */
|
|
155
|
+
brand_id: number;
|
|
156
|
+
/** Original brand name */
|
|
157
|
+
original_brand_name: string;
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* Global item description info
|
|
161
|
+
*/
|
|
162
|
+
export interface GlobalItemDescriptionInfo {
|
|
163
|
+
/** Extended description details */
|
|
164
|
+
extended_description?: {
|
|
165
|
+
/** List of description fields */
|
|
166
|
+
field_list: {
|
|
167
|
+
/** Field type */
|
|
168
|
+
field_type: string;
|
|
169
|
+
/** Text content */
|
|
170
|
+
text?: string;
|
|
171
|
+
/** Image info */
|
|
172
|
+
image_info?: {
|
|
173
|
+
/** Image ID */
|
|
174
|
+
image_id: string;
|
|
175
|
+
/** Image URL */
|
|
176
|
+
image_url: string;
|
|
177
|
+
};
|
|
178
|
+
}[];
|
|
179
|
+
};
|
|
180
|
+
}
|
|
181
|
+
/**
|
|
182
|
+
* Global item complete information
|
|
183
|
+
*/
|
|
184
|
+
export interface GlobalItemInfo {
|
|
185
|
+
/** Shopee's unique identifier for a global item */
|
|
186
|
+
global_item_id: number;
|
|
187
|
+
/** Category ID */
|
|
188
|
+
category_id: number;
|
|
189
|
+
/** Global item name */
|
|
190
|
+
global_item_name: string;
|
|
191
|
+
/** Global item description */
|
|
192
|
+
description: string;
|
|
193
|
+
/** Global item SKU */
|
|
194
|
+
global_item_sku?: string;
|
|
195
|
+
/** Item weight in KG */
|
|
196
|
+
weight?: number;
|
|
197
|
+
/** Package dimension */
|
|
198
|
+
dimension?: GlobalItemDimension;
|
|
199
|
+
/** Image information */
|
|
200
|
+
image: GlobalItemImage;
|
|
201
|
+
/** Video information */
|
|
202
|
+
video_info?: GlobalItemVideoInfo;
|
|
203
|
+
/** Price information */
|
|
204
|
+
price_info: GlobalItemPriceInfo[];
|
|
205
|
+
/** Stock information */
|
|
206
|
+
stock_info: GlobalItemStockInfo[];
|
|
207
|
+
/** Attribute list */
|
|
208
|
+
attribute_list: GlobalItemAttribute[];
|
|
209
|
+
/** Pre-order info */
|
|
210
|
+
pre_order?: GlobalItemPreOrder;
|
|
211
|
+
/** Brand info */
|
|
212
|
+
brand?: GlobalItemBrand;
|
|
213
|
+
/** Item status: NORMAL, DELETED, BANNED, UNLIST */
|
|
214
|
+
item_status: string;
|
|
215
|
+
/** Whether item has model */
|
|
216
|
+
has_model: boolean;
|
|
217
|
+
/** Create time */
|
|
218
|
+
create_time: number;
|
|
219
|
+
/** Update time */
|
|
220
|
+
update_time: number;
|
|
221
|
+
/** Condition: NEW, USED */
|
|
222
|
+
condition?: string;
|
|
223
|
+
/** GTIN code */
|
|
224
|
+
gtin_code?: string;
|
|
225
|
+
/** Description type: normal, extended */
|
|
226
|
+
description_type?: string;
|
|
227
|
+
/** Description info for extended descriptions */
|
|
228
|
+
description_info?: GlobalItemDescriptionInfo;
|
|
229
|
+
}
|
|
230
|
+
/**
|
|
231
|
+
* Parameters for getting global item info
|
|
232
|
+
*/
|
|
233
|
+
export type GetGlobalItemInfoParams = {
|
|
234
|
+
/** List of global item IDs to retrieve (max 50) */
|
|
235
|
+
global_item_id_list: number[];
|
|
236
|
+
};
|
|
237
|
+
/**
|
|
238
|
+
* Response for getting global item info
|
|
239
|
+
*/
|
|
240
|
+
export interface GetGlobalItemInfoResponse extends FetchResponse<{
|
|
241
|
+
/** List of global item info */
|
|
242
|
+
global_item_list: GlobalItemInfo[];
|
|
243
|
+
}> {
|
|
244
|
+
}
|
|
245
|
+
/**
|
|
246
|
+
* Global model information
|
|
247
|
+
*/
|
|
248
|
+
export interface GlobalModel {
|
|
249
|
+
/** Global model ID */
|
|
250
|
+
global_model_id: number;
|
|
251
|
+
/** Tier index list */
|
|
252
|
+
tier_index: number[];
|
|
253
|
+
/** Model SKU */
|
|
254
|
+
model_sku?: string;
|
|
255
|
+
/** Price info per region */
|
|
256
|
+
price_info: GlobalItemPriceInfo[];
|
|
257
|
+
/** Stock info */
|
|
258
|
+
stock_info: GlobalItemStockInfo[];
|
|
259
|
+
/** Model image */
|
|
260
|
+
image?: {
|
|
261
|
+
/** Image ID */
|
|
262
|
+
image_id: string;
|
|
263
|
+
/** Image URL */
|
|
264
|
+
image_url: string;
|
|
265
|
+
};
|
|
266
|
+
/** Create time */
|
|
267
|
+
create_time: number;
|
|
268
|
+
/** Update time */
|
|
269
|
+
update_time: number;
|
|
270
|
+
}
|
|
271
|
+
/**
|
|
272
|
+
* Global tier variation
|
|
273
|
+
*/
|
|
274
|
+
export interface GlobalTierVariation {
|
|
275
|
+
/** Tier variation name */
|
|
276
|
+
name: string;
|
|
277
|
+
/** List of options */
|
|
278
|
+
option_list: {
|
|
279
|
+
/** Option name */
|
|
280
|
+
option: string;
|
|
281
|
+
/** Option image */
|
|
282
|
+
image?: {
|
|
283
|
+
/** Image ID */
|
|
284
|
+
image_id: string;
|
|
285
|
+
/** Image URL */
|
|
286
|
+
image_url: string;
|
|
287
|
+
};
|
|
288
|
+
}[];
|
|
289
|
+
}
|
|
290
|
+
/**
|
|
291
|
+
* Parameters for getting global model list
|
|
292
|
+
*/
|
|
293
|
+
export type GetGlobalModelListParams = {
|
|
294
|
+
/** Global item ID */
|
|
295
|
+
global_item_id: number;
|
|
296
|
+
};
|
|
297
|
+
/**
|
|
298
|
+
* Response for getting global model list
|
|
299
|
+
*/
|
|
300
|
+
export interface GetGlobalModelListResponse extends FetchResponse<{
|
|
301
|
+
/** Tier variation list */
|
|
302
|
+
tier_variation: GlobalTierVariation[];
|
|
303
|
+
/** Global model list */
|
|
304
|
+
global_model: GlobalModel[];
|
|
305
|
+
}> {
|
|
306
|
+
}
|
|
307
|
+
/**
|
|
308
|
+
* Parameters for adding a global item
|
|
309
|
+
*/
|
|
310
|
+
export type AddGlobalItemParams = {
|
|
311
|
+
/** Category ID */
|
|
312
|
+
category_id: number;
|
|
313
|
+
/** Global item name */
|
|
314
|
+
global_item_name: string;
|
|
315
|
+
/** Item description */
|
|
316
|
+
description: string;
|
|
317
|
+
/** Global item SKU */
|
|
318
|
+
global_item_sku?: string;
|
|
319
|
+
/** Item weight in KG */
|
|
320
|
+
weight?: number;
|
|
321
|
+
/** Package dimension */
|
|
322
|
+
dimension?: GlobalItemDimension;
|
|
323
|
+
/** Image information */
|
|
324
|
+
image: {
|
|
325
|
+
/** List of image IDs */
|
|
326
|
+
image_id_list: string[];
|
|
327
|
+
};
|
|
328
|
+
/** Video information */
|
|
329
|
+
video_info?: {
|
|
330
|
+
/** List of video IDs */
|
|
331
|
+
video_id_list: string[];
|
|
332
|
+
};
|
|
333
|
+
/** Attribute list */
|
|
334
|
+
attribute_list?: GlobalItemAttribute[];
|
|
335
|
+
/** Brand info */
|
|
336
|
+
brand?: {
|
|
337
|
+
/** Brand ID */
|
|
338
|
+
brand_id: number;
|
|
339
|
+
};
|
|
340
|
+
/** Condition: NEW, USED */
|
|
341
|
+
condition?: string;
|
|
342
|
+
/** GTIN code */
|
|
343
|
+
gtin_code?: string;
|
|
344
|
+
/** Description type: normal, extended */
|
|
345
|
+
description_type?: string;
|
|
346
|
+
/** Description info for extended descriptions */
|
|
347
|
+
description_info?: GlobalItemDescriptionInfo;
|
|
348
|
+
};
|
|
349
|
+
/**
|
|
350
|
+
* Response for adding a global item
|
|
351
|
+
*/
|
|
352
|
+
export interface AddGlobalItemResponse extends FetchResponse<{
|
|
353
|
+
/** Created global item ID */
|
|
354
|
+
global_item_id: number;
|
|
355
|
+
}> {
|
|
356
|
+
}
|
|
357
|
+
/**
|
|
358
|
+
* Parameters for updating a global item
|
|
359
|
+
*/
|
|
360
|
+
export type UpdateGlobalItemParams = {
|
|
361
|
+
/** Global item ID */
|
|
362
|
+
global_item_id: number;
|
|
363
|
+
/** Category ID */
|
|
364
|
+
category_id?: number;
|
|
365
|
+
/** Global item name */
|
|
366
|
+
global_item_name?: string;
|
|
367
|
+
/** Item description */
|
|
368
|
+
description?: string;
|
|
369
|
+
/** Global item SKU */
|
|
370
|
+
global_item_sku?: string;
|
|
371
|
+
/** Item weight in KG */
|
|
372
|
+
weight?: number;
|
|
373
|
+
/** Package dimension */
|
|
374
|
+
dimension?: GlobalItemDimension;
|
|
375
|
+
/** Image information */
|
|
376
|
+
image?: {
|
|
377
|
+
/** List of image IDs */
|
|
378
|
+
image_id_list: string[];
|
|
379
|
+
};
|
|
380
|
+
/** Video information */
|
|
381
|
+
video_info?: {
|
|
382
|
+
/** List of video IDs */
|
|
383
|
+
video_id_list: string[];
|
|
384
|
+
};
|
|
385
|
+
/** Attribute list */
|
|
386
|
+
attribute_list?: GlobalItemAttribute[];
|
|
387
|
+
/** Brand info */
|
|
388
|
+
brand?: {
|
|
389
|
+
/** Brand ID */
|
|
390
|
+
brand_id: number;
|
|
391
|
+
};
|
|
392
|
+
/** Condition: NEW, USED */
|
|
393
|
+
condition?: string;
|
|
394
|
+
/** GTIN code */
|
|
395
|
+
gtin_code?: string;
|
|
396
|
+
/** Description type: normal, extended */
|
|
397
|
+
description_type?: string;
|
|
398
|
+
/** Description info for extended descriptions */
|
|
399
|
+
description_info?: GlobalItemDescriptionInfo;
|
|
400
|
+
};
|
|
401
|
+
/**
|
|
402
|
+
* Response for updating a global item
|
|
403
|
+
*/
|
|
404
|
+
export interface UpdateGlobalItemResponse extends FetchResponse<{
|
|
405
|
+
/** Updated global item ID */
|
|
406
|
+
global_item_id: number;
|
|
407
|
+
}> {
|
|
408
|
+
}
|
|
409
|
+
/**
|
|
410
|
+
* Parameters for deleting a global item
|
|
411
|
+
*/
|
|
412
|
+
export type DeleteGlobalItemParams = {
|
|
413
|
+
/** Global item ID */
|
|
414
|
+
global_item_id: number;
|
|
415
|
+
};
|
|
416
|
+
/**
|
|
417
|
+
* Response for deleting a global item
|
|
418
|
+
*/
|
|
419
|
+
export interface DeleteGlobalItemResponse extends BaseResponse {
|
|
420
|
+
}
|
|
421
|
+
/**
|
|
422
|
+
* Parameters for adding a global model
|
|
423
|
+
*/
|
|
424
|
+
export type AddGlobalModelParams = {
|
|
425
|
+
/** Global item ID */
|
|
426
|
+
global_item_id: number;
|
|
427
|
+
/** Model list to add */
|
|
428
|
+
model_list: {
|
|
429
|
+
/** Tier index */
|
|
430
|
+
tier_index: number[];
|
|
431
|
+
/** Model SKU */
|
|
432
|
+
model_sku?: string;
|
|
433
|
+
/** Model image */
|
|
434
|
+
image?: {
|
|
435
|
+
/** Image ID */
|
|
436
|
+
image_id: string;
|
|
437
|
+
};
|
|
438
|
+
}[];
|
|
439
|
+
};
|
|
440
|
+
/**
|
|
441
|
+
* Response for adding a global model
|
|
442
|
+
*/
|
|
443
|
+
export interface AddGlobalModelResponse extends FetchResponse<{
|
|
444
|
+
/** List of added model results */
|
|
445
|
+
model_list: {
|
|
446
|
+
/** Global model ID */
|
|
447
|
+
global_model_id: number;
|
|
448
|
+
/** Tier index */
|
|
449
|
+
tier_index: number[];
|
|
450
|
+
}[];
|
|
451
|
+
}> {
|
|
452
|
+
}
|
|
453
|
+
/**
|
|
454
|
+
* Parameters for updating a global model
|
|
455
|
+
*/
|
|
456
|
+
export type UpdateGlobalModelParams = {
|
|
457
|
+
/** Global item ID */
|
|
458
|
+
global_item_id: number;
|
|
459
|
+
/** Model list to update */
|
|
460
|
+
model_list: {
|
|
461
|
+
/** Global model ID */
|
|
462
|
+
global_model_id: number;
|
|
463
|
+
/** Model SKU */
|
|
464
|
+
model_sku?: string;
|
|
465
|
+
/** Model image */
|
|
466
|
+
image?: {
|
|
467
|
+
/** Image ID */
|
|
468
|
+
image_id: string;
|
|
469
|
+
};
|
|
470
|
+
}[];
|
|
471
|
+
};
|
|
472
|
+
/**
|
|
473
|
+
* Response for updating a global model
|
|
474
|
+
*/
|
|
475
|
+
export interface UpdateGlobalModelResponse extends FetchResponse<{
|
|
476
|
+
/** List of updated model results */
|
|
477
|
+
model_list: {
|
|
478
|
+
/** Global model ID */
|
|
479
|
+
global_model_id: number;
|
|
480
|
+
}[];
|
|
481
|
+
}> {
|
|
482
|
+
}
|
|
483
|
+
/**
|
|
484
|
+
* Parameters for deleting a global model
|
|
485
|
+
*/
|
|
486
|
+
export type DeleteGlobalModelParams = {
|
|
487
|
+
/** Global item ID */
|
|
488
|
+
global_item_id: number;
|
|
489
|
+
/** List of global model IDs to delete */
|
|
490
|
+
global_model_id_list: number[];
|
|
491
|
+
};
|
|
492
|
+
/**
|
|
493
|
+
* Response for deleting a global model
|
|
494
|
+
*/
|
|
495
|
+
export interface DeleteGlobalModelResponse extends FetchResponse<{
|
|
496
|
+
/** List of deleted model results */
|
|
497
|
+
model_list: {
|
|
498
|
+
/** Global model ID */
|
|
499
|
+
global_model_id: number;
|
|
500
|
+
/** Success status */
|
|
501
|
+
success: boolean;
|
|
502
|
+
}[];
|
|
503
|
+
}> {
|
|
504
|
+
}
|
|
505
|
+
/**
|
|
506
|
+
* Parameters for initializing tier variation
|
|
507
|
+
*/
|
|
508
|
+
export type InitGlobalTierVariationParams = {
|
|
509
|
+
/** Global item ID */
|
|
510
|
+
global_item_id: number;
|
|
511
|
+
/** Tier variation list (max 2 tiers) */
|
|
512
|
+
tier_variation: {
|
|
513
|
+
/** Tier variation name */
|
|
514
|
+
name: string;
|
|
515
|
+
/** List of options */
|
|
516
|
+
option_list: {
|
|
517
|
+
/** Option name */
|
|
518
|
+
option: string;
|
|
519
|
+
/** Option image */
|
|
520
|
+
image?: {
|
|
521
|
+
/** Image ID */
|
|
522
|
+
image_id: string;
|
|
523
|
+
};
|
|
524
|
+
}[];
|
|
525
|
+
}[];
|
|
526
|
+
/** Model list */
|
|
527
|
+
model_list: {
|
|
528
|
+
/** Tier index */
|
|
529
|
+
tier_index: number[];
|
|
530
|
+
/** Model SKU */
|
|
531
|
+
model_sku?: string;
|
|
532
|
+
/** Model image */
|
|
533
|
+
image?: {
|
|
534
|
+
/** Image ID */
|
|
535
|
+
image_id: string;
|
|
536
|
+
};
|
|
537
|
+
}[];
|
|
538
|
+
};
|
|
539
|
+
/**
|
|
540
|
+
* Response for initializing tier variation
|
|
541
|
+
*/
|
|
542
|
+
export interface InitGlobalTierVariationResponse extends FetchResponse<{
|
|
543
|
+
/** List of created models */
|
|
544
|
+
model_list: {
|
|
545
|
+
/** Global model ID */
|
|
546
|
+
global_model_id: number;
|
|
547
|
+
/** Tier index */
|
|
548
|
+
tier_index: number[];
|
|
549
|
+
}[];
|
|
550
|
+
}> {
|
|
551
|
+
}
|
|
552
|
+
/**
|
|
553
|
+
* Parameters for updating tier variation
|
|
554
|
+
*/
|
|
555
|
+
export type UpdateGlobalTierVariationParams = {
|
|
556
|
+
/** Global item ID */
|
|
557
|
+
global_item_id: number;
|
|
558
|
+
/** Tier variation list */
|
|
559
|
+
tier_variation: {
|
|
560
|
+
/** Tier variation name */
|
|
561
|
+
name: string;
|
|
562
|
+
/** List of options */
|
|
563
|
+
option_list: {
|
|
564
|
+
/** Option name */
|
|
565
|
+
option: string;
|
|
566
|
+
/** Option image */
|
|
567
|
+
image?: {
|
|
568
|
+
/** Image ID */
|
|
569
|
+
image_id: string;
|
|
570
|
+
};
|
|
571
|
+
}[];
|
|
572
|
+
}[];
|
|
573
|
+
};
|
|
574
|
+
/**
|
|
575
|
+
* Response for updating tier variation
|
|
576
|
+
*/
|
|
577
|
+
export interface UpdateGlobalTierVariationResponse extends BaseResponse {
|
|
578
|
+
}
|
|
579
|
+
/**
|
|
580
|
+
* Parameters for updating global item stock
|
|
581
|
+
*/
|
|
582
|
+
export type UpdateGlobalStockParams = {
|
|
583
|
+
/** Global item ID */
|
|
584
|
+
global_item_id: number;
|
|
585
|
+
/** Stock list to update */
|
|
586
|
+
stock_list: {
|
|
587
|
+
/** Global model ID. If not provided, update item-level stock */
|
|
588
|
+
global_model_id?: number;
|
|
589
|
+
/** Shop ID */
|
|
590
|
+
shop_id: number;
|
|
591
|
+
/** Normal stock */
|
|
592
|
+
normal_stock: number;
|
|
593
|
+
}[];
|
|
594
|
+
};
|
|
595
|
+
/**
|
|
596
|
+
* Response for updating global item stock
|
|
597
|
+
*/
|
|
598
|
+
export interface UpdateGlobalStockResponse extends FetchResponse<{
|
|
599
|
+
/** List of stock update results */
|
|
600
|
+
result_list: {
|
|
601
|
+
/** Shop ID */
|
|
602
|
+
shop_id: number;
|
|
603
|
+
/** Global model ID */
|
|
604
|
+
global_model_id?: number;
|
|
605
|
+
/** Success status */
|
|
606
|
+
success: boolean;
|
|
607
|
+
/** Error message if failed */
|
|
608
|
+
error_description?: string;
|
|
609
|
+
}[];
|
|
610
|
+
}> {
|
|
611
|
+
}
|
|
612
|
+
/**
|
|
613
|
+
* Parameters for updating global item price
|
|
614
|
+
*/
|
|
615
|
+
export type UpdateGlobalPriceParams = {
|
|
616
|
+
/** Global item ID */
|
|
617
|
+
global_item_id: number;
|
|
618
|
+
/** Price list to update */
|
|
619
|
+
price_list: {
|
|
620
|
+
/** Global model ID. If not provided, update item-level price */
|
|
621
|
+
global_model_id?: number;
|
|
622
|
+
/** Shop ID */
|
|
623
|
+
shop_id: number;
|
|
624
|
+
/** Original price */
|
|
625
|
+
original_price: number;
|
|
626
|
+
}[];
|
|
627
|
+
};
|
|
628
|
+
/**
|
|
629
|
+
* Response for updating global item price
|
|
630
|
+
*/
|
|
631
|
+
export interface UpdateGlobalPriceResponse extends FetchResponse<{
|
|
632
|
+
/** List of price update results */
|
|
633
|
+
result_list: {
|
|
634
|
+
/** Shop ID */
|
|
635
|
+
shop_id: number;
|
|
636
|
+
/** Global model ID */
|
|
637
|
+
global_model_id?: number;
|
|
638
|
+
/** Success status */
|
|
639
|
+
success: boolean;
|
|
640
|
+
/** Error message if failed */
|
|
641
|
+
error_description?: string;
|
|
642
|
+
}[];
|
|
643
|
+
}> {
|
|
644
|
+
}
|
|
645
|
+
/**
|
|
646
|
+
* Parameters for getting attribute tree
|
|
647
|
+
*/
|
|
648
|
+
export type GetGlobalAttributeTreeParams = {
|
|
649
|
+
/** Category ID */
|
|
650
|
+
category_id: number;
|
|
651
|
+
/** Language for attribute names */
|
|
652
|
+
language?: string;
|
|
653
|
+
};
|
|
654
|
+
/**
|
|
655
|
+
* Response for getting attribute tree
|
|
656
|
+
*/
|
|
657
|
+
export interface GetGlobalAttributeTreeResponse extends FetchResponse<{
|
|
658
|
+
/** List of attributes */
|
|
659
|
+
attribute_list: Attribute[];
|
|
660
|
+
}> {
|
|
661
|
+
}
|
|
662
|
+
/**
|
|
663
|
+
* Brand information
|
|
664
|
+
*/
|
|
665
|
+
export interface Brand {
|
|
666
|
+
/** Brand ID */
|
|
667
|
+
brand_id: number;
|
|
668
|
+
/** Original brand name */
|
|
669
|
+
original_brand_name: string;
|
|
670
|
+
/** Display brand name */
|
|
671
|
+
display_brand_name: string;
|
|
672
|
+
}
|
|
673
|
+
/**
|
|
674
|
+
* Parameters for getting brand list
|
|
675
|
+
*/
|
|
676
|
+
export type GetGlobalBrandListParams = {
|
|
677
|
+
/** Category ID */
|
|
678
|
+
category_id: number;
|
|
679
|
+
/** Offset for pagination */
|
|
680
|
+
offset?: number;
|
|
681
|
+
/** Page size (max 100) */
|
|
682
|
+
page_size: number;
|
|
683
|
+
/** Status: 1-normal, 2-pending */
|
|
684
|
+
status?: number;
|
|
685
|
+
/** Language for brand names */
|
|
686
|
+
language?: string;
|
|
687
|
+
};
|
|
688
|
+
/**
|
|
689
|
+
* Response for getting brand list
|
|
690
|
+
*/
|
|
691
|
+
export interface GetGlobalBrandListResponse extends FetchResponse<{
|
|
692
|
+
/** List of brands */
|
|
693
|
+
brand_list: Brand[];
|
|
694
|
+
/** Whether there are more pages */
|
|
695
|
+
has_next_page: boolean;
|
|
696
|
+
/** Next page offset */
|
|
697
|
+
next_offset: number;
|
|
698
|
+
/** Total brand count */
|
|
699
|
+
total_count: number;
|
|
700
|
+
}> {
|
|
701
|
+
}
|
|
702
|
+
/**
|
|
703
|
+
* Parameters for category recommendation
|
|
704
|
+
*/
|
|
705
|
+
export type GlobalCategoryRecommendParams = {
|
|
706
|
+
/** Global item name */
|
|
707
|
+
global_item_name: string;
|
|
708
|
+
};
|
|
709
|
+
/**
|
|
710
|
+
* Response for category recommendation
|
|
711
|
+
*/
|
|
712
|
+
export interface GlobalCategoryRecommendResponse extends FetchResponse<{
|
|
713
|
+
/** List of recommended categories */
|
|
714
|
+
category_id_list: number[];
|
|
715
|
+
}> {
|
|
716
|
+
}
|
|
717
|
+
/**
|
|
718
|
+
* Parameters for getting global item limit
|
|
719
|
+
*/
|
|
720
|
+
export type GetGlobalItemLimitParams = {
|
|
721
|
+
/** Category ID */
|
|
722
|
+
category_id: number;
|
|
723
|
+
};
|
|
724
|
+
/**
|
|
725
|
+
* Global item limit info
|
|
726
|
+
*/
|
|
727
|
+
export interface GlobalItemLimit {
|
|
728
|
+
/** Maximum image count */
|
|
729
|
+
max_image_count: number;
|
|
730
|
+
/** Maximum video count */
|
|
731
|
+
max_video_count: number;
|
|
732
|
+
/** Maximum name length */
|
|
733
|
+
max_name_length: number;
|
|
734
|
+
/** Maximum description length */
|
|
735
|
+
max_description_length: number;
|
|
736
|
+
/** Whether video is supported */
|
|
737
|
+
support_video: boolean;
|
|
738
|
+
/** Whether size chart is supported */
|
|
739
|
+
support_size_chart: boolean;
|
|
740
|
+
}
|
|
741
|
+
/**
|
|
742
|
+
* Response for getting global item limit
|
|
743
|
+
*/
|
|
744
|
+
export interface GetGlobalItemLimitResponse extends FetchResponse<{
|
|
745
|
+
/** Limit information */
|
|
746
|
+
limit_info: GlobalItemLimit;
|
|
747
|
+
}> {
|
|
748
|
+
}
|
|
749
|
+
/**
|
|
750
|
+
* Shop info for publishing
|
|
751
|
+
*/
|
|
752
|
+
export interface PublishableShop {
|
|
753
|
+
/** Shop ID */
|
|
754
|
+
shop_id: number;
|
|
755
|
+
/** Shop name */
|
|
756
|
+
shop_name: string;
|
|
757
|
+
/** Shop region */
|
|
758
|
+
region: string;
|
|
759
|
+
}
|
|
760
|
+
/**
|
|
761
|
+
* Parameters for getting publishable shop list
|
|
762
|
+
*/
|
|
763
|
+
export type GetPublishableShopParams = {
|
|
764
|
+
/** Global item ID */
|
|
765
|
+
global_item_id: number;
|
|
766
|
+
};
|
|
767
|
+
/**
|
|
768
|
+
* Response for getting publishable shop list
|
|
769
|
+
*/
|
|
770
|
+
export interface GetPublishableShopResponse extends FetchResponse<{
|
|
771
|
+
/** List of publishable shops */
|
|
772
|
+
shop_list: PublishableShop[];
|
|
773
|
+
}> {
|
|
774
|
+
}
|
|
775
|
+
/**
|
|
776
|
+
* Parameters for getting shop publishable status
|
|
777
|
+
*/
|
|
778
|
+
export type GetShopPublishableStatusParams = {
|
|
779
|
+
/** Global item ID */
|
|
780
|
+
global_item_id: number;
|
|
781
|
+
/** List of shop IDs to check */
|
|
782
|
+
shop_id_list: number[];
|
|
783
|
+
};
|
|
784
|
+
/**
|
|
785
|
+
* Response for getting shop publishable status
|
|
786
|
+
*/
|
|
787
|
+
export interface GetShopPublishableStatusResponse extends FetchResponse<{
|
|
788
|
+
/** List of shop status */
|
|
789
|
+
shop_list: {
|
|
790
|
+
/** Shop ID */
|
|
791
|
+
shop_id: number;
|
|
792
|
+
/** Whether the shop is publishable */
|
|
793
|
+
publishable: boolean;
|
|
794
|
+
/** Reason if not publishable */
|
|
795
|
+
reason?: string;
|
|
796
|
+
}[];
|
|
797
|
+
}> {
|
|
798
|
+
}
|
|
799
|
+
/**
|
|
800
|
+
* Parameters for creating publish task
|
|
801
|
+
*/
|
|
802
|
+
export type CreatePublishTaskParams = {
|
|
803
|
+
/** Global item ID */
|
|
804
|
+
global_item_id: number;
|
|
805
|
+
/** List of shops to publish to */
|
|
806
|
+
shop_list: {
|
|
807
|
+
/** Shop ID */
|
|
808
|
+
shop_id: number;
|
|
809
|
+
}[];
|
|
810
|
+
};
|
|
811
|
+
/**
|
|
812
|
+
* Response for creating publish task
|
|
813
|
+
*/
|
|
814
|
+
export interface CreatePublishTaskResponse extends FetchResponse<{
|
|
815
|
+
/** Publish task ID */
|
|
816
|
+
publish_task_id: string;
|
|
817
|
+
}> {
|
|
818
|
+
}
|
|
819
|
+
/**
|
|
820
|
+
* Parameters for getting publish task result
|
|
821
|
+
*/
|
|
822
|
+
export type GetPublishTaskResultParams = {
|
|
823
|
+
/** Publish task ID */
|
|
824
|
+
publish_task_id: string;
|
|
825
|
+
};
|
|
826
|
+
/**
|
|
827
|
+
* Response for getting publish task result
|
|
828
|
+
*/
|
|
829
|
+
export interface GetPublishTaskResultResponse extends FetchResponse<{
|
|
830
|
+
/** Task status: PROCESSING, SUCCESS, FAILED */
|
|
831
|
+
status: string;
|
|
832
|
+
/** List of publish results */
|
|
833
|
+
result_list: {
|
|
834
|
+
/** Shop ID */
|
|
835
|
+
shop_id: number;
|
|
836
|
+
/** Item ID in the shop */
|
|
837
|
+
item_id?: number;
|
|
838
|
+
/** Success status */
|
|
839
|
+
success: boolean;
|
|
840
|
+
/** Error message if failed */
|
|
841
|
+
error_description?: string;
|
|
842
|
+
}[];
|
|
843
|
+
}> {
|
|
844
|
+
}
|
|
845
|
+
/**
|
|
846
|
+
* Parameters for getting published list
|
|
847
|
+
*/
|
|
848
|
+
export type GetPublishedListParams = {
|
|
849
|
+
/** Global item ID */
|
|
850
|
+
global_item_id: number;
|
|
851
|
+
};
|
|
852
|
+
/**
|
|
853
|
+
* Published shop info
|
|
854
|
+
*/
|
|
855
|
+
export interface PublishedShop {
|
|
856
|
+
/** Shop ID */
|
|
857
|
+
shop_id: number;
|
|
858
|
+
/** Item ID in the shop */
|
|
859
|
+
item_id: number;
|
|
860
|
+
/** Shop name */
|
|
861
|
+
shop_name: string;
|
|
862
|
+
/** Shop region */
|
|
863
|
+
region: string;
|
|
864
|
+
}
|
|
865
|
+
/**
|
|
866
|
+
* Response for getting published list
|
|
867
|
+
*/
|
|
868
|
+
export interface GetPublishedListResponse extends FetchResponse<{
|
|
869
|
+
/** List of published shops */
|
|
870
|
+
shop_list: PublishedShop[];
|
|
871
|
+
}> {
|
|
872
|
+
}
|
|
873
|
+
/**
|
|
874
|
+
* Parameters for getting global item ID by shop item ID
|
|
875
|
+
*/
|
|
876
|
+
export type GetGlobalItemIdParams = {
|
|
877
|
+
/** Shop ID */
|
|
878
|
+
shop_id: number;
|
|
879
|
+
/** Item ID in the shop */
|
|
880
|
+
item_id: number;
|
|
881
|
+
};
|
|
882
|
+
/**
|
|
883
|
+
* Response for getting global item ID
|
|
884
|
+
*/
|
|
885
|
+
export interface GetGlobalItemIdResponse extends FetchResponse<{
|
|
886
|
+
/** Global item ID */
|
|
887
|
+
global_item_id: number;
|
|
888
|
+
}> {
|
|
889
|
+
}
|
|
890
|
+
/**
|
|
891
|
+
* Parameters for getting recommended attributes
|
|
892
|
+
*/
|
|
893
|
+
export type GetGlobalRecommendAttributeParams = {
|
|
894
|
+
/** Global item ID */
|
|
895
|
+
global_item_id: number;
|
|
896
|
+
};
|
|
897
|
+
/**
|
|
898
|
+
* Response for getting recommended attributes
|
|
899
|
+
*/
|
|
900
|
+
export interface GetGlobalRecommendAttributeResponse extends FetchResponse<{
|
|
901
|
+
/** List of recommended attributes */
|
|
902
|
+
attribute_list: Attribute[];
|
|
903
|
+
}> {
|
|
904
|
+
}
|
|
905
|
+
/**
|
|
906
|
+
* Parameters for searching global attribute value list
|
|
907
|
+
*/
|
|
908
|
+
export type SearchGlobalAttributeValueListParams = {
|
|
909
|
+
/** Category ID */
|
|
910
|
+
category_id: number;
|
|
911
|
+
/** Attribute ID */
|
|
912
|
+
attribute_id: number;
|
|
913
|
+
/** Search keyword */
|
|
914
|
+
keyword: string;
|
|
915
|
+
/** Language */
|
|
916
|
+
language?: string;
|
|
917
|
+
/** Page number */
|
|
918
|
+
page_num?: number;
|
|
919
|
+
/** Page size */
|
|
920
|
+
page_size?: number;
|
|
921
|
+
};
|
|
922
|
+
/**
|
|
923
|
+
* Response for searching global attribute value list
|
|
924
|
+
*/
|
|
925
|
+
export interface SearchGlobalAttributeValueListResponse extends FetchResponse<{
|
|
926
|
+
/** List of attribute values */
|
|
927
|
+
attribute_value_list: {
|
|
928
|
+
/** Value ID */
|
|
929
|
+
value_id: number;
|
|
930
|
+
/** Original value name */
|
|
931
|
+
original_value_name: string;
|
|
932
|
+
/** Display value name */
|
|
933
|
+
display_value_name: string;
|
|
934
|
+
/** Value unit */
|
|
935
|
+
value_unit?: string;
|
|
936
|
+
}[];
|
|
937
|
+
}> {
|
|
938
|
+
}
|
|
939
|
+
/**
|
|
940
|
+
* Parameters for getting variations
|
|
941
|
+
*/
|
|
942
|
+
export type GetGlobalVariationsParams = {
|
|
943
|
+
/** Global item ID */
|
|
944
|
+
global_item_id: number;
|
|
945
|
+
};
|
|
946
|
+
/**
|
|
947
|
+
* Response for getting variations
|
|
948
|
+
*/
|
|
949
|
+
export interface GetGlobalVariationsResponse extends FetchResponse<{
|
|
950
|
+
/** Tier variation list */
|
|
951
|
+
tier_variation: GlobalTierVariation[];
|
|
952
|
+
}> {
|
|
953
|
+
}
|
|
954
|
+
/**
|
|
955
|
+
* Parameters for setting sync field
|
|
956
|
+
*/
|
|
957
|
+
export type SetSyncFieldParams = {
|
|
958
|
+
/** Global item ID */
|
|
959
|
+
global_item_id: number;
|
|
960
|
+
/** List of shops to set sync field */
|
|
961
|
+
shop_list: {
|
|
962
|
+
/** Shop ID */
|
|
963
|
+
shop_id: number;
|
|
964
|
+
/** Fields to sync */
|
|
965
|
+
sync_field_list: string[];
|
|
966
|
+
}[];
|
|
967
|
+
};
|
|
968
|
+
/**
|
|
969
|
+
* Response for setting sync field
|
|
970
|
+
*/
|
|
971
|
+
export interface SetSyncFieldResponse extends FetchResponse<{
|
|
972
|
+
/** List of results */
|
|
973
|
+
result_list: {
|
|
974
|
+
/** Shop ID */
|
|
975
|
+
shop_id: number;
|
|
976
|
+
/** Success status */
|
|
977
|
+
success: boolean;
|
|
978
|
+
/** Error message if failed */
|
|
979
|
+
error_description?: string;
|
|
980
|
+
}[];
|
|
981
|
+
}> {
|
|
982
|
+
}
|
|
983
|
+
/**
|
|
984
|
+
* Parameters for getting local adjustment rate
|
|
985
|
+
*/
|
|
986
|
+
export type GetLocalAdjustmentRateParams = {
|
|
987
|
+
/** Global item ID */
|
|
988
|
+
global_item_id: number;
|
|
989
|
+
/** List of shop IDs */
|
|
990
|
+
shop_id_list: number[];
|
|
991
|
+
};
|
|
992
|
+
/**
|
|
993
|
+
* Response for getting local adjustment rate
|
|
994
|
+
*/
|
|
995
|
+
export interface GetLocalAdjustmentRateResponse extends FetchResponse<{
|
|
996
|
+
/** List of adjustment rates */
|
|
997
|
+
adjustment_rate_list: {
|
|
998
|
+
/** Shop ID */
|
|
999
|
+
shop_id: number;
|
|
1000
|
+
/** Global model ID */
|
|
1001
|
+
global_model_id?: number;
|
|
1002
|
+
/** Adjustment rate (percentage) */
|
|
1003
|
+
adjustment_rate: number;
|
|
1004
|
+
}[];
|
|
1005
|
+
}> {
|
|
1006
|
+
}
|
|
1007
|
+
/**
|
|
1008
|
+
* Parameters for updating local adjustment rate
|
|
1009
|
+
*/
|
|
1010
|
+
export type UpdateLocalAdjustmentRateParams = {
|
|
1011
|
+
/** Global item ID */
|
|
1012
|
+
global_item_id: number;
|
|
1013
|
+
/** List of adjustment rates to update */
|
|
1014
|
+
adjustment_rate_list: {
|
|
1015
|
+
/** Shop ID */
|
|
1016
|
+
shop_id: number;
|
|
1017
|
+
/** Global model ID */
|
|
1018
|
+
global_model_id?: number;
|
|
1019
|
+
/** Adjustment rate (percentage) */
|
|
1020
|
+
adjustment_rate: number;
|
|
1021
|
+
}[];
|
|
1022
|
+
};
|
|
1023
|
+
/**
|
|
1024
|
+
* Response for updating local adjustment rate
|
|
1025
|
+
*/
|
|
1026
|
+
export interface UpdateLocalAdjustmentRateResponse extends FetchResponse<{
|
|
1027
|
+
/** List of update results */
|
|
1028
|
+
result_list: {
|
|
1029
|
+
/** Shop ID */
|
|
1030
|
+
shop_id: number;
|
|
1031
|
+
/** Global model ID */
|
|
1032
|
+
global_model_id?: number;
|
|
1033
|
+
/** Success status */
|
|
1034
|
+
success: boolean;
|
|
1035
|
+
/** Error message if failed */
|
|
1036
|
+
error_description?: string;
|
|
1037
|
+
}[];
|
|
1038
|
+
}> {
|
|
1039
|
+
}
|
|
1040
|
+
/**
|
|
1041
|
+
* Size chart information
|
|
1042
|
+
*/
|
|
1043
|
+
export interface SizeChart {
|
|
1044
|
+
/** Size chart ID */
|
|
1045
|
+
size_chart_id: string;
|
|
1046
|
+
/** Size chart name */
|
|
1047
|
+
size_chart_name: string;
|
|
1048
|
+
/** Size chart table */
|
|
1049
|
+
size_chart_table: {
|
|
1050
|
+
/** Header row */
|
|
1051
|
+
header: string[];
|
|
1052
|
+
/** Data rows */
|
|
1053
|
+
rows: string[][];
|
|
1054
|
+
};
|
|
1055
|
+
}
|
|
1056
|
+
/**
|
|
1057
|
+
* Parameters for getting size chart list
|
|
1058
|
+
*/
|
|
1059
|
+
export type GetGlobalSizeChartListParams = {
|
|
1060
|
+
/** Offset for pagination */
|
|
1061
|
+
offset?: number;
|
|
1062
|
+
/** Page size */
|
|
1063
|
+
page_size: number;
|
|
1064
|
+
};
|
|
1065
|
+
/**
|
|
1066
|
+
* Response for getting size chart list
|
|
1067
|
+
*/
|
|
1068
|
+
export interface GetGlobalSizeChartListResponse extends FetchResponse<{
|
|
1069
|
+
/** List of size charts */
|
|
1070
|
+
size_chart_list: SizeChart[];
|
|
1071
|
+
/** Whether there are more pages */
|
|
1072
|
+
has_next_page: boolean;
|
|
1073
|
+
/** Next page offset */
|
|
1074
|
+
next_offset: number;
|
|
1075
|
+
}> {
|
|
1076
|
+
}
|
|
1077
|
+
/**
|
|
1078
|
+
* Parameters for getting size chart detail
|
|
1079
|
+
*/
|
|
1080
|
+
export type GetGlobalSizeChartDetailParams = {
|
|
1081
|
+
/** Size chart ID */
|
|
1082
|
+
size_chart_id: string;
|
|
1083
|
+
};
|
|
1084
|
+
/**
|
|
1085
|
+
* Response for getting size chart detail
|
|
1086
|
+
*/
|
|
1087
|
+
export interface GetGlobalSizeChartDetailResponse extends FetchResponse<{
|
|
1088
|
+
/** Size chart information */
|
|
1089
|
+
size_chart: SizeChart;
|
|
1090
|
+
}> {
|
|
1091
|
+
}
|
|
1092
|
+
/**
|
|
1093
|
+
* Parameters for updating size chart
|
|
1094
|
+
*/
|
|
1095
|
+
export type UpdateSizeChartParams = {
|
|
1096
|
+
/** Size chart ID */
|
|
1097
|
+
size_chart_id: string;
|
|
1098
|
+
/** Size chart name */
|
|
1099
|
+
size_chart_name?: string;
|
|
1100
|
+
/** Size chart table */
|
|
1101
|
+
size_chart_table?: {
|
|
1102
|
+
/** Header row */
|
|
1103
|
+
header: string[];
|
|
1104
|
+
/** Data rows */
|
|
1105
|
+
rows: string[][];
|
|
1106
|
+
};
|
|
1107
|
+
};
|
|
1108
|
+
/**
|
|
1109
|
+
* Response for updating size chart
|
|
1110
|
+
*/
|
|
1111
|
+
export interface UpdateSizeChartResponse extends BaseResponse {
|
|
1112
|
+
}
|
|
1113
|
+
/**
|
|
1114
|
+
* Parameters for checking size chart support
|
|
1115
|
+
*/
|
|
1116
|
+
export type SupportSizeChartParams = {
|
|
1117
|
+
/** Category ID */
|
|
1118
|
+
category_id: number;
|
|
1119
|
+
};
|
|
1120
|
+
/**
|
|
1121
|
+
* Response for checking size chart support
|
|
1122
|
+
*/
|
|
1123
|
+
export interface SupportSizeChartResponse extends FetchResponse<{
|
|
1124
|
+
/** Whether size chart is supported */
|
|
1125
|
+
support: boolean;
|
|
1126
|
+
}> {
|
|
1127
|
+
}
|