@sp-api-sdk/easy-ship-api-2022-03-23 4.3.10 → 4.3.12

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.
@@ -90,6 +90,7 @@ exports.setSearchParams = setSearchParams;
90
90
  * This function will run for every key-value pair encountered by JSON.stringify while traversing an object.
91
91
  * Converting a set to a string will return an empty object, so an intermediate conversion to an array is required.
92
92
  */
93
+ // @ts-ignore
93
94
  const replaceWithSerializableTypeIfNeeded = function (key, value) {
94
95
  if (value instanceof Set) {
95
96
  return Array.from(value);
@@ -91,8 +91,8 @@ class Configuration {
91
91
  * @return True if the given MIME is JSON, false otherwise.
92
92
  */
93
93
  isJsonMime(mime) {
94
- const jsonMime = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
95
- return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
94
+ const jsonMime = /^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$/i;
95
+ return mime !== null && jsonMime.test(mime);
96
96
  }
97
97
  }
98
98
  exports.Configuration = Configuration;
@@ -28,5 +28,5 @@ exports.Code = {
28
28
  InvalidOrderState: 'InvalidOrderState',
29
29
  RegionNotSupported: 'RegionNotSupported',
30
30
  OrderNotEligibleForRescheduling: 'OrderNotEligibleForRescheduling',
31
- InternalServerError: 'InternalServerError'
31
+ InternalServerError: 'InternalServerError',
32
32
  };
@@ -19,5 +19,5 @@ exports.HandoverMethod = void 0;
19
19
  */
20
20
  exports.HandoverMethod = {
21
21
  Pickup: 'PICKUP',
22
- Dropoff: 'DROPOFF'
22
+ Dropoff: 'DROPOFF',
23
23
  };
@@ -19,5 +19,5 @@ exports.LabelFormat = void 0;
19
19
  */
20
20
  exports.LabelFormat = {
21
21
  Pdf: 'PDF',
22
- Zpl: 'ZPL'
22
+ Zpl: 'ZPL',
23
23
  };
@@ -29,5 +29,5 @@ exports.PackageStatus = {
29
29
  LostInTransit: 'LostInTransit',
30
30
  LabelCanceled: 'LabelCanceled',
31
31
  DamagedInTransit: 'DamagedInTransit',
32
- OutForDelivery: 'OutForDelivery'
32
+ OutForDelivery: 'OutForDelivery',
33
33
  };
@@ -18,5 +18,5 @@ exports.UnitOfLength = void 0;
18
18
  * The unit of measurement used to measure the length.
19
19
  */
20
20
  exports.UnitOfLength = {
21
- Cm: 'cm'
21
+ Cm: 'cm',
22
22
  };
@@ -19,5 +19,5 @@ exports.UnitOfWeight = void 0;
19
19
  */
20
20
  exports.UnitOfWeight = {
21
21
  Grams: 'grams',
22
- G: 'g'
22
+ G: 'g',
23
23
  };
@@ -81,6 +81,7 @@ export const setSearchParams = function (url, ...objects) {
81
81
  * This function will run for every key-value pair encountered by JSON.stringify while traversing an object.
82
82
  * Converting a set to a string will return an empty object, so an intermediate conversion to an array is required.
83
83
  */
84
+ // @ts-ignore
84
85
  export const replaceWithSerializableTypeIfNeeded = function (key, value) {
85
86
  if (value instanceof Set) {
86
87
  return Array.from(value);
@@ -88,7 +88,7 @@ export class Configuration {
88
88
  * @return True if the given MIME is JSON, false otherwise.
89
89
  */
90
90
  isJsonMime(mime) {
91
- const jsonMime = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
92
- return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
91
+ const jsonMime = /^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$/i;
92
+ return mime !== null && jsonMime.test(mime);
93
93
  }
94
94
  }
@@ -25,5 +25,5 @@ export const Code = {
25
25
  InvalidOrderState: 'InvalidOrderState',
26
26
  RegionNotSupported: 'RegionNotSupported',
27
27
  OrderNotEligibleForRescheduling: 'OrderNotEligibleForRescheduling',
28
- InternalServerError: 'InternalServerError'
28
+ InternalServerError: 'InternalServerError',
29
29
  };
@@ -16,5 +16,5 @@
16
16
  */
17
17
  export const HandoverMethod = {
18
18
  Pickup: 'PICKUP',
19
- Dropoff: 'DROPOFF'
19
+ Dropoff: 'DROPOFF',
20
20
  };
@@ -16,5 +16,5 @@
16
16
  */
17
17
  export const LabelFormat = {
18
18
  Pdf: 'PDF',
19
- Zpl: 'ZPL'
19
+ Zpl: 'ZPL',
20
20
  };
@@ -26,5 +26,5 @@ export const PackageStatus = {
26
26
  LostInTransit: 'LostInTransit',
27
27
  LabelCanceled: 'LabelCanceled',
28
28
  DamagedInTransit: 'DamagedInTransit',
29
- OutForDelivery: 'OutForDelivery'
29
+ OutForDelivery: 'OutForDelivery',
30
30
  };
@@ -15,5 +15,5 @@
15
15
  * The unit of measurement used to measure the length.
16
16
  */
17
17
  export const UnitOfLength = {
18
- Cm: 'cm'
18
+ Cm: 'cm',
19
19
  };
@@ -16,5 +16,5 @@
16
16
  */
17
17
  export const UnitOfWeight = {
18
18
  Grams: 'grams',
19
- G: 'g'
19
+ G: 'g',
20
20
  };
@@ -28,7 +28,7 @@ export declare const setSearchParams: (url: URL, ...objects: any[]) => void;
28
28
  * This function will run for every key-value pair encountered by JSON.stringify while traversing an object.
29
29
  * Converting a set to a string will return an empty object, so an intermediate conversion to an array is required.
30
30
  */
31
- export declare const replaceWithSerializableTypeIfNeeded: (key: any, value: any) => any;
31
+ export declare const replaceWithSerializableTypeIfNeeded: (key: string, value: any) => any;
32
32
  export declare const serializeDataIfNeeded: (value: any, requestOptions: any, configuration?: Configuration) => any;
33
33
  export declare const toPathString: (url: URL) => string;
34
34
  export declare const createRequestFunction: (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) => <T = unknown, R = AxiosResponse<T>>(axios?: AxiosInstance, basePath?: string) => Promise<R>;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@sp-api-sdk/easy-ship-api-2022-03-23",
3
3
  "author": "Bertrand Marron <bertrand@bizon.solutions>",
4
4
  "description": "Use the Selling Partner API for Easy Ship to build applications for sellers to manage and ship Amazon Easy Ship orders. With this API, you can get available time slots, schedule and reschedule Easy Ship orders, and print shipping labels, invoices, and warranties. To review the differences in Easy Ship operations by marketplace, refer to Marketplace support.",
5
- "version": "4.3.10",
5
+ "version": "4.3.12",
6
6
  "main": "dist/cjs/index.js",
7
7
  "module": "dist/es/index.js",
8
8
  "types": "dist/types/index.d.ts",
@@ -18,8 +18,8 @@
18
18
  "dist/**/*.d.ts"
19
19
  ],
20
20
  "dependencies": {
21
- "@sp-api-sdk/common": "2.1.29",
22
- "axios": "^1.13.5"
21
+ "@sp-api-sdk/common": "2.1.31",
22
+ "axios": "^1.15.2"
23
23
  },
24
24
  "repository": {
25
25
  "type": "git",
@@ -40,5 +40,5 @@
40
40
  "sp sdk",
41
41
  "easy ship api"
42
42
  ],
43
- "gitHead": "2c1fe783fb7c2204e7e19d4f85fa2bdf822e4593"
43
+ "gitHead": "cc3ed7e58346bf7a4110ed8f1353aae840f294e2"
44
44
  }