@delopay/sdk 0.158.0 → 0.159.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/{chunk-4YLUV3YJ.js → chunk-NQJP5VBB.js} +45 -7
- package/dist/{chunk-4YLUV3YJ.js.map → chunk-NQJP5VBB.js.map} +1 -1
- package/dist/index.cjs +44 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +107 -14
- package/dist/index.d.ts +107 -14
- package/dist/index.js +1 -1
- package/dist/internal.cjs +109 -6
- package/dist/internal.cjs.map +1 -1
- package/dist/internal.d.cts +77 -2
- package/dist/internal.d.ts +77 -2
- package/dist/internal.js +66 -1
- package/dist/internal.js.map +1 -1
- package/package.json +1 -1
package/dist/internal.cjs
CHANGED
|
@@ -8507,12 +8507,29 @@ var CheckoutSession = class {
|
|
|
8507
8507
|
* checkout payload with `card_connector_server_confirm: true`. Stripe refuses
|
|
8508
8508
|
* a Stripe.js confirm of such an intent.
|
|
8509
8509
|
*
|
|
8510
|
-
* Send the
|
|
8511
|
-
* Element
|
|
8512
|
-
*
|
|
8513
|
-
*
|
|
8514
|
-
*
|
|
8515
|
-
*
|
|
8510
|
+
* Send the PaymentMethod `stripe.createPaymentMethod` produced from the
|
|
8511
|
+
* Payment Element (or Express Checkout Element), which needs
|
|
8512
|
+
* `paymentMethodCreation: 'manual'` on the Elements instance. A
|
|
8513
|
+
* ConfirmationToken is refused with `400`: Stripe will not confirm such an
|
|
8514
|
+
* intent with one.
|
|
8515
|
+
*
|
|
8516
|
+
* The router judges the card's issuing country and the buyer's IP country
|
|
8517
|
+
* against the shop's sell-to restrictions before Stripe authorises, and a
|
|
8518
|
+
* refusal throws a `DelopayError` with code `DE_10`. When the answer's
|
|
8519
|
+
* `status` is `requires_action`, run `stripe.handleNextAction` with its
|
|
8520
|
+
* `client_secret` — safe, because the intent is `confirmation_method=manual`
|
|
8521
|
+
* and that secret confirms nothing without the secret key — then call this
|
|
8522
|
+
* again without a payment method to finalize.
|
|
8523
|
+
*
|
|
8524
|
+
* A PaymentMethod rules out what `stripe.createPaymentMethod` cannot
|
|
8525
|
+
* produce: Stripe names Amazon Pay and Klarna in the Express Checkout
|
|
8526
|
+
* Element, which need `stripe.createConfirmationToken` instead. Neither can
|
|
8527
|
+
* be paid through this route, so a caller must not offer them on a
|
|
8528
|
+
* server-confirmed intent — mount the Express Checkout Element with those
|
|
8529
|
+
* methods `'never'`, as DeloPay's own checkout does. The router drops only
|
|
8530
|
+
* the methods its server-side confirm cannot finish at all (BLIK and ACSS
|
|
8531
|
+
* pre-authorized debits) from the card form's mount, so the rest of the
|
|
8532
|
+
* selection still reaches the element and is the caller's to constrain.
|
|
8516
8533
|
*
|
|
8517
8534
|
* `POST /payment-link/{merchantId}/{paymentId}/stripe-confirm`
|
|
8518
8535
|
*/
|
|
@@ -8523,6 +8540,27 @@ var CheckoutSession = class {
|
|
|
8523
8540
|
headers: this.bearerHeaders(options?.headers)
|
|
8524
8541
|
});
|
|
8525
8542
|
}
|
|
8543
|
+
/**
|
|
8544
|
+
* Ask whether NomuPay's COPYandPAY widget may submit a card, from the
|
|
8545
|
+
* form's pre-submit hook.
|
|
8546
|
+
*
|
|
8547
|
+
* Only for a checkout stamped `NomupayOppwaCheckoutData.submit_grant`: the
|
|
8548
|
+
* card form sits beside always-shown wallet buttons of another account, and
|
|
8549
|
+
* this answer closes those buttons before it allows the card. `authorized`
|
|
8550
|
+
* is `false` when the payment no longer waits for a payment method, or when
|
|
8551
|
+
* this is not the attempt's live card-form checkout; when a wallet beside it
|
|
8552
|
+
* is already being paid, the route answers an error instead. Submit the
|
|
8553
|
+
* widget only on `true`.
|
|
8554
|
+
*
|
|
8555
|
+
* `POST /payment-link/{merchantId}/{paymentId}/nomupay-card-authorization`
|
|
8556
|
+
*/
|
|
8557
|
+
async nomupayCardAuthorization(params, options) {
|
|
8558
|
+
return this.client.request("POST", `${this.linkBase}/nomupay-card-authorization`, {
|
|
8559
|
+
body: params,
|
|
8560
|
+
...options,
|
|
8561
|
+
headers: this.bearerHeaders(options?.headers)
|
|
8562
|
+
});
|
|
8563
|
+
}
|
|
8526
8564
|
/**
|
|
8527
8565
|
* The payment's current state — status polling for redirect/popup rails.
|
|
8528
8566
|
*
|
|
@@ -9371,6 +9409,71 @@ var AdminPortal = class {
|
|
|
9371
9409
|
`/admin-portal/accounts/${encodeURIComponent(merchantId)}/sell-to-restrictions`
|
|
9372
9410
|
);
|
|
9373
9411
|
}
|
|
9412
|
+
/**
|
|
9413
|
+
* The deployment's replay-masking rules: extra page elements the session
|
|
9414
|
+
* recorder hides on top of the ones it always hides.
|
|
9415
|
+
*
|
|
9416
|
+
* `GET /admin-portal/replay-masking`
|
|
9417
|
+
*/
|
|
9418
|
+
async getReplayMasking() {
|
|
9419
|
+
return this.request("GET", "/admin-portal/replay-masking");
|
|
9420
|
+
}
|
|
9421
|
+
/**
|
|
9422
|
+
* Replace the deployment's replay-masking rules. Additive to the recorder's
|
|
9423
|
+
* built-in floor: a rule can widen what a recording leaves out and can never
|
|
9424
|
+
* reveal something the recorder hides unconditionally.
|
|
9425
|
+
*
|
|
9426
|
+
* `PUT /admin-portal/replay-masking`
|
|
9427
|
+
*/
|
|
9428
|
+
async updateReplayMasking(params) {
|
|
9429
|
+
return this.request("PUT", "/admin-portal/replay-masking", { body: params });
|
|
9430
|
+
}
|
|
9431
|
+
/**
|
|
9432
|
+
* One merchant's replay-masking rules.
|
|
9433
|
+
*
|
|
9434
|
+
* `GET /admin-portal/accounts/{merchantId}/replay-masking`
|
|
9435
|
+
*/
|
|
9436
|
+
async getMerchantReplayMasking(merchantId) {
|
|
9437
|
+
return this.request(
|
|
9438
|
+
"GET",
|
|
9439
|
+
`/admin-portal/accounts/${encodeURIComponent(merchantId)}/replay-masking`
|
|
9440
|
+
);
|
|
9441
|
+
}
|
|
9442
|
+
/**
|
|
9443
|
+
* Replace one merchant's replay-masking rules.
|
|
9444
|
+
*
|
|
9445
|
+
* `PUT /admin-portal/accounts/{merchantId}/replay-masking`
|
|
9446
|
+
*/
|
|
9447
|
+
async updateMerchantReplayMasking(merchantId, params) {
|
|
9448
|
+
return this.request(
|
|
9449
|
+
"PUT",
|
|
9450
|
+
`/admin-portal/accounts/${encodeURIComponent(merchantId)}/replay-masking`,
|
|
9451
|
+
{ body: params }
|
|
9452
|
+
);
|
|
9453
|
+
}
|
|
9454
|
+
/**
|
|
9455
|
+
* One shop's replay-masking rules.
|
|
9456
|
+
*
|
|
9457
|
+
* `GET /admin-portal/accounts/{merchantId}/business-profile/{profileId}/replay-masking`
|
|
9458
|
+
*/
|
|
9459
|
+
async getShopReplayMasking(merchantId, profileId) {
|
|
9460
|
+
return this.request(
|
|
9461
|
+
"GET",
|
|
9462
|
+
`/admin-portal/accounts/${encodeURIComponent(merchantId)}/business-profile/${encodeURIComponent(profileId)}/replay-masking`
|
|
9463
|
+
);
|
|
9464
|
+
}
|
|
9465
|
+
/**
|
|
9466
|
+
* Replace one shop's replay-masking rules.
|
|
9467
|
+
*
|
|
9468
|
+
* `PUT /admin-portal/accounts/{merchantId}/business-profile/{profileId}/replay-masking`
|
|
9469
|
+
*/
|
|
9470
|
+
async updateShopReplayMasking(merchantId, profileId, params) {
|
|
9471
|
+
return this.request(
|
|
9472
|
+
"PUT",
|
|
9473
|
+
`/admin-portal/accounts/${encodeURIComponent(merchantId)}/business-profile/${encodeURIComponent(profileId)}/replay-masking`,
|
|
9474
|
+
{ body: params }
|
|
9475
|
+
);
|
|
9476
|
+
}
|
|
9374
9477
|
/**
|
|
9375
9478
|
* Soft-delete a transaction of ANY merchant. Only payments whose status
|
|
9376
9479
|
* is in the admin delete policy can be deleted; the action is audited.
|