@medusajs/js-sdk 2.0.5-snapshot-20241120143407 → 2.0.5-snapshot-20241124153140
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/admin/order.d.ts +20 -0
- package/dist/admin/order.d.ts.map +1 -1
- package/dist/admin/order.js +26 -0
- package/dist/admin/order.js.map +1 -1
- package/dist/auth/index.d.ts +4 -4
- package/dist/auth/index.d.ts.map +1 -1
- package/dist/auth/index.js +5 -5
- package/dist/auth/index.js.map +1 -1
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +4 -2
- package/dist/client.js.map +1 -1
- package/dist/esm/admin/order.d.ts +20 -0
- package/dist/esm/admin/order.d.ts.map +1 -1
- package/dist/esm/admin/order.js +28 -0
- package/dist/esm/admin/order.js.map +1 -1
- package/dist/esm/auth/index.d.ts +4 -4
- package/dist/esm/auth/index.d.ts.map +1 -1
- package/dist/esm/auth/index.js +5 -5
- package/dist/esm/auth/index.js.map +1 -1
- package/dist/esm/client.d.ts.map +1 -1
- package/dist/esm/client.js +4 -2
- package/dist/esm/client.js.map +1 -1
- package/dist/esm/store/index.d.ts +97 -0
- package/dist/esm/store/index.d.ts.map +1 -1
- package/dist/esm/store/index.js +124 -0
- package/dist/esm/store/index.js.map +1 -1
- package/dist/store/index.d.ts +97 -0
- package/dist/store/index.d.ts.map +1 -1
- package/dist/store/index.js +124 -0
- package/dist/store/index.js.map +1 -1
- package/package.json +2 -2
package/dist/admin/order.d.ts
CHANGED
@@ -123,6 +123,26 @@ export declare class Order {
|
|
123
123
|
* })
|
124
124
|
*/
|
125
125
|
cancel(id: string, headers?: ClientHeaders): Promise<HttpTypes.AdminOrderResponse>;
|
126
|
+
/**
|
127
|
+
* This method requests an order transfer. It sends a request to the
|
128
|
+
* [Request Order Transfer](https://docs.medusajs.com/api/admin#orders_postordersidrequesttransfer)
|
129
|
+
* API route.
|
130
|
+
*
|
131
|
+
* @param id - The order's ID.
|
132
|
+
* @param headers - Headers to pass in the request.
|
133
|
+
* @param body - The transfer's details - the id of the next owner.
|
134
|
+
* @returns The order's details.
|
135
|
+
*
|
136
|
+
* @example
|
137
|
+
* sdk.admin.order.requestTransfer("order_123", {
|
138
|
+
* customer_id: "cus_123",
|
139
|
+
* internal_note: "Internal note",
|
140
|
+
* })
|
141
|
+
* .then(({ order }) => {
|
142
|
+
* console.log(order)
|
143
|
+
* })
|
144
|
+
*/
|
145
|
+
requestTransfer(id: string, body: HttpTypes.AdminRequestOrderTransfer, headers?: ClientHeaders): Promise<HttpTypes.AdminOrderResponse>;
|
126
146
|
/**
|
127
147
|
* This method creates a fulfillment for an order. It sends a request to the
|
128
148
|
* [Create Fulfillment](https://docs.medusajs.com/api/admin#orders_postordersidfulfillments)
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"order.d.ts","sourceRoot":"","sources":["../../src/admin/order.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,SAAS,EAET,YAAY,EACb,MAAM,iBAAiB,CAAA;AAGxB,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAA;AAExC,qBAAa,KAAK;IAChB;;OAEG;IACH,OAAO,CAAC,MAAM,CAAQ;IACtB;;OAEG;gBACS,MAAM,EAAE,MAAM;IAI1B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAgCG;IACG,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,YAAY,EAAE,OAAO,CAAC,EAAE,aAAa;IAUxE;;;;;;;;;;;;;;OAcG;IACG,eAAe,CACnB,EAAE,EAAE,MAAM,EACV,KAAK,CAAC,EAAE,SAAS,CAAC,iBAAiB,EACnC,OAAO,CAAC,EAAE,aAAa;IAWzB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6CG;IACG,IAAI,CACR,WAAW,CAAC,EAAE,SAAS,CAAC,iBAAiB,EACzC,OAAO,CAAC,EAAE,aAAa;
|
1
|
+
{"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EAAE,EAAE,MAAM,EACV,aAAa,EAAE,MAAM,EACrB,IAAI,EAAE,SAAS,CAAC,2BAA2B,EAC3C,OAAO,CAAC,EAAE,aAAa;IAYzB;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA4BG;IACG,cAAc,CAClB,EAAE,EAAE,MAAM,EACV,aAAa,EAAE,MAAM,EACrB,IAAI,EAAE,SAAS,CAAC,wBAAwB,EACxC,KAAK,CAAC,EAAE,YAAY,EACpB,OAAO,CAAC,EAAE,aAAa;IAazB;;;;;;;;;;;;;;;;;;;;;OAqBG;IACG,eAAe,CACnB,EAAE,EAAE,MAAM,EACV,aAAa,EAAE,MAAM,EACrB,IAAI,EAAE,SAAS,CAAC,oCAAoC,EACpD,KAAK,CAAC,EAAE,YAAY,EACpB,OAAO,CAAC,EAAE,aAAa;IAazB;;;;;;;;;;;;;;;;OAgBG;IACG,WAAW,CACf,EAAE,EAAE,MAAM,EACV,WAAW,CAAC,EAAE,UAAU,GAAG,SAAS,CAAC,wBAAwB,EAC7D,OAAO,CAAC,EAAE,aAAa;IAUzB;;;;;;;;;;;;;;;OAeG;IACG,aAAa,CACjB,EAAE,EAAE,MAAM,EACV,WAAW,CAAC,EAAE,UAAU,GAAG,SAAS,CAAC,sBAAsB,EAC3D,OAAO,CAAC,EAAE,aAAa;CAU1B"}
|
package/dist/admin/order.js
CHANGED
@@ -141,6 +141,32 @@ class Order {
|
|
141
141
|
headers,
|
142
142
|
});
|
143
143
|
}
|
144
|
+
/**
|
145
|
+
* This method requests an order transfer. It sends a request to the
|
146
|
+
* [Request Order Transfer](https://docs.medusajs.com/api/admin#orders_postordersidrequesttransfer)
|
147
|
+
* API route.
|
148
|
+
*
|
149
|
+
* @param id - The order's ID.
|
150
|
+
* @param headers - Headers to pass in the request.
|
151
|
+
* @param body - The transfer's details - the id of the next owner.
|
152
|
+
* @returns The order's details.
|
153
|
+
*
|
154
|
+
* @example
|
155
|
+
* sdk.admin.order.requestTransfer("order_123", {
|
156
|
+
* customer_id: "cus_123",
|
157
|
+
* internal_note: "Internal note",
|
158
|
+
* })
|
159
|
+
* .then(({ order }) => {
|
160
|
+
* console.log(order)
|
161
|
+
* })
|
162
|
+
*/
|
163
|
+
async requestTransfer(id, body, headers) {
|
164
|
+
return await this.client.fetch(`/admin/orders/${id}/transfer`, {
|
165
|
+
method: "POST",
|
166
|
+
headers,
|
167
|
+
body,
|
168
|
+
});
|
169
|
+
}
|
144
170
|
/**
|
145
171
|
* This method creates a fulfillment for an order. It sends a request to the
|
146
172
|
* [Create Fulfillment](https://docs.medusajs.com/api/admin#orders_postordersidfulfillments)
|
package/dist/admin/order.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"order.js","sourceRoot":"","sources":["../../src/admin/order.ts"],"names":[],"mappings":";;;AAWA,MAAa,KAAK;IAKhB;;OAEG;IACH,YAAY,MAAc;QACxB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAA;IACtB,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAgCG;IACH,KAAK,CAAC,QAAQ,CAAC,EAAU,EAAE,KAAoB,EAAE,OAAuB;QACtE,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAC5B,iBAAiB,EAAE,EAAE,EACrB;YACE,KAAK;YACL,OAAO;SACR,CACF,CAAA;IACH,CAAC;IAED;;;;;;;;;;;;;;OAcG;IACH,KAAK,CAAC,eAAe,CACnB,EAAU,EACV,KAAmC,EACnC,OAAuB;QAEvB,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAC5B,iBAAiB,EAAE,UAAU,EAC7B;YACE,KAAK;YACL,OAAO;SACR,CACF,CAAA;IACH,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6CG;IACH,KAAK,CAAC,IAAI,CACR,WAAyC,EACzC,OAAuB;QAEvB,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,
|
1
|
+
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,OAAO;YACP,IAAI;YACJ,KAAK;SACN,CACF,CAAA;IACH,CAAC;IAED;;;;;;;;;;;;;;;;OAgBG;IACH,KAAK,CAAC,WAAW,CACf,EAAU,EACV,WAA6D,EAC7D,OAAuB;QAEvB,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAE5B,iBAAiB,EAAE,UAAU,EAAE;YAC/B,KAAK,EAAE,WAAW;YAClB,OAAO;SACR,CAAC,CAAA;IACJ,CAAC;IAED;;;;;;;;;;;;;;;OAeG;IACH,KAAK,CAAC,aAAa,CACjB,EAAU,EACV,WAA2D,EAC3D,OAAuB;QAEvB,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAC5B,iBAAiB,EAAE,aAAa,EAChC;YACE,KAAK,EAAE,WAAW;YAClB,OAAO;SACR,CACF,CAAA;IACH,CAAC;CACF;AA5aD,sBA4aC"}
|
package/dist/auth/index.d.ts
CHANGED
@@ -153,22 +153,22 @@ export declare class Auth {
|
|
153
153
|
* @param actor - The actor type. For example, `user` for admin user, or `customer` for customer.
|
154
154
|
* @param provider - The authentication provider to use. For example, `emailpass`.
|
155
155
|
* @param body - The data necessary to update the user's authentication data. When resetting the user's password,
|
156
|
-
* send the `
|
156
|
+
* send the `password` property.
|
157
157
|
*
|
158
158
|
* @example
|
159
159
|
* sdk.auth.updateProvider(
|
160
160
|
* "customer",
|
161
161
|
* "emailpass",
|
162
162
|
* {
|
163
|
-
* email: "customer@gmail.com",
|
164
163
|
* password: "supersecret"
|
165
|
-
* }
|
164
|
+
* },
|
165
|
+
* token
|
166
166
|
* )
|
167
167
|
* .then(() => {
|
168
168
|
* // password updated
|
169
169
|
* })
|
170
170
|
*/
|
171
|
-
updateProvider: (actor: string, provider: string, body: Record<string, unknown
|
171
|
+
updateProvider: (actor: string, provider: string, body: Record<string, unknown>, token: string) => Promise<void>;
|
172
172
|
/**
|
173
173
|
* @ignore
|
174
174
|
*/
|
package/dist/auth/index.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/auth/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAA;AAC3C,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AAEjC,qBAAa,IAAI;IACf,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,MAAM,CAAQ;gBAEV,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM;IAK1C;;;;;;;;;;;;;;;;;;;;;OAqBG;IACH,QAAQ,UACC,MAAM,UACL,MAAM,WACL,SAAS,CAAC,4BAA4B,qBAahD;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BG;IACH,KAAK,UACI,MAAM,UACL,MAAM,WACL,SAAS,CAAC,4BAA4B,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;OAmB1E;IAED;;;;;;;;;;;;;;;;;;;;;;;;OAwBG;IACH,QAAQ,UACC,MAAM,UACL,MAAM,UACN,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,qBAYhC;IAED;;;;;;;;;;;OAWG;IACH,OAAO,wBAYN;IAED;;;;;;;;;OASG;IACH,MAAM,sBAQL;IAED;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,aAAa,UACJ,MAAM,YACH,MAAM,QACV;QACJ;;;WAGG;QACH,UAAU,EAAE,MAAM,CAAA;KACnB,mBAOF;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BG;IACH,cAAc,UACL,MAAM,YACH,MAAM,QACV,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/auth/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAA;AAC3C,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AAEjC,qBAAa,IAAI;IACf,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,MAAM,CAAQ;gBAEV,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM;IAK1C;;;;;;;;;;;;;;;;;;;;;OAqBG;IACH,QAAQ,UACC,MAAM,UACL,MAAM,WACL,SAAS,CAAC,4BAA4B,qBAahD;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BG;IACH,KAAK,UACI,MAAM,UACL,MAAM,WACL,SAAS,CAAC,4BAA4B,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;OAmB1E;IAED;;;;;;;;;;;;;;;;;;;;;;;;OAwBG;IACH,QAAQ,UACC,MAAM,UACL,MAAM,UACN,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,qBAYhC;IAED;;;;;;;;;;;OAWG;IACH,OAAO,wBAYN;IAED;;;;;;;;;OASG;IACH,MAAM,sBAQL;IAED;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,aAAa,UACJ,MAAM,YACH,MAAM,QACV;QACJ;;;WAGG;QACH,UAAU,EAAE,MAAM,CAAA;KACnB,mBAOF;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BG;IACH,cAAc,UACL,MAAM,YACH,MAAM,QACV,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,SACtB,MAAM,mBASd;IAED;;OAEG;IACH,OAAO,CAAC,SAAS,CAUhB;CACF"}
|
package/dist/auth/index.js
CHANGED
@@ -191,23 +191,23 @@ class Auth {
|
|
191
191
|
* @param actor - The actor type. For example, `user` for admin user, or `customer` for customer.
|
192
192
|
* @param provider - The authentication provider to use. For example, `emailpass`.
|
193
193
|
* @param body - The data necessary to update the user's authentication data. When resetting the user's password,
|
194
|
-
* send the `
|
194
|
+
* send the `password` property.
|
195
195
|
*
|
196
196
|
* @example
|
197
197
|
* sdk.auth.updateProvider(
|
198
198
|
* "customer",
|
199
199
|
* "emailpass",
|
200
200
|
* {
|
201
|
-
* email: "customer@gmail.com",
|
202
201
|
* password: "supersecret"
|
203
|
-
* }
|
202
|
+
* },
|
203
|
+
* token
|
204
204
|
* )
|
205
205
|
* .then(() => {
|
206
206
|
* // password updated
|
207
207
|
* })
|
208
208
|
*/
|
209
|
-
this.updateProvider = async (actor, provider, body) => {
|
210
|
-
await this.client.fetch(`/auth/${actor}/${provider}/update`, {
|
209
|
+
this.updateProvider = async (actor, provider, body, token) => {
|
210
|
+
await this.client.fetch(`/auth/${actor}/${provider}/update?token=${token}`, {
|
211
211
|
method: "POST",
|
212
212
|
body,
|
213
213
|
});
|
package/dist/auth/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/auth/index.ts"],"names":[],"mappings":";;;AAIA,MAAa,IAAI;IAIf,YAAY,MAAc,EAAE,MAAc;QAK1C;;;;;;;;;;;;;;;;;;;;;WAqBG;QACH,aAAQ,GAAG,KAAK,EACd,KAAa,EACb,MAAc,EACd,OAA+C,EAC/C,EAAE;YACF,MAAM,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CACvC,SAAS,KAAK,IAAI,MAAM,WAAW,EACnC;gBACE,MAAM,EAAE,MAAM;gBACd,IAAI,EAAE,OAAO;aACd,CACF,CAAA;YAED,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAA;YAE3B,OAAO,KAAK,CAAA;QACd,CAAC,CAAA;QAED;;;;;;;;;;;;;;;;;;;;;;;;;;;WA2BG;QACH,UAAK,GAAG,KAAK,EACX,KAAa,EACb,MAAc,EACd,OAAyE,EACzE,EAAE;YACF,oEAAoE;YACpE,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAGhD,SAAS,KAAK,IAAI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AAG,MAAM,CAAA;QACpB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAA;IACtB,CAAC;CAyRF;AAhSD,oBAgSC"}
|
package/dist/client.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,WAAW,EACX,MAAM,EACN,SAAS,EACT,UAAU,EACV,mBAAmB,EAEpB,MAAM,SAAS,CAAA;AAEhB,eAAO,MAAM,sBAAsB,0BAA0B,CAAA;AA2E7D,qBAAa,UAAW,SAAQ,KAAK;IACnC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,UAAU,EAAE,MAAM,GAAG,SAAS,CAAA;gBAElB,OAAO,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM;CAKlE;AAED,qBAAa,MAAM;IACV,MAAM,EAAE,WAAW,CAAA;IAC1B,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,MAAM,CAAQ;IAEtB,OAAO,CAAC,uBAAuB,CAAsB;IACrD,OAAO,CAAC,KAAK,CAAK;gBAEN,MAAM,EAAE,MAAM;IAiB1B;;;;;;;;;;;OAWG;IACH,KAAK,CAAC,CAAC,SAAS,GAAG,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,CAAC,EAAE,SAAS,GAAG,OAAO,CAAC,CAAC,CAAC;IAIrE;;;;;;;;;OASG;IACG,WAAW,CACf,KAAK,EAAE,UAAU,EACjB,IAAI,CAAC,EAAE,SAAS,GACf,OAAO,CAAC,mBAAmB,CAAC;IAiB/B,QAAQ,CAAC,KAAK,EAAE,MAAM;IAItB,UAAU;IAIV,SAAS,CAAC,WAAW;IAkBrB,SAAS,CAAC,UAAU,IAAI,WAAW;
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,WAAW,EAC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CAAC,SAAS,kCAelB;IAED,SAAS,CAAC,oBAAoB;;;MAqB7B;CACF"}
|
package/dist/client.js
CHANGED
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
6
|
exports.Client = exports.FetchError = exports.PUBLISHABLE_KEY_HEADER = void 0;
|
7
|
-
const qs_1 = __importDefault(require("qs"));
|
8
7
|
const fetch_event_stream_1 = require("fetch-event-stream");
|
8
|
+
const qs_1 = __importDefault(require("qs"));
|
9
9
|
exports.PUBLISHABLE_KEY_HEADER = "x-publishable-api-key";
|
10
10
|
// We want to explicitly retrieve the base URL instead of relying on relative paths that differ in behavior between browsers.
|
11
11
|
const getBaseUrl = (passedBaseUrl) => {
|
@@ -238,7 +238,9 @@ class Client {
|
|
238
238
|
});
|
239
239
|
let normalizedInput = input;
|
240
240
|
if (input instanceof URL || typeof input === "string") {
|
241
|
-
|
241
|
+
const baseUrl = new URL(this.config.baseUrl);
|
242
|
+
const fullPath = `${baseUrl.pathname.replace(/\/$/, '')}/${input.toString().replace(/^\//, '')}`;
|
243
|
+
normalizedInput = new URL(fullPath, baseUrl.origin);
|
242
244
|
if (init?.query) {
|
243
245
|
const params = Object.fromEntries(normalizedInput.searchParams.entries());
|
244
246
|
const stringifiedQuery = qs_1.default.stringify({ ...params, ...init.query });
|
package/dist/client.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":";;;;;;AAAA,
|
1
|
+
{"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":";;;;;;AAAA,2DAA2C;AAC3C,4CAAmB;AAUN,QAAA,sBAAsB,GAAG,uBAAuB,CAAA;AAE7D,6HAA6H;AAC7H,MAAM,UAAU,GAAG,CAAC,aAAqB,EAAE,EAAE;IAC3C,IAAI,OAAO,MAAM,KAAK,WAAW,E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GAAG,MAAM,EAAE,GAAG,IAAI,CAAC,KAAK,EAAE,CAAC,CAAA;oBACnE,eAAe,CAAC,MAAM,GAAG,gBAAgB,CAAA;gBAC3C,CAAC;YACH,CAAC;YAED,IAAI,CAAC,MAAM,CAAC,KAAK,CACf,0BAA0B,EAC1B,QAAQ,eAAe,CAAC,QAAQ,EAAE,IAAI,EACtC,YAAY,IAAI,CAAC,SAAS,CAAC,eAAe,CAAC,OAAO,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,CAClE,CAAA;YAED,kFAAkF;YAClF,OAAO,MAAM,KAAK,CAChB,eAAe,EACf,gBAAgB,CAAC,IAAI,EAAE,OAAO,EAAE,IAAI,CAAC,MAAM,CAAC,CAC7C,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE;gBACd,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,iCAAiC,IAAI,CAAC,MAAM,IAAI,CAAC,CAAA;gBACnE,OAAO,iBAAiB,CAAC,IAAI,EAAE,OAAO,CAAC,CAAA;YACzC,CAAC,CAAC,CAAA;QACJ,CAAC,CAAA;IACH,CAAC;CAmFF;AA/OD,wBA+OC"}
|
@@ -123,6 +123,26 @@ export declare class Order {
|
|
123
123
|
* })
|
124
124
|
*/
|
125
125
|
cancel(id: string, headers?: ClientHeaders): Promise<HttpTypes.AdminOrderResponse>;
|
126
|
+
/**
|
127
|
+
* This method requests an order transfer. It sends a request to the
|
128
|
+
* [Request Order Transfer](https://docs.medusajs.com/api/admin#orders_postordersidrequesttransfer)
|
129
|
+
* API route.
|
130
|
+
*
|
131
|
+
* @param id - The order's ID.
|
132
|
+
* @param headers - Headers to pass in the request.
|
133
|
+
* @param body - The transfer's details - the id of the next owner.
|
134
|
+
* @returns The order's details.
|
135
|
+
*
|
136
|
+
* @example
|
137
|
+
* sdk.admin.order.requestTransfer("order_123", {
|
138
|
+
* customer_id: "cus_123",
|
139
|
+
* internal_note: "Internal note",
|
140
|
+
* })
|
141
|
+
* .then(({ order }) => {
|
142
|
+
* console.log(order)
|
143
|
+
* })
|
144
|
+
*/
|
145
|
+
requestTransfer(id: string, body: HttpTypes.AdminRequestOrderTransfer, headers?: ClientHeaders): Promise<HttpTypes.AdminOrderResponse>;
|
126
146
|
/**
|
127
147
|
* This method creates a fulfillment for an order. It sends a request to the
|
128
148
|
* [Create Fulfillment](https://docs.medusajs.com/api/admin#orders_postordersidfulfillments)
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"order.d.ts","sourceRoot":"","sources":["../../../src/admin/order.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,SAAS,EAET,YAAY,EACb,MAAM,iBAAiB,CAAA;AAGxB,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAA;AAExC,qBAAa,KAAK;IAChB;;OAEG;IACH,OAAO,CAAC,MAAM,CAAQ;IACtB;;OAEG;gBACS,MAAM,EAAE,MAAM;IAI1B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAgCG;IACG,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,YAAY,EAAE,OAAO,CAAC,EAAE,aAAa;IAUxE;;;;;;;;;;;;;;OAcG;IACG,eAAe,CACnB,EAAE,EAAE,MAAM,EACV,KAAK,CAAC,EAAE,SAAS,CAAC,iBAAiB,EACnC,OAAO,CAAC,EAAE,aAAa;IAWzB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6CG;IACG,IAAI,CACR,WAAW,CAAC,EAAE,SAAS,CAAC,iBAAiB,EACzC,OAAO,CAAC,EAAE,aAAa;
|
1
|
+
{"version":3,"file":"order.d.ts","sourceRoot":"","sources":["../../../src/admin/order.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,SAAS,EAET,YAAY,EACb,MAAM,iBAAiB,CAAA;AAGxB,OAAO,EAAE,MAAM,EA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G,cAAc,CAClB,EAAE,EAAE,MAAM,EACV,aAAa,EAAE,MAAM,EACrB,IAAI,EAAE,SAAS,CAAC,wBAAwB,EACxC,KAAK,CAAC,EAAE,YAAY,EACpB,OAAO,CAAC,EAAE,aAAa;IAazB;;;;;;;;;;;;;;;;;;;;;OAqBG;IACG,eAAe,CACnB,EAAE,EAAE,MAAM,EACV,aAAa,EAAE,MAAM,EACrB,IAAI,EAAE,SAAS,CAAC,oCAAoC,EACpD,KAAK,CAAC,EAAE,YAAY,EACpB,OAAO,CAAC,EAAE,aAAa;IAazB;;;;;;;;;;;;;;;;OAgBG;IACG,WAAW,CACf,EAAE,EAAE,MAAM,EACV,WAAW,CAAC,EAAE,UAAU,GAAG,SAAS,CAAC,wBAAwB,EAC7D,OAAO,CAAC,EAAE,aAAa;IAUzB;;;;;;;;;;;;;;;OAeG;IACG,aAAa,CACjB,EAAE,EAAE,MAAM,EACV,WAAW,CAAC,EAAE,UAAU,GAAG,SAAS,CAAC,sBAAsB,EAC3D,OAAO,CAAC,EAAE,aAAa;CAU1B"}
|
package/dist/esm/admin/order.js
CHANGED
@@ -155,6 +155,34 @@ export class Order {
|
|
155
155
|
});
|
156
156
|
});
|
157
157
|
}
|
158
|
+
/**
|
159
|
+
* This method requests an order transfer. It sends a request to the
|
160
|
+
* [Request Order Transfer](https://docs.medusajs.com/api/admin#orders_postordersidrequesttransfer)
|
161
|
+
* API route.
|
162
|
+
*
|
163
|
+
* @param id - The order's ID.
|
164
|
+
* @param headers - Headers to pass in the request.
|
165
|
+
* @param body - The transfer's details - the id of the next owner.
|
166
|
+
* @returns The order's details.
|
167
|
+
*
|
168
|
+
* @example
|
169
|
+
* sdk.admin.order.requestTransfer("order_123", {
|
170
|
+
* customer_id: "cus_123",
|
171
|
+
* internal_note: "Internal note",
|
172
|
+
* })
|
173
|
+
* .then(({ order }) => {
|
174
|
+
* console.log(order)
|
175
|
+
* })
|
176
|
+
*/
|
177
|
+
requestTransfer(id, body, headers) {
|
178
|
+
return __awaiter(this, void 0, void 0, function* () {
|
179
|
+
return yield this.client.fetch(`/admin/orders/${id}/transfer`, {
|
180
|
+
method: "POST",
|
181
|
+
headers,
|
182
|
+
body,
|
183
|
+
});
|
184
|
+
});
|
185
|
+
}
|
158
186
|
/**
|
159
187
|
* This method creates a fulfillment for an order. It sends a request to the
|
160
188
|
* [Create Fulfillment](https://docs.medusajs.com/api/admin#orders_postordersidfulfillments)
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"order.js","sourceRoot":"","sources":["../../../src/admin/order.ts"],"names":[],"mappings":";;;;;;;;;AAWA,MAAM,OAAO,KAAK;IAKhB;;OAEG;IACH,YAAY,MAAc;QACxB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAA;IACtB,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAgCG;IACG,QAAQ,CAAC,EAAU,EAAE,KAAoB,EAAE,OAAuB;;YACtE,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAC5B,iBAAiB,EAAE,EAAE,EACrB;gBACE,KAAK;gBACL,OAAO;aACR,CACF,CAAA;QACH,CAAC;KAAA;IAED;;;;;;;;;;;;;;OAcG;IACG,eAAe,CACnB,EAAU,EACV,KAAmC,EACnC,OAAuB;;YAEvB,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAC5B,iBAAiB,EAAE,UAAU,EAC7B;gBACE,KAAK;gBACL,OAAO;aACR,CACF,CAAA;QACH,CAAC;KAAA;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6CG;IACG,IAAI,CACR,WAAyC,EACzC,OAAuB;;YAEvB,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,
|
1
|
+
{"version":3,"file":"order.js","sourceRoot":"","sources":["../../../src/admin/order.ts"],"names":[],"mappings":";;;;;;;;;AAWA,MAAM,OAAO,KAAK;IAKhB;;OAEG;IACH,YAAY,MAAc;QACxB,I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B;;YAEvB,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAE5B,iBAAiB,EAAE,UAAU,EAAE;gBAC/B,KAAK,EAAE,WAAW;gBAClB,OAAO;aACR,CAAC,CAAA;QACJ,CAAC;KAAA;IAED;;;;;;;;;;;;;;;OAeG;IACG,aAAa,CACjB,EAAU,EACV,WAA2D,EAC3D,OAAuB;;YAEvB,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAC5B,iBAAiB,EAAE,aAAa,EAChC;gBACE,KAAK,EAAE,WAAW;gBAClB,OAAO;aACR,CACF,CAAA;QACH,CAAC;KAAA;CACF"}
|
package/dist/esm/auth/index.d.ts
CHANGED
@@ -153,22 +153,22 @@ export declare class Auth {
|
|
153
153
|
* @param actor - The actor type. For example, `user` for admin user, or `customer` for customer.
|
154
154
|
* @param provider - The authentication provider to use. For example, `emailpass`.
|
155
155
|
* @param body - The data necessary to update the user's authentication data. When resetting the user's password,
|
156
|
-
* send the `
|
156
|
+
* send the `password` property.
|
157
157
|
*
|
158
158
|
* @example
|
159
159
|
* sdk.auth.updateProvider(
|
160
160
|
* "customer",
|
161
161
|
* "emailpass",
|
162
162
|
* {
|
163
|
-
* email: "customer@gmail.com",
|
164
163
|
* password: "supersecret"
|
165
|
-
* }
|
164
|
+
* },
|
165
|
+
* token
|
166
166
|
* )
|
167
167
|
* .then(() => {
|
168
168
|
* // password updated
|
169
169
|
* })
|
170
170
|
*/
|
171
|
-
updateProvider: (actor: string, provider: string, body: Record<string, unknown
|
171
|
+
updateProvider: (actor: string, provider: string, body: Record<string, unknown>, token: string) => Promise<void>;
|
172
172
|
/**
|
173
173
|
* @ignore
|
174
174
|
*/
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/auth/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAA;AAC3C,OAAO,EAAE,MAAM,EAAE,MAAM,W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AAE,MAAM,EAAE,MAAM;IAK1C;;;;;;;;;;;;;;;;;;;;;OAqBG;IACH,QAAQ,UACC,MAAM,UACL,MAAM,WACL,SAAS,CAAC,4BAA4B,qBAahD;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BG;IACH,KAAK,UACI,MAAM,UACL,MAAM,WACL,SAAS,CAAC,4BAA4B,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;OAmB1E;IAED;;;;;;;;;;;;;;;;;;;;;;;;OAwBG;IACH,QAAQ,UACC,MAAM,UACL,MAAM,UACN,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,qBAYhC;IAED;;;;;;;;;;;OAWG;IACH,OAAO,wBAYN;IAED;;;;;;;;;OASG;IACH,MAAM,sBAQL;IAED;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,aAAa,UACJ,MAAM,YACH,MAAM,QACV;QACJ;;;WAGG;QACH,UAAU,EAAE,MAAM,CAAA;KACnB,mBAOF;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BG;IACH,cAAc,UACL,MAAM,YACH,MAAM,QACV,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,SACtB,MAAM,mBASd;IAED;;OAEG;IACH,OAAO,CAAC,SAAS,CAUhB;CACF"}
|
package/dist/esm/auth/index.js
CHANGED
@@ -198,23 +198,23 @@ export class Auth {
|
|
198
198
|
* @param actor - The actor type. For example, `user` for admin user, or `customer` for customer.
|
199
199
|
* @param provider - The authentication provider to use. For example, `emailpass`.
|
200
200
|
* @param body - The data necessary to update the user's authentication data. When resetting the user's password,
|
201
|
-
* send the `
|
201
|
+
* send the `password` property.
|
202
202
|
*
|
203
203
|
* @example
|
204
204
|
* sdk.auth.updateProvider(
|
205
205
|
* "customer",
|
206
206
|
* "emailpass",
|
207
207
|
* {
|
208
|
-
* email: "customer@gmail.com",
|
209
208
|
* password: "supersecret"
|
210
|
-
* }
|
209
|
+
* },
|
210
|
+
* token
|
211
211
|
* )
|
212
212
|
* .then(() => {
|
213
213
|
* // password updated
|
214
214
|
* })
|
215
215
|
*/
|
216
|
-
this.updateProvider = (actor, provider, body) => __awaiter(this, void 0, void 0, function* () {
|
217
|
-
yield this.client.fetch(`/auth/${actor}/${provider}/update`, {
|
216
|
+
this.updateProvider = (actor, provider, body, token) => __awaiter(this, void 0, void 0, function* () {
|
217
|
+
yield this.client.fetch(`/auth/${actor}/${provider}/update?token=${token}`, {
|
218
218
|
method: "POST",
|
219
219
|
body,
|
220
220
|
});
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/auth/index.ts"],"names":[],"mappings":";;;;;;;;;AAIA,MAAM,OAAO,IAAI;IAIf,YAAY,MAAc,EAAE,MAAc;QAK1C;;;;;;;;;;;;;;;;;;;;;WAqBG;QACH,aAAQ,GAAG,CACT,KAAa,EACb,MAAc,EACd,OAA+C,EAC/C,EAAE;YACF,MAAM,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CACvC,SAAS,KAAK,IAAI,MAAM,WAAW,EACnC;gBACE,MAAM,EAAE,MAAM;gBACd,IAAI,EAAE,OAAO;aACd,CACF,CAAA;YAED,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAA;YAE3B,OAAO,KAAK,CAAA;QACd,CAAC,CAAA,CAAA;QAED;;;;;;;;;;;;;;;;;;;;;;;;;;;WA2BG;QACH,UAAK,GAAG,CACN,KAAa,EACb,MAAc,EACd,OAAyE,EACzE,EAAE;YACF,oEAAoE;YACpE,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,KAAK,CAGhD,SAAS,KAAK,IAAI,MAAM,EAAE,EAAE;gBAC7B,MAAM,EAAE,MAAM;gBACd,IAAI,EAAE,OAAO;aACd,CAAC,CAAA;YAEF,gFAAgF;YAChF,4EAA4E;YAC5E,IAAI,QAAQ,EAA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CAAC;CAyRF"}
|
package/dist/esm/client.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../src/client.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,WAAW,EACX,MAAM,EACN,SAAS,EACT,UAAU,EACV,mBAAmB,EAEpB,MAAM,SAAS,CAAA;AAEhB,eAAO,MAAM,sBAAsB,0BAA0B,CAAA;AA2E7D,qBAAa,UAAW,SAAQ,KAAK;IACnC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,UAAU,EAAE,MAAM,GAAG,SAAS,CAAA;gBAElB,OAAO,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM;CAKlE;AAED,qBAAa,MAAM;IACV,MAAM,EAAE,WAAW,CAAA;IAC1B,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,MAAM,CAAQ;IAEtB,OAAO,CAAC,uBAAuB,CAAsB;IACrD,OAAO,CAAC,KAAK,CAAK;gBAEN,MAAM,EAAE,MAAM;IAiB1B;;;;;;;;;;;OAWG;IACH,KAAK,CAAC,CAAC,SAAS,GAAG,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,CAAC,EAAE,SAAS,GAAG,OAAO,CAAC,CAAC,CAAC;IAIrE;;;;;;;;;OASG;IACG,WAAW,CACf,KAAK,EAAE,UAAU,EACjB,IAAI,CAAC,EAAE,SAAS,GACf,OAAO,CAAC,mBAAmB,CAAC;IAiB/B,QAAQ,CAAC,KAAK,EAAE,MAAM;IAItB,UAAU;IAIV,SAAS,CAAC,WAAW;IAkBrB,SAAS,CAAC,UAAU,IAAI,WAAW;
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../src/client.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,WAAW,EACX,MAAM,EACN,SAAS,EACT,UAAU,EACV,mBAAmB,EAEpB,MAAM,SAAS,CAAA;AAEhB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client.js
CHANGED
@@ -7,8 +7,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
7
7
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
8
8
|
});
|
9
9
|
};
|
10
|
-
import qs from "qs";
|
11
10
|
import { events } from "fetch-event-stream";
|
11
|
+
import qs from "qs";
|
12
12
|
export const PUBLISHABLE_KEY_HEADER = "x-publishable-api-key";
|
13
13
|
// We want to explicitly retrieve the base URL instead of relying on relative paths that differ in behavior between browsers.
|
14
14
|
const getBaseUrl = (passedBaseUrl) => {
|
@@ -223,7 +223,9 @@ export class Client {
|
|
223
223
|
});
|
224
224
|
let normalizedInput = input;
|
225
225
|
if (input instanceof URL || typeof input === "string") {
|
226
|
-
|
226
|
+
const baseUrl = new URL(this.config.baseUrl);
|
227
|
+
const fullPath = `${baseUrl.pathname.replace(/\/$/, '')}/${input.toString().replace(/^\//, '')}`;
|
228
|
+
normalizedInput = new URL(fullPath, baseUrl.origin);
|
227
229
|
if (init === null || init === void 0 ? void 0 : init.query) {
|
228
230
|
const params = Object.fromEntries(normalizedInput.searchParams.entries());
|
229
231
|
const stringifiedQuery = qs.stringify(Object.assign(Object.assign({}, params), init.query));
|
package/dist/esm/client.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../src/client.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,MAAM,
|
1
|
+
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../src/client.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAA;AAC3C,OAAO,EAAE,MAAM,IAAI,CAAA;AAUnB,MAAM,CAAC,MAAM,sBAAsB,GAAG,uBAAuB,CAAA;AAE7D,6HAA6H;AAC7H,MAAM,UAAU,GAAG,CAAC,aAAqB,EAAE,EAAE;IAC3C,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;Q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G,EAAE,CAAC,SAAS,iCAAM,MAAM,GAAK,IAAI,CAAC,KAAK,EAAG,CAAA;oBACnE,eAAe,CAAC,MAAM,GAAG,gBAAgB,CAAA;gBAC3C,CAAC;YACH,CAAC;YAED,IAAI,CAAC,MAAM,CAAC,KAAK,CACf,0BAA0B,EAC1B,QAAQ,eAAe,CAAC,QAAQ,EAAE,IAAI,EACtC,YAAY,IAAI,CAAC,SAAS,CAAC,eAAe,CAAC,OAAO,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,CAClE,CAAA;YAED,kFAAkF;YAClF,OAAO,MAAM,KAAK,CAChB,eAAe,EACf,gBAAgB,CAAC,IAAI,EAAE,OAAO,EAAE,IAAI,CAAC,MAAM,CAAC,CAC7C,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE;gBACd,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,iCAAiC,IAAI,CAAC,MAAM,IAAI,CAAC,CAAA;gBACnE,OAAO,iBAAiB,CAAC,IAAI,EAAE,OAAO,CAAC,CAAA;YACzC,CAAC,CAAC,CAAA;QACJ,CAAC,CAAA,CAAA;IACH,CAAC;CAmFF"}
|
@@ -774,6 +774,103 @@ export declare class Store {
|
|
774
774
|
retrieve: (id: string, query?: SelectParams, headers?: ClientHeaders) => Promise<{
|
775
775
|
order: HttpTypes.StoreOrder;
|
776
776
|
}>;
|
777
|
+
/**
|
778
|
+
* This method requests a order transfer from a guest account to the current, logged in customer account.
|
779
|
+
*
|
780
|
+
* Customer requesting the transfer must be logged in.
|
781
|
+
*
|
782
|
+
* @param body - The transfer's details.
|
783
|
+
* @param query - Configure the fields to retrieve in the order.
|
784
|
+
* @param headers - Headers to pass in the request.
|
785
|
+
* @returns The order details.
|
786
|
+
*
|
787
|
+
* @example
|
788
|
+
* sdk.store.order.requestTransfer(
|
789
|
+
* "order_123",
|
790
|
+
* {
|
791
|
+
* description: "I want to transfer this order to my friend."
|
792
|
+
* },
|
793
|
+
* {},
|
794
|
+
* {
|
795
|
+
* Authorization: `Bearer ${token}`
|
796
|
+
* }
|
797
|
+
* )
|
798
|
+
* .then(({ order }) => {
|
799
|
+
* console.log(order)
|
800
|
+
* })
|
801
|
+
*/
|
802
|
+
requestTransfer: (id: string, body: HttpTypes.StoreRequestOrderTransfer, query?: SelectParams, headers?: ClientHeaders) => Promise<HttpTypes.StoreOrderResponse>;
|
803
|
+
/**
|
804
|
+
* This method cancels an order transfer request.
|
805
|
+
*
|
806
|
+
* Customer requesting the transfer must be logged in.
|
807
|
+
*
|
808
|
+
* @param id - The order's ID.
|
809
|
+
* @param query - Configure the fields to retrieve in the order.
|
810
|
+
* @param headers - Headers to pass in the request.
|
811
|
+
* @returns The order details.
|
812
|
+
*
|
813
|
+
* @example
|
814
|
+
* sdk.store.order.cancelTransfer(
|
815
|
+
* "order_123",
|
816
|
+
* {},
|
817
|
+
* {
|
818
|
+
* Authorization: `Bearer ${token}`
|
819
|
+
* }
|
820
|
+
* )
|
821
|
+
* .then(({ order }) => {
|
822
|
+
* console.log(order)
|
823
|
+
* })
|
824
|
+
*/
|
825
|
+
cancelTransfer: (id: string, query?: SelectParams, headers?: ClientHeaders) => Promise<HttpTypes.StoreOrderResponse>;
|
826
|
+
/**
|
827
|
+
* The method called for the original owner to accept the order transfer to a new owner.
|
828
|
+
*
|
829
|
+
* @param id - The order's ID.
|
830
|
+
* @param body - The payload containing the transfer token.
|
831
|
+
* @param query - Configure the fields to retrieve in the order.
|
832
|
+
* @param headers - Headers to pass in the request.
|
833
|
+
* @returns The order details.
|
834
|
+
*
|
835
|
+
* @example
|
836
|
+
* sdk.store.order.acceptTransfer(
|
837
|
+
* "order_123",
|
838
|
+
* {
|
839
|
+
* token: "transfer_token"
|
840
|
+
* },
|
841
|
+
* {
|
842
|
+
* Authorization: `Bearer ${token}`
|
843
|
+
* }
|
844
|
+
* )
|
845
|
+
* .then(({ order }) => {
|
846
|
+
* console.log(order)
|
847
|
+
* })
|
848
|
+
*/
|
849
|
+
acceptTransfer: (id: string, body: HttpTypes.StoreAcceptOrderTransfer, query?: SelectParams, headers?: ClientHeaders) => Promise<HttpTypes.StoreOrderResponse>;
|
850
|
+
/**
|
851
|
+
* The method called for the original owner to decline the order transfer to a new owner.
|
852
|
+
*
|
853
|
+
* @param id - The order's ID.
|
854
|
+
* @param body - The payload containing the transfer token.
|
855
|
+
* @param query - Configure the fields to retrieve in the order.
|
856
|
+
* @param headers - Headers to pass in the request.
|
857
|
+
* @returns The order details.
|
858
|
+
*
|
859
|
+
* @example
|
860
|
+
* sdk.store.order.declineTransfer(
|
861
|
+
* "order_123",
|
862
|
+
* {
|
863
|
+
* token: "transfer_token"
|
864
|
+
* },
|
865
|
+
* {
|
866
|
+
* Authorization: `Bearer ${token}`
|
867
|
+
* }
|
868
|
+
* )
|
869
|
+
* .then(({ order }) => {
|
870
|
+
* console.log(order)
|
871
|
+
* })
|
872
|
+
*/
|
873
|
+
declineTransfer: (id: string, body: HttpTypes.StoreDeclineOrderTransfer, query?: SelectParams, headers?: ClientHeaders) => Promise<HttpTypes.StoreOrderResponse>;
|
777
874
|
};
|
778
875
|
customer: {
|
779
876
|
/**
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/store/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AACrE,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAA;AAExC,qBAAa,KAAK;IAChB;;OAEG;IACH,OAAO,CAAC,MAAM,CAAQ;IAEtB;;OAEG;gBACS,MAAM,EAAE,MAAM;IAInB,MAAM;QACX;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;WA+CG;uBAEO,UAAU,GAAG,SAAS,CAAC,kBAAkB,YACvC,aAAa;QAUzB;;;;;;;;;;;;;;;;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QACJ,SAAS,CAAC,yBAAyB,UACjC,YAAY,YACV,aAAa;QAYzB;;;;;;;;;;;;;;;;;;;;;WAqBG;6BAEG,MAAM,UACF,YAAY,YACV,aAAa;QAWzB;;;;;;;;;;;;;;;;;;;;;;WAsBG;6BAEG,MAAM,QACJ,SAAS,CAAC,wBAAwB,UAChC,YAAY,YACV,aAAa;QAYzB;;;;;;;;;;;;;;;;;;;;;;WAsBG;8BAEG,MAAM,QACJ,SAAS,CAAC,yBAAyB,UACjC,YAAY,YACV,aAAa;MAY1B;IAEM,QAAQ;QACb;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;WAgCG;uBAEK,SAAS,CAAC,mBAAmB,UAC3B,YAAY,YACV,aAAa;QAYzB;;;;;;;;;;;;;;;;;;;;;WAqBG;uBAEK,SAAS,CAAC,mBAAmB,UAC3B,YAAY,YACV,aAAa;QAYzB;;;;;;;;;;;;;;;;WAgBG;2BACsB,YAAY,YAAY,aAAa;QAS9D;;;;;;;;;;;;;;;;;;;;;WAqBG;8BAEK,SAAS,CAAC,0BAA0B,UAClC,YAAY,YACV,aAAa;QAYzB;;;;;;;;;;;;;;;;;;;;;;;;;WAyBG;mCAEU,MAAM,QACX,SAAS,CAAC,0BAA0B,UAClC,YAAY,YACV,aAAa;QAYzB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;WAkDG;8BAEO,UAAU,GAAG,SAAS,CAAC,2BAA2B,YAChD,aAAa;QAUzB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;WAyCG;qCAEU,MAAM,UACT,YAAY,YACV,aAAa;QAUzB;;;;;;;;;;;;;;;;;;WAkBG;mCAC8B,MAAM,YAAY,aAAa;MASjE;CACF"}
|
package/dist/esm/store/index.js
CHANGED
@@ -910,6 +910,130 @@ export class Store {
|
|
910
910
|
query,
|
911
911
|
});
|
912
912
|
}),
|
913
|
+
/**
|
914
|
+
* This method requests a order transfer from a guest account to the current, logged in customer account.
|
915
|
+
*
|
916
|
+
* Customer requesting the transfer must be logged in.
|
917
|
+
*
|
918
|
+
* @param body - The transfer's details.
|
919
|
+
* @param query - Configure the fields to retrieve in the order.
|
920
|
+
* @param headers - Headers to pass in the request.
|
921
|
+
* @returns The order details.
|
922
|
+
*
|
923
|
+
* @example
|
924
|
+
* sdk.store.order.requestTransfer(
|
925
|
+
* "order_123",
|
926
|
+
* {
|
927
|
+
* description: "I want to transfer this order to my friend."
|
928
|
+
* },
|
929
|
+
* {},
|
930
|
+
* {
|
931
|
+
* Authorization: `Bearer ${token}`
|
932
|
+
* }
|
933
|
+
* )
|
934
|
+
* .then(({ order }) => {
|
935
|
+
* console.log(order)
|
936
|
+
* })
|
937
|
+
*/
|
938
|
+
requestTransfer: (id, body, query, headers) => __awaiter(this, void 0, void 0, function* () {
|
939
|
+
return this.client.fetch(`/store/orders/${id}/transfer/request`, {
|
940
|
+
method: "POST",
|
941
|
+
headers,
|
942
|
+
body,
|
943
|
+
query,
|
944
|
+
});
|
945
|
+
}),
|
946
|
+
/**
|
947
|
+
* This method cancels an order transfer request.
|
948
|
+
*
|
949
|
+
* Customer requesting the transfer must be logged in.
|
950
|
+
*
|
951
|
+
* @param id - The order's ID.
|
952
|
+
* @param query - Configure the fields to retrieve in the order.
|
953
|
+
* @param headers - Headers to pass in the request.
|
954
|
+
* @returns The order details.
|
955
|
+
*
|
956
|
+
* @example
|
957
|
+
* sdk.store.order.cancelTransfer(
|
958
|
+
* "order_123",
|
959
|
+
* {},
|
960
|
+
* {
|
961
|
+
* Authorization: `Bearer ${token}`
|
962
|
+
* }
|
963
|
+
* )
|
964
|
+
* .then(({ order }) => {
|
965
|
+
* console.log(order)
|
966
|
+
* })
|
967
|
+
*/
|
968
|
+
cancelTransfer: (id, query, headers) => __awaiter(this, void 0, void 0, function* () {
|
969
|
+
return this.client.fetch(`/store/orders/${id}/transfer/cancel`, {
|
970
|
+
method: "POST",
|
971
|
+
headers,
|
972
|
+
query,
|
973
|
+
});
|
974
|
+
}),
|
975
|
+
/**
|
976
|
+
* The method called for the original owner to accept the order transfer to a new owner.
|
977
|
+
*
|
978
|
+
* @param id - The order's ID.
|
979
|
+
* @param body - The payload containing the transfer token.
|
980
|
+
* @param query - Configure the fields to retrieve in the order.
|
981
|
+
* @param headers - Headers to pass in the request.
|
982
|
+
* @returns The order details.
|
983
|
+
*
|
984
|
+
* @example
|
985
|
+
* sdk.store.order.acceptTransfer(
|
986
|
+
* "order_123",
|
987
|
+
* {
|
988
|
+
* token: "transfer_token"
|
989
|
+
* },
|
990
|
+
* {
|
991
|
+
* Authorization: `Bearer ${token}`
|
992
|
+
* }
|
993
|
+
* )
|
994
|
+
* .then(({ order }) => {
|
995
|
+
* console.log(order)
|
996
|
+
* })
|
997
|
+
*/
|
998
|
+
acceptTransfer: (id, body, query, headers) => __awaiter(this, void 0, void 0, function* () {
|
999
|
+
return this.client.fetch(`/store/orders/${id}/transfer/accept`, {
|
1000
|
+
method: "POST",
|
1001
|
+
headers,
|
1002
|
+
body,
|
1003
|
+
query,
|
1004
|
+
});
|
1005
|
+
}),
|
1006
|
+
/**
|
1007
|
+
* The method called for the original owner to decline the order transfer to a new owner.
|
1008
|
+
*
|
1009
|
+
* @param id - The order's ID.
|
1010
|
+
* @param body - The payload containing the transfer token.
|
1011
|
+
* @param query - Configure the fields to retrieve in the order.
|
1012
|
+
* @param headers - Headers to pass in the request.
|
1013
|
+
* @returns The order details.
|
1014
|
+
*
|
1015
|
+
* @example
|
1016
|
+
* sdk.store.order.declineTransfer(
|
1017
|
+
* "order_123",
|
1018
|
+
* {
|
1019
|
+
* token: "transfer_token"
|
1020
|
+
* },
|
1021
|
+
* {
|
1022
|
+
* Authorization: `Bearer ${token}`
|
1023
|
+
* }
|
1024
|
+
* )
|
1025
|
+
* .then(({ order }) => {
|
1026
|
+
* console.log(order)
|
1027
|
+
* })
|
1028
|
+
*/
|
1029
|
+
declineTransfer: (id, body, query, headers) => __awaiter(this, void 0, void 0, function* () {
|
1030
|
+
return this.client.fetch(`/store/orders/${id}/transfer/decline`, {
|
1031
|
+
method: "POST",
|
1032
|
+
headers,
|
1033
|
+
body,
|
1034
|
+
query,
|
1035
|
+
});
|
1036
|
+
}),
|
913
1037
|
};
|
914
1038
|
this.customer = {
|
915
1039
|
/**
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/store/index.ts"],"names":[],"mappings":";;;;;;;;;AAIA,MAAM,OAAO,KAAK;IAMhB;;OAEG;IACH,YAAY,MAAc;QAInB,WAAM,GAAG;YACd;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eA+CG;YACH,IAAI,EAAE,CACJ,KAAiD,EACjD,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,gBAAgB,EAChB;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC,CAAA;YACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eAoCG;YACH,QAAQ,EAAE,CACR,EAAU,EACV,KAAoB,EACpB,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,kBAAkB,EAAE,EAAE,EACtB;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC,CAAA;SACF,CAAA;QAEM,eAAU,GAAG;YAClB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eA+CG;YACH,IAAI,EAAE,CACJ,KAAqD,EACrD,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,oBAAoB,EACpB;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC,CAAA;YACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eAiCG;YACH,QAAQ,EAAE,CACR,EAAU,EACV,KAAoB,EACpB,OAAuB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M,CAAC,KAAK,CACtB,iCAAiC,SAAS,EAAE,EAC5C;oBACE,MAAM,EAAE,QAAQ;oBAChB,OAAO;iBACR,CACF,CAAA;YACH,CAAC,CAAA;SACF,CAAA;
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/store/index.ts"],"names":[],"mappings":";;;;;;;;;AAIA,MAAM,OAAO,KAAK;IAMhB;;OAEG;IACH,YAAY,MAAc;QAInB,WAAM,GAAG;YACd;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eA+CG;YACH,IAAI,EAAE,CACJ,KAAiD,EACjD,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,gBAAgB,EAChB;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC,CAAA;YACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eAoCG;YACH,QAAQ,EAAE,CACR,EAAU,EACV,KAAoB,EACpB,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,kBAAkB,EAAE,EAAE,EACtB;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC,CAAA;SACF,CAAA;QAEM,eAAU,GAAG;YAClB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eA+CG;YACH,IAAI,EAAE,CACJ,KAAqD,EACrD,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,oBAAoB,EACpB;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC,CAAA;YACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eAiCG;YACH,QAAQ,EAAE,CACR,EAAU,EACV,KAAoB,EACpB,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,sBAAsB,EAA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,CAAC;CAwhDF"}
|
package/dist/store/index.d.ts
CHANGED
@@ -774,6 +774,103 @@ export declare class Store {
|
|
774
774
|
retrieve: (id: string, query?: SelectParams, headers?: ClientHeaders) => Promise<{
|
775
775
|
order: HttpTypes.StoreOrder;
|
776
776
|
}>;
|
777
|
+
/**
|
778
|
+
* This method requests a order transfer from a guest account to the current, logged in customer account.
|
779
|
+
*
|
780
|
+
* Customer requesting the transfer must be logged in.
|
781
|
+
*
|
782
|
+
* @param body - The transfer's details.
|
783
|
+
* @param query - Configure the fields to retrieve in the order.
|
784
|
+
* @param headers - Headers to pass in the request.
|
785
|
+
* @returns The order details.
|
786
|
+
*
|
787
|
+
* @example
|
788
|
+
* sdk.store.order.requestTransfer(
|
789
|
+
* "order_123",
|
790
|
+
* {
|
791
|
+
* description: "I want to transfer this order to my friend."
|
792
|
+
* },
|
793
|
+
* {},
|
794
|
+
* {
|
795
|
+
* Authorization: `Bearer ${token}`
|
796
|
+
* }
|
797
|
+
* )
|
798
|
+
* .then(({ order }) => {
|
799
|
+
* console.log(order)
|
800
|
+
* })
|
801
|
+
*/
|
802
|
+
requestTransfer: (id: string, body: HttpTypes.StoreRequestOrderTransfer, query?: SelectParams, headers?: ClientHeaders) => Promise<HttpTypes.StoreOrderResponse>;
|
803
|
+
/**
|
804
|
+
* This method cancels an order transfer request.
|
805
|
+
*
|
806
|
+
* Customer requesting the transfer must be logged in.
|
807
|
+
*
|
808
|
+
* @param id - The order's ID.
|
809
|
+
* @param query - Configure the fields to retrieve in the order.
|
810
|
+
* @param headers - Headers to pass in the request.
|
811
|
+
* @returns The order details.
|
812
|
+
*
|
813
|
+
* @example
|
814
|
+
* sdk.store.order.cancelTransfer(
|
815
|
+
* "order_123",
|
816
|
+
* {},
|
817
|
+
* {
|
818
|
+
* Authorization: `Bearer ${token}`
|
819
|
+
* }
|
820
|
+
* )
|
821
|
+
* .then(({ order }) => {
|
822
|
+
* console.log(order)
|
823
|
+
* })
|
824
|
+
*/
|
825
|
+
cancelTransfer: (id: string, query?: SelectParams, headers?: ClientHeaders) => Promise<HttpTypes.StoreOrderResponse>;
|
826
|
+
/**
|
827
|
+
* The method called for the original owner to accept the order transfer to a new owner.
|
828
|
+
*
|
829
|
+
* @param id - The order's ID.
|
830
|
+
* @param body - The payload containing the transfer token.
|
831
|
+
* @param query - Configure the fields to retrieve in the order.
|
832
|
+
* @param headers - Headers to pass in the request.
|
833
|
+
* @returns The order details.
|
834
|
+
*
|
835
|
+
* @example
|
836
|
+
* sdk.store.order.acceptTransfer(
|
837
|
+
* "order_123",
|
838
|
+
* {
|
839
|
+
* token: "transfer_token"
|
840
|
+
* },
|
841
|
+
* {
|
842
|
+
* Authorization: `Bearer ${token}`
|
843
|
+
* }
|
844
|
+
* )
|
845
|
+
* .then(({ order }) => {
|
846
|
+
* console.log(order)
|
847
|
+
* })
|
848
|
+
*/
|
849
|
+
acceptTransfer: (id: string, body: HttpTypes.StoreAcceptOrderTransfer, query?: SelectParams, headers?: ClientHeaders) => Promise<HttpTypes.StoreOrderResponse>;
|
850
|
+
/**
|
851
|
+
* The method called for the original owner to decline the order transfer to a new owner.
|
852
|
+
*
|
853
|
+
* @param id - The order's ID.
|
854
|
+
* @param body - The payload containing the transfer token.
|
855
|
+
* @param query - Configure the fields to retrieve in the order.
|
856
|
+
* @param headers - Headers to pass in the request.
|
857
|
+
* @returns The order details.
|
858
|
+
*
|
859
|
+
* @example
|
860
|
+
* sdk.store.order.declineTransfer(
|
861
|
+
* "order_123",
|
862
|
+
* {
|
863
|
+
* token: "transfer_token"
|
864
|
+
* },
|
865
|
+
* {
|
866
|
+
* Authorization: `Bearer ${token}`
|
867
|
+
* }
|
868
|
+
* )
|
869
|
+
* .then(({ order }) => {
|
870
|
+
* console.log(order)
|
871
|
+
* })
|
872
|
+
*/
|
873
|
+
declineTransfer: (id: string, body: HttpTypes.StoreDeclineOrderTransfer, query?: SelectParams, headers?: ClientHeaders) => Promise<HttpTypes.StoreOrderResponse>;
|
777
874
|
};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Aa;QAYzB;;;;;;;;;;;;;;;;;;;;;;;;;WAyBG;mCAEU,MAAM,QACX,SAAS,CAAC,0BAA0B,UAClC,YAAY,YACV,aAAa;QAYzB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;WAkDG;8BAEO,UAAU,GAAG,SAAS,CAAC,2BAA2B,YAChD,aAAa;QAUzB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;WAyCG;qCAEU,MAAM,UACT,YAAY,YACV,aAAa;QAUzB;;;;;;;;;;;;;;;;;;WAkBG;mCAC8B,MAAM,YAAY,aAAa;MASjE;CACF"}
|
package/dist/store/index.js
CHANGED
@@ -903,6 +903,130 @@ class Store {
|
|
903
903
|
query,
|
904
904
|
});
|
905
905
|
},
|
906
|
+
/**
|
907
|
+
* This method requests a order transfer from a guest account to the current, logged in customer account.
|
908
|
+
*
|
909
|
+
* Customer requesting the transfer must be logged in.
|
910
|
+
*
|
911
|
+
* @param body - The transfer's details.
|
912
|
+
* @param query - Configure the fields to retrieve in the order.
|
913
|
+
* @param headers - Headers to pass in the request.
|
914
|
+
* @returns The order details.
|
915
|
+
*
|
916
|
+
* @example
|
917
|
+
* sdk.store.order.requestTransfer(
|
918
|
+
* "order_123",
|
919
|
+
* {
|
920
|
+
* description: "I want to transfer this order to my friend."
|
921
|
+
* },
|
922
|
+
* {},
|
923
|
+
* {
|
924
|
+
* Authorization: `Bearer ${token}`
|
925
|
+
* }
|
926
|
+
* )
|
927
|
+
* .then(({ order }) => {
|
928
|
+
* console.log(order)
|
929
|
+
* })
|
930
|
+
*/
|
931
|
+
requestTransfer: async (id, body, query, headers) => {
|
932
|
+
return this.client.fetch(`/store/orders/${id}/transfer/request`, {
|
933
|
+
method: "POST",
|
934
|
+
headers,
|
935
|
+
body,
|
936
|
+
query,
|
937
|
+
});
|
938
|
+
},
|
939
|
+
/**
|
940
|
+
* This method cancels an order transfer request.
|
941
|
+
*
|
942
|
+
* Customer requesting the transfer must be logged in.
|
943
|
+
*
|
944
|
+
* @param id - The order's ID.
|
945
|
+
* @param query - Configure the fields to retrieve in the order.
|
946
|
+
* @param headers - Headers to pass in the request.
|
947
|
+
* @returns The order details.
|
948
|
+
*
|
949
|
+
* @example
|
950
|
+
* sdk.store.order.cancelTransfer(
|
951
|
+
* "order_123",
|
952
|
+
* {},
|
953
|
+
* {
|
954
|
+
* Authorization: `Bearer ${token}`
|
955
|
+
* }
|
956
|
+
* )
|
957
|
+
* .then(({ order }) => {
|
958
|
+
* console.log(order)
|
959
|
+
* })
|
960
|
+
*/
|
961
|
+
cancelTransfer: async (id, query, headers) => {
|
962
|
+
return this.client.fetch(`/store/orders/${id}/transfer/cancel`, {
|
963
|
+
method: "POST",
|
964
|
+
headers,
|
965
|
+
query,
|
966
|
+
});
|
967
|
+
},
|
968
|
+
/**
|
969
|
+
* The method called for the original owner to accept the order transfer to a new owner.
|
970
|
+
*
|
971
|
+
* @param id - The order's ID.
|
972
|
+
* @param body - The payload containing the transfer token.
|
973
|
+
* @param query - Configure the fields to retrieve in the order.
|
974
|
+
* @param headers - Headers to pass in the request.
|
975
|
+
* @returns The order details.
|
976
|
+
*
|
977
|
+
* @example
|
978
|
+
* sdk.store.order.acceptTransfer(
|
979
|
+
* "order_123",
|
980
|
+
* {
|
981
|
+
* token: "transfer_token"
|
982
|
+
* },
|
983
|
+
* {
|
984
|
+
* Authorization: `Bearer ${token}`
|
985
|
+
* }
|
986
|
+
* )
|
987
|
+
* .then(({ order }) => {
|
988
|
+
* console.log(order)
|
989
|
+
* })
|
990
|
+
*/
|
991
|
+
acceptTransfer: async (id, body, query, headers) => {
|
992
|
+
return this.client.fetch(`/store/orders/${id}/transfer/accept`, {
|
993
|
+
method: "POST",
|
994
|
+
headers,
|
995
|
+
body,
|
996
|
+
query,
|
997
|
+
});
|
998
|
+
},
|
999
|
+
/**
|
1000
|
+
* The method called for the original owner to decline the order transfer to a new owner.
|
1001
|
+
*
|
1002
|
+
* @param id - The order's ID.
|
1003
|
+
* @param body - The payload containing the transfer token.
|
1004
|
+
* @param query - Configure the fields to retrieve in the order.
|
1005
|
+
* @param headers - Headers to pass in the request.
|
1006
|
+
* @returns The order details.
|
1007
|
+
*
|
1008
|
+
* @example
|
1009
|
+
* sdk.store.order.declineTransfer(
|
1010
|
+
* "order_123",
|
1011
|
+
* {
|
1012
|
+
* token: "transfer_token"
|
1013
|
+
* },
|
1014
|
+
* {
|
1015
|
+
* Authorization: `Bearer ${token}`
|
1016
|
+
* }
|
1017
|
+
* )
|
1018
|
+
* .then(({ order }) => {
|
1019
|
+
* console.log(order)
|
1020
|
+
* })
|
1021
|
+
*/
|
1022
|
+
declineTransfer: async (id, body, query, headers) => {
|
1023
|
+
return this.client.fetch(`/store/orders/${id}/transfer/decline`, {
|
1024
|
+
method: "POST",
|
1025
|
+
headers,
|
1026
|
+
body,
|
1027
|
+
query,
|
1028
|
+
});
|
1029
|
+
},
|
906
1030
|
};
|
907
1031
|
this.customer = {
|
908
1032
|
/**
|
package/dist/store/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/store/index.ts"],"names":[],"mappings":";;;AAIA,MAAa,KAAK;IAMhB;;OAEG;IACH,YAAY,MAAc;QAInB,WAAM,GAAG;YACd;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eA+CG;YACH,IAAI,EAAE,KAAK,EACT,KAAiD,EACjD,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,gBAAgB,EAChB;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC;YACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eAoCG;YACH,QAAQ,EAAE,KAAK,EACb,EAAU,EACV,KAAoB,EACpB,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,kBA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B,+BAA+B,EAC/B;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC;YACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eAyCG;YACH,eAAe,EAAE,KAAK,EACpB,SAAiB,EACjB,KAAoB,EACpB,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,iCAAiC,SAAS,EAAE,EAC5C;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC;YACD;;;;;;;;;;;;;;;;;;eAkBG;YACH,aAAa,EAAE,KAAK,EAAE,SAAiB,EAAE,OAAuB,EAAE,EAAE;gBAClE,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,iCAAiC,SAAS,EAAE,EAC5C;oBACE,MAAM,EAAE,QAAQ;oBAChB,OAAO;iBACR,CACF,CAAA;YACH,CAAC;SACF,CAAA;
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/store/index.ts"],"names":[],"mappings":";;;AAIA,MAAa,KAAK;IAMhB;;OAEG;IACH,YAAY,MAAc;QAInB,WAAM,GAAG;YACd;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eA+CG;YACH,IAAI,EAAE,KAAK,EACT,KAAiD,EACjD,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,gBAAgB,EAChB;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC;YACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eAoCG;YACH,QAAQ,EAAE,KAAK,EACb,EAAU,EACV,KAAoB,EACpB,OAAuB,EACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,kBAAkB,EAAE,EAAE,EACtB;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC;SACF,CAAA;QAEM,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ACvB,EAAE;gBACF,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,iCAAiC,SAAS,EAAE,EAC5C;oBACE,KAAK;oBACL,OAAO;iBACR,CACF,CAAA;YACH,CAAC;YACD;;;;;;;;;;;;;;;;;;eAkBG;YACH,aAAa,EAAE,KAAK,EAAE,SAAiB,EAAE,OAAuB,EAAE,EAAE;gBAClE,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CACtB,iCAAiC,SAAS,EAAE,EAC5C;oBACE,MAAM,EAAE,QAAQ;oBAChB,OAAO;iBACR,CACF,CAAA;YACH,CAAC;SACF,CAAA;QAxhDC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAA;IACtB,CAAC;CAwhDF;AAniDD,sBAmiDC"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@medusajs/js-sdk",
|
3
|
-
"version": "2.0.5-snapshot-
|
3
|
+
"version": "2.0.5-snapshot-20241124153140",
|
4
4
|
"description": "SDK for the Medusa API",
|
5
5
|
"main": "dist/index.js",
|
6
6
|
"module": "dist/esm/index.js",
|
@@ -35,7 +35,7 @@
|
|
35
35
|
"typescript": "^5.6.2"
|
36
36
|
},
|
37
37
|
"dependencies": {
|
38
|
-
"@medusajs/types": "2.0.5-snapshot-
|
38
|
+
"@medusajs/types": "2.0.5-snapshot-20241124153140",
|
39
39
|
"fetch-event-stream": "^0.1.5",
|
40
40
|
"qs": "^6.12.1"
|
41
41
|
},
|