@congminh1254/shopee-sdk 1.7.0 → 1.9.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.
Files changed (62) hide show
  1. package/README.md +46 -9
  2. package/lib/__tests__/integration/document.integration.test.d.ts +1 -0
  3. package/lib/__tests__/integration/document.integration.test.js +35 -0
  4. package/lib/__tests__/integration/document.integration.test.js.map +1 -0
  5. package/lib/__tests__/integration/media.integration.test.d.ts +1 -0
  6. package/lib/__tests__/integration/media.integration.test.js +119 -0
  7. package/lib/__tests__/integration/media.integration.test.js.map +1 -0
  8. package/lib/__tests__/integration/order.integration.test.d.ts +1 -0
  9. package/lib/__tests__/integration/order.integration.test.js +25 -0
  10. package/lib/__tests__/integration/order.integration.test.js.map +1 -0
  11. package/lib/__tests__/integration/payment.integration.test.d.ts +1 -0
  12. package/lib/__tests__/integration/payment.integration.test.js +56 -0
  13. package/lib/__tests__/integration/payment.integration.test.js.map +1 -0
  14. package/lib/__tests__/integration/product.integration.test.d.ts +1 -0
  15. package/lib/__tests__/integration/product.integration.test.js +191 -0
  16. package/lib/__tests__/integration/product.integration.test.js.map +1 -0
  17. package/lib/__tests__/integration/public.integration.test.d.ts +1 -0
  18. package/lib/__tests__/integration/public.integration.test.js +27 -0
  19. package/lib/__tests__/integration/public.integration.test.js.map +1 -0
  20. package/lib/__tests__/integration/setup.d.ts +6 -0
  21. package/lib/__tests__/integration/setup.js +51 -0
  22. package/lib/__tests__/integration/setup.js.map +1 -0
  23. package/lib/__tests__/integration/shop.integration.test.d.ts +1 -0
  24. package/lib/__tests__/integration/shop.integration.test.js +23 -0
  25. package/lib/__tests__/integration/shop.integration.test.js.map +1 -0
  26. package/lib/__tests__/integration/voucher.integration.test.d.ts +1 -0
  27. package/lib/__tests__/integration/voucher.integration.test.js +63 -0
  28. package/lib/__tests__/integration/voucher.integration.test.js.map +1 -0
  29. package/lib/__tests__/managers/order.manager.test.js +38 -0
  30. package/lib/__tests__/managers/order.manager.test.js.map +1 -1
  31. package/lib/__tests__/managers/payment.manager.test.js +13 -15
  32. package/lib/__tests__/managers/payment.manager.test.js.map +1 -1
  33. package/lib/__tests__/sdk.test.js +93 -4
  34. package/lib/__tests__/sdk.test.js.map +1 -1
  35. package/lib/__tests__/utils/env-helper.d.ts +22 -0
  36. package/lib/__tests__/utils/env-helper.js +53 -0
  37. package/lib/__tests__/utils/env-helper.js.map +1 -0
  38. package/lib/__tests__/utils/init.d.ts +1 -0
  39. package/lib/__tests__/utils/init.js +45 -0
  40. package/lib/__tests__/utils/init.js.map +1 -0
  41. package/lib/__tests__/utils/sandbox-auth-automation.d.ts +8 -0
  42. package/lib/__tests__/utils/sandbox-auth-automation.js +109 -0
  43. package/lib/__tests__/utils/sandbox-auth-automation.js.map +1 -0
  44. package/lib/fetch.js +6 -7
  45. package/lib/fetch.js.map +1 -1
  46. package/lib/managers/order.manager.d.ts +8 -1
  47. package/lib/managers/order.manager.js +14 -0
  48. package/lib/managers/order.manager.js.map +1 -1
  49. package/lib/schemas/logistics.d.ts +9 -0
  50. package/lib/schemas/logistics.js.map +1 -1
  51. package/lib/schemas/order.d.ts +56 -0
  52. package/lib/schemas/order.js.map +1 -1
  53. package/lib/schemas/payment.d.ts +6 -14
  54. package/lib/schemas/region.d.ts +9 -2
  55. package/lib/schemas/region.js +9 -2
  56. package/lib/schemas/region.js.map +1 -1
  57. package/lib/sdk.d.ts +6 -1
  58. package/lib/sdk.js +22 -6
  59. package/lib/sdk.js.map +1 -1
  60. package/lib/version.d.ts +1 -1
  61. package/lib/version.js +1 -1
  62. package/package.json +6 -1
