@agent-cards/sdk 0.23.28 → 0.24.1
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/CHANGELOG.md +84 -0
- package/PREFLIGHT.md +7 -1
- package/README.md +197 -102
- package/dist/aci.d.ts +52 -22
- package/dist/aci.js +79 -15
- package/dist/adyen-merchant-hosted.generated.d.ts +2 -2
- package/dist/adyen-merchant-hosted.generated.js +586 -55
- package/dist/agent-amount.generated.js +1 -1
- package/dist/agentcard.d.ts +4 -5
- package/dist/agentcard.js +4 -5
- package/dist/amadeus.d.ts +9 -3
- package/dist/amadeus.js +33 -4
- package/dist/api-module.d.ts +1 -7
- package/dist/api-module.js +3 -5
- package/dist/{voice-retry.js → api-retry.js} +1 -1
- package/dist/api-types.d.ts +53 -0
- package/dist/{voice-types.js → api-types.js} +7 -2
- package/dist/approvals.d.ts +166 -0
- package/dist/approvals.js +213 -0
- package/dist/aurus.d.ts +33 -0
- package/dist/aurus.js +75 -0
- package/dist/builtin-registry.generated.js +1 -1
- package/dist/buy.d.ts +20 -101
- package/dist/buy.js +19 -74
- package/dist/capabilities.generated.js +1 -1
- package/dist/card-fields.generated.js +2864 -249
- package/dist/cardlink-vpos.d.ts +43 -0
- package/dist/cardlink-vpos.js +90 -0
- package/dist/cdp.d.ts +3 -13
- package/dist/cdp.js +244 -175
- package/dist/checkout-com.generated.js +5 -1
- package/dist/client.d.ts +170 -22
- package/dist/client.js +281 -40
- package/dist/creditguard.generated.d.ts +4 -4
- package/dist/cybersource-flex.generated.d.ts +39 -1
- package/dist/cybersource-flex.generated.js +100 -11
- package/dist/datatrans.generated.js +22 -1
- package/dist/eghl.d.ts +40 -0
- package/dist/eghl.js +72 -0
- package/dist/elavon-converge.generated.js +5 -3
- package/dist/gmo.generated.js +7 -2
- package/dist/hold.d.ts +8 -0
- package/dist/hold.js +43 -2
- package/dist/hosted-entry.js +4 -0
- package/dist/index.d.ts +9 -15
- package/dist/index.js +6 -10
- package/dist/lifecycle.d.ts +9 -61
- package/dist/lifecycle.js +24 -10
- package/dist/merchant-card-endpoints.generated.d.ts +6 -1
- package/dist/merchant-card-endpoints.generated.js +344 -19
- package/dist/merchant-hosted.d.ts +8 -1
- package/dist/nike-order.d.ts +51 -0
- package/dist/nike-order.js +81 -0
- package/dist/oceanpayment.d.ts +38 -0
- package/dist/oceanpayment.js +70 -0
- package/dist/paddle-tokenex.generated.js +111 -11
- package/dist/payplug.d.ts +41 -0
- package/dist/payplug.js +71 -0
- package/dist/payrails.generated.js +33 -8
- package/dist/pre-claim.d.ts +11 -0
- package/dist/pre-claim.js +130 -7
- package/dist/preflight-capabilities.generated.d.ts +0 -4
- package/dist/preflight-capabilities.generated.js +0 -5
- package/dist/preflight-catalog.json +200 -6
- package/dist/preflight-playwright.d.ts +2 -2
- package/dist/preflight-playwright.js +63 -14
- package/dist/preflight-schemas.json +18 -0
- package/dist/preflight.generated.d.ts +5 -4
- package/dist/preflight.generated.js +63 -3
- package/dist/preparation.d.ts +7 -0
- package/dist/preparation.js +21 -0
- package/dist/prepared-processor.d.ts +18 -5
- package/dist/prepared-processor.js +48 -8
- package/dist/primer.generated.js +2889 -268
- package/dist/processout.generated.d.ts +61 -0
- package/dist/processout.generated.js +577 -0
- package/dist/requests.js +1 -1
- package/dist/shiji-sts.generated.js +111 -11
- package/dist/stripe-checkout.generated.js +2761 -319
- package/dist/substitutions.generated.js +553 -26
- package/dist/tap-payments.generated.js +111 -11
- package/dist/twoc2p.generated.js +111 -11
- package/dist/url-masks/bluesnap.d.ts +2 -0
- package/dist/url-masks/bluesnap.js +15 -0
- package/dist/url-masks/oceanpayment.d.ts +2 -0
- package/dist/url-masks/oceanpayment.js +13 -0
- package/dist/url-masks/payplug.d.ts +2 -0
- package/dist/url-masks/payplug.js +13 -0
- package/dist/url-masks/vtex_payments.d.ts +2 -0
- package/dist/url-masks/vtex_payments.js +12 -0
- package/dist/url-masks.generated.d.ts +1 -1
- package/dist/url-masks.generated.js +6 -2
- package/dist/verifone.generated.js +42 -2
- package/dist/vtex-payments.generated.d.ts +127 -0
- package/dist/vtex-payments.generated.js +544 -0
- package/dist/webhooks.d.ts +2 -2
- package/dist/webhooks.js +2 -2
- package/examples/preflight/kernel-native/inventory.json +1 -1
- package/package.json +6 -8
- package/dist/languages.d.ts +0 -23
- package/dist/languages.js +0 -76
- package/dist/voice-pkce.d.ts +0 -49
- package/dist/voice-pkce.js +0 -147
- package/dist/voice-stream.generated.d.ts +0 -118
- package/dist/voice-stream.generated.js +0 -170
- package/dist/voice-types.d.ts +0 -735
- package/dist/voice.d.ts +0 -373
- package/dist/voice.js +0 -815
- package/readme.test.mjs +0 -53
- /package/dist/{voice-retry.d.ts → api-retry.d.ts} +0 -0
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
// @ts-nocheck
|
|
2
2
|
// Generated from @agent-cards/payment-core. Do not edit.
|
|
3
|
-
// artifact-sha256:
|
|
3
|
+
// artifact-sha256: a4f45fd0e69b19e8cb2da463b865012950ae5bcc9971c01d3e348a7de1a255ef
|
|
4
4
|
// src/checkout-com.js
|
|
5
5
|
var ENDPOINTS = Object.freeze({
|
|
6
6
|
production: ["https://api.checkout.com/tokens", "https://card-acquisition-gateway.checkout.com/tokens"],
|
|
7
7
|
sandbox: ["https://api.sandbox.checkout.com/tokens", "https://card-acquisition-gateway.sandbox.checkout.com/tokens"]
|
|
8
8
|
});
|
|
9
|
+
var MERCHANT_ENDPOINT = /^https:\/\/(?:[a-z0-9]+\.)?(?:api(\.sandbox)?\.checkout\.com\/tokens|devices\.api(\.sandbox)?\.checkout\.com\/(?:cag\/)?tokens)$/;
|
|
9
10
|
var record = (value) => value !== null && typeof value === "object" && !Array.isArray(value);
|
|
10
11
|
var own = (value, name) => Object.prototype.hasOwnProperty.call(value, name);
|
|
11
12
|
var keys = (value, allowed) => record(value) && Object.keys(value).every((name) => allowed.includes(name));
|
|
@@ -123,6 +124,9 @@ function checkoutComEnvironment(url) {
|
|
|
123
124
|
return "production";
|
|
124
125
|
if (ENDPOINTS.sandbox.includes(url))
|
|
125
126
|
return "sandbox";
|
|
127
|
+
const merchant = typeof url === "string" ? MERCHANT_ENDPOINT.exec(url) : null;
|
|
128
|
+
if (merchant?.[0] === url)
|
|
129
|
+
return merchant[1] || merchant[2] ? "sandbox" : "production";
|
|
126
130
|
return void 0;
|
|
127
131
|
}
|
|
128
132
|
var ADDRESS_TEXT = ["address_line1", "address_line2", "city", "state", "zip", "name"];
|
package/dist/client.d.ts
CHANGED
|
@@ -7,8 +7,8 @@ import { type VerifoneProfile, type VerifoneSubstitutions } from './verifone.js'
|
|
|
7
7
|
import { type MerchantSessionCapture } from './merchant-session-probe.js';
|
|
8
8
|
import { type PaddleTokenexServedFacts } from './paddle-tokenex.js';
|
|
9
9
|
import type { PaddleCheckoutCapture } from './paddle-checkout-watch.js';
|
|
10
|
-
import { VoiceModule, type VoiceOptions } from './voice.js';
|
|
11
10
|
import { BuyModule } from './buy.js';
|
|
11
|
+
import { ApprovalsModule } from './approvals.js';
|
|
12
12
|
import { RequestRegistry } from './requests.js';
|
|
13
13
|
import type { ApiTransport } from './api-module.js';
|
|
14
14
|
import { type MicroformField, type MicroformSidecar } from './cybersource-flex.js';
|
|
@@ -121,6 +121,15 @@ export declare const SUPPORTED_REGISTRY_FEATURES: readonly string[];
|
|
|
121
121
|
* recognizer is never in BUILTIN_REGISTRY, so a build reaches it only through a
|
|
122
122
|
* sync that declares its capability, and whether an org may pay through it
|
|
123
123
|
* stays the API's decision.
|
|
124
|
+
* `bluesnap_hosted_payment_fields`: BlueSnap's Hosted Payment Fields, whose card
|
|
125
|
+
* number, expiry and code frames each PUT their own field as JSON to the
|
|
126
|
+
* merchant's payment-fields token. This build pauses the card number PUT, holds
|
|
127
|
+
* the expiry and code PUTs and answers them with its answer (aci.ts, the JSON
|
|
128
|
+
* split card), and the cardholder's device sends the whole card in that one PUT
|
|
129
|
+
* (payment-core processors/bluesnap.js). The request names no amount, so the
|
|
130
|
+
* agent's pair, above zero, is the one the cardholder approves. Served on the
|
|
131
|
+
* same terms: only to a build that lists it, for a company Agentcard turned
|
|
132
|
+
* BlueSnap on for.
|
|
124
133
|
* `creditguard_pps_process`: CreditGuard's hosted payment page (Hyp PPS), whose
|
|
125
134
|
* card submit this build pays only under a prepared checkout that names the
|
|
126
135
|
* framed page (prepare({ psp: 'creditguard', environment, paymentPageUrl })). The
|
|
@@ -459,6 +468,18 @@ export declare const SUPPORTED_REGISTRY_FEATURES: readonly string[];
|
|
|
459
468
|
* page the create names. Served on the same terms: only to a build that lists it, for a company
|
|
460
469
|
* Agentcard turned Pin Payments on for.
|
|
461
470
|
*
|
|
471
|
+
* `paymentwall_card_token`: the card request Paymentwall's card form (Brick) sends, from its number
|
|
472
|
+
* frame on pwgateway.com inside Paymentwall's hosted widget or from a merchant's own page: a form POST
|
|
473
|
+
* to https://pwgateway.com/api/token (https://api.paymentwall.com/api/brick/token for a test key)
|
|
474
|
+
* under the merchant's public key. This build pauses only the card form's own body at those exact
|
|
475
|
+
* URLs (payment-core processors/paymentwall.js); a stored card's code, a wallet's token, a brand from
|
|
476
|
+
* the page's select or any other body there fails in the browser before anything is created. The
|
|
477
|
+
* cardholder's device sends the request itself with the real card, and the page gets the token answer
|
|
478
|
+
* payment-core's judge rebuilt. The request names no amount, so the agent's pair, above zero, is the
|
|
479
|
+
* one the cardholder approves, and the API pays only a Paymentwall project payment-core pins for the
|
|
480
|
+
* checkout page the create names. Served on the same terms: only to a build that lists it, for a
|
|
481
|
+
* company Agentcard turned Paymentwall on for.
|
|
482
|
+
*
|
|
462
483
|
* `sbps_token_jsonp`: SB Payment Service's card token request, the JSONP <script>
|
|
463
484
|
* GET its token script sends to /token/generateToken on token.sps-system.com. This
|
|
464
485
|
* build pauses it only as the browser writes it, aborts any other request on that
|
|
@@ -475,6 +496,56 @@ export declare const SUPPORTED_REGISTRY_FEATURES: readonly string[];
|
|
|
475
496
|
* Served on the same terms, and the API holds the lane to Agentcard's own company
|
|
476
497
|
* until a reviewed change binds the client key to the merchant.
|
|
477
498
|
*
|
|
499
|
+
* `iyzico_checkout_form`: the card payment iyzico's Checkout Form posts as one JSON request to
|
|
500
|
+
* api.iyzipay.com/payment/iyzipos/checkoutform/auth/ecom, or initialize3ds/ecom for 3-D Secure
|
|
501
|
+
* (sandbox-api.iyzipay.com in test), under the form's X-IYZI-TOKEN. This build pauses only the
|
|
502
|
+
* form's own payment with a new card at those exact URLs (payment-core processors/iyzico.js); a saved
|
|
503
|
+
* card, a card kept on file, installments and a currency conversion fail in the browser before
|
|
504
|
+
* anything is created. The cardholder's device sends the payment itself, and the page gets iyzico's
|
|
505
|
+
* answer as payment-core's judge rebuilt it: the payment done, or the bank's 3-D Secure page, which
|
|
506
|
+
* the form then runs in the agent's browser. The payment names its price but not its currency, so
|
|
507
|
+
* authorize() needs the agent's pair, and the API holds its amount to the price. Served on the same
|
|
508
|
+
* terms, and the API holds the lane to Agentcard's own company.
|
|
509
|
+
*
|
|
510
|
+
* `aurus_one_time_token`: the card request Aurus Pay's ecom card frame (O'Reilly Auto Parts) sends to
|
|
511
|
+
* pecst<NN>.aurusepay.com/storeservices/ecom/oneTimeToken, the card sealed in the frame under a public key its own
|
|
512
|
+
* script carries. This build pauses it only when Aurus's card frame sent it (aurus.ts aurusPreClaim); the same
|
|
513
|
+
* request from the store's page or another frame fails in the browser before anything is created. The request
|
|
514
|
+
* names no amount, so authorize() needs the agent's pair, above zero. The cardholder's device does not seal for
|
|
515
|
+
* Aurus yet (payment-core processors/aurus.js), so a paused request opens no approval that pays.
|
|
516
|
+
*
|
|
517
|
+
* `viva_smart_checkout_chargetoken`: the card request Viva Wallet's Smart Checkout page sends as one
|
|
518
|
+
* JSON request to www.vivapayments.com/web2/checkout/v2/chargetokens (demo.vivapayments.com in test),
|
|
519
|
+
* on Pay, after the page's own reCAPTCHA run. This build pauses only the page's own card body at that
|
|
520
|
+
* exact URL (payment-core processors/viva_wallet.js); a body that keeps the card, pays with a stored
|
|
521
|
+
* card, converts the currency or is the page's second try after a decline fails in the browser before
|
|
522
|
+
* anything is created. The cardholder's device sends the card through Agentcard's checkout relay, since
|
|
523
|
+
* the page's request answers no other origin, and the page gets Viva's single-use charge token as
|
|
524
|
+
* payment-core's judge rebuilt it; the page then charges that token card free. The body names its
|
|
525
|
+
* amount, which the API holds to the agent's pair, and the API pays a live token only for an order
|
|
526
|
+
* payment-core pins. Served on the same terms, and the API holds the lane to Agentcard's own company.
|
|
527
|
+
*
|
|
528
|
+
* `paystack_pinned_key`: the charge Paystack's hosted checkout sends as one form POST to
|
|
529
|
+
* standard.paystack.co/charge/, the card only as `clientdata`, RSA ciphertext under the one key
|
|
530
|
+
* Paystack's page carries. This build pauses only the card page's own charge at that exact URL
|
|
531
|
+
* (payment-core processors/paystack.js); a charge that keeps the card, starts a plan or carries a PIN
|
|
532
|
+
* fails in the browser before anything is created. The cardholder's device encrypts the real card under
|
|
533
|
+
* the same pinned key and sends the charge itself, and the page gets Paystack's answer: paid, declined,
|
|
534
|
+
* or the issuer's 3-D Secure step, which the page then runs in the agent's browser. The charge names
|
|
535
|
+
* no amount, so authorize() needs the agent's pair, above zero. Served on the same terms, and the API
|
|
536
|
+
* holds the lane to Agentcard's own company.
|
|
537
|
+
*
|
|
538
|
+
* `usaepay_payment_key`: the card request USAePay's Pay.js card frame sends as one JSON request to
|
|
539
|
+
* www.usaepay.com/api/v2/pub/payment_keys (secure.usaepay.com alike; sandbox.usaepay.com in test), under
|
|
540
|
+
* the merchant's public key in its Authorization. This build pauses only the frame's own card body at
|
|
541
|
+
* that exact URL (payment-core processors/usaepay.js); a Google Pay or Apple Pay token and a bank
|
|
542
|
+
* account on the same URL fail in the browser before anything is created. The cardholder's device sends
|
|
543
|
+
* the card through Agentcard's checkout relay, since USAePay answers no browser origin, and the frame
|
|
544
|
+
* gets USAePay's single-use payment key as payment-core's judge rebuilt it; the merchant's server
|
|
545
|
+
* charges that key afterwards. The request names no amount, so authorize() needs the agent's pair, and
|
|
546
|
+
* the API pays a live key only to a merchant payment-core pins for the checkout page. Served on the same
|
|
547
|
+
* terms, and the API holds the lane to Agentcard's own company.
|
|
548
|
+
*
|
|
478
549
|
* `tap_card_sdk_token`: the token request Tap Payments' card frame sends to sdk.tap.company, carrying
|
|
479
550
|
* the card only as one ciphertext the frame writes under the merchant's own RSA key. This build pauses
|
|
480
551
|
* it and writes over the placeholder's ciphertext the one the cardholder's device wrote under the key
|
|
@@ -502,6 +573,41 @@ export declare const SUPPORTED_REGISTRY_FEATURES: readonly string[];
|
|
|
502
573
|
* (agent-amount-processors.json), is the one the cardholder approves. Served on the same terms: only
|
|
503
574
|
* to a build that lists it, for a company Agentcard turned Openpay on for.
|
|
504
575
|
*
|
|
576
|
+
* `processout_card_token`: the card request ProcessOut.js's card frame sends from js.processout.com to
|
|
577
|
+
* api.processout.com/cards under the store's project id, only through a prepared checkout: the frame
|
|
578
|
+
* gives the page 20 seconds from the shop's continue press, so the cardholder approves before it. The
|
|
579
|
+
* card URL names the project in its query, so the claim binds the request by its project's environment
|
|
580
|
+
* and its shape, never by the prepared URL. The cardholder's device sends the card to ProcessOut itself
|
|
581
|
+
* and the frame gets back ProcessOut's token alone, rebuilt by payment-core's judge. The request names
|
|
582
|
+
* no amount, so the agent's pair, above zero (agent-amount-processors.json), is the one the cardholder
|
|
583
|
+
* approves. Served on the same terms: only to a build that lists it, for a company Agentcard turned
|
|
584
|
+
* ProcessOut on for.
|
|
585
|
+
*
|
|
586
|
+
* `monei_card_token`: the card request MONEI's card frame sends from MONEI's payment page
|
|
587
|
+
* (secure.monei.com/payments/<id>) to api.monei.com/v1/tokens, with the payment's id and the card. This
|
|
588
|
+
* build pauses only the frame's own body for a payment at that exact URL (payment-core
|
|
589
|
+
* processors/monei.js); MONEI's account flow, Click to Pay and a wallet on the same URL fail in the
|
|
590
|
+
* browser before anything is created. The request names neither the merchant nor the amount, so the API
|
|
591
|
+
* reads MONEI's own record of the payment and holds the agent's pair, above zero
|
|
592
|
+
* (agent-amount-processors.json), to MONEI's amount exactly. The cardholder's device sends the card to
|
|
593
|
+
* MONEI itself and the frame gets back MONEI's payment token alone, rebuilt by payment-core's judge.
|
|
594
|
+
* Served on the same terms: only to a build that lists it, for a company Agentcard turned MONEI on for.
|
|
595
|
+
*
|
|
596
|
+
* `frisbii_card_token`: the card request Frisbii Checkout's hosted payment page (checkout.reepay.com or
|
|
597
|
+
* checkout.frisbii.com, as an overlay, an embedded frame or a full window) sends to
|
|
598
|
+
* card.reepay.com or card.frisbii.com /v1/token/?session=<id>, with the merchant's public key and the
|
|
599
|
+
* card. This build pauses only the page's own body at that exact URL (payment-core
|
|
600
|
+
* processors/frisbii.js); any other body on it, one that keeps the card on file included, fails in the
|
|
601
|
+
* browser before anything is created. The page's two other card paths, a stored card's token
|
|
602
|
+
* (/v1/token/cof/) and Click to Pay (/v1/token/create_click_to_pay), are held and refused whatever
|
|
603
|
+
* their body, so neither leaves the browser either. The request names the amount only when
|
|
604
|
+
* the session carries 3-D Secure data, so the agent's pair is required, above zero
|
|
605
|
+
* (agent-amount-processors.json), and the API refuses it when it differs from the page's own. The
|
|
606
|
+
* cardholder's device sends the card to Frisbii
|
|
607
|
+
* itself and the page gets back Frisbii's card token or 3-D Secure step alone, rebuilt by payment-core's
|
|
608
|
+
* judge. Served on the same terms: only to a build that lists it, for a company Agentcard turned Frisbii
|
|
609
|
+
* on for.
|
|
610
|
+
*
|
|
505
611
|
* `aps_custom_merchant_page`: Amazon Payment Services' custom merchant page, whose own card form
|
|
506
612
|
* posts top-level to /FortAPI/paymentPage on checkout.payfort.com (sbcheckout.payfort.com on APS's
|
|
507
613
|
* sandbox) with service_command=TOKENIZATION. This build pauses that navigation; the cardholder's
|
|
@@ -522,6 +628,14 @@ export declare const SUPPORTED_REGISTRY_FEATURES: readonly string[];
|
|
|
522
628
|
* the cardholder approves, and the API holds its amount to the body's. Served on the same terms: only to a build
|
|
523
629
|
* that lists it, for a company Agentcard turned Nexi Checkout on for.
|
|
524
630
|
*
|
|
631
|
+
* `oceanpayment_hosted_payment_page`: the card post of Oceanpayment's hosted payment page (secure.oceanpayment.com, where
|
|
632
|
+
* Oceanpayment's Shopify redirect app sends the buyer), a native form post to /gateway/sendPay;jsessionid=<session> with
|
|
633
|
+
* the card in clear (test-secure.oceanpayment.com for a test row). This build pauses only that post, exactly as the page's
|
|
634
|
+
* form action writes it, and aborts every other post to Oceanpayment's two hosts (oceanpayment.ts), so the agent's
|
|
635
|
+
* placeholder never reaches Oceanpayment; the cardholder's device writes the real card into the paused post and sends it
|
|
636
|
+
* through the checkout relay. The post names no amount, so the agent's pair, above zero, is the one the cardholder
|
|
637
|
+
* approves. Served on the same terms: only to a build that lists it, for a company Agentcard turned Oceanpayment on for.
|
|
638
|
+
*
|
|
525
639
|
* `barion_hosted_payment_page`: Barion's Smart Gateway, whose card-free link
|
|
526
640
|
* (secure.barion.com/Pay?Id=<payment id>, a plain GET the merchant's redirect or script sends
|
|
527
641
|
* the buyer to) this build pauses for the cardholder's device by its exact link (hosted-entry.ts),
|
|
@@ -529,6 +643,27 @@ export declare const SUPPORTED_REGISTRY_FEATURES: readonly string[];
|
|
|
529
643
|
* send (pre-claim.ts, barion.ts). Served on the same terms as Przelewy24's: only to a build that
|
|
530
644
|
* lists it, for a company Agentcard turned Barion on for.
|
|
531
645
|
*
|
|
646
|
+
* `payplug_hosted_payment_page`: PayPlug's payment page, whose card-free link
|
|
647
|
+
* (secure.payplug.com/pay/<payment id>, or /pay/test/<payment id>, a plain GET the merchant's
|
|
648
|
+
* redirect or script sends the buyer to) this build pauses for the cardholder's device by its exact
|
|
649
|
+
* link (hosted-entry.ts), and whose card post this build never lets the agent's browser send
|
|
650
|
+
* (pre-claim.ts, payplug.ts). The link names no amount, so authorize() asks for the agent's, above
|
|
651
|
+
* zero. Served only to a build that lists it, and the API turns PayPlug on for Agentcard's own
|
|
652
|
+
* company alone.
|
|
653
|
+
*
|
|
654
|
+
* `cardlink_vpos_hosted_payment_page`: Cardlink's VPOS, the payment page of Eurobank, Cardlink and Nexi
|
|
655
|
+
* Greece, whose card-free signed entry (a form post to /vpos/shophandlermpi on one of the three hosts) this build
|
|
656
|
+
* pauses for the cardholder's device, and whose card page's post and card check on the same URL this build never
|
|
657
|
+
* lets the agent's browser send (pre-claim.ts, cardlink-vpos.ts). Served only to a build that lists it, and the API
|
|
658
|
+
* turns the lane on for Agentcard's own company alone.
|
|
659
|
+
*
|
|
660
|
+
* `eghl_hosted_payment_page`: eGHL's payment page (ADAPTIS, formerly eGHL, on securepay.e-ghl.com), whose card-free
|
|
661
|
+
* entry (a GET of /IPG/payment.aspx with the payment in its query, which the merchant's checkout or eGHL's Shopify app
|
|
662
|
+
* sends the buyer to) this build pauses for the cardholder's device by its exact URL (hosted-entry.ts), and whose card
|
|
663
|
+
* page's post to the same address this build never lets the agent's browser send (pre-claim.ts, eghl.ts). The entry
|
|
664
|
+
* names its amount, and the API holds the agent's pair to it exactly. Served only to a build that lists it, and the API
|
|
665
|
+
* turns the lane on for Agentcard's own company alone.
|
|
666
|
+
*
|
|
532
667
|
* `paymob_checkout_pay`: the card payment Paymob's own checkout sends, from Unified Checkout
|
|
533
668
|
* (<country>.checkout.paymob.com) or from the Pixel card frame a merchant's page embeds, as JSON to
|
|
534
669
|
* https://<accept|uae|ksa|oman>.paymob.com/api/acceptance/payments/pay. This build pauses only the
|
|
@@ -789,6 +924,14 @@ export interface CardEndpointReplay extends ExecutionMetadata {
|
|
|
789
924
|
body: string;
|
|
790
925
|
withheld: 'card_in_response' | 'unreadable_in_response' | 'refused_step_in_response' | null;
|
|
791
926
|
amountAuthority?: AmountAuthority;
|
|
927
|
+
/**
|
|
928
|
+
* The amount the cardholder approved, an integer in the currency's smallest unit with its code, as the API's read
|
|
929
|
+
* names it; absent when it names none. Nike's order after its card is held to it (nike-order.ts).
|
|
930
|
+
*/
|
|
931
|
+
approved?: {
|
|
932
|
+
amount: number;
|
|
933
|
+
currency: string;
|
|
934
|
+
};
|
|
792
935
|
}
|
|
793
936
|
/**
|
|
794
937
|
* The device_encrypt flow (Payrails): the cardholder's device encrypted the
|
|
@@ -1019,6 +1162,12 @@ export interface AuthorizeInput extends ExecutionMetadata {
|
|
|
1019
1162
|
};
|
|
1020
1163
|
/** Milliseconds from the caller's pay click until the SDK caught the card request, measured on one clock. */
|
|
1021
1164
|
payToInterceptMs?: number;
|
|
1165
|
+
/**
|
|
1166
|
+
* When the card request paused, in epoch milliseconds on this machine's clock; the adapters fill it. A VTEX Payments
|
|
1167
|
+
* card post, whose checkout gives the post 12 seconds, sends how long ago that was (`paused_ms`), and the API counts
|
|
1168
|
+
* the row's send-by from it.
|
|
1169
|
+
*/
|
|
1170
|
+
pausedAt?: number;
|
|
1022
1171
|
/**
|
|
1023
1172
|
* WHICH stored card should pay — a vault card id from
|
|
1024
1173
|
* GET /api/v2/vault_cards. The approval page preselects it (the human can
|
|
@@ -1562,13 +1711,6 @@ export interface VaultClientOptions {
|
|
|
1562
1711
|
* the error is thrown. Default [500, 1500]; [] disables retries.
|
|
1563
1712
|
*/
|
|
1564
1713
|
unverifiableRetryDelaysMs?: number[];
|
|
1565
|
-
/**
|
|
1566
|
-
* The voice module: how this product approves purchases by voice, named
|
|
1567
|
-
* once per business, with the Vault return link and the verifier address
|
|
1568
|
-
* beside it. Leave it out and the client approves on Agentcard's page
|
|
1569
|
-
* (`approval: 'sheet'`). See `VoiceOptions`.
|
|
1570
|
-
*/
|
|
1571
|
-
voice?: VoiceOptions;
|
|
1572
1714
|
/**
|
|
1573
1715
|
* Test mode only: run a merchant-hosted checkout against your own Adyen TEST
|
|
1574
1716
|
* account. Each entry arms your own endpoint as taking the card request of a
|
|
@@ -1626,22 +1768,22 @@ export declare class VaultClient {
|
|
|
1626
1768
|
* false: a live client.
|
|
1627
1769
|
*/
|
|
1628
1770
|
get sandbox(): boolean;
|
|
1629
|
-
/** What every module shares: the token, the HTTP path
|
|
1771
|
+
/** What every module shares: the token, the HTTP path and the poll settings. */
|
|
1630
1772
|
protected readonly transport: ApiTransport;
|
|
1631
|
-
/**
|
|
1632
|
-
* Approve purchases by voice inside your own product: connect a person once,
|
|
1633
|
-
* create the purchase, ask for the key word, read the result. Same
|
|
1634
|
-
* credentials, same token as the checkout calls. Approves on Agentcard's
|
|
1635
|
-
* page unless `voice: { approval: 'in_app' }` was named at construction.
|
|
1636
|
-
*/
|
|
1637
|
-
readonly voice: VoiceModule;
|
|
1638
1773
|
/**
|
|
1639
1774
|
* The Purchase API from the same client: ask for a cart on behalf of a
|
|
1640
1775
|
* person you connected, confirm it by its hash, and name an approval the
|
|
1641
|
-
* person already gave
|
|
1642
|
-
* nothing a second time. Same credentials, same token as the
|
|
1776
|
+
* person already gave so the API places against it and asks for
|
|
1777
|
+
* nothing a second time. Same credentials, same token as the checkout calls.
|
|
1643
1778
|
*/
|
|
1644
1779
|
readonly buy: BuyModule;
|
|
1780
|
+
/**
|
|
1781
|
+
* Purchases your server creates for a person, approved on Agentcard's page:
|
|
1782
|
+
* create one (`request: 'sandbox'` under a sandbox client), send the person
|
|
1783
|
+
* its `approval_url`, then read the decision or wait for it. Same
|
|
1784
|
+
* credentials, same token as the checkout calls.
|
|
1785
|
+
*/
|
|
1786
|
+
readonly approvals: ApprovalsModule;
|
|
1645
1787
|
/**
|
|
1646
1788
|
* The request builders: the processor requests a purchase pauses on, the
|
|
1647
1789
|
* shipped ones and yours (`requests.register`, `requests.build`).
|
|
@@ -1865,9 +2007,9 @@ export declare class VaultClient {
|
|
|
1865
2007
|
* exactly the approved payment method (the page's own, or written by the
|
|
1866
2008
|
* adapters in place of a card the confirm carries again).
|
|
1867
2009
|
* The API allows a card save for any company, for an approval given on the
|
|
1868
|
-
* Vault page,
|
|
1869
|
-
*
|
|
1870
|
-
*
|
|
2010
|
+
* Vault page, with no amount, and a SetupIntent Stripe reports still
|
|
2011
|
+
* confirmable on the same Stripe account; any other answer rejects with a
|
|
2012
|
+
* CheckoutApiError whose code says why (for example `amount_mismatch`, or
|
|
1871
2013
|
* `continuation_invalid` for a confirm that is not a card-free SetupIntent
|
|
1872
2014
|
* confirm). Nothing
|
|
1873
2015
|
* is charged: the adapters continue the page's request once this resolves.
|
|
@@ -1983,7 +2125,9 @@ export declare class VaultClient {
|
|
|
1983
2125
|
* (Stripe did not answer the read-back) is retried on a short backoff
|
|
1984
2126
|
* instead of being left to the page's own retry loop, and a 409
|
|
1985
2127
|
* `amount_mismatch` becomes an AmountMismatchError at stage 'create' so the
|
|
1986
|
-
* adapters treat it as an answered request, not a dead page.
|
|
2128
|
+
* adapters treat it as an answered request, not a dead page. `atSend` adds
|
|
2129
|
+
* fields counted as each request leaves, after any token wait, 401 refresh or
|
|
2130
|
+
* backoff, so a field that measures time (VTEX's paused_ms) measures it then.
|
|
1987
2131
|
*/
|
|
1988
2132
|
private createAuthorization;
|
|
1989
2133
|
private token;
|
|
@@ -2000,9 +2144,13 @@ export declare class VaultClient {
|
|
|
2000
2144
|
* Only fetch and a successful response's body read belong to that retry:
|
|
2001
2145
|
* OAuth, HTTP errors, invalid JSON and every mutation remain outside it.
|
|
2002
2146
|
* The existing one-time 401 refresh carries the remaining read budget.
|
|
2147
|
+
* `bodyAt`, when given, builds the body as each request leaves, after the
|
|
2148
|
+
* token and on the 401 refresh's resend, in place of `init.body`.
|
|
2003
2149
|
*/
|
|
2004
2150
|
private call;
|
|
2005
2151
|
private post;
|
|
2152
|
+
/** A POST whose body is built as each request leaves (call's `bodyAt`), for a body that counts time. */
|
|
2153
|
+
private postAtSend;
|
|
2006
2154
|
private get;
|
|
2007
2155
|
private readPreparation;
|
|
2008
2156
|
}
|