@medusajs/medusa 1.6.2-alpha.0 → 1.6.2
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/.turbo/turbo-build.log +1 -1
- package/CHANGELOG.md +11 -2
- package/dist/api/index.d.ts +1 -0
- package/dist/api/index.js +1 -0
- package/dist/api/index.js.map +1 -1
- package/dist/api/routes/admin/currencies/list-currencies.d.ts +26 -10
- package/dist/api/routes/admin/currencies/list-currencies.js +26 -10
- package/dist/api/routes/admin/currencies/list-currencies.js.map +1 -1
- package/dist/api/routes/admin/currencies/update-currency.d.ts +22 -0
- package/dist/api/routes/admin/currencies/update-currency.js +22 -0
- package/dist/api/routes/admin/currencies/update-currency.js.map +1 -1
- package/dist/api/routes/admin/order-edits/add-line-item.d.ts +27 -6
- package/dist/api/routes/admin/order-edits/add-line-item.js +27 -6
- package/dist/api/routes/admin/order-edits/add-line-item.js.map +1 -1
- package/dist/api/routes/admin/order-edits/cancel-order-edit.d.ts +2 -2
- package/dist/api/routes/admin/order-edits/cancel-order-edit.js +2 -2
- package/dist/api/routes/admin/order-edits/confirm-order-edit.d.ts +2 -2
- package/dist/api/routes/admin/order-edits/confirm-order-edit.js +2 -2
- package/dist/api/routes/admin/order-edits/create-order-edit.d.ts +17 -3
- package/dist/api/routes/admin/order-edits/create-order-edit.js +17 -3
- package/dist/api/routes/admin/order-edits/create-order-edit.js.map +1 -1
- package/dist/api/routes/admin/order-edits/delete-order-edit-item-change.d.ts +1 -1
- package/dist/api/routes/admin/order-edits/delete-order-edit-item-change.js +1 -1
- package/dist/api/routes/admin/order-edits/delete-order-edit.d.ts +1 -1
- package/dist/api/routes/admin/order-edits/delete-order-edit.js +1 -1
- package/dist/api/routes/admin/order-edits/get-order-edit.d.ts +1 -1
- package/dist/api/routes/admin/order-edits/get-order-edit.js +1 -1
- package/dist/api/routes/admin/order-edits/list-order-edit.d.ts +12 -3
- package/dist/api/routes/admin/order-edits/list-order-edit.js +12 -3
- package/dist/api/routes/admin/order-edits/list-order-edit.js.map +1 -1
- package/dist/api/routes/admin/order-edits/request-confirmation.d.ts +1 -1
- package/dist/api/routes/admin/order-edits/request-confirmation.js +1 -1
- package/dist/api/routes/admin/order-edits/update-order-edit-line-item.d.ts +16 -3
- package/dist/api/routes/admin/order-edits/update-order-edit-line-item.js +16 -3
- package/dist/api/routes/admin/order-edits/update-order-edit-line-item.js.map +1 -1
- package/dist/api/routes/admin/order-edits/update-order-edit.d.ts +12 -3
- package/dist/api/routes/admin/order-edits/update-order-edit.js +12 -3
- package/dist/api/routes/admin/order-edits/update-order-edit.js.map +1 -1
- package/dist/api/routes/admin/product-types/list-product-types.d.ts +3 -7
- package/dist/api/routes/admin/product-types/list-product-types.js +3 -24
- package/dist/api/routes/admin/product-types/list-product-types.js.map +1 -1
- package/dist/api/routes/admin/products/list-types.d.ts +1 -0
- package/dist/api/routes/admin/products/list-types.js +1 -0
- package/dist/api/routes/admin/products/list-types.js.map +1 -1
- package/dist/api/routes/admin/returns/receive-return.d.ts +2 -2
- package/dist/api/routes/admin/returns/receive-return.js +2 -2
- package/dist/api/routes/store/carts/create-payment-sessions.js +25 -30
- package/dist/api/routes/store/carts/create-payment-sessions.js.map +1 -1
- package/dist/api/routes/store/index.js +2 -0
- package/dist/api/routes/store/index.js.map +1 -1
- package/dist/api/routes/store/order-edits/complete-order-edit.d.ts +1 -1
- package/dist/api/routes/store/order-edits/complete-order-edit.js +1 -1
- package/dist/api/routes/store/order-edits/decline-order-edit.d.ts +1 -1
- package/dist/api/routes/store/order-edits/decline-order-edit.js +1 -1
- package/dist/api/routes/store/order-edits/get-order-edit.d.ts +1 -1
- package/dist/api/routes/store/order-edits/get-order-edit.js +1 -1
- package/dist/api/routes/store/product-types/index.d.ts +15 -0
- package/dist/api/routes/store/product-types/index.js +59 -0
- package/dist/api/routes/store/product-types/index.js.map +1 -0
- package/dist/api/routes/store/product-types/list-product-types.d.ts +138 -0
- package/dist/api/routes/store/product-types/list-product-types.js +274 -0
- package/dist/api/routes/store/product-types/list-product-types.js.map +1 -0
- package/dist/api/routes/store/products/list-products.d.ts +9 -0
- package/dist/api/routes/store/products/list-products.js +9 -0
- package/dist/api/routes/store/products/list-products.js.map +1 -1
- package/dist/api/routes/store/returns/create-return.d.ts +2 -2
- package/dist/api/routes/store/returns/create-return.js +2 -2
- package/dist/models/order-edit.d.ts +27 -3
- package/dist/models/order-edit.js +27 -3
- package/dist/models/order-edit.js.map +1 -1
- package/dist/models/order-item-change.d.ts +20 -4
- package/dist/models/order-item-change.js +20 -4
- package/dist/models/order-item-change.js.map +1 -1
- package/dist/models/payment-collection.d.ts +98 -0
- package/dist/models/payment-collection.js +98 -0
- package/dist/models/payment-collection.js.map +1 -1
- package/dist/models/region.d.ts +1 -1
- package/dist/models/region.js +1 -1
- package/dist/services/event-bus.d.ts +9 -3
- package/dist/services/event-bus.js +6 -0
- package/dist/services/event-bus.js.map +1 -1
- package/dist/services/product-type.d.ts +2 -2
- package/dist/services/product-type.js +3 -3
- package/dist/services/product-type.js.map +1 -1
- package/package.json +2 -2
package/.turbo/turbo-build.log
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
[32m@medusajs/medusa:build[0m: cache hit, replaying output [
|
|
1
|
+
[32m@medusajs/medusa:build[0m: cache hit, replaying output [2m4bc3754e8952c70a[0m
|
package/CHANGELOG.md
CHANGED
|
@@ -1,10 +1,19 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
-
## 1.6.2
|
|
3
|
+
## 1.6.2
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
7
|
-
- [`
|
|
7
|
+
- [#2568](https://github.com/medusajs/medusa/pull/2568) [`2d095a0ce`](https://github.com/medusajs/medusa/commit/2d095a0ce14ab7f24b4e6856cb4850cea18af21c) Thanks [@adrien2p](https://github.com/adrien2p)! - fix(medusa): fix missing throw in the store cart create-payment-sessions
|
|
8
|
+
|
|
9
|
+
* [#2566](https://github.com/medusajs/medusa/pull/2566) [`8069ed5e9`](https://github.com/medusajs/medusa/commit/8069ed5e99dc53a912df9bb860114d2258044108) Thanks [@srindom](https://github.com/srindom)! - fix(medusa): add support for retrying failed event bus jobs
|
|
10
|
+
|
|
11
|
+
- [#2552](https://github.com/medusajs/medusa/pull/2552) [`7b0ceeffb`](https://github.com/medusajs/medusa/commit/7b0ceeffb4616c3f4e0cf51aba2ab381c61ea5d7) Thanks [@patrick-medusajs](https://github.com/patrick-medusajs)! - feat(medusa, medusa-js, medusa-react): /store api product types
|
|
12
|
+
|
|
13
|
+
* [#2460](https://github.com/medusajs/medusa/pull/2460) [`5ea4b728e`](https://github.com/medusajs/medusa/commit/5ea4b728e728a7e6d4d6fe7255ea80395ab75bd3) Thanks [@github-actions](https://github.com/apps/github-actions)! - Order/cart decorate totals should assign items totals, shipping option requirements should be tax-inclusive if shipping option is, ensure swaps can be created on orders with discounts
|
|
14
|
+
|
|
15
|
+
* Updated dependencies []:
|
|
16
|
+
- @medusajs/medusa-cli@1.3.4
|
|
8
17
|
|
|
9
18
|
## 1.6.1
|
|
10
19
|
|
package/dist/api/index.d.ts
CHANGED
|
@@ -39,6 +39,7 @@ export * from "./routes/store/gift-cards";
|
|
|
39
39
|
export * from "./routes/store/order-edits";
|
|
40
40
|
export * from "./routes/store/orders";
|
|
41
41
|
export * from "./routes/store/products";
|
|
42
|
+
export * from "./routes/store/product-types";
|
|
42
43
|
export * from "./routes/store/regions";
|
|
43
44
|
export * from "./routes/store/return-reasons";
|
|
44
45
|
export * from "./routes/store/returns";
|
package/dist/api/index.js
CHANGED
|
@@ -70,6 +70,7 @@ __exportStar(require("./routes/store/gift-cards"), exports);
|
|
|
70
70
|
__exportStar(require("./routes/store/order-edits"), exports);
|
|
71
71
|
__exportStar(require("./routes/store/orders"), exports);
|
|
72
72
|
__exportStar(require("./routes/store/products"), exports);
|
|
73
|
+
__exportStar(require("./routes/store/product-types"), exports);
|
|
73
74
|
__exportStar(require("./routes/store/regions"), exports);
|
|
74
75
|
__exportStar(require("./routes/store/return-reasons"), exports);
|
|
75
76
|
__exportStar(require("./routes/store/returns"), exports);
|
package/dist/api/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/api/index.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,mCAAgC;AAChC,8EAAsD;AACtD,yDAAkC;AAClC,yDAAkC;AAElC,iCAAiC;AACjC,mBAAe,UAAC,SAAS,EAAE,MAAM;IAC/B,IAAM,GAAG,GAAG,IAAA,gBAAM,GAAE,CAAA;IAEpB,IAAA,eAAK,EAAC,GAAG,EAAE,SAAS,EAAE,MAAM,CAAC,CAAA;IAC7B,IAAA,eAAK,EAAC,GAAG,EAAE,SAAS,EAAE,MAAM,CAAC,CAAA;IAE7B,GAAG,CAAC,GAAG,CAAC,IAAA,uBAAY,GAAE,CAAC,CAAA;IAEvB,OAAO,GAAG,CAAA;AACZ,CAAC,EAAA;AAED,QAAQ;AACR,mEAAgD;AAChD,sDAAmC;AACnC,uDAAoC;AACpC,6DAA0C;AAC1C,4DAAyC;AACzC,iEAA8C;AAC9C,2DAAwC;AACxC,2DAAwC;AACxC,8DAA2C;AAC3C,4DAAyC;AACzC,yDAAsC;AACtC,uDAAoC;AACpC,+DAA4C;AAC5C,6DAA0C;AAC1C,wDAAqC;AACrC,6DAA0C;AAC1C,8DAA2C;AAC3C,+DAA4C;AAC5C,0DAAuC;AACvC,yDAAsC;AACtC,gEAA6C;AAC7C,yDAAsC;AACtC,gEAA6C;AAC7C,kEAA+C;AAC/C,mEAAgD;AAChD,uDAAoC;AACpC,uDAAoC;AACpC,2DAAwC;AACxC,yDAAsC;AACtC,uDAAoC;AACpC,0DAAuC;AACvC,QAAQ;AACR,sDAAmC;AACnC,uDAAoC;AACpC,6DAA0C;AAC1C,2DAAwC;AACxC,4DAAyC;AACzC,6DAA0C;AAC1C,wDAAqC;AACrC,0DAAuC;AACvC,yDAAsC;AACtC,gEAA6C;AAC7C,yDAAsC;AACtC,kEAA+C;AAC/C,uDAAoC;AACpC,0DAAuC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/api/index.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,mCAAgC;AAChC,8EAAsD;AACtD,yDAAkC;AAClC,yDAAkC;AAElC,iCAAiC;AACjC,mBAAe,UAAC,SAAS,EAAE,MAAM;IAC/B,IAAM,GAAG,GAAG,IAAA,gBAAM,GAAE,CAAA;IAEpB,IAAA,eAAK,EAAC,GAAG,EAAE,SAAS,EAAE,MAAM,CAAC,CAAA;IAC7B,IAAA,eAAK,EAAC,GAAG,EAAE,SAAS,EAAE,MAAM,CAAC,CAAA;IAE7B,GAAG,CAAC,GAAG,CAAC,IAAA,uBAAY,GAAE,CAAC,CAAA;IAEvB,OAAO,GAAG,CAAA;AACZ,CAAC,EAAA;AAED,QAAQ;AACR,mEAAgD;AAChD,sDAAmC;AACnC,uDAAoC;AACpC,6DAA0C;AAC1C,4DAAyC;AACzC,iEAA8C;AAC9C,2DAAwC;AACxC,2DAAwC;AACxC,8DAA2C;AAC3C,4DAAyC;AACzC,yDAAsC;AACtC,uDAAoC;AACpC,+DAA4C;AAC5C,6DAA0C;AAC1C,wDAAqC;AACrC,6DAA0C;AAC1C,8DAA2C;AAC3C,+DAA4C;AAC5C,0DAAuC;AACvC,yDAAsC;AACtC,gEAA6C;AAC7C,yDAAsC;AACtC,gEAA6C;AAC7C,kEAA+C;AAC/C,mEAAgD;AAChD,uDAAoC;AACpC,uDAAoC;AACpC,2DAAwC;AACxC,yDAAsC;AACtC,uDAAoC;AACpC,0DAAuC;AACvC,QAAQ;AACR,sDAAmC;AACnC,uDAAoC;AACpC,6DAA0C;AAC1C,2DAAwC;AACxC,4DAAyC;AACzC,6DAA0C;AAC1C,wDAAqC;AACrC,0DAAuC;AACvC,+DAA4C;AAC5C,yDAAsC;AACtC,gEAA6C;AAC7C,yDAAsC;AACtC,kEAA+C;AAC/C,uDAAoC;AACpC,0DAAuC"}
|
|
@@ -10,9 +10,25 @@ import { ExtendedRequest } from "../../../../types/global";
|
|
|
10
10
|
* parameters:
|
|
11
11
|
* - (query) code {string} Code of the currency to search for.
|
|
12
12
|
* - (query) includes_tax {boolean} Search for tax inclusive currencies.
|
|
13
|
-
* - (query) order {string} to retrieve products in.
|
|
14
|
-
* - (query) offset {
|
|
15
|
-
* - (query) limit {
|
|
13
|
+
* - (query) order {string} order to retrieve products in.
|
|
14
|
+
* - (query) offset=0 {number} How many products to skip in the result.
|
|
15
|
+
* - (query) limit=20 {number} Limit the number of products returned.
|
|
16
|
+
* x-codeSamples:
|
|
17
|
+
* - lang: JavaScript
|
|
18
|
+
* label: JS Client
|
|
19
|
+
* source: |
|
|
20
|
+
* import Medusa from "@medusajs/medusa-js"
|
|
21
|
+
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
22
|
+
* // must be previously logged in or use api token
|
|
23
|
+
* medusa.admin.currencies.list()
|
|
24
|
+
* .then(({ currencies, count, offset, limit }) => {
|
|
25
|
+
* console.log(currencies.length);
|
|
26
|
+
* });
|
|
27
|
+
* - lang: Shell
|
|
28
|
+
* label: cURL
|
|
29
|
+
* source: |
|
|
30
|
+
* curl --location --request POST 'https://medusa-url.com/admin/currencies' \
|
|
31
|
+
* --header 'Authorization: Bearer {api_token}'
|
|
16
32
|
* tags:
|
|
17
33
|
* - Currency
|
|
18
34
|
* responses:
|
|
@@ -22,19 +38,19 @@ import { ExtendedRequest } from "../../../../types/global";
|
|
|
22
38
|
* application/json:
|
|
23
39
|
* schema:
|
|
24
40
|
* properties:
|
|
41
|
+
* currencies:
|
|
42
|
+
* type: array
|
|
43
|
+
* items:
|
|
44
|
+
* $ref: "#/components/schemas/currency"
|
|
25
45
|
* count:
|
|
26
|
-
* description: The number of Currency.
|
|
27
46
|
* type: integer
|
|
47
|
+
* description: The total number of items available
|
|
28
48
|
* offset:
|
|
29
|
-
* description: The offset of the Currency query.
|
|
30
49
|
* type: integer
|
|
50
|
+
* description: The number of items skipped before these items
|
|
31
51
|
* limit:
|
|
32
|
-
* description: The limit of the currency query.
|
|
33
52
|
* type: integer
|
|
34
|
-
*
|
|
35
|
-
* type: array
|
|
36
|
-
* items:
|
|
37
|
-
* $ref: "#/components/schemas/currency"
|
|
53
|
+
* description: The number of items per page
|
|
38
54
|
*/
|
|
39
55
|
declare const _default: (req: ExtendedRequest<Currency>, res: any) => Promise<void>;
|
|
40
56
|
export default _default;
|
|
@@ -93,9 +93,25 @@ var feature_flag_decorators_1 = require("../../../../utils/feature-flag-decorato
|
|
|
93
93
|
* parameters:
|
|
94
94
|
* - (query) code {string} Code of the currency to search for.
|
|
95
95
|
* - (query) includes_tax {boolean} Search for tax inclusive currencies.
|
|
96
|
-
* - (query) order {string} to retrieve products in.
|
|
97
|
-
* - (query) offset {
|
|
98
|
-
* - (query) limit {
|
|
96
|
+
* - (query) order {string} order to retrieve products in.
|
|
97
|
+
* - (query) offset=0 {number} How many products to skip in the result.
|
|
98
|
+
* - (query) limit=20 {number} Limit the number of products returned.
|
|
99
|
+
* x-codeSamples:
|
|
100
|
+
* - lang: JavaScript
|
|
101
|
+
* label: JS Client
|
|
102
|
+
* source: |
|
|
103
|
+
* import Medusa from "@medusajs/medusa-js"
|
|
104
|
+
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
105
|
+
* // must be previously logged in or use api token
|
|
106
|
+
* medusa.admin.currencies.list()
|
|
107
|
+
* .then(({ currencies, count, offset, limit }) => {
|
|
108
|
+
* console.log(currencies.length);
|
|
109
|
+
* });
|
|
110
|
+
* - lang: Shell
|
|
111
|
+
* label: cURL
|
|
112
|
+
* source: |
|
|
113
|
+
* curl --location --request POST 'https://medusa-url.com/admin/currencies' \
|
|
114
|
+
* --header 'Authorization: Bearer {api_token}'
|
|
99
115
|
* tags:
|
|
100
116
|
* - Currency
|
|
101
117
|
* responses:
|
|
@@ -105,19 +121,19 @@ var feature_flag_decorators_1 = require("../../../../utils/feature-flag-decorato
|
|
|
105
121
|
* application/json:
|
|
106
122
|
* schema:
|
|
107
123
|
* properties:
|
|
124
|
+
* currencies:
|
|
125
|
+
* type: array
|
|
126
|
+
* items:
|
|
127
|
+
* $ref: "#/components/schemas/currency"
|
|
108
128
|
* count:
|
|
109
|
-
* description: The number of Currency.
|
|
110
129
|
* type: integer
|
|
130
|
+
* description: The total number of items available
|
|
111
131
|
* offset:
|
|
112
|
-
* description: The offset of the Currency query.
|
|
113
132
|
* type: integer
|
|
133
|
+
* description: The number of items skipped before these items
|
|
114
134
|
* limit:
|
|
115
|
-
* description: The limit of the currency query.
|
|
116
135
|
* type: integer
|
|
117
|
-
*
|
|
118
|
-
* type: array
|
|
119
|
-
* items:
|
|
120
|
-
* $ref: "#/components/schemas/currency"
|
|
136
|
+
* description: The number of items per page
|
|
121
137
|
*/
|
|
122
138
|
exports.default = (function (req, res) { return __awaiter(void 0, void 0, void 0, function () {
|
|
123
139
|
var currencyService, _a, skip, take, _b, currencies, count;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list-currencies.js","sourceRoot":"","sources":["../../../../../src/api/routes/admin/currencies/list-currencies.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mDAAiE;AACjE,kHAAoG;AAGpG,mDAA+D;AAE/D,qFAAiF;AAEjF
|
|
1
|
+
{"version":3,"file":"list-currencies.js","sourceRoot":"","sources":["../../../../../src/api/routes/admin/currencies/list-currencies.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mDAAiE;AACjE,kHAAoG;AAGpG,mDAA+D;AAE/D,qFAAiF;AAEjF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkDG;AACH,mBAAe,UAAO,GAA8B,EAAE,GAAG;;;;;gBACjD,eAAe,GAAoB,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,iBAAiB,CAAC,CAAA;gBAEvE,KAAiB,GAAG,CAAC,UAAU,EAA7B,IAAI,UAAA,EAAE,IAAI,UAAA,CAAmB;gBAErC,GAAG,CAAC,UAAU,CAAC,MAAM,GAAG,SAAS,CAAA;gBACjC,IAAI,GAAG,CAAC,UAAU,CAAC,KAAK,IAAI,GAAG,CAAC,UAAU,CAAC,KAAK,CAAC,YAAY,CAAC,EAAE;oBAC9D,OAAO,GAAG,CAAC,UAAU,CAAC,KAAK,CAAC,YAAY,CAAC,CAAA;iBAC1C;gBAC2B,qBAAM,eAAe,CAAC,YAAY,CAC5D,GAAG,CAAC,gBAAgB,EACpB,GAAG,CAAC,UAAU,CACf,EAAA;;gBAHK,KAAA,sBAAsB,SAG3B,KAAA,EAHM,UAAU,QAAA,EAAE,KAAK,QAAA;gBAKxB,GAAG,CAAC,IAAI,CAAC;oBACP,UAAU,YAAA;oBACV,KAAK,OAAA;oBACL,MAAM,EAAE,IAAI;oBACZ,KAAK,EAAE,IAAI;iBACZ,CAAC,CAAA;;;;KACH,EAAA;AAED;IAA8C,4CAAoB;IAAlE;;IAcA,CAAC;IAXC;QAFC,IAAA,0BAAQ,GAAE;QACV,IAAA,4BAAU,GAAE;;0DACA;IAMb;QAJC,IAAA,+CAAqB,EAAC,+BAA8B,CAAC,GAAG,EAAE;YACzD,IAAA,2BAAS,GAAE;YACX,IAAA,4BAAU,GAAE;SACb,CAAC;;kEACoB;IAItB;QAFC,IAAA,0BAAQ,GAAE;QACV,IAAA,4BAAU,GAAE;;2DACC;IAChB,+BAAC;CAAA,AAdD,CAA8C,6BAAoB,GAcjE;AAdY,4DAAwB"}
|
|
@@ -16,6 +16,28 @@ import { ExtendedRequest } from "../../../../types/global";
|
|
|
16
16
|
* includes_tax:
|
|
17
17
|
* type: boolean
|
|
18
18
|
* description: "[EXPERIMENTAL] Tax included in prices of currency."
|
|
19
|
+
* x-codeSamples:
|
|
20
|
+
* - lang: JavaScript
|
|
21
|
+
* label: JS Client
|
|
22
|
+
* source: |
|
|
23
|
+
* import Medusa from "@medusajs/medusa-js"
|
|
24
|
+
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
25
|
+
* // must be previously logged in or use api token
|
|
26
|
+
* medusa.admin.currencies.update(code, {
|
|
27
|
+
* includes_tax: true
|
|
28
|
+
* })
|
|
29
|
+
* .then(({ currency }) => {
|
|
30
|
+
* console.log(currency.id);
|
|
31
|
+
* });
|
|
32
|
+
* - lang: Shell
|
|
33
|
+
* label: cURL
|
|
34
|
+
* source: |
|
|
35
|
+
* curl --location --request POST 'https://medusa-url.com/admin/currencies/{code}' \
|
|
36
|
+
* --header 'Authorization: Bearer {api_token}' \
|
|
37
|
+
* --header 'Content-Type: application/json' \
|
|
38
|
+
* --data-raw '{
|
|
39
|
+
* "includes_tax": true
|
|
40
|
+
* }'
|
|
19
41
|
* tags:
|
|
20
42
|
* - Currency
|
|
21
43
|
* responses:
|
|
@@ -68,6 +68,28 @@ var tax_inclusive_pricing_1 = __importDefault(require("../../../../loaders/featu
|
|
|
68
68
|
* includes_tax:
|
|
69
69
|
* type: boolean
|
|
70
70
|
* description: "[EXPERIMENTAL] Tax included in prices of currency."
|
|
71
|
+
* x-codeSamples:
|
|
72
|
+
* - lang: JavaScript
|
|
73
|
+
* label: JS Client
|
|
74
|
+
* source: |
|
|
75
|
+
* import Medusa from "@medusajs/medusa-js"
|
|
76
|
+
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
77
|
+
* // must be previously logged in or use api token
|
|
78
|
+
* medusa.admin.currencies.update(code, {
|
|
79
|
+
* includes_tax: true
|
|
80
|
+
* })
|
|
81
|
+
* .then(({ currency }) => {
|
|
82
|
+
* console.log(currency.id);
|
|
83
|
+
* });
|
|
84
|
+
* - lang: Shell
|
|
85
|
+
* label: cURL
|
|
86
|
+
* source: |
|
|
87
|
+
* curl --location --request POST 'https://medusa-url.com/admin/currencies/{code}' \
|
|
88
|
+
* --header 'Authorization: Bearer {api_token}' \
|
|
89
|
+
* --header 'Content-Type: application/json' \
|
|
90
|
+
* --data-raw '{
|
|
91
|
+
* "includes_tax": true
|
|
92
|
+
* }'
|
|
71
93
|
* tags:
|
|
72
94
|
* - Currency
|
|
73
95
|
* responses:
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"update-currency.js","sourceRoot":"","sources":["../../../../../src/api/routes/admin/currencies/update-currency.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mDAAuD;AAIvD,qFAAiF;AACjF,kHAAoG;AAEpG
|
|
1
|
+
{"version":3,"file":"update-currency.js","sourceRoot":"","sources":["../../../../../src/api/routes/admin/currencies/update-currency.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mDAAuD;AAIvD,qFAAiF;AACjF,kHAAoG;AAEpG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiDG;AACH,mBAAe,UAAO,GAA8B,EAAE,GAAG;;;;;gBACjD,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,IAAc,CAAA;gBAChC,IAAI,GAAG,GAAG,CAAC,aAA+C,CAAA;gBAC1D,eAAe,GAAoB,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,iBAAiB,CAAC,CAAA;gBAE5D,qBAAM,eAAe,CAAC,MAAM,CAAC,IAAI,EAAE,IAAI,CAAC,EAAA;;gBAAnD,QAAQ,GAAG,SAAwC;gBAEzD,GAAG,CAAC,IAAI,CAAC,EAAE,QAAQ,UAAA,EAAE,CAAC,CAAA;;;;KACvB,EAAA;AAED;IAAA;IAMA,CAAC;IADC;QAJC,IAAA,+CAAqB,EAAC,+BAA8B,CAAC,GAAG,EAAE;YACzD,IAAA,4BAAU,GAAE;YACZ,IAAA,2BAAS,GAAE;SACZ,CAAC;;wEACoB;IACxB,qCAAC;CAAA,AAND,IAMC;AANY,wEAA8B"}
|
|
@@ -6,6 +6,23 @@ import { Request, Response } from "express";
|
|
|
6
6
|
* description: "Create an OrderEdit LineItem."
|
|
7
7
|
* parameters:
|
|
8
8
|
* - (path) id=* {string} The ID of the Order Edit.
|
|
9
|
+
* requestBody:
|
|
10
|
+
* content:
|
|
11
|
+
* application/json:
|
|
12
|
+
* schema:
|
|
13
|
+
* required:
|
|
14
|
+
* - variant_id
|
|
15
|
+
* - quantity
|
|
16
|
+
* properties:
|
|
17
|
+
* variant_id:
|
|
18
|
+
* description: The ID of the variant ID to add
|
|
19
|
+
* type: string
|
|
20
|
+
* quantity:
|
|
21
|
+
* description: The quantity to add
|
|
22
|
+
* type: number
|
|
23
|
+
* metadata:
|
|
24
|
+
* description: An optional set of key-value pairs to hold additional information.
|
|
25
|
+
* type: object
|
|
9
26
|
* x-authenticated: true
|
|
10
27
|
* x-codeSamples:
|
|
11
28
|
* - lang: JavaScript
|
|
@@ -14,16 +31,20 @@ import { Request, Response } from "express";
|
|
|
14
31
|
* import Medusa from "@medusajs/medusa-js"
|
|
15
32
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
16
33
|
* // must be previously logged in or use api token
|
|
17
|
-
* medusa.admin.
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
34
|
+
* medusa.admin.orderEdits.addLineItem(order_edit_id, {
|
|
35
|
+
* variant_id,
|
|
36
|
+
* quantity
|
|
37
|
+
* })
|
|
38
|
+
* .then(({ order_edit }) => {
|
|
39
|
+
* console.log(order_edit.id)
|
|
40
|
+
* })
|
|
21
41
|
* - lang: Shell
|
|
22
42
|
* label: cURL
|
|
23
43
|
* source: |
|
|
24
44
|
* curl --location --request POST 'https://medusa-url.com/admin/order-edits/{id}/items' \
|
|
25
|
-
* --header 'Authorization: Bearer {api_token}'
|
|
26
|
-
*
|
|
45
|
+
* --header 'Authorization: Bearer {api_token}' \
|
|
46
|
+
* --header 'Content-Type: application/json' \
|
|
47
|
+
* --data-raw '{ "variant_id": "variant_01G1G5V2MRX2V3PVSR2WXYPFB6", "quantity": 3 }'
|
|
27
48
|
* security:
|
|
28
49
|
* - api_token: []
|
|
29
50
|
* - cookie_auth: []
|
|
@@ -55,6 +55,23 @@ var order_edit_1 = require("../../../../types/order-edit");
|
|
|
55
55
|
* description: "Create an OrderEdit LineItem."
|
|
56
56
|
* parameters:
|
|
57
57
|
* - (path) id=* {string} The ID of the Order Edit.
|
|
58
|
+
* requestBody:
|
|
59
|
+
* content:
|
|
60
|
+
* application/json:
|
|
61
|
+
* schema:
|
|
62
|
+
* required:
|
|
63
|
+
* - variant_id
|
|
64
|
+
* - quantity
|
|
65
|
+
* properties:
|
|
66
|
+
* variant_id:
|
|
67
|
+
* description: The ID of the variant ID to add
|
|
68
|
+
* type: string
|
|
69
|
+
* quantity:
|
|
70
|
+
* description: The quantity to add
|
|
71
|
+
* type: number
|
|
72
|
+
* metadata:
|
|
73
|
+
* description: An optional set of key-value pairs to hold additional information.
|
|
74
|
+
* type: object
|
|
58
75
|
* x-authenticated: true
|
|
59
76
|
* x-codeSamples:
|
|
60
77
|
* - lang: JavaScript
|
|
@@ -63,16 +80,20 @@ var order_edit_1 = require("../../../../types/order-edit");
|
|
|
63
80
|
* import Medusa from "@medusajs/medusa-js"
|
|
64
81
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
65
82
|
* // must be previously logged in or use api token
|
|
66
|
-
* medusa.admin.
|
|
67
|
-
*
|
|
68
|
-
*
|
|
69
|
-
*
|
|
83
|
+
* medusa.admin.orderEdits.addLineItem(order_edit_id, {
|
|
84
|
+
* variant_id,
|
|
85
|
+
* quantity
|
|
86
|
+
* })
|
|
87
|
+
* .then(({ order_edit }) => {
|
|
88
|
+
* console.log(order_edit.id)
|
|
89
|
+
* })
|
|
70
90
|
* - lang: Shell
|
|
71
91
|
* label: cURL
|
|
72
92
|
* source: |
|
|
73
93
|
* curl --location --request POST 'https://medusa-url.com/admin/order-edits/{id}/items' \
|
|
74
|
-
* --header 'Authorization: Bearer {api_token}'
|
|
75
|
-
*
|
|
94
|
+
* --header 'Authorization: Bearer {api_token}' \
|
|
95
|
+
* --header 'Content-Type: application/json' \
|
|
96
|
+
* --data-raw '{ "variant_id": "variant_01G1G5V2MRX2V3PVSR2WXYPFB6", "quantity": 3 }'
|
|
76
97
|
* security:
|
|
77
98
|
* - api_token: []
|
|
78
99
|
* - cookie_auth: []
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"add-line-item.js","sourceRoot":"","sources":["../../../../../src/api/routes/admin/order-edits/add-line-item.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,mDAA6D;AAI7D,2DAGqC;AAErC
|
|
1
|
+
{"version":3,"file":"add-line-item.js","sourceRoot":"","sources":["../../../../../src/api/routes/admin/order-edits/add-line-item.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,mDAA6D;AAI7D,2DAGqC;AAErC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwEG;AACH,mBAAe,UAAO,GAAY,EAAE,GAAa;;;;;gBACzC,gBAAgB,GAAG,GAAG,CAAC,KAAK,CAAC,OAAO,CACxC,kBAAkB,CACC,CAAA;gBAEb,EAAE,GAAK,GAAG,CAAC,MAAM,GAAf,CAAe;gBAEnB,OAAO,GAAG,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,SAAS,CAAkB,CAAA;gBAEvD,IAAI,GAAG,GAAG,CAAC,aAAoD,CAAA;gBAErE,qBAAM,OAAO,CAAC,WAAW,CAAC,UAAO,kBAAkB;;;wCACjD,qBAAM,gBAAgB;yCACnB,eAAe,CAAC,kBAAkB,CAAC;yCACnC,WAAW,CAAC,EAAE,EAAE,IAAI,CAAC,EAAA;;oCAFxB,SAEwB,CAAA;;;;yBACzB,CAAC,EAAA;;gBAJF,SAIE,CAAA;gBAEc,qBAAM,gBAAgB,CAAC,QAAQ,CAAC,EAAE,EAAE;wBAClD,MAAM,EAAE,mCAAsB;wBAC9B,SAAS,EAAE,sCAAyB;qBACrC,CAAC,EAAA;;gBAHE,SAAS,GAAG,SAGd;gBAEU,qBAAM,gBAAgB,CAAC,cAAc,CAAC,SAAS,CAAC,EAAA;;gBAA5D,SAAS,GAAG,SAAgD,CAAA;gBAE5D,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC;oBACnB,UAAU,EAAE,SAAS;iBACtB,CAAC,CAAA;;;;KACH,EAAA;AAED;IAAA;IASA,CAAC;IAPC;QADC,IAAA,0BAAQ,GAAE;;2EACO;IAGlB;QADC,IAAA,uBAAK,GAAE;;yEACQ;IAGhB;QADC,IAAA,4BAAU,GAAE;;yEACiC;IAChD,0CAAC;CAAA,AATD,IASC;AATY,kFAAmC"}
|
|
@@ -14,14 +14,14 @@ import { Request, Response } from "express";
|
|
|
14
14
|
* import Medusa from "@medusajs/medusa-js"
|
|
15
15
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
16
16
|
* // must be previously logged in or use api token
|
|
17
|
-
* medusa.admin.
|
|
17
|
+
* medusa.admin.orderEdits.cancel(order_edit_id)
|
|
18
18
|
* .then(({ order_edit }) => {
|
|
19
19
|
* console.log(order_edit.id)
|
|
20
20
|
* })
|
|
21
21
|
* - lang: Shell
|
|
22
22
|
* label: cURL
|
|
23
23
|
* source: |
|
|
24
|
-
* curl --location --request POST 'https://medusa-url.com/admin/order-edits
|
|
24
|
+
* curl --location --request POST 'https://medusa-url.com/admin/order-edits/{id}/cancel' \
|
|
25
25
|
* --header 'Authorization: Bearer {api_token}'
|
|
26
26
|
* security:
|
|
27
27
|
* - api_token: []
|
|
@@ -52,14 +52,14 @@ var order_edit_1 = require("../../../../types/order-edit");
|
|
|
52
52
|
* import Medusa from "@medusajs/medusa-js"
|
|
53
53
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
54
54
|
* // must be previously logged in or use api token
|
|
55
|
-
* medusa.admin.
|
|
55
|
+
* medusa.admin.orderEdits.cancel(order_edit_id)
|
|
56
56
|
* .then(({ order_edit }) => {
|
|
57
57
|
* console.log(order_edit.id)
|
|
58
58
|
* })
|
|
59
59
|
* - lang: Shell
|
|
60
60
|
* label: cURL
|
|
61
61
|
* source: |
|
|
62
|
-
* curl --location --request POST 'https://medusa-url.com/admin/order-edits
|
|
62
|
+
* curl --location --request POST 'https://medusa-url.com/admin/order-edits/{id}/cancel' \
|
|
63
63
|
* --header 'Authorization: Bearer {api_token}'
|
|
64
64
|
* security:
|
|
65
65
|
* - api_token: []
|
|
@@ -14,14 +14,14 @@ import { Request, Response } from "express";
|
|
|
14
14
|
* import Medusa from "@medusajs/medusa-js"
|
|
15
15
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
16
16
|
* // must be previously logged in or use api token
|
|
17
|
-
* medusa.admin.
|
|
17
|
+
* medusa.admin.orderEdits.confirm(order_edit_id)
|
|
18
18
|
* .then(({ order_edit }) => {
|
|
19
19
|
* console.log(order_edit.id)
|
|
20
20
|
* })
|
|
21
21
|
* - lang: Shell
|
|
22
22
|
* label: cURL
|
|
23
23
|
* source: |
|
|
24
|
-
* curl --location --request POST 'https://medusa-url.com/admin/order-edits
|
|
24
|
+
* curl --location --request POST 'https://medusa-url.com/admin/order-edits/{id}/confirm' \
|
|
25
25
|
* --header 'Authorization: Bearer {api_token}'
|
|
26
26
|
* security:
|
|
27
27
|
* - api_token: []
|
|
@@ -52,14 +52,14 @@ var order_edit_1 = require("../../../../types/order-edit");
|
|
|
52
52
|
* import Medusa from "@medusajs/medusa-js"
|
|
53
53
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
54
54
|
* // must be previously logged in or use api token
|
|
55
|
-
* medusa.admin.
|
|
55
|
+
* medusa.admin.orderEdits.confirm(order_edit_id)
|
|
56
56
|
* .then(({ order_edit }) => {
|
|
57
57
|
* console.log(order_edit.id)
|
|
58
58
|
* })
|
|
59
59
|
* - lang: Shell
|
|
60
60
|
* label: cURL
|
|
61
61
|
* source: |
|
|
62
|
-
* curl --location --request POST 'https://medusa-url.com/admin/order-edits
|
|
62
|
+
* curl --location --request POST 'https://medusa-url.com/admin/order-edits/{id}/confirm' \
|
|
63
63
|
* --header 'Authorization: Bearer {api_token}'
|
|
64
64
|
* security:
|
|
65
65
|
* - api_token: []
|
|
@@ -4,6 +4,19 @@ import { Request, Response } from "express";
|
|
|
4
4
|
* operationId: "PostOrderEdits"
|
|
5
5
|
* summary: "Create an OrderEdit"
|
|
6
6
|
* description: "Creates an OrderEdit."
|
|
7
|
+
* requestBody:
|
|
8
|
+
* content:
|
|
9
|
+
* application/json:
|
|
10
|
+
* schema:
|
|
11
|
+
* required:
|
|
12
|
+
* - order_id
|
|
13
|
+
* properties:
|
|
14
|
+
* order_id:
|
|
15
|
+
* description: The ID of the order to create the edit for.
|
|
16
|
+
* type: string
|
|
17
|
+
* internal_note:
|
|
18
|
+
* description: An optional note to create for the order edit.
|
|
19
|
+
* type: string
|
|
7
20
|
* x-authenticated: true
|
|
8
21
|
* x-codeSamples:
|
|
9
22
|
* - lang: JavaScript
|
|
@@ -12,7 +25,7 @@ import { Request, Response } from "express";
|
|
|
12
25
|
* import Medusa from "@medusajs/medusa-js"
|
|
13
26
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
14
27
|
* // must be previously logged in or use api token
|
|
15
|
-
* medusa.admin.
|
|
28
|
+
* medusa.admin.orderEdits.create({ order_id })
|
|
16
29
|
* .then(({ order_edit }) => {
|
|
17
30
|
* console.log(order_edit.id)
|
|
18
31
|
* })
|
|
@@ -20,8 +33,9 @@ import { Request, Response } from "express";
|
|
|
20
33
|
* label: cURL
|
|
21
34
|
* source: |
|
|
22
35
|
* curl --location --request POST 'https://medusa-url.com/admin/order-edits' \
|
|
23
|
-
* --header 'Authorization: Bearer {api_token}'
|
|
24
|
-
*
|
|
36
|
+
* --header 'Authorization: Bearer {api_token}' \
|
|
37
|
+
* --header 'Content-Type: application/json' \
|
|
38
|
+
* --data-raw '{ "order_id": "my_order_id", "internal_note": "my_optional_note" }'
|
|
25
39
|
* security:
|
|
26
40
|
* - api_token: []
|
|
27
41
|
* - cookie_auth: []
|
|
@@ -53,6 +53,19 @@ var order_edit_1 = require("../../../../types/order-edit");
|
|
|
53
53
|
* operationId: "PostOrderEdits"
|
|
54
54
|
* summary: "Create an OrderEdit"
|
|
55
55
|
* description: "Creates an OrderEdit."
|
|
56
|
+
* requestBody:
|
|
57
|
+
* content:
|
|
58
|
+
* application/json:
|
|
59
|
+
* schema:
|
|
60
|
+
* required:
|
|
61
|
+
* - order_id
|
|
62
|
+
* properties:
|
|
63
|
+
* order_id:
|
|
64
|
+
* description: The ID of the order to create the edit for.
|
|
65
|
+
* type: string
|
|
66
|
+
* internal_note:
|
|
67
|
+
* description: An optional note to create for the order edit.
|
|
68
|
+
* type: string
|
|
56
69
|
* x-authenticated: true
|
|
57
70
|
* x-codeSamples:
|
|
58
71
|
* - lang: JavaScript
|
|
@@ -61,7 +74,7 @@ var order_edit_1 = require("../../../../types/order-edit");
|
|
|
61
74
|
* import Medusa from "@medusajs/medusa-js"
|
|
62
75
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
63
76
|
* // must be previously logged in or use api token
|
|
64
|
-
* medusa.admin.
|
|
77
|
+
* medusa.admin.orderEdits.create({ order_id })
|
|
65
78
|
* .then(({ order_edit }) => {
|
|
66
79
|
* console.log(order_edit.id)
|
|
67
80
|
* })
|
|
@@ -69,8 +82,9 @@ var order_edit_1 = require("../../../../types/order-edit");
|
|
|
69
82
|
* label: cURL
|
|
70
83
|
* source: |
|
|
71
84
|
* curl --location --request POST 'https://medusa-url.com/admin/order-edits' \
|
|
72
|
-
* --header 'Authorization: Bearer {api_token}'
|
|
73
|
-
*
|
|
85
|
+
* --header 'Authorization: Bearer {api_token}' \
|
|
86
|
+
* --header 'Content-Type: application/json' \
|
|
87
|
+
* --data-raw '{ "order_id": "my_order_id", "internal_note": "my_optional_note" }'
|
|
74
88
|
* security:
|
|
75
89
|
* - api_token: []
|
|
76
90
|
* - cookie_auth: []
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-order-edit.js","sourceRoot":"","sources":["../../../../../src/api/routes/admin/order-edits/create-order-edit.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,mDAAsD;AAEtD,2DAGqC;AAErC
|
|
1
|
+
{"version":3,"file":"create-order-edit.js","sourceRoot":"","sources":["../../../../../src/api/routes/admin/order-edits/create-order-edit.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,mDAAsD;AAEtD,2DAGqC;AAErC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+DG;AACH,mBAAe,UAAO,GAAY,EAAE,GAAa;;;;;;gBACzC,gBAAgB,GAAG,GAAG,CAAC,KAAK,CAAC,OAAO,CACxC,kBAAkB,CACC,CAAA;gBACf,OAAO,GAAG,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,SAAS,CAAkB,CAAA;gBAEvD,IAAI,GAAG,GAAG,CAAC,aAAuC,CAAA;gBAClD,cAAc,GAAG,CAAC,MAAA,MAAA,GAAG,CAAC,IAAI,0CAAE,EAAE,mCAAI,MAAA,GAAG,CAAC,IAAI,0CAAE,MAAM,CAAW,CAAA;gBAE1C,qBAAM,OAAO,CAAC,WAAW,CAChD,UAAO,kBAAkB;;;wCAChB,qBAAM,gBAAgB;yCAC1B,eAAe,CAAC,kBAAkB,CAAC;yCACnC,MAAM,CAAC,IAAI,EAAE,EAAE,cAAc,gBAAA,EAAE,CAAC,EAAA;wCAFnC,sBAAO,SAE4B,EAAA;;;yBACpC,CACF,EAAA;;gBANK,gBAAgB,GAAG,SAMxB;gBAEe,qBAAM,gBAAgB,CAAC,QAAQ,CAAC,gBAAgB,CAAC,EAAE,EAAE;wBACnE,MAAM,EAAE,mCAAsB;wBAC9B,SAAS,EAAE,sCAAyB;qBACrC,CAAC,EAAA;;gBAHE,SAAS,GAAG,SAGd;gBACU,qBAAM,gBAAgB,CAAC,cAAc,CAAC,SAAS,CAAC,EAAA;;gBAA5D,SAAS,GAAG,SAAgD,CAAA;gBAE5D,sBAAO,GAAG,CAAC,IAAI,CAAC,EAAE,UAAU,EAAE,SAAS,EAAE,CAAC,EAAA;;;KAC3C,EAAA;AAED;IAAA;IAOA,CAAC;IALC;QADC,IAAA,0BAAQ,GAAE;;4DACK;IAIhB;QAFC,IAAA,4BAAU,GAAE;QACZ,IAAA,0BAAQ,GAAE;;iEACW;IACxB,6BAAC;CAAA,AAPD,IAOC;AAPY,wDAAsB"}
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* import Medusa from "@medusajs/medusa-js"
|
|
15
15
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
16
16
|
* // must be previously logged in or use api token
|
|
17
|
-
* medusa.admin.orderEdits.deleteItemChange(
|
|
17
|
+
* medusa.admin.orderEdits.deleteItemChange(order_edit_id, item_change_id)
|
|
18
18
|
* .then(({ id, object, deleted }) => {
|
|
19
19
|
* console.log(id)
|
|
20
20
|
* })
|
|
@@ -52,7 +52,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
52
52
|
* import Medusa from "@medusajs/medusa-js"
|
|
53
53
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
54
54
|
* // must be previously logged in or use api token
|
|
55
|
-
* medusa.admin.orderEdits.deleteItemChange(
|
|
55
|
+
* medusa.admin.orderEdits.deleteItemChange(order_edit_id, item_change_id)
|
|
56
56
|
* .then(({ id, object, deleted }) => {
|
|
57
57
|
* console.log(id)
|
|
58
58
|
* })
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* import Medusa from "@medusajs/medusa-js"
|
|
14
14
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
15
15
|
* // must be previously logged in or use api token
|
|
16
|
-
* medusa.admin.orderEdits.delete(
|
|
16
|
+
* medusa.admin.orderEdits.delete(order_edit_id)
|
|
17
17
|
* .then(({ id, object, deleted }) => {
|
|
18
18
|
* console.log(id)
|
|
19
19
|
* })
|
|
@@ -51,7 +51,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
51
51
|
* import Medusa from "@medusajs/medusa-js"
|
|
52
52
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
53
53
|
* // must be previously logged in or use api token
|
|
54
|
-
* medusa.admin.orderEdits.delete(
|
|
54
|
+
* medusa.admin.orderEdits.delete(order_edit_id)
|
|
55
55
|
* .then(({ id, object, deleted }) => {
|
|
56
56
|
* console.log(id)
|
|
57
57
|
* })
|
|
@@ -17,7 +17,7 @@ import { FindParams } from "../../../../types/common";
|
|
|
17
17
|
* import Medusa from "@medusajs/medusa-js"
|
|
18
18
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
19
19
|
* // must be previously logged in or use api token
|
|
20
|
-
* medusa.admin.
|
|
20
|
+
* medusa.admin.orderEdits.retrieve(orderEditId)
|
|
21
21
|
* .then(({ order_edit }) => {
|
|
22
22
|
* console.log(order_edit.id)
|
|
23
23
|
* })
|
|
@@ -70,7 +70,7 @@ var common_1 = require("../../../../types/common");
|
|
|
70
70
|
* import Medusa from "@medusajs/medusa-js"
|
|
71
71
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
72
72
|
* // must be previously logged in or use api token
|
|
73
|
-
* medusa.admin.
|
|
73
|
+
* medusa.admin.orderEdits.retrieve(orderEditId)
|
|
74
74
|
* .then(({ order_edit }) => {
|
|
75
75
|
* console.log(order_edit.id)
|
|
76
76
|
* })
|
|
@@ -19,9 +19,9 @@ import { Request, Response } from "express";
|
|
|
19
19
|
* import Medusa from "@medusajs/medusa-js"
|
|
20
20
|
* const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3 })
|
|
21
21
|
* // must be previously logged in or use api token
|
|
22
|
-
* medusa.admin.
|
|
23
|
-
* .then(({ order_edits }) => {
|
|
24
|
-
* console.log(order_edits)
|
|
22
|
+
* medusa.admin.orderEdits.list()
|
|
23
|
+
* .then(({ order_edits, count, limit, offset }) => {
|
|
24
|
+
* console.log(order_edits.length)
|
|
25
25
|
* })
|
|
26
26
|
* - lang: Shell
|
|
27
27
|
* label: cURL
|
|
@@ -43,6 +43,15 @@ import { Request, Response } from "express";
|
|
|
43
43
|
* order_edits:
|
|
44
44
|
* type: array
|
|
45
45
|
* $ref: "#/components/schemas/order_edit"
|
|
46
|
+
* count:
|
|
47
|
+
* type: integer
|
|
48
|
+
* description: The total number of items available
|
|
49
|
+
* offset:
|
|
50
|
+
* type: integer
|
|
51
|
+
* description: The number of items skipped before these items
|
|
52
|
+
* limit:
|
|
53
|
+
* type: integer
|
|
54
|
+
* description: The number of items per page
|
|
46
55
|
* "400":
|
|
47
56
|
* $ref: "#/components/responses/400_error"
|
|
48
57
|
* "401":
|