@@ -59,6 +59,16 @@ export interface OrderItem {
59
59
  /** The unique identifier of a specific promotion applied to an item */
60
60
  promotion_id: number;
61
61
  }>;
62
+ /** The quantity of the item model that remains active in the order and is still expected to be fulfilled */
63
+ active_qty?: number;
64
+ /** The quantity of the item model that is currently under a cancellation request but has not yet reached the final cancelled status */
65
+ cancel_requested_qty?: number;
66
+ /** The quantity of the item model that has already been successfully cancelled */
67
+ cancelled_qty?: number;
68
+ /** The quantity of the item model that is currently under a return/refund request */
69
+ return_requested_qty?: number;
70
+ /** The quantity of the item model that has already been successfully returned through the return/refund process */
71
+ returned_qty?: number;
62
72
  }
63
73
  /**
64
74
  * Represents an item in a package with basic information
@@ -282,6 +292,12 @@ export interface Order {
282
292
  }>;
283
293
  /** [Only for PH,TH,VN,MY,BR,TW] True if the order includes hot listing item */
284
294
  hot_listing_order?: boolean;
295
+ /** Indicates whether the order can be full cancelled */
296
+ can_full_cancel_order?: boolean;
297
+ /** Indicates whether the order is eligible for partial cancellation */
298
+ can_partial_cancel_order?: boolean;
299
+ /** Indicates the buyer’s preference for handling out-of-stock items in the order */
300
+ buyer_preference_for_partial_cancellation?: number;
285
301
  }
286
302
  /**
287
303
  * The kind of time range field for order list query
@@ -479,6 +495,21 @@ export interface CancelOrderItem {
479
495
  /** Shopee's unique identifier for a model of an item */
480
496
  model_id: number;
481
497
  }
498
+ /**
499
+ * Represents an item in a partial cancel request
500
+ */
501
+ export interface CancelOrderPartialCancelItem {
502
+ /** The unique identifier of the item to be partially cancelled */
503
+ item_id: number;
504
+ /** The unique identifier of the model to be partially cancelled */
505
+ model_id: number;
506
+ /** The identity of order item */
507
+ order_item_id?: number;
508
+ /** The identity of product promotion */
509
+ promotion_group_id?: number;
510
+ /** The quantity of the specified item model to be cancelled */
511
+ model_quantity: number;
512
+ }
482
513
  /**
483
514
  * Parameters for canceling an order
484
515
  */
@@ -489,6 +520,8 @@ export interface CancelOrderParams {
489
520
  cancel_reason: string;
490
521
  /** Required when cancel_reason is OUT_OF_STOCK */
491
522
  item_list?: CancelOrderItem[];
523
+ /** The list of item models and quantities that the seller wants to partially cancel */
524
+ partial_cancel_item_list?: CancelOrderPartialCancelItem[];
492
525
  }
493
526
  /**
494
527
  * Response from canceling an order
@@ -498,6 +531,23 @@ export interface CancelOrderResponse extends FetchResponse<{
498
531
  update_time: number;
499
532
  }> {
500
533
  }
534
+ /**
535
+ * Parameters for getting estimated cancellation value
536
+ */
537
+ export interface GetEstimateCancelValueParams {
538
+ /** Shopee's unique identifier for an order */
539
+ order_sn: string;
540
+ /** The list of item models and quantities for estimate calculation */
541
+ partial_cancel_item_list: CancelOrderPartialCancelItem[];
542
+ }
543
+ /**
544
+ * Response for getting estimated cancellation value
545
+ */
546
+ export interface GetEstimateCancelValueResponse extends FetchResponse<{
547
+ /** The estimated cancellation value for the selected item quantities */
548
+ cancel_value: number;
549
+ }> {
550
+ }
501
551
  /**
502
552
  * Query parameters for getting buyer invoice info
503
553
  */
