@congminh1254/shopee-sdk 0.6.0 → 0.8.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/lib/managers/account-health.manager.d.ts +208 -0
- package/lib/managers/account-health.manager.js +257 -0
- package/lib/managers/account-health.manager.js.map +1 -0
- package/lib/managers/index.d.ts +1 -0
- package/lib/managers/index.js +1 -0
- package/lib/managers/index.js.map +1 -1
- package/lib/managers/product.manager.d.ts +20 -1
- package/lib/managers/product.manager.js +26 -0
- package/lib/managers/product.manager.js.map +1 -1
- package/lib/schemas/account-health.d.ts +734 -0
- package/lib/schemas/account-health.js +200 -0
- package/lib/schemas/account-health.js.map +1 -0
- package/lib/schemas/index.d.ts +1 -0
- package/lib/schemas/index.js +1 -0
- package/lib/schemas/index.js.map +1 -1
- package/lib/schemas/product.d.ts +151 -0
- package/lib/sdk.d.ts +2 -0
- package/lib/sdk.js +2 -0
- package/lib/sdk.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Metric type enum values
|
|
3
|
+
* 1 = Fulfillment Performance
|
|
4
|
+
* 2 = Listing Performance
|
|
5
|
+
* 3 = Customer Service Performance
|
|
6
|
+
*/
|
|
7
|
+
export var MetricType;
|
|
8
|
+
(function (MetricType) {
|
|
9
|
+
MetricType[MetricType["FulfillmentPerformance"] = 1] = "FulfillmentPerformance";
|
|
10
|
+
MetricType[MetricType["ListingPerformance"] = 2] = "ListingPerformance";
|
|
11
|
+
MetricType[MetricType["CustomerServicePerformance"] = 3] = "CustomerServicePerformance";
|
|
12
|
+
})(MetricType || (MetricType = {}));
|
|
13
|
+
/**
|
|
14
|
+
* Metric unit enum values
|
|
15
|
+
* 1 = Number
|
|
16
|
+
* 2 = Percentage
|
|
17
|
+
* 3 = Second
|
|
18
|
+
* 4 = Day
|
|
19
|
+
* 5 = Hour
|
|
20
|
+
*/
|
|
21
|
+
export var MetricUnit;
|
|
22
|
+
(function (MetricUnit) {
|
|
23
|
+
MetricUnit[MetricUnit["Number"] = 1] = "Number";
|
|
24
|
+
MetricUnit[MetricUnit["Percentage"] = 2] = "Percentage";
|
|
25
|
+
MetricUnit[MetricUnit["Second"] = 3] = "Second";
|
|
26
|
+
MetricUnit[MetricUnit["Day"] = 4] = "Day";
|
|
27
|
+
MetricUnit[MetricUnit["Hour"] = 5] = "Hour";
|
|
28
|
+
})(MetricUnit || (MetricUnit = {}));
|
|
29
|
+
/**
|
|
30
|
+
* Overall performance rating enum values
|
|
31
|
+
* 1 = Poor
|
|
32
|
+
* 2 = ImprovementNeeded
|
|
33
|
+
* 3 = Good
|
|
34
|
+
* 4 = Excellent
|
|
35
|
+
*/
|
|
36
|
+
export var PerformanceRating;
|
|
37
|
+
(function (PerformanceRating) {
|
|
38
|
+
PerformanceRating[PerformanceRating["Poor"] = 1] = "Poor";
|
|
39
|
+
PerformanceRating[PerformanceRating["ImprovementNeeded"] = 2] = "ImprovementNeeded";
|
|
40
|
+
PerformanceRating[PerformanceRating["Good"] = 3] = "Good";
|
|
41
|
+
PerformanceRating[PerformanceRating["Excellent"] = 4] = "Excellent";
|
|
42
|
+
})(PerformanceRating || (PerformanceRating = {}));
|
|
43
|
+
/**
|
|
44
|
+
* Violation types that can be used to filter penalty point history
|
|
45
|
+
* These values correspond to different violation categories that might result in penalty points.
|
|
46
|
+
* For a complete list, refer to the Shopee API documentation.
|
|
47
|
+
*/
|
|
48
|
+
export var ViolationType;
|
|
49
|
+
(function (ViolationType) {
|
|
50
|
+
ViolationType[ViolationType["HighLateShipmentRate"] = 5] = "HighLateShipmentRate";
|
|
51
|
+
ViolationType[ViolationType["HighNonFulfillmentRate"] = 6] = "HighNonFulfillmentRate";
|
|
52
|
+
ViolationType[ViolationType["HighNumberOfNonFulfilledOrders"] = 7] = "HighNumberOfNonFulfilledOrders";
|
|
53
|
+
ViolationType[ViolationType["HighNumberOfLateShippedOrders"] = 8] = "HighNumberOfLateShippedOrders";
|
|
54
|
+
ViolationType[ViolationType["ProhibitedListings"] = 9] = "ProhibitedListings";
|
|
55
|
+
ViolationType[ViolationType["CounterfeitIPInfringement"] = 10] = "CounterfeitIPInfringement";
|
|
56
|
+
ViolationType[ViolationType["Spam"] = 11] = "Spam";
|
|
57
|
+
ViolationType[ViolationType["CopyStealImages"] = 12] = "CopyStealImages";
|
|
58
|
+
ViolationType[ViolationType["ReUploadingDeletedListings"] = 13] = "ReUploadingDeletedListings";
|
|
59
|
+
ViolationType[ViolationType["BoughtCounterfeitFromMall"] = 14] = "BoughtCounterfeitFromMall";
|
|
60
|
+
ViolationType[ViolationType["CounterfeitCaughtByShopee"] = 15] = "CounterfeitCaughtByShopee";
|
|
61
|
+
ViolationType[ViolationType["HighPercentageOfPreOrderListings"] = 16] = "HighPercentageOfPreOrderListings";
|
|
62
|
+
ViolationType[ViolationType["ConfirmedFraudAttempts"] = 17] = "ConfirmedFraudAttempts";
|
|
63
|
+
ViolationType[ViolationType["ConfirmedFraudAttemptsWithVouchers"] = 18] = "ConfirmedFraudAttemptsWithVouchers";
|
|
64
|
+
ViolationType[ViolationType["FakeReturnAddress"] = 19] = "FakeReturnAddress";
|
|
65
|
+
ViolationType[ViolationType["ShippingFraudAbuse"] = 20] = "ShippingFraudAbuse";
|
|
66
|
+
ViolationType[ViolationType["HighNonRespondedChat"] = 21] = "HighNonRespondedChat";
|
|
67
|
+
ViolationType[ViolationType["RudeChatReplies"] = 22] = "RudeChatReplies";
|
|
68
|
+
ViolationType[ViolationType["RequestBuyerToCancel"] = 23] = "RequestBuyerToCancel";
|
|
69
|
+
ViolationType[ViolationType["RudeReplyToBuyerReview"] = 24] = "RudeReplyToBuyerReview";
|
|
70
|
+
ViolationType[ViolationType["ViolateReturnRefundPolicy"] = 25] = "ViolateReturnRefundPolicy";
|
|
71
|
+
ViolationType[ViolationType["TierReason"] = 101] = "TierReason";
|
|
72
|
+
ViolationType[ViolationType["MisuseOfShopeesIP"] = 3026] = "MisuseOfShopeesIP";
|
|
73
|
+
ViolationType[ViolationType["ViolateShopNameRegulations"] = 3028] = "ViolateShopNameRegulations";
|
|
74
|
+
ViolationType[ViolationType["DirectTransactionsOutsidePlatform"] = 3030] = "DirectTransactionsOutsidePlatform";
|
|
75
|
+
ViolationType[ViolationType["ShippingEmptyIncompleteParcels"] = 3032] = "ShippingEmptyIncompleteParcels";
|
|
76
|
+
ViolationType[ViolationType["SevereViolationsOnShopeeFeed"] = 3034] = "SevereViolationsOnShopeeFeed";
|
|
77
|
+
ViolationType[ViolationType["SevereViolationsOnShopeeLIVE"] = 3036] = "SevereViolationsOnShopeeLIVE";
|
|
78
|
+
ViolationType[ViolationType["MisuseOfLocalVendorTag"] = 3038] = "MisuseOfLocalVendorTag";
|
|
79
|
+
ViolationType[ViolationType["MisleadingShopTagInListingImage"] = 3040] = "MisleadingShopTagInListingImage";
|
|
80
|
+
ViolationType[ViolationType["CounterfeitIPInfringementTest"] = 3042] = "CounterfeitIPInfringementTest";
|
|
81
|
+
ViolationType[ViolationType["RepeatOffenderIPInfringement"] = 3044] = "RepeatOffenderIPInfringement";
|
|
82
|
+
ViolationType[ViolationType["ViolationOfLiveAnimalsSelling"] = 3046] = "ViolationOfLiveAnimalsSelling";
|
|
83
|
+
ViolationType[ViolationType["ChatSpam"] = 3048] = "ChatSpam";
|
|
84
|
+
ViolationType[ViolationType["HighOverseasReturnRefundsRate"] = 3050] = "HighOverseasReturnRefundsRate";
|
|
85
|
+
ViolationType[ViolationType["PrivacyBreachInBuyerReply"] = 3052] = "PrivacyBreachInBuyerReply";
|
|
86
|
+
ViolationType[ViolationType["OrderBrushing"] = 3054] = "OrderBrushing";
|
|
87
|
+
ViolationType[ViolationType["PornImage"] = 3056] = "PornImage";
|
|
88
|
+
ViolationType[ViolationType["IncorrectProductCategories"] = 3058] = "IncorrectProductCategories";
|
|
89
|
+
ViolationType[ViolationType["ExtremelyHighNonFulfillmentRate"] = 3060] = "ExtremelyHighNonFulfillmentRate";
|
|
90
|
+
ViolationType[ViolationType["AMSOverdueInvoicePayment"] = 3062] = "AMSOverdueInvoicePayment";
|
|
91
|
+
ViolationType[ViolationType["GovernmentRelatedListing"] = 3064] = "GovernmentRelatedListing";
|
|
92
|
+
ViolationType[ViolationType["ListingInvalidGiftedItems"] = 3066] = "ListingInvalidGiftedItems";
|
|
93
|
+
ViolationType[ViolationType["HighNonFulfillmentRateNDD"] = 3068] = "HighNonFulfillmentRateNDD";
|
|
94
|
+
ViolationType[ViolationType["HighLateShipmentRateNDD"] = 3070] = "HighLateShipmentRateNDD";
|
|
95
|
+
ViolationType[ViolationType["OPFRViolationValue"] = 3072] = "OPFRViolationValue";
|
|
96
|
+
ViolationType[ViolationType["DirectTransactionsOutsidePlatformViaChat"] = 3074] = "DirectTransactionsOutsidePlatformViaChat";
|
|
97
|
+
ViolationType[ViolationType["ProhibitedListingsExtreme"] = 3090] = "ProhibitedListingsExtreme";
|
|
98
|
+
ViolationType[ViolationType["ProhibitedListingsHigh"] = 3091] = "ProhibitedListingsHigh";
|
|
99
|
+
ViolationType[ViolationType["ProhibitedListingsMid"] = 3092] = "ProhibitedListingsMid";
|
|
100
|
+
ViolationType[ViolationType["ProhibitedListingsLow"] = 3093] = "ProhibitedListingsLow";
|
|
101
|
+
ViolationType[ViolationType["CounterfeitListingsExtreme"] = 3094] = "CounterfeitListingsExtreme";
|
|
102
|
+
ViolationType[ViolationType["CounterfeitListingsHigh"] = 3095] = "CounterfeitListingsHigh";
|
|
103
|
+
ViolationType[ViolationType["CounterfeitListingsMid"] = 3096] = "CounterfeitListingsMid";
|
|
104
|
+
ViolationType[ViolationType["CounterfeitListingsLow"] = 3097] = "CounterfeitListingsLow";
|
|
105
|
+
ViolationType[ViolationType["SpamListingsExtreme"] = 3098] = "SpamListingsExtreme";
|
|
106
|
+
ViolationType[ViolationType["SpamListingsHigh"] = 3099] = "SpamListingsHigh";
|
|
107
|
+
ViolationType[ViolationType["SpamListingsMid"] = 3100] = "SpamListingsMid";
|
|
108
|
+
ViolationType[ViolationType["SpamListingsLow"] = 3101] = "SpamListingsLow";
|
|
109
|
+
ViolationType[ViolationType["ReturnRefundRateNonIntegrated"] = 3145] = "ReturnRefundRateNonIntegrated";
|
|
110
|
+
ViolationType[ViolationType["PoorProductQuality"] = 4130] = "PoorProductQuality";
|
|
111
|
+
})(ViolationType || (ViolationType = {}));
|
|
112
|
+
/**
|
|
113
|
+
* Status of punishment records
|
|
114
|
+
*/
|
|
115
|
+
export var PunishmentStatus;
|
|
116
|
+
(function (PunishmentStatus) {
|
|
117
|
+
/** Ongoing punishments */
|
|
118
|
+
PunishmentStatus[PunishmentStatus["Ongoing"] = 1] = "Ongoing";
|
|
119
|
+
/** Ended punishments */
|
|
120
|
+
PunishmentStatus[PunishmentStatus["Ended"] = 2] = "Ended";
|
|
121
|
+
})(PunishmentStatus || (PunishmentStatus = {}));
|
|
122
|
+
/**
|
|
123
|
+
* Types of shop punishments
|
|
124
|
+
*/
|
|
125
|
+
export var PunishmentType;
|
|
126
|
+
(function (PunishmentType) {
|
|
127
|
+
/** Listings not displayed in category browsing */
|
|
128
|
+
PunishmentType[PunishmentType["ListingsNotDisplayedInCategoryBrowsing"] = 103] = "ListingsNotDisplayedInCategoryBrowsing";
|
|
129
|
+
/** Listings not displayed in search */
|
|
130
|
+
PunishmentType[PunishmentType["ListingsNotDisplayedInSearch"] = 104] = "ListingsNotDisplayedInSearch";
|
|
131
|
+
/** Unable to create new listings */
|
|
132
|
+
PunishmentType[PunishmentType["UnableToCreateNewListings"] = 105] = "UnableToCreateNewListings";
|
|
133
|
+
/** Unable to edit listings */
|
|
134
|
+
PunishmentType[PunishmentType["UnableToEditListings"] = 106] = "UnableToEditListings";
|
|
135
|
+
/** Unable to join marketing campaigns */
|
|
136
|
+
PunishmentType[PunishmentType["UnableToJoinMarketingCampaigns"] = 107] = "UnableToJoinMarketingCampaigns";
|
|
137
|
+
/** No shipping subsidies */
|
|
138
|
+
PunishmentType[PunishmentType["NoShippingSubsidies"] = 108] = "NoShippingSubsidies";
|
|
139
|
+
/** Account is suspended */
|
|
140
|
+
PunishmentType[PunishmentType["AccountSuspended"] = 109] = "AccountSuspended";
|
|
141
|
+
/** Listings not displayed in search (alternative code) */
|
|
142
|
+
PunishmentType[PunishmentType["ListingsNotDisplayedInSearchAlt"] = 600] = "ListingsNotDisplayedInSearchAlt";
|
|
143
|
+
/** Shop listings hide from recommendation */
|
|
144
|
+
PunishmentType[PunishmentType["ShopListingsHideFromRecommendation"] = 601] = "ShopListingsHideFromRecommendation";
|
|
145
|
+
/** Listings not displayed in category browsing (alternative code) */
|
|
146
|
+
PunishmentType[PunishmentType["ListingsNotDisplayedInCategoryBrowsingAlt"] = 602] = "ListingsNotDisplayedInCategoryBrowsingAlt";
|
|
147
|
+
/** Listing Limit is reduced (Tier 1) */
|
|
148
|
+
PunishmentType[PunishmentType["ListingLimitReducedTier1"] = 1109] = "ListingLimitReducedTier1";
|
|
149
|
+
/** Listing Limit is reduced (Tier 2) */
|
|
150
|
+
PunishmentType[PunishmentType["ListingLimitReducedTier2"] = 1110] = "ListingLimitReducedTier2";
|
|
151
|
+
/** Listing Limit is reduced (POL) */
|
|
152
|
+
PunishmentType[PunishmentType["ListingLimitReducedPOL"] = 1111] = "ListingLimitReducedPOL";
|
|
153
|
+
/** Listing Limit is reduced (additional code) */
|
|
154
|
+
PunishmentType[PunishmentType["ListingLimitReducedExtra"] = 1112] = "ListingLimitReducedExtra";
|
|
155
|
+
/** Order Limit */
|
|
156
|
+
PunishmentType[PunishmentType["OrderLimit"] = 2008] = "OrderLimit";
|
|
157
|
+
})(PunishmentType || (PunishmentType = {}));
|
|
158
|
+
/**
|
|
159
|
+
* Reasons for shop punishments
|
|
160
|
+
*/
|
|
161
|
+
export var PunishmentReason;
|
|
162
|
+
(function (PunishmentReason) {
|
|
163
|
+
/** Tier 1 punishment */
|
|
164
|
+
PunishmentReason[PunishmentReason["Tier1"] = 1] = "Tier1";
|
|
165
|
+
/** Tier 2 punishment */
|
|
166
|
+
PunishmentReason[PunishmentReason["Tier2"] = 2] = "Tier2";
|
|
167
|
+
/** Tier 3 punishment */
|
|
168
|
+
PunishmentReason[PunishmentReason["Tier3"] = 3] = "Tier3";
|
|
169
|
+
/** Tier 4 punishment */
|
|
170
|
+
PunishmentReason[PunishmentReason["Tier4"] = 4] = "Tier4";
|
|
171
|
+
/** Tier 5 punishment */
|
|
172
|
+
PunishmentReason[PunishmentReason["Tier5"] = 5] = "Tier5";
|
|
173
|
+
/** Listing Limit Tier 1 */
|
|
174
|
+
PunishmentReason[PunishmentReason["ListingLimitTier1"] = 1109] = "ListingLimitTier1";
|
|
175
|
+
/** Listing Limit Tier 2 */
|
|
176
|
+
PunishmentReason[PunishmentReason["ListingLimitTier2"] = 1110] = "ListingLimitTier2";
|
|
177
|
+
/** Listing Limit POL */
|
|
178
|
+
PunishmentReason[PunishmentReason["ListingLimitPOL"] = 1111] = "ListingLimitPOL";
|
|
179
|
+
})(PunishmentReason || (PunishmentReason = {}));
|
|
180
|
+
/**
|
|
181
|
+
* Reason types for listing issues
|
|
182
|
+
*/
|
|
183
|
+
export var ListingIssueReason;
|
|
184
|
+
(function (ListingIssueReason) {
|
|
185
|
+
/** Prohibited listing */
|
|
186
|
+
ListingIssueReason[ListingIssueReason["Prohibited"] = 1] = "Prohibited";
|
|
187
|
+
/** Counterfeit listing */
|
|
188
|
+
ListingIssueReason[ListingIssueReason["Counterfeit"] = 2] = "Counterfeit";
|
|
189
|
+
/** Spam listing */
|
|
190
|
+
ListingIssueReason[ListingIssueReason["Spam"] = 3] = "Spam";
|
|
191
|
+
/** Inappropriate image */
|
|
192
|
+
ListingIssueReason[ListingIssueReason["InappropriateImage"] = 4] = "InappropriateImage";
|
|
193
|
+
/** Insufficient information */
|
|
194
|
+
ListingIssueReason[ListingIssueReason["InsufficientInfo"] = 5] = "InsufficientInfo";
|
|
195
|
+
/** Mall listing improvement needed */
|
|
196
|
+
ListingIssueReason[ListingIssueReason["MallListingImprovement"] = 6] = "MallListingImprovement";
|
|
197
|
+
/** Other listing improvement needed */
|
|
198
|
+
ListingIssueReason[ListingIssueReason["OtherListingImprovement"] = 7] = "OtherListingImprovement";
|
|
199
|
+
})(ListingIssueReason || (ListingIssueReason = {}));
|
|
200
|
+
//# sourceMappingURL=account-health.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"account-health.js","sourceRoot":"","sources":["../../src/schemas/account-health.ts"],"names":[],"mappings":"AA8CA;;;;;GAKG;AACH,MAAM,CAAN,IAAY,UAIX;AAJD,WAAY,UAAU;IACpB,+EAA0B,CAAA;IAC1B,uEAAsB,CAAA;IACtB,uFAA8B,CAAA;AAChC,CAAC,EAJW,UAAU,KAAV,UAAU,QAIrB;AAED;;;;;;;GAOG;AACH,MAAM,CAAN,IAAY,UAMX;AAND,WAAY,UAAU;IACpB,+CAAU,CAAA;IACV,uDAAc,CAAA;IACd,+CAAU,CAAA;IACV,yCAAO,CAAA;IACP,2CAAQ,CAAA;AACV,CAAC,EANW,UAAU,KAAV,UAAU,QAMrB;AAED;;;;;;GAMG;AACH,MAAM,CAAN,IAAY,iBAKX;AALD,WAAY,iBAAiB;IAC3B,yDAAQ,CAAA;IACR,mFAAqB,CAAA;IACrB,yDAAQ,CAAA;IACR,mEAAa,CAAA;AACf,CAAC,EALW,iBAAiB,KAAjB,iBAAiB,QAK5B;AAgVD;;;;GAIG;AACH,MAAM,CAAN,IAAY,aA8DX;AA9DD,WAAY,aAAa;IACvB,iFAAwB,CAAA;IACxB,qFAA0B,CAAA;IAC1B,qGAAkC,CAAA;IAClC,mGAAiC,CAAA;IACjC,6EAAsB,CAAA;IACtB,4FAA8B,CAAA;IAC9B,kDAAS,CAAA;IACT,wEAAoB,CAAA;IACpB,8FAA+B,CAAA;IAC/B,4FAA8B,CAAA;IAC9B,4FAA8B,CAAA;IAC9B,0GAAqC,CAAA;IACrC,sFAA2B,CAAA;IAC3B,8GAAuC,CAAA;IACvC,4EAAsB,CAA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AsC;IACtC,+FAA0B,CAAA;IAC1B,uCAAuC;IACvC,iGAA2B,CAAA;AAC7B,CAAC,EAfW,kBAAkB,KAAlB,kBAAkB,QAe7B"}
|
package/lib/schemas/index.d.ts
CHANGED
package/lib/schemas/index.js
CHANGED
package/lib/schemas/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,qBAAqB,CAAC"}
|
package/lib/schemas/product.d.ts
CHANGED
|
@@ -602,3 +602,154 @@ export interface GetItemBaseInfoResponse extends BaseResponse {
|
|
|
602
602
|
tax_info?: TaxInfo;
|
|
603
603
|
};
|
|
604
604
|
}
|
|
605
|
+
/**
|
|
606
|
+
* Parameters for getting model list of an item
|
|
607
|
+
*/
|
|
608
|
+
export type GetModelListParams = {
|
|
609
|
+
/** The ID of the item */
|
|
610
|
+
item_id: number;
|
|
611
|
+
};
|
|
612
|
+
/**
|
|
613
|
+
* Option information in variation
|
|
614
|
+
*/
|
|
615
|
+
export interface VariationOption {
|
|
616
|
+
/** Option name */
|
|
617
|
+
option: string;
|
|
618
|
+
/** Image information for the option */
|
|
619
|
+
image?: {
|
|
620
|
+
/** Id of image */
|
|
621
|
+
image_id?: string;
|
|
622
|
+
/** Url of image */
|
|
623
|
+
image_url?: string;
|
|
624
|
+
};
|
|
625
|
+
}
|
|
626
|
+
/**
|
|
627
|
+
* Tier variation information
|
|
628
|
+
*/
|
|
629
|
+
export interface TierVariation {
|
|
630
|
+
/** List of options for this variation */
|
|
631
|
+
option_list: VariationOption[];
|
|
632
|
+
/** Variation name */
|
|
633
|
+
name: string;
|
|
634
|
+
}
|
|
635
|
+
/**
|
|
636
|
+
* Model price information
|
|
637
|
+
*/
|
|
638
|
+
export interface ModelPriceInfo {
|
|
639
|
+
/** Currency for the item price */
|
|
640
|
+
currency?: string;
|
|
641
|
+
/** Current price of item */
|
|
642
|
+
current_price: number;
|
|
643
|
+
/** Original price of item */
|
|
644
|
+
original_price: number;
|
|
645
|
+
/** Original price of item after tax */
|
|
646
|
+
inflated_price_of_original_price: number;
|
|
647
|
+
/** Current price of item after tax */
|
|
648
|
+
inflated_price_of_current_price: number;
|
|
649
|
+
/** SIP item price. Only returned for SIP primary shop */
|
|
650
|
+
sip_item_price?: number;
|
|
651
|
+
/** SIP item price source, could be manual or auto. Only returned for SIP primary shop */
|
|
652
|
+
sip_item_price_source?: string;
|
|
653
|
+
/** The currency of sip_item_price. Only returned for SIP primary shop */
|
|
654
|
+
sip_item_price_currency?: string;
|
|
655
|
+
}
|
|
656
|
+
/**
|
|
657
|
+
* Pre-order information for the model
|
|
658
|
+
*/
|
|
659
|
+
export interface ModelPreOrder {
|
|
660
|
+
/** Whether the model is on pre-order */
|
|
661
|
+
is_pre_order: boolean;
|
|
662
|
+
/** The days to ship for pre-order */
|
|
663
|
+
days_to_ship: number;
|
|
664
|
+
}
|
|
665
|
+
/**
|
|
666
|
+
* Model stock information
|
|
667
|
+
*/
|
|
668
|
+
export interface ModelStockInfoV2 {
|
|
669
|
+
/** Stock summary info */
|
|
670
|
+
summary_info?: StockSummaryInfo;
|
|
671
|
+
/** Seller stock */
|
|
672
|
+
seller_stock?: SellerStock[];
|
|
673
|
+
/** Shopee stock */
|
|
674
|
+
shopee_stock?: ShopeeStock[];
|
|
675
|
+
/** Advance stock details */
|
|
676
|
+
advance_stock?: AdvanceStock;
|
|
677
|
+
}
|
|
678
|
+
/**
|
|
679
|
+
* Model dimension information
|
|
680
|
+
*/
|
|
681
|
+
export interface ModelDimension {
|
|
682
|
+
/** The height of package for this model, the unit is CM */
|
|
683
|
+
package_height: number;
|
|
684
|
+
/** The length of package for this model, the unit is CM */
|
|
685
|
+
package_length: number;
|
|
686
|
+
/** The width of package for this model, the unit is CM */
|
|
687
|
+
package_width: number;
|
|
688
|
+
}
|
|
689
|
+
/**
|
|
690
|
+
* Individual model information
|
|
691
|
+
*/
|
|
692
|
+
export interface ModelInfo {
|
|
693
|
+
/** Price information for this model */
|
|
694
|
+
price_info: ModelPriceInfo[];
|
|
695
|
+
/** Model ID */
|
|
696
|
+
model_id?: number;
|
|
697
|
+
/** Tier index of this model */
|
|
698
|
+
tier_index?: number[];
|
|
699
|
+
/** Current promotion ID of this model */
|
|
700
|
+
promotion_id?: number;
|
|
701
|
+
/** SKU of this model */
|
|
702
|
+
model_sku?: string;
|
|
703
|
+
/** The model status, either MODEL_NORMAL or MODEL_UNAVAILABLE */
|
|
704
|
+
model_status?: string;
|
|
705
|
+
/** Pre-order information */
|
|
706
|
+
pre_order?: ModelPreOrder;
|
|
707
|
+
/** Stock information v2 */
|
|
708
|
+
stock_info_v2?: ModelStockInfoV2;
|
|
709
|
+
/** GTIN code (only available for TW seller and BR local seller) */
|
|
710
|
+
gtin_code?: string;
|
|
711
|
+
/** The weight of this model, the unit is KG */
|
|
712
|
+
weight?: string;
|
|
713
|
+
/** The dimension of this model */
|
|
714
|
+
dimension?: ModelDimension;
|
|
715
|
+
/** Whether model is fulfillment by shopee */
|
|
716
|
+
is_fulfillment_by_shopee?: boolean;
|
|
717
|
+
}
|
|
718
|
+
/**
|
|
719
|
+
* Standardized variation option
|
|
720
|
+
*/
|
|
721
|
+
export interface StandardVariationOption {
|
|
722
|
+
/** Standardize Option ID */
|
|
723
|
+
variation_option_id?: number;
|
|
724
|
+
/** Standardize Option Name */
|
|
725
|
+
variation_option_name?: string;
|
|
726
|
+
/** ID of image */
|
|
727
|
+
image_id?: string;
|
|
728
|
+
/** URL of image */
|
|
729
|
+
image_url?: string;
|
|
730
|
+
}
|
|
731
|
+
/**
|
|
732
|
+
* Standardized variation information
|
|
733
|
+
*/
|
|
734
|
+
export interface StandardiseTierVariation {
|
|
735
|
+
/** Standardize Variation ID */
|
|
736
|
+
variation_id?: number;
|
|
737
|
+
/** Standardize Variation Name */
|
|
738
|
+
variation_name?: string;
|
|
739
|
+
/** Standardize Variation Group ID */
|
|
740
|
+
variation_group_id?: number;
|
|
741
|
+
/** Standardize Variation Option List */
|
|
742
|
+
variation_option_list?: StandardVariationOption[];
|
|
743
|
+
}
|
|
744
|
+
/**
|
|
745
|
+
* Response for getting model list
|
|
746
|
+
*/
|
|
747
|
+
export interface GetModelListResponse extends FetchResponse<{
|
|
748
|
+
/** Variation config of item */
|
|
749
|
+
tier_variation: TierVariation[];
|
|
750
|
+
/** Model list */
|
|
751
|
+
model: ModelInfo[];
|
|
752
|
+
/** Standardise Variation config of item */
|
|
753
|
+
standardise_tier_variation?: StandardiseTierVariation[];
|
|
754
|
+
}> {
|
|
755
|
+
}
|
package/lib/sdk.d.ts
CHANGED
|
@@ -10,6 +10,7 @@ import { PaymentManager } from "./managers/payment.manager.js";
|
|
|
10
10
|
import { LogisticsManager } from "./managers/logistics.manager.js";
|
|
11
11
|
import { VoucherManager } from "./managers/voucher.manager.js";
|
|
12
12
|
import { AdsManager } from "./managers/ads.manager.js";
|
|
13
|
+
import { AccountHealthManager } from "./managers/account-health.manager.js";
|
|
13
14
|
export interface ShopeeConfig {
|
|
14
15
|
partner_id: number;
|
|
15
16
|
partner_key: string;
|
|
@@ -30,6 +31,7 @@ export declare class ShopeeSDK {
|
|
|
30
31
|
readonly payment: PaymentManager;
|
|
31
32
|
readonly logistics: LogisticsManager;
|
|
32
33
|
readonly voucher: VoucherManager;
|
|
34
|
+
readonly accountHealth: AccountHealthManager;
|
|
33
35
|
constructor(config: ShopeeConfig, tokenStorage?: TokenStorage);
|
|
34
36
|
getConfig(): ShopeeConfig;
|
|
35
37
|
setRegion(region: ShopeeRegion): void;
|
package/lib/sdk.js
CHANGED
|
@@ -11,6 +11,7 @@ import { PaymentManager } from "./managers/payment.manager.js";
|
|
|
11
11
|
import { LogisticsManager } from "./managers/logistics.manager.js";
|
|
12
12
|
import { VoucherManager } from "./managers/voucher.manager.js";
|
|
13
13
|
import { AdsManager } from "./managers/ads.manager.js";
|
|
14
|
+
import { AccountHealthManager } from "./managers/account-health.manager.js";
|
|
14
15
|
export class ShopeeSDK {
|
|
15
16
|
constructor(config, tokenStorage) {
|
|
16
17
|
this.config = {
|
|
@@ -32,6 +33,7 @@ export class ShopeeSDK {
|
|
|
32
33
|
this.payment = new PaymentManager(this.config);
|
|
33
34
|
this.logistics = new LogisticsManager(this.config);
|
|
34
35
|
this.voucher = new VoucherManager(this.config);
|
|
36
|
+
this.accountHealth = new AccountHealthManager(this.config);
|
|
35
37
|
}
|
|
36
38
|
getConfig() {
|
|
37
39
|
return this.config;
|
package/lib/sdk.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sdk.js","sourceRoot":"","sources":["../src/sdk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAC3D,OAAO,EAAE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