@mitumba/sdk 5.27.0 → 5.29.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +21 -3
- package/dist/index.d.ts +21 -3
- package/dist/index.js +9 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +9 -0
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -2483,6 +2483,7 @@ var REFUSAL_CODES = /* @__PURE__ */ new Set([
|
|
|
2483
2483
|
"empty_cart",
|
|
2484
2484
|
"cannot_buy_own",
|
|
2485
2485
|
"invalid_deliveries",
|
|
2486
|
+
"invalid_selection",
|
|
2486
2487
|
"address_not_found",
|
|
2487
2488
|
"idempotency_conflict",
|
|
2488
2489
|
"listing_unavailable",
|
|
@@ -2518,6 +2519,14 @@ var CheckoutsModule = class {
|
|
|
2518
2519
|
async get(checkoutId, options) {
|
|
2519
2520
|
return this.client.get(`/orders/checkouts/${encodeURIComponent(checkoutId)}`, void 0, options);
|
|
2520
2521
|
}
|
|
2522
|
+
/**
|
|
2523
|
+
* Cancel one of the buyer's unpaid checkouts: its orders are cancelled and its items freed, while
|
|
2524
|
+
* the cart keeps them. Cancelling again answers the same. A refusal throws an `APIError` whose
|
|
2525
|
+
* `code` is a `CancelCheckoutRefusalCode`.
|
|
2526
|
+
*/
|
|
2527
|
+
async cancel(checkoutId, options) {
|
|
2528
|
+
return this.client.post(`/orders/checkouts/${encodeURIComponent(checkoutId)}/cancel`, void 0, options);
|
|
2529
|
+
}
|
|
2521
2530
|
};
|
|
2522
2531
|
|
|
2523
2532
|
// src/modules/settings.ts
|