@@ -722,6 +772,12 @@ export interface PackageDetail {
722
772
  is_buyer_shop_collection?: boolean;
723
773
  /** The image url of the proof for buyer self collection at the store */
724
774
  buyer_proof_of_collection?: string[];
775
+ /** Indicates whether the order can be full cancelled */
776
+ can_full_cancel_order?: boolean;
777
+ /** Indicates whether the order is eligible for partial cancellation */
778
+ can_partial_cancel_order?: boolean;
779
+ /** Indicates the buyer’s preference for handling out-of-stock items in the order */
780
+ buyer_preference_for_partial_cancellation?: number;
725
781
  }
726
782
  /**
727
783
  * Response for getting package detail
@@ -1 +1 @@
1
- {"version":3,"file":"order.js","sourceRoot":"","sources":["../../src/schemas/order.ts"],"names":[],"mappings":"AAmXA,MAAM,CAAC,MAAM,iBAAiB,GAC5B,qbAAqb,CAAC"}
1
+ {"version":3,"file":"order.js","sourceRoot":"","sources":["../../src/schemas/order.ts"],"names":[],"mappings":"AAmYA,MAAM,CAAC,MAAM,iBAAiB,GAC5B,qbAAqb,CAAC"}
@@ -545,25 +545,17 @@ export interface GetWalletTransactionListResponse extends BaseResponse {
545
545
  more: boolean;
546
546
  };
547
547
  }
548
- /**
549
- * Payment method item
550
- */
551
- export interface PaymentMethod {
552
- /** Payment method ID */
553
- payment_method_id: number;
554
- /** Payment method name */
555
- payment_method_name: string;
556
- /** Whether this payment method is enabled */
557
- is_enabled: boolean;
548
+ export interface PaymentMethodRegion {
549
+ /** Region code */
550
+ region: string;
551
+ /** List of payment methods in this region */
552
+ payment_method: string[];
558
553
  }
559
554
  /**
560
555
  * Response for get payment method list API
561
556
  */
562
557
  export interface GetPaymentMethodListResponse extends BaseResponse {
563
- response: {
564
- /** List of payment methods */
565
- payment_method_list: PaymentMethod[];
566
- };
558
+ response: PaymentMethodRegion[];
567
559
  }
568
560
  /**
569
561
  * Response for get shop installment status API
@@ -7,8 +7,15 @@ export declare enum ShopeeRegion {
7
7
  }
8
8
  export declare const SHOPEE_BASE_URLS: {
9
9
  readonly GLOBAL: "https://partner.shopeemobile.com/api/v2";
10
- readonly CHINA: "https://openplatform.shopee.cn/api/v2/public";
10
+ readonly CHINA: "https://openplatform.shopee.cn/api/v2";
11
11
  readonly BRAZIL: "https://openplatform.shopee.com.br/api/v2";
12
- readonly TEST_GLOBAL: "https://partner.test-stable.shopeemobile.com/api/v2";
12
+ readonly TEST_GLOBAL: "https://openplatform.sandbox.test-stable.shopee.sg/api/v2";
13
13
  readonly TEST_CHINA: "https://openplatform.test-stable.shopee.cn/api/v2";
14
14
  };
15
+ export declare const SHOPEE_AUTH_URLS: {
16
+ GLOBAL: string;
17
+ CHINA: string;
18
+ BRAZIL: string;
19
+ TEST_GLOBAL: string;
20
+ TEST_CHINA: string;
21
+ };
@@ -8,9 +8,16 @@ export var ShopeeRegion;
8
8
  })(ShopeeRegion || (ShopeeRegion = {}));
9
9
  export const SHOPEE_BASE_URLS = {
10
10
  [ShopeeRegion.GLOBAL]: "https://partner.shopeemobile.com/api/v2",
11
- [ShopeeRegion.CHINA]: "https://openplatform.shopee.cn/api/v2/public",
11
+ [ShopeeRegion.CHINA]: "https://openplatform.shopee.cn/api/v2",
12
12
  [ShopeeRegion.BRAZIL]: "https://openplatform.shopee.com.br/api/v2",
13
- [ShopeeRegion.TEST_GLOBAL]: "https://partner.test-stable.shopeemobile.com/api/v2",
13
+ [ShopeeRegion.TEST_GLOBAL]: "https://openplatform.sandbox.test-stable.shopee.sg/api/v2",
14
14
  [ShopeeRegion.TEST_CHINA]: "https://openplatform.test-stable.shopee.cn/api/v2",
15
15
  };
16
+ export const SHOPEE_AUTH_URLS = {
17
+ [ShopeeRegion.GLOBAL]: "https://open.shopee.com/auth",
18
+ [ShopeeRegion.CHINA]: "https://open.shopee.cn/auth",
19
+ [ShopeeRegion.BRAZIL]: "https://open.shopee.com.br/auth",
20
+ [ShopeeRegion.TEST_GLOBAL]: "https://open.sandbox.test-stable.shopee.com/auth",
21
+ [ShopeeRegion.TEST_CHINA]: "https://open.sandbox.test-stable.shopee.cn/auth",
22
+ };
16
23
  //# sourceMappingURL=region.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"region.js","sourceRoot":"","sources":["../../src/schemas/region.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,YAMX;AAND,WAAY,YAAY;IACtB,iCAAiB,CAAA;IACjB,+BAAe,CAAA;IACf,iCAAiB,CAAA;IACjB,2CAA2B,CAAA;IAC3B,yCAAyB,CAAA;AAC3B,CAAC,EANW,YAAY,KAAZ,YAAY,QAMvB;AAED,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE,yCAAyC;IAChE,CAAC,YAAY,CAAC,KAAK,CAAC,EAAE,8CAA8C;IACpE,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE,2CAA2C;IAClE,CAAC,YAAY,CAAC,WAAW,CAAC,EAAE,qDAAqD;IACjF,CAAC,YAAY,CAAC,UAAU,CAAC,EAAE,mDAAmD;CACtE,CAAC"}
1
+ {"version":3,"file":"region.js","sourceRoot":"","sources":["../../src/schemas/region.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,YAMX;AAND,WAAY,YAAY;IACtB,iCAAiB,CAAA;IACjB,+BAAe,CAAA;IACf,iCAAiB,CAAA;IACjB,2CAA2B,CAAA;IAC3B,yCAAyB,CAAA;AAC3B,CAAC,EANW,YAAY,KAAZ,YAAY,QAMvB;AAED,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE,yCAAyC;IAChE,CAAC,YAAY,CAAC,KAAK,CAAC,EAAE,uCAAuC;IAC7D,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE,2CAA2C;IAClE,CAAC,YAAY,CAAC,WAAW,CAAC,EAAE,2DAA2D;IACvF,CAAC,YAAY,CAAC,UAAU,CAAC,EAAE,mDAAmD;CACtE,CAAC;AAEX,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE,8BAA8B;IACrD,CAAC,YAAY,CAAC,KAAK,CAAC,EAAE,6BAA6B;IACnD,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE,iCAAiC;IACxD,CAAC,YAAY,CAAC,WAAW,CAAC,EAAE,kDAAkD;IAC9E,CAAC,YAAY,CAAC,UAAU,CAAC,EAAE,iDAAiD;CAC7E,CAAC"}
package/lib/sdk.d.ts CHANGED
@@ -36,6 +36,7 @@ export interface ShopeeConfig {
36
36
  partner_key: string;
37
37
  region?: ShopeeRegion;
38
38
  base_url?: string;
39
+ base_auth_url?: string;
39
40
  sdk?: ShopeeSDK;
40
41
  shop_id?: number;
41
42
  agent?: Agent;
@@ -76,8 +77,12 @@ export declare class ShopeeSDK {
76
77
  getConfig(): ShopeeConfig;
77
78
  setRegion(region: ShopeeRegion): void;
78
79
  setBaseUrl(baseUrl: string): void;
80
+ setBaseAuthUrl(baseAuthUrl: string): void;
79
81
  setFetchAgent(fetchAgent: Agent): void;
80
- getAuthorizationUrl(redirect_uri: string): string;
82
+ getAuthorizationUrl(redirect_uri: string, options?: {
83
+ auth_type?: "seller" | "supplier" | "user";
84
+ state?: string;
85
+ }): string;
81
86
  authenticateWithCode(code: string, shopId?: number, mainAccountId?: number): Promise<AccessToken | null>;
82
87
  getAuthToken(): Promise<AccessToken | null>;
83
88
  refreshToken(shop_id?: number, merchant_id?: number): Promise<AccessToken | null>;
package/lib/sdk.js CHANGED
@@ -1,12 +1,11 @@
1
1
  import { ProductManager } from "./managers/product.manager.js";
2
2
  import { OrderManager } from "./managers/order.manager.js";
3
3
  import { AuthManager } from "./managers/auth.manager.js";
4
- import { ShopeeRegion, SHOPEE_BASE_URLS } from "./schemas/region.js";
4
+ import { ShopeeRegion, SHOPEE_BASE_URLS, SHOPEE_AUTH_URLS } from "./schemas/region.js";
5
5
  import { CustomTokenStorage } from "./storage/custom-token-storage.js";
6
6
  import { ShopeeSdkError } from "./errors.js";
7
7
  import { PublicManager } from "./managers/public.manager.js";
8
8
  import { PushManager } from "./managers/push.manager.js";
9
- import { generateSignature } from "./utils/signature.js";
10
9
  import { PaymentManager } from "./managers/payment.manager.js";
11
10
  import { LogisticsManager } from "./managers/logistics.manager.js";
12
11
  import { VoucherManager } from "./managers/voucher.manager.js";
@@ -65,10 +64,12 @@ export class ShopeeSDK {
65
64
  video;
66
65
  constructor(config, tokenStorage) {
67
66
  this.config = {
68
- region: ShopeeRegion.GLOBAL,
69
67
  ...config,
68
+ region: config.region || (config.base_url ? undefined : ShopeeRegion.GLOBAL),
70
69
  base_url: config.base_url ||
71
70
  (config.region ? SHOPEE_BASE_URLS[config.region] : SHOPEE_BASE_URLS[ShopeeRegion.GLOBAL]),
71
+ base_auth_url: config.base_auth_url ||
72
+ (config.region ? SHOPEE_AUTH_URLS[config.region] : SHOPEE_AUTH_URLS[ShopeeRegion.GLOBAL]),
72
73
  sdk: this,
73
74
  };
74
75
  // Initialize token storage
@@ -110,17 +111,32 @@ export class ShopeeSDK {
110
111
  setRegion(region) {
111
112
  this.config.region = region;
112
113
  this.config.base_url = SHOPEE_BASE_URLS[region];
114
+ this.config.base_auth_url = SHOPEE_AUTH_URLS[region];
113
115
  }
114
116
  setBaseUrl(baseUrl) {
115
117
  this.config.base_url = baseUrl;
116
118
  this.config.region = undefined;
117
119
  }
120
+ setBaseAuthUrl(baseAuthUrl) {
121
+ this.config.base_auth_url = baseAuthUrl;
122
+ this.config.region = undefined;
123
+ }
118
124
  setFetchAgent(fetchAgent) {
119
125
  this.config.agent = fetchAgent;
120
126
  }
121
- getAuthorizationUrl(redirect_uri) {
122
- const timestamp = Math.floor(Date.now() / 1000);
123
- return `${this.config.base_url}/shop/auth_partner?partner_id=${this.config.partner_id}&timestamp=${timestamp}&redirect=${redirect_uri}&sign=${generateSignature(this.config.partner_key, [this.config.partner_id.toString(), "/api/v2/shop/auth_partner", timestamp.toString()])}`;
127
+ getAuthorizationUrl(redirect_uri, options) {
128
+ const authType = options?.auth_type || "seller";
129
+ const state = options?.state;
130
+ const authBaseUrl = this.config.base_auth_url || SHOPEE_AUTH_URLS[this.config.region || ShopeeRegion.GLOBAL];
131
+ const url = new URL(authBaseUrl);
132
+ url.searchParams.append("partner_id", this.config.partner_id.toString());
133
+ url.searchParams.append("auth_type", authType);
134
+ url.searchParams.append("redirect_uri", redirect_uri);
135
+ url.searchParams.append("response_type", "code");
136
+ if (state) {
137
+ url.searchParams.append("state", state);
138
+ }
139
+ return url.toString();
124
140
  }
125
141
  async authenticateWithCode(code, shopId, mainAccountId) {
126
142
  const token = await this.auth.getAccessToken(code, shopId, mainAccountId);
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,WAAW,EAAE,MAAM,4BAA4B,CAAC;AACzD,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAErE,OAAO,EAAE,kBAAkB,EAAE,MAAM,mCAAmC,CAAC;AAEvE,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAC7D,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4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AAC,oBAAoB,CAC/B,IAAY,EACZ,MAAe,EACf,aAAsB;QAEtB,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,cAAc,CAAC,IAAI,EAAE,MAAM,EAAE,aAAa,CAAC,CAAC;QAC1E,MAAM,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;QACrC,OAAO,KAAK,CAAC;IACf,CAAC;IAEM,KAAK,CAAC,YAAY;QACvB,OAAO,IAAI,CAAC,YAAY,CAAC,GAAG,EAAE,CAAC;IACjC,CAAC;IAEM,KAAK,CAAC,YAAY,CAAC,OAAgB,EAAE,WAAoB;QAC9D,MAAM,SAAS,GAAG,MAAM,IAAI,CAAC,YAAY,CAAC,GAAG,EAAE,CAAC;QAChD,IAAI,CAAC,SAAS,EAAE,CAAC;YACf,MAAM,IAAI,cAAc,CAAC,2BAA2B,CAAC,CAAC;QACxD,CAAC;QACD,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,eAAe,CAC3C,SAAS,CAAC,aAAa,EACvB,OAAO,IAAI,SAAS,CAAC,OAAO,EAC5B,WAAW,CACZ,CAAC;QACF,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,OAAO,IAAI,CAAC;QACd,CAAC;QAED,MAAM,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;QACrC,OAAO,KAAK,CAAC;IACf,CAAC;CACF;AAED,eAAe,SAAS,CAAC"}
package/lib/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "1.7.0";
1
+ export declare const SDK_VERSION = "1.9.0";
package/lib/version.js CHANGED
@@ -1,3 +1,3 @@
1
1
  // This file is auto-generated during the build process. Do not edit manually.
2
- export const SDK_VERSION = "1.7.0";
2
+ export const SDK_VERSION = "1.9.0";
3
3
  //# sourceMappingURL=version.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@congminh1254/shopee-sdk",
3
- "version": "1.7.0",
3
+ "version": "1.9.0",
4
4
  "description": "Shopee SDK maintaining by community",
5
5
  "type": "module",
6
6
  "main": "./lib/sdk.js",
@@ -41,6 +41,8 @@
41
41
  "prebuild": "node scripts/generate-version.js",
42
42
  "build": "npm run prebuild && node --loader ts-node/esm node_modules/.bin/tsc",
43
43
  "test": "NODE_OPTIONS=--experimental-vm-modules jest",
44
+ "test:sandbox": "dotenv -- tsx src/__tests__/utils/init.ts",
45
+ "auth:sandbox": "dotenv -- tsx src/__tests__/utils/init.ts --auth-only",
44
46
  "format": "prettier --write \"src/**/*.ts\"",
45
47
  "format:check": "prettier --check \"src/**/*.ts\"",
46
48
  "lint": "eslint \"src/**/*.ts\"",
@@ -76,11 +78,14 @@
76
78
  "@types/jest": "^30.0.0",
77
79
  "@typescript-eslint/eslint-plugin": "^8.59.0",
78
80
  "@typescript-eslint/parser": "^8.59.0",
81
+ "dotenv": "^17.4.2",
82
+ "dotenv-cli": "^11.0.0",
79
83
  "eslint": "^10.2.1",
80
84
  "eslint-config-prettier": "^10.1.8",
81
85
  "globals": "^17.5.0",
82
86
  "husky": "^9.1.7",
83
87
  "jest": "^30.4.2",
88
+ "playwright": "^1.60.0",
84
89
  "prettier": "^3.8.3",
85
90
  "ts-jest": "^29.4.10",
86
91
  "ts-node": "^10.9.2",