@agent-cards/sdk 0.23.12 → 0.23.14
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 +38 -1
- package/LICENSE +38 -0
- package/PREFLIGHT.md +1 -1
- package/README.md +53 -14
- package/dist/adyen-merchant-hosted.generated.js +2 -2
- package/dist/builtin-registry.generated.js +1 -1
- package/dist/card-fields.generated.js +843 -3
- package/dist/cdp.js +101 -13
- package/dist/client.d.ts +91 -2
- package/dist/client.js +205 -13
- package/dist/creditguard.generated.d.ts +100 -2
- package/dist/creditguard.generated.js +333 -3
- package/dist/datatrans.generated.d.ts +19 -4
- package/dist/datatrans.generated.js +15 -3
- package/dist/ebanx.d.ts +107 -0
- package/dist/ebanx.generated.d.ts +78 -0
- package/dist/ebanx.generated.js +577 -0
- package/dist/ebanx.js +159 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +2 -0
- package/dist/lifecycle.d.ts +35 -3
- package/dist/lifecycle.js +38 -3
- package/dist/paddle-tokenex.d.ts +56 -0
- package/dist/paddle-tokenex.generated.d.ts +67 -0
- package/dist/paddle-tokenex.generated.js +951 -0
- package/dist/paddle-tokenex.js +95 -0
- package/dist/paddle-vgs-pay.d.ts +55 -0
- package/dist/paddle-vgs-pay.js +115 -0
- package/dist/paddle-vgs.generated.d.ts +29 -1
- package/dist/paddle-vgs.generated.js +124 -5
- package/dist/paysafe.generated.d.ts +5 -7
- package/dist/paysafe.generated.js +50 -18
- package/dist/pre-claim.d.ts +46 -1
- package/dist/pre-claim.js +338 -17
- package/dist/preparation.d.ts +13 -0
- package/dist/preparation.js +22 -0
- package/dist/prepared-processor.js +6 -2
- package/dist/primer.generated.js +878 -38
- package/dist/redsys.d.ts +42 -0
- package/dist/redsys.js +68 -0
- package/dist/stripe-checkout.generated.js +479 -11
- package/package.json +9 -6
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// @ts-nocheck
|
|
2
2
|
// Generated from @agent-cards/payment-core. Do not edit.
|
|
3
|
-
// artifact-sha256:
|
|
3
|
+
// artifact-sha256: eaa31e10104ec55a9914d5b874f25cb17e713de912b48ef41d7f987786e65785
|
|
4
4
|
// src/deep-freeze.js
|
|
5
5
|
function deepFreeze(value) {
|
|
6
6
|
if (value && typeof value === "object" && !Object.isFrozen(value)) {
|
|
@@ -298,6 +298,102 @@ var PROCESSOR_DEFINITIONS = deepFreeze([
|
|
|
298
298
|
callbackUrls: ["ekashu_success_url", "ekashu_failure_url", "ekashu_return_url"]
|
|
299
299
|
}
|
|
300
300
|
},
|
|
301
|
+
{
|
|
302
|
+
psp: "redsys",
|
|
303
|
+
// Redsys's hosted payment page, the TPV Virtual redirect most Spanish banks give their merchants. The
|
|
304
|
+
// merchant's page posts a signed ENTRY form top-level to sis.redsys.es/sis/realizarPago (or its
|
|
305
|
+
// /utf-8 twin): the amount, the merchant's FUC and terminal, its result URLs and an HMAC-SHA256 over
|
|
306
|
+
// them, and no card. Redsys answers with its own card page under a session of its own (a jsessionid
|
|
307
|
+
// in the page's form action), so a card form rebuilt away from that session has no order to pay
|
|
308
|
+
// (processors/redsys.js). The paused request is therefore the entry, a Document navigation that
|
|
309
|
+
// carries no card: the cardholder's device repeats it over the end-to-end TLS relay, fills the card
|
|
310
|
+
// into the page Redsys returns to it and posts it back in that same session, and the runtime resolves
|
|
311
|
+
// the paused navigation with the hosted_form notice. Only the two entry paths are matched, exactly
|
|
312
|
+
// (processors/redsys.js isRedsysEntryUrl: a query would reach Redsys's servlets as fields): the card
|
|
313
|
+
// post (/sis/pagoTarjeta), the older page's 3-D Secure card lookup and InSite's card post carry a
|
|
314
|
+
// card, and the SDK refuses them in the agent's browser, so no dummy card ever reaches Redsys.
|
|
315
|
+
// Redsys's test platform (sis-t.redsys.es) answers on port 25443 alone, which no recognizer takes,
|
|
316
|
+
// and isRedsysEntryUrl takes only the live host: it is listed so the live host classifies as live and
|
|
317
|
+
// the create refuses a test row there (live_host_on_sandbox_row), since no test row can reach a
|
|
318
|
+
// Redsys test host. Dark: served only to a client that declares the capability, and gated off for
|
|
319
|
+
// every org the operator has not allowlisted.
|
|
320
|
+
capability: "redsys_hosted_payment_page",
|
|
321
|
+
match: "sis\\.redsys\\.es/sis/realizarPago(?:/utf-8)?",
|
|
322
|
+
hosts: ["^sis\\.redsys\\.es$", "^sis-t\\.redsys\\.es$"],
|
|
323
|
+
sandboxHosts: ["^sis-t\\.redsys\\.es$"],
|
|
324
|
+
hostEnvironmentPinned: true,
|
|
325
|
+
encoding: "form",
|
|
326
|
+
passthroughHeaders: [],
|
|
327
|
+
mode: "hosted_form",
|
|
328
|
+
hostedForm: {
|
|
329
|
+
// The card goes into the page Redsys returns to the device, not into the paused entry, which must
|
|
330
|
+
// carry none (processors/redsys.js checkRedsysEntry). The device never posts a form of its own:
|
|
331
|
+
// the Vault's form-action policy leaves this host out.
|
|
332
|
+
cardIn: "processor_page",
|
|
333
|
+
// The entry's own rules (processors/redsys.js checkRedsysEntry), the reviewed merchants among them:
|
|
334
|
+
// the create runs them, and naming them here makes the cardholder's device run them again on the
|
|
335
|
+
// entry it is about to repeat (forms.js hostedFormTemplateRefusal).
|
|
336
|
+
policy: "redsys",
|
|
337
|
+
required: ["Ds_SignatureVersion", "Ds_MerchantParameters", "Ds_Signature"],
|
|
338
|
+
// Redsys's card page's own fields, which the device fills on that page (never in the entry).
|
|
339
|
+
card: { number: "Sis_Numero_Tarjeta", month: "Sis_Caducidad_Tarjeta_Mes", year: "Sis_Caducidad_Tarjeta_Anno", cvc: "Sis_Tarjeta_CVV2" },
|
|
340
|
+
// The FUC, terminal, order, amount and currency inside the signed Ds_MerchantParameters name one
|
|
341
|
+
// payment; the policy reads them there (checkRedsysEntry's dedupe), since no form field holds them.
|
|
342
|
+
dedupe: ["Ds_MerchantParameters"]
|
|
343
|
+
}
|
|
344
|
+
},
|
|
345
|
+
{
|
|
346
|
+
psp: "quickpay",
|
|
347
|
+
// QuickPay's hosted payment window, where most Danish and Nordic webshops send the buyer (DanDomain,
|
|
348
|
+
// SmartWeb, Shoporama and the WooCommerce, Magento and PrestaShop modules). The merchant's page posts a
|
|
349
|
+
// signed ENTRY form top-level to https://payment.quickpay.net/ (QuickPay's Form API v10): the amount, the
|
|
350
|
+
// merchant and agreement ids, its order id, its continue, cancel and callback URLs and an HMAC-SHA256
|
|
351
|
+
// checksum over them, and no card. QuickPay answers with its window under a session of its own (the
|
|
352
|
+
// window's path, /<32 hex>, and a hidden field of its card form), so a card form rebuilt away from that
|
|
353
|
+
// session has no payment to pay (processors/quickpay.js). The paused request is therefore the entry, a
|
|
354
|
+
// Document navigation that carries no card: the cardholder's device repeats it over the end-to-end TLS
|
|
355
|
+
// relay, fills the card into the window QuickPay returns to it and posts it back in that same session, and
|
|
356
|
+
// the runtime resolves the paused navigation with the hosted_form notice. Only the entry path is matched,
|
|
357
|
+
// exactly (processors/quickpay.js isQuickpayEntryUrl: a query would reach QuickPay's server as fields
|
|
358
|
+
// beside the signed body): the window's card post (/process_card), its fee lookup (/calculate_fee, which
|
|
359
|
+
// carries the card number) and its wallet token post carry a card, and the SDK refuses them in the agent's
|
|
360
|
+
// browser, so no dummy card ever reaches QuickPay. QuickPay has no test host: a test payment runs on this
|
|
361
|
+
// host with QuickPay's own test card numbers, so the host marks no environment. Dark: served only to a
|
|
362
|
+
// client that declares the capability, and gated off for every org the operator has not allowlisted.
|
|
363
|
+
capability: "quickpay_hosted_payment_page",
|
|
364
|
+
match: "payment\\.quickpay\\.net/",
|
|
365
|
+
hosts: ["^payment\\.quickpay\\.net$"],
|
|
366
|
+
encoding: "form",
|
|
367
|
+
passthroughHeaders: [],
|
|
368
|
+
mode: "hosted_form",
|
|
369
|
+
hostedForm: {
|
|
370
|
+
// The card goes into the window QuickPay returns to the device, not into the paused entry, which must
|
|
371
|
+
// carry none (processors/quickpay.js checkQuickpayEntry). The device never posts a form of its own: the
|
|
372
|
+
// Vault's form-action policy leaves this host out.
|
|
373
|
+
cardIn: "processor_page",
|
|
374
|
+
// The entry's own rules (processors/quickpay.js checkQuickpayEntry), the reviewed merchants among them:
|
|
375
|
+
// the create runs them, and naming them here makes the cardholder's device run them again on the entry
|
|
376
|
+
// it is about to repeat (forms.js hostedFormTemplateRefusal).
|
|
377
|
+
policy: "quickpay",
|
|
378
|
+
required: [
|
|
379
|
+
"version",
|
|
380
|
+
"merchant_id",
|
|
381
|
+
"agreement_id",
|
|
382
|
+
"order_id",
|
|
383
|
+
"amount",
|
|
384
|
+
"currency",
|
|
385
|
+
"continueurl",
|
|
386
|
+
"cancelurl",
|
|
387
|
+
"callbackurl",
|
|
388
|
+
"checksum"
|
|
389
|
+
],
|
|
390
|
+
// The window's own card fields, which the device fills in the window (never in the entry).
|
|
391
|
+
card: { number: "cardnumber", month: "expiration[month]", year: "expiration[year]", cvc: "cvd" },
|
|
392
|
+
// The merchant, its agreement, its order and the amount name one payment, as QuickPay keys one payment
|
|
393
|
+
// per merchant on its order id.
|
|
394
|
+
dedupe: ["merchant_id", "agreement_id", "order_id", "amount", "currency"]
|
|
395
|
+
}
|
|
396
|
+
},
|
|
301
397
|
// ── Verified tokenizers (plaintext PAN in the body) ───────────────────────
|
|
302
398
|
// Each entry below was checked against the PSP's own shipped browser SDK or a
|
|
303
399
|
// live probe, then run through resolveRecognizerForUrl with positive, sibling
|
|
@@ -583,13 +679,26 @@ var PROCESSOR_DEFINITIONS = deepFreeze([
|
|
|
583
679
|
// Verified from https://hosted.test.paysafe.com/checkout/1.8.0/main.bundle.js
|
|
584
680
|
// and its byte-identical production sibling (SHA-256 e9e111ff03073cc936a47674e8e7c5db4a6d1050e1b65bf5e20723116fd5080c).
|
|
585
681
|
// Its native LIVE/TEST environment map selects exactly hosted[.test].paysafe.com.
|
|
682
|
+
// Checkout v1 latest (loader version 1.16.1; checkout/v1/latest/main.js SHA-256
|
|
683
|
+
// 328c6443da930f3648826248afa3c342cdd07d04e49a78b0878dda187772bf80) posts the same body to
|
|
684
|
+
// checkout/api/v1/tokenize on api[.test].paysafe.com, the hosts its vendor.js maps LIVE/TEST to.
|
|
685
|
+
// It and Paysafe.js latest set X-Internal-Correlation-Id, X-App-Version and X-TransactionSource
|
|
686
|
+
// on every card request, and Paysafe's CORS answer on all three API card paths allows them for
|
|
687
|
+
// any origin (2026-10-15), so a replay keeps them as the native request sends them.
|
|
586
688
|
// Keep host/path pairs separate: details/log are not card requests;
|
|
587
689
|
// card/tokenize uses a saved paymentToken, and 3DS-specific paths are unverified.
|
|
588
|
-
match: "(?:api(\\.test)?\\.paysafe\\.com/(?:paymenthub/v1/singleusepaymenthandles|js/api/v1/tokenize)|hosted(\\.test)?\\.paysafe\\.com/checkout/api/v1/tokenize)(?![\\w/-])",
|
|
690
|
+
match: "(?:api(\\.test)?\\.paysafe\\.com/(?:paymenthub/v1/singleusepaymenthandles|js/api/v1/tokenize|checkout/api/v1/tokenize)|hosted(\\.test)?\\.paysafe\\.com/checkout/api/v1/tokenize)(?![\\w/-])",
|
|
589
691
|
hosts: ["^api\\.paysafe\\.com$", "^api\\.test\\.paysafe\\.com$", "^hosted\\.paysafe\\.com$", "^hosted\\.test\\.paysafe\\.com$"],
|
|
590
692
|
sandboxHosts: ["^api\\.test\\.paysafe\\.com$", "^hosted\\.test\\.paysafe\\.com$"],
|
|
591
693
|
encoding: "json",
|
|
592
|
-
passthroughHeaders: [
|
|
694
|
+
passthroughHeaders: [
|
|
695
|
+
"^authorization$",
|
|
696
|
+
"^x-paysafe-credentials$",
|
|
697
|
+
"^correlationid$",
|
|
698
|
+
"^x-internal-correlation-id$",
|
|
699
|
+
"^x-app-version$",
|
|
700
|
+
"^x-transactionsource$"
|
|
701
|
+
]
|
|
593
702
|
},
|
|
594
703
|
{
|
|
595
704
|
psp: "recurly",
|
|
@@ -1131,7 +1240,8 @@ var PROCESSOR_DEFINITIONS = deepFreeze([
|
|
|
1131
1240
|
// decides, and neither the request nor the page names it), so the S7 host rule has no test-only
|
|
1132
1241
|
// host to pin, and the device's test-card rule cannot tell a test payment from a live one here.
|
|
1133
1242
|
// A live row can therefore send a real card to a payment page created on a public test terminal,
|
|
1134
|
-
// whose transactions anyone holding Pelecard's published demo credentials can read back.
|
|
1243
|
+
// whose transactions anyone holding Pelecard's published demo credentials can read back. Agentcard
|
|
1244
|
+
// accepted that on 2026-10-11 (pelecard.js header); a test row sends only a documented test card.
|
|
1135
1245
|
// Ships dark: served only to a client that declares `pelecard_transaction`, gated off for every org
|
|
1136
1246
|
// until an operator allowlists one, and never replayed by autopilot (EXCLUDED_OPERATIONS).
|
|
1137
1247
|
capability: "pelecard_transaction",
|
|
@@ -1192,14 +1302,20 @@ var PROCESSOR_DEFINITIONS = deepFreeze([
|
|
|
1192
1302
|
// (SeboCalm). Its Angular transaction service posts the card to /services/v1/txn/<txId>/process as
|
|
1193
1303
|
// same-origin JSON, no auth header, no cookie: the txId is the only credential and the submit is the
|
|
1194
1304
|
// sale itself. PAN@ root `cardNumber` (expMonth MM, expYear YY, cvv, personalId) in plaintext, or one
|
|
1195
|
-
// js-jose JWE in root `jwePayload` when the transaction carries a jwePublicKey (creditguard.js
|
|
1196
|
-
// that variant
|
|
1197
|
-
// 2026-09-25. /card/details, /card/details/dcc, /cc/ddc/init, /cg3ds/*, /otp/request
|
|
1198
|
-
// /applepay|paybox|pcp/process share the prefix, carry the agent's placeholder or no card, and
|
|
1199
|
-
// out at the exact path; (?![\w/-]) is the right edge for the SDK's unanchored test. pps2 is a
|
|
1305
|
+
// js-jose JWE in root `jwePayload` when the transaction carries a jwePublicKey (creditguard.js admits
|
|
1306
|
+
// that variant only where a caller passes its flag). Sources: templates/cgt-basic/main.js on pps and
|
|
1307
|
+
// ppsuat, reviewed 2026-09-25. /card/details, /card/details/dcc, /cc/ddc/init, /cg3ds/*, /otp/request
|
|
1308
|
+
// and /applepay|paybox|pcp/process share the prefix, carry the agent's placeholder or no card, and
|
|
1309
|
+
// fall out at the exact path; (?![\w/-]) is the right edge for the SDK's unanchored test. pps2 is a
|
|
1200
1310
|
// production host (cg-safecharge-3ds envConfig: pps, pps2, cgmpi = prod). The legacy MPI page
|
|
1201
1311
|
// (cgmpi.creditguard.co.il), pps-dev, ppsqa, pps-qa1 and cguat2 are deliberately absent.
|
|
1202
1312
|
// creditguard.js judges the whole request before a card is written and fills only the card fields.
|
|
1313
|
+
// - deviceSteps: on a 3-D Secure transaction through Cardinal, the three calls the cardholder's
|
|
1314
|
+
// device sends with the real card before the submit, on the paused submit's own host and
|
|
1315
|
+
// transaction (creditguard.js creditguardDeviceStepUrl, which the transport checks with
|
|
1316
|
+
// request-policy.js assertAllowedDeviceStep). The SDK answers the page's own copies of them
|
|
1317
|
+
// with the placeholder, so those never leave the agent's browser. Definitions-only: the served
|
|
1318
|
+
// row does not carry them.
|
|
1203
1319
|
// Ships dark: served only to a client that declares `creditguard_pps_process`, gated off for every
|
|
1204
1320
|
// org until an operator allowlists one, never replayed by autopilot (EXCLUDED_OPERATIONS).
|
|
1205
1321
|
capability: "creditguard_pps_process",
|
|
@@ -1217,7 +1333,12 @@ var PROCESSOR_DEFINITIONS = deepFreeze([
|
|
|
1217
1333
|
passthroughHeaders: [],
|
|
1218
1334
|
// A /process body without either (Google Pay, a saved cardId, a js-jose object fallback) is not a
|
|
1219
1335
|
// new card, and with no passWithoutCard it is refused instead of paused.
|
|
1220
|
-
jsonCardFields: [["cardNumber"], ["jwePayload"]]
|
|
1336
|
+
jsonCardFields: [["cardNumber"], ["jwePayload"]],
|
|
1337
|
+
deviceSteps: {
|
|
1338
|
+
ddc_init: "(?:pps|pps2|ppsuat)\\.creditguard\\.co\\.il/services/v1/txn/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/cc/ddc/init",
|
|
1339
|
+
threeds_init: "(?:pps|pps2|ppsuat)\\.creditguard\\.co\\.il/services/v1/txn/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/cg3ds/process/init",
|
|
1340
|
+
threeds_outcome: "(?:pps|pps2|ppsuat)\\.creditguard\\.co\\.il/services/v1/txn/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/cg3ds/process/outcome"
|
|
1341
|
+
}
|
|
1221
1342
|
},
|
|
1222
1343
|
{
|
|
1223
1344
|
psp: "payrails",
|
|
@@ -1445,6 +1566,100 @@ var PROCESSOR_DEFINITIONS = deepFreeze([
|
|
|
1445
1566
|
preparationRequired: true,
|
|
1446
1567
|
encoding: "json",
|
|
1447
1568
|
passthroughHeaders: ["^authorization$"]
|
|
1569
|
+
},
|
|
1570
|
+
{
|
|
1571
|
+
psp: "payfast",
|
|
1572
|
+
// Payfast by Network's hosted payment page (South Africa), which every Payfast Pay Now button,
|
|
1573
|
+
// payment link, plugin redirect and Onsite modal opens at payment.payfast.io/eng/process/payment/<uuid>
|
|
1574
|
+
// (www.payfast.co.za serves the same uuid and routes). The card tab posts the card with one jQuery
|
|
1575
|
+
// XHR to /eng/method/CreditCard/<uuid>/pay on the page's own host, form encoded, no encryption:
|
|
1576
|
+
// card_number, cvv, expiry_month and expiry_year beside the name, the consent box and the
|
|
1577
|
+
// page's reCAPTCHA fields. The request names no amount: the merchant's entry bound it to the uuid,
|
|
1578
|
+
// so the agent's amount is the price the cardholder approves. payfast.js holds the rule the pause
|
|
1579
|
+
// decision reads: the exact URL, and the card tab's body byte for byte, with a saved card (cc_key)
|
|
1580
|
+
// and a pay that stores the card (consent_check 1) refused. The route answers no browser origin,
|
|
1581
|
+
// so the card leaves only through the checkout relay. 3-D Secure, the currency switch and the
|
|
1582
|
+
// other methods carry no card and use other paths, which `match` leaves out.
|
|
1583
|
+
// Ships dark: served only to a client that declares `payfast_card_pay`, gated off for every org
|
|
1584
|
+
// until an operator lists one (`payfast:<org>`), and autopilot never sends this request
|
|
1585
|
+
// (autopilot.js DEVICE_REPLAY_REFUSED_OPERATIONS). The environment is pinned (S7):
|
|
1586
|
+
// sandbox.payfast.co.za only on test rows and only with documented test cards.
|
|
1587
|
+
capability: "payfast_card_pay",
|
|
1588
|
+
match: "(?:payment\\.payfast\\.io|www\\.payfast\\.co\\.za|sandbox\\.payfast\\.co\\.za)/eng/method/CreditCard/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/pay",
|
|
1589
|
+
hosts: ["^payment\\.payfast\\.io$", "^www\\.payfast\\.co\\.za$", "^sandbox\\.payfast\\.co\\.za$"],
|
|
1590
|
+
sandboxHosts: ["^sandbox\\.payfast\\.co\\.za$"],
|
|
1591
|
+
hostEnvironmentPinned: true,
|
|
1592
|
+
encoding: "form",
|
|
1593
|
+
// jQuery's same-origin marker and its JSON Accept: with them Payfast answers its JSON, a refusal
|
|
1594
|
+
// included. The CSRF header, Origin, Referer and cookies never ride.
|
|
1595
|
+
passthroughHeaders: ["^x-requested-with$", "^accept$"],
|
|
1596
|
+
cardFields: ["card_number"]
|
|
1597
|
+
},
|
|
1598
|
+
{
|
|
1599
|
+
psp: "paddle_tokenex",
|
|
1600
|
+
// Paddle's checkout frame (buy.paddle.com) on a checkout whose card method names TokenEx as its
|
|
1601
|
+
// tokenizer: the frame RSA-encrypts the number and the CVV itself (JSEncrypt, RSAES-PKCS1-v1_5,
|
|
1602
|
+
// base64) under the account-level TokenEx public key the checkout serves, and carries both inside
|
|
1603
|
+
// its own pay call, so /pay IS the card request. One JSON POST to /pay on checkout-service.paddle.com
|
|
1604
|
+
// (sandbox-checkout-service.paddle.com in test), Classic at /checkout/<id>/pay ("CARD") and Billing at
|
|
1605
|
+
// /transaction-checkout/<che_...>/pay ("card"). The card sits at
|
|
1606
|
+
// data.payment_method_data.card.tokenex_card.{encrypted_card_number, encrypted_cvv}, beside metadata
|
|
1607
|
+
// the frame read from the typed card. paddle-tokenex.js holds the request rule the pause decision, the
|
|
1608
|
+
// API's create, the device and the substitution read: the exact /pay URL, the frame's body shape, and
|
|
1609
|
+
// the two ciphertexts under the key pinned per environment (paddle-keys.js). cse mode, as GMO and
|
|
1610
|
+
// Shiji STS ship: the cardholder's device re-encrypts the real card under the pin and the runtime
|
|
1611
|
+
// swaps the two ciphertexts and the five metadata facts into the paused /pay (substitutePaddleTokenex),
|
|
1612
|
+
// and the agent's page continues the /pay (production checkout-service refuses a cross-origin /pay from
|
|
1613
|
+
// the Vault's own origin, so the device cannot send it). A /pay that names no tokenex_card (PayPal, a
|
|
1614
|
+
// wallet, a saved card, a VGS or Spreedly token pay) carries none of the cardholder's cards and
|
|
1615
|
+
// continues untouched (passWithoutCard, read by card-fields.js paddleTokenexBodyVerdict).
|
|
1616
|
+
// Ships dark: served only to a client that declares `paddle_tokenex_pay`, gated off for every org
|
|
1617
|
+
// until an operator lists one (`paddle_tokenex:<org>`), and autopilot never sends this request
|
|
1618
|
+
// (autopilot.js DEVICE_REPLAY_REFUSED_OPERATIONS). The environment is pinned (S7): sandbox-checkout-
|
|
1619
|
+
// service only on test rows and only with documented test cards, checkout-service only on live rows.
|
|
1620
|
+
capability: "paddle_tokenex_pay",
|
|
1621
|
+
match: "(?:sandbox-)?checkout-service\\.paddle\\.com/(?:checkout|transaction-checkout)/[A-Za-z0-9_-]{1,64}/pay(?![\\w/.-])",
|
|
1622
|
+
hosts: ["^checkout-service\\.paddle\\.com$", "^sandbox-checkout-service\\.paddle\\.com$"],
|
|
1623
|
+
sandboxHosts: ["^sandbox-checkout-service\\.paddle\\.com$"],
|
|
1624
|
+
hostEnvironmentPinned: true,
|
|
1625
|
+
encoding: "json",
|
|
1626
|
+
passthroughHeaders: [],
|
|
1627
|
+
// The card the device fills sits here; card-fields.js reads the whole /pay through paddleTokenexBodyVerdict
|
|
1628
|
+
// (a tokenex_card /pay is a card request, a /pay without it continues), and this path keeps the catalog's
|
|
1629
|
+
// "passWithoutCard beside a card field" invariant and tells a cardFields-aware client which member is the card.
|
|
1630
|
+
jsonCardFields: [["data", "payment_method_data", "card", "tokenex_card", "encrypted_card_number"]],
|
|
1631
|
+
passWithoutCard: "(?:sandbox-)?checkout-service\\.paddle\\.com/(?:checkout|transaction-checkout)/[A-Za-z0-9_-]{1,64}/pay",
|
|
1632
|
+
// The two ciphertexts, by role, so the client table carries the same encrypted-field set the approve
|
|
1633
|
+
// leg accepts (vault-allowlist-drift). The generic Adyen substitution refuses these, as it does Shiji's,
|
|
1634
|
+
// because they are RSA base64, not a JWE: only substitutePaddleTokenex writes this body, dispatched by psp.
|
|
1635
|
+
encryptedCardFields: { number: "encrypted_card_number", cvc: "encrypted_cvv" },
|
|
1636
|
+
clientSideEncrypted: true,
|
|
1637
|
+
mode: "cse",
|
|
1638
|
+
cse: { scheme: "rsa-pkcs1v15", at: "data.payment_method_data.card.tokenex_card", fields: ["encrypted_card_number", "encrypted_cvv"] }
|
|
1639
|
+
},
|
|
1640
|
+
{
|
|
1641
|
+
psp: "lyra",
|
|
1642
|
+
// Lyra's Krypton embedded form (PayZen, Systempay, Sogecommerce, Lyra Collect): the hidden checkout
|
|
1643
|
+
// frame on static.<brand> posts the card as JSON (Content-Type text/plain) to ProcessPayment/2 on the
|
|
1644
|
+
// brand's API host, with the form token's session id as a `;jsessionid=` path parameter. PAN@
|
|
1645
|
+
// paymentForm.pan, expiry MM @ .expiryMonth and YYYY @ .expiryYear, code @ .securityCode. lyra.js
|
|
1646
|
+
// holds the one body rule: the frame's card body under a form token that pays once is a card
|
|
1647
|
+
// request; the same URL's card-free 3-D Secure follow-up (instructionResult) continues untouched
|
|
1648
|
+
// (passWithoutCard); everything else is refused before any approval. TEST and PRODUCTION share these
|
|
1649
|
+
// hosts, so the key and the token name the environment, never the host (no sandbox marker). Lyra's API
|
|
1650
|
+
// refuses a POST that names none of its own static origins, so the card can leave the cardholder's
|
|
1651
|
+
// device only through the checkout relay. Ships dark: served only to a client that declares
|
|
1652
|
+
// `lyra_krypton_payment`, gated off for every org until an operator lists `lyra:<org>`, and autopilot
|
|
1653
|
+
// never sends it (autopilot.js DEVICE_REPLAY_REFUSED_OPERATIONS). `(?![\w/;.%-])` ends the path for a
|
|
1654
|
+
// consumer that tests `match` unanchored. Not here: Lyra's hosted payment page (vads-payment), and its
|
|
1655
|
+
// other brands' hosts (Scellius, Clic&Pay, Mi Cuenta Web and the rest of the bundle's table).
|
|
1656
|
+
capability: "lyra_krypton_payment",
|
|
1657
|
+
match: "api(?:\\.payzen\\.eu|\\.systempay\\.fr|-sogecommerce\\.societegenerale\\.eu|\\.lyra\\.com)/api-payment/V4/Charge/Public/ProcessPayment/2(?:;jsessionid=[A-Za-z0-9._-]{1,128})?(?![\\w/;.%-])",
|
|
1658
|
+
hosts: ["^api\\.payzen\\.eu$", "^api\\.systempay\\.fr$", "^api-sogecommerce\\.societegenerale\\.eu$", "^api\\.lyra\\.com$"],
|
|
1659
|
+
encoding: "json",
|
|
1660
|
+
passthroughHeaders: [],
|
|
1661
|
+
jsonCardFields: [["paymentForm", "pan"]],
|
|
1662
|
+
passWithoutCard: "api(?:\\.payzen\\.eu|\\.systempay\\.fr|-sogecommerce\\.societegenerale\\.eu|\\.lyra\\.com)/api-payment/V4/Charge/Public/ProcessPayment/2(?:;jsessionid=[A-Za-z0-9._-]{1,128})?"
|
|
1448
1663
|
}
|
|
1449
1664
|
]);
|
|
1450
1665
|
var PSP_RECOGNIZERS = deepFreeze(PROCESSOR_DEFINITIONS.map(({ compose, encryptedCardFields, deviceSteps, deviceEncrypt, ...definition }) => definition));
|
|
@@ -1498,9 +1713,13 @@ var DATATRANS_HOSTS = Object.freeze(["pay.datatrans.com", "pay.sandbox.datatrans
|
|
|
1498
1713
|
var DATATRANS_REFUSAL_REASONS = Object.freeze(["unsupported", "card_on_file", "brand_mismatch", "unregistered_merchant"]);
|
|
1499
1714
|
var DATATRANS_REGISTRATION_POLICIES = Object.freeze(["refuse", "disclose", "agentcard_single_use"]);
|
|
1500
1715
|
var DATATRANS_REVIEWED_MERCHANT_IDS = Object.freeze({
|
|
1501
|
-
"pay.datatrans.com": Object.freeze([]),
|
|
1716
|
+
"pay.datatrans.com": Object.freeze(["3000022877"]),
|
|
1502
1717
|
"pay.sandbox.datatrans.com": Object.freeze(["1110022968", "1100007006"])
|
|
1503
1718
|
});
|
|
1719
|
+
var DATATRANS_MERCHANT_ACCOUNT_NAMES = Object.freeze({
|
|
1720
|
+
"pay.datatrans.com": Object.freeze({ "3000022877": "RaiseNow" }),
|
|
1721
|
+
"pay.sandbox.datatrans.com": Object.freeze({})
|
|
1722
|
+
});
|
|
1504
1723
|
var DATATRANS_PAYMENT_METHODS = Object.freeze(["VIS", "ECA", "AMX", "DIN", "DIS", "JCB", "CUP", "MAU", "UAP", "DNK"]);
|
|
1505
1724
|
var DATATRANS_TEST_PANS = Object.freeze([
|
|
1506
1725
|
"4242424242424242",
|
|
@@ -1556,6 +1775,48 @@ var pin2 = (fields) => Object.freeze({
|
|
|
1556
1775
|
var PADDLE_VGS_MERCHANT_PINS = /* @__PURE__ */ Object.freeze([
|
|
1557
1776
|
pin2({ id: "rectangle_pro", merchant: "Rectangle Pro", origins: ["https://rectangleapp.com"], sellerClaim: null })
|
|
1558
1777
|
]);
|
|
1778
|
+
var FACT_KEYS = /* @__PURE__ */ Object.freeze(["card_first_six", "card_last_four", "expiry_month", "expiry_year", "card_brand"]);
|
|
1779
|
+
var METADATA_KEYS = /* @__PURE__ */ Object.freeze(["cardholder_name", ...FACT_KEYS]);
|
|
1780
|
+
// src/payfast.js
|
|
1781
|
+
var PAYFAST_PAY_HOSTS = /* @__PURE__ */ Object.freeze({
|
|
1782
|
+
production: Object.freeze(["payment.payfast.io", "www.payfast.co.za"]),
|
|
1783
|
+
sandbox: Object.freeze(["sandbox.payfast.co.za"])
|
|
1784
|
+
});
|
|
1785
|
+
// src/rsa-pkcs1v15.js
|
|
1786
|
+
var TYPED_ARRAY = Object.getPrototypeOf(Uint8Array.prototype);
|
|
1787
|
+
var typedArrayName = Object.getOwnPropertyDescriptor(TYPED_ARRAY, Symbol.toStringTag).get;
|
|
1788
|
+
// src/paddle-keys.js
|
|
1789
|
+
var PADDLE_TOKENEX_KEYS = /* @__PURE__ */ Object.freeze({
|
|
1790
|
+
sandbox: Object.freeze({
|
|
1791
|
+
spki: "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAvWpIQFjQQCPpaIlJKpegirp5kLkzLB1AxHmnLk73D3TJbAGqr1QmlsWDBtMPMRpdzzUM7ZwX3kzhIuATV4Pe7RKp3nZlVmcrT0YCQXBrTwqZNh775z58GP2kZs+gVfNqBampJPzSB/hB62KkByhECn6grrRjiAVwJyZVEvs/2vrxaEpO+aE16emtX12RgI5JdzdOiNyZEQteU6zRBRJEocPWVxExaOpVVVJ5+UnW0LcalzA+lRGRTrQJ5JguAPiAOzRPTK/lYFFpCAl/F8wtoAVG1c8zO2NcQ0Pko+fmeidRFxJ/did2btV+9Mkze3mBphwFmvnxa35LF+Cs/XJHDwIDAQAB",
|
|
1792
|
+
sha256: "877d29a008ed9998d6035032870c63dcc4cbf37ca22cb50b0cc9fe2250a9e3dc"
|
|
1793
|
+
}),
|
|
1794
|
+
production: Object.freeze({
|
|
1795
|
+
spki: "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA8gGPMwBRPuVyJReZGIkWH/+Bf5pnpDN1bSR2cLYLXVT8CaSnTw74qeboSnktgYCi1D9R3Bj2fYzTIwGGZb8KinLdxwbqZmHwrE9cFhCaHbG/E0PbqQGhXP2vbniZTT4M0i0Cbi7ES3Bw5zqNbIZZnX041QEpxLvIyWPKZCX+fBogNMhWfCF779aclChjHkwZMsufThVWE9xklWGxXiytx5aL4I5JPxq0I7cAkZGGs4aF/GxWwPaq7R3wPikJQ0YHnCMfcURzl2Hnw/inqyMy+JB6djTq2/BdzMAhWTh3cDWq9Xu+gEkb/QCd0n1yYIdKuDISlk/AfHdWe34IvzhVyQIDAQAB",
|
|
1796
|
+
sha256: "92529bd289bb24d52a1bdcc42edc9ac0bb1dacbb58f7568573d44771e1287762"
|
|
1797
|
+
})
|
|
1798
|
+
});
|
|
1799
|
+
// src/paddle-tokenex.js
|
|
1800
|
+
var PADDLE_TOKENEX_FACT_KEYS = /* @__PURE__ */ Object.freeze(["card_first_six", "card_last_four", "expiry_month", "expiry_year", "card_brand"]);
|
|
1801
|
+
var METADATA_KEYS2 = /* @__PURE__ */ Object.freeze(["cardholder_name", ...PADDLE_TOKENEX_FACT_KEYS]);
|
|
1802
|
+
var CARD_PATH = /* @__PURE__ */ Object.freeze(["data", "payment_method_data", "card"]);
|
|
1803
|
+
var TOKENEX_PATH = /* @__PURE__ */ Object.freeze([...CARD_PATH, "tokenex_card"]);
|
|
1804
|
+
// src/lyra.js
|
|
1805
|
+
var LYRA_HOSTS = /* @__PURE__ */ Object.freeze({
|
|
1806
|
+
"api.payzen.eu": Object.freeze({ staticOrigin: "https://static.payzen.eu", prefixes: Object.freeze(["01", "02"]) }),
|
|
1807
|
+
"api.systempay.fr": Object.freeze({ staticOrigin: "https://static.systempay.fr", prefixes: Object.freeze(["24", "25"]) }),
|
|
1808
|
+
"api-sogecommerce.societegenerale.eu": Object.freeze({ staticOrigin: "https://static-sogecommerce.societegenerale.eu", prefixes: Object.freeze(["06", "07"]) }),
|
|
1809
|
+
"api.lyra.com": Object.freeze({ staticOrigin: "https://static.lyra.com", prefixes: Object.freeze(["10", "11"]) })
|
|
1810
|
+
});
|
|
1811
|
+
var LYRA_MERCHANT_PINS = /* @__PURE__ */ Object.freeze([
|
|
1812
|
+
Object.freeze({
|
|
1813
|
+
id: "le_mas_lyon",
|
|
1814
|
+
merchant: "Association Le MAS",
|
|
1815
|
+
origins: Object.freeze(["https://www.mas-asso.fr"]),
|
|
1816
|
+
shopIds: Object.freeze(["95120524"]),
|
|
1817
|
+
hosts: Object.freeze(["api.systempay.fr"])
|
|
1818
|
+
})
|
|
1819
|
+
]);
|
|
1559
1820
|
// src/cybersource-secure-acceptance.js
|
|
1560
1821
|
var SA_BODY_LIMIT = 32 * 1024;
|
|
1561
1822
|
var SA_REPLY_LIMIT = 64 * 1024;
|
|
@@ -1624,6 +1885,213 @@ var DECLINE_LABELS = Object.freeze(["label_error_payment", "label_error_bin", "l
|
|
|
1624
1885
|
var EXPIRED_LABELS = Object.freeze(["session_timeout", "ppid_expired"]);
|
|
1625
1886
|
var REF_KEYS = Object.freeze(["recloc", "orderId", "mopId", "pri", "approvalcode", "externalId", "paymentMerchantReference", "prr"]);
|
|
1626
1887
|
var PAYMENT_INFORMATION_KEYS = Object.freeze(["approvalcode", "pri", "externalId", "mopId"]);
|
|
1888
|
+
// src/processors/ekashu.js
|
|
1889
|
+
var EKASHU_HOSTS = Object.freeze(["live.ekashu.com", "test.ekashu.com"]);
|
|
1890
|
+
var EKASHU_TEST_PANS = Object.freeze(["4100000000000100", "5100000000000107"]);
|
|
1891
|
+
var EKASHU_SIGNED_FIELDS = Object.freeze([
|
|
1892
|
+
"ekashu_3d_secure_verify",
|
|
1893
|
+
"ekashu_amount",
|
|
1894
|
+
"ekashu_amount_format",
|
|
1895
|
+
"ekashu_auto_confirm",
|
|
1896
|
+
"ekashu_callback_failure_url",
|
|
1897
|
+
"ekashu_callback_include_post",
|
|
1898
|
+
"ekashu_callback_success_url",
|
|
1899
|
+
"ekashu_card_address_editable",
|
|
1900
|
+
"ekashu_card_address_required",
|
|
1901
|
+
"ekashu_card_address_verify",
|
|
1902
|
+
"ekashu_card_email_address_mandatory",
|
|
1903
|
+
"ekashu_card_phone_number_mandatory",
|
|
1904
|
+
"ekashu_card_title_mandatory",
|
|
1905
|
+
"ekashu_card_zip_code_verify",
|
|
1906
|
+
"ekashu_currency",
|
|
1907
|
+
"ekashu_delivery_address_editable",
|
|
1908
|
+
"ekashu_delivery_address_required",
|
|
1909
|
+
"ekashu_delivery_email_address_mandatory",
|
|
1910
|
+
"ekashu_delivery_phone_number_mandatory",
|
|
1911
|
+
"ekashu_delivery_title_mandatory",
|
|
1912
|
+
"ekashu_description",
|
|
1913
|
+
"ekashu_device",
|
|
1914
|
+
"ekashu_duplicate_check",
|
|
1915
|
+
"ekashu_duplicate_minutes",
|
|
1916
|
+
"ekashu_failure_return_text",
|
|
1917
|
+
"ekashu_failure_url",
|
|
1918
|
+
"ekashu_hash_code_format",
|
|
1919
|
+
"ekashu_hash_code_type",
|
|
1920
|
+
"ekashu_hash_code_version",
|
|
1921
|
+
"ekashu_include_post",
|
|
1922
|
+
"ekashu_invoice_address_editable",
|
|
1923
|
+
"ekashu_invoice_address_required",
|
|
1924
|
+
"ekashu_invoice_email_address_mandatory",
|
|
1925
|
+
"ekashu_invoice_phone_number_mandatory",
|
|
1926
|
+
"ekashu_invoice_title_mandatory",
|
|
1927
|
+
"ekashu_locale",
|
|
1928
|
+
"ekashu_payment_methods",
|
|
1929
|
+
"ekashu_reference",
|
|
1930
|
+
"ekashu_request_type",
|
|
1931
|
+
"ekashu_return_text",
|
|
1932
|
+
"ekashu_seller_address",
|
|
1933
|
+
"ekashu_seller_email_address",
|
|
1934
|
+
"ekashu_seller_id",
|
|
1935
|
+
"ekashu_seller_key",
|
|
1936
|
+
"ekashu_seller_name",
|
|
1937
|
+
"ekashu_shortcut_icon",
|
|
1938
|
+
"ekashu_style_sheet",
|
|
1939
|
+
"ekashu_success_url",
|
|
1940
|
+
"ekashu_title",
|
|
1941
|
+
"ekashu_verification_value_mask",
|
|
1942
|
+
"ekashu_verification_value_verify",
|
|
1943
|
+
"ekashu_viewport"
|
|
1944
|
+
]);
|
|
1945
|
+
var REQUIRED = Object.freeze([
|
|
1946
|
+
"ekashu_seller_id",
|
|
1947
|
+
"ekashu_seller_key",
|
|
1948
|
+
"ekashu_amount",
|
|
1949
|
+
"ekashu_currency",
|
|
1950
|
+
"ekashu_reference",
|
|
1951
|
+
"ekashu_hash_code",
|
|
1952
|
+
"ekashu_hash_code_type",
|
|
1953
|
+
"ekashu_hash_code_version",
|
|
1954
|
+
"ekashu_success_url",
|
|
1955
|
+
"ekashu_failure_url",
|
|
1956
|
+
"ekashu_callback_success_url"
|
|
1957
|
+
]);
|
|
1958
|
+
var CARD_KEYS = Object.freeze([
|
|
1959
|
+
"ekashu_card_number",
|
|
1960
|
+
"ekashu_expires_end_month",
|
|
1961
|
+
"ekashu_expires_end_year",
|
|
1962
|
+
"ekashu_verification_value",
|
|
1963
|
+
"ekashu_valid_from_month",
|
|
1964
|
+
"ekashu_valid_from_year",
|
|
1965
|
+
"ekashu_issue_number"
|
|
1966
|
+
]);
|
|
1967
|
+
var PAGE_KEYS = Object.freeze(["ekashu_stage", "ekashu_context", "ekashu_submission_id"]);
|
|
1968
|
+
var STORED_KEYS = Object.freeze(["ekashu_card_hash", "ekashu_card_reference", "ekashu_cof_initiated_by", "ekashu_cof_reason", "ekashu_cof_id"]);
|
|
1969
|
+
var REDIRECT_KEYS = Object.freeze(["ekashu_success_url", "ekashu_failure_url", "ekashu_return_url"]);
|
|
1970
|
+
var CALLBACK_KEYS = Object.freeze(["ekashu_callback_success_url", "ekashu_callback_failure_url"]);
|
|
1971
|
+
var MAX_ENTRY = 16 * 1024;
|
|
1972
|
+
var MAX_PAGE = 256 * 1024;
|
|
1973
|
+
var EKASHU_SELLERS = Object.freeze([
|
|
1974
|
+
Object.freeze({ sellerId: "25060100", merchant: "Heathrow Drop-off", entryHost: "heathrowdropoff.apcoa.com", callbackHost: "incomingapi.apcoa.co.uk" })
|
|
1975
|
+
]);
|
|
1976
|
+
var CARD_FIELDS = Object.freeze({
|
|
1977
|
+
number: "ekashu_card_number",
|
|
1978
|
+
month: "ekashu_expires_end_month",
|
|
1979
|
+
year: "ekashu_expires_end_year",
|
|
1980
|
+
cvc: "ekashu_verification_value"
|
|
1981
|
+
});
|
|
1982
|
+
var NAME_FIELDS = Object.freeze({ first: "ekashu_card_first_name", last: "ekashu_card_last_name" });
|
|
1983
|
+
var LEFT_EMPTY = Object.freeze(["ekashu_card_title", "ekashu_valid_from_month", "ekashu_valid_from_year", "ekashu_issue_number"]);
|
|
1984
|
+
var VISIBLE = /* @__PURE__ */ new Set([...Object.values(CARD_FIELDS), ...Object.values(NAME_FIELDS), ...LEFT_EMPTY]);
|
|
1985
|
+
// src/processors/redsys.js
|
|
1986
|
+
var REDSYS_HOSTS = Object.freeze(["sis.redsys.es"]);
|
|
1987
|
+
var REDSYS_ENTRY_PATHS = Object.freeze(["/sis/realizarPago", "/sis/realizarPago/utf-8"]);
|
|
1988
|
+
var REDSYS_MERCHANTS = Object.freeze([]);
|
|
1989
|
+
var MAX_ENTRY2 = 16 * 1024;
|
|
1990
|
+
var MAX_PARAMETERS = 8 * 1024;
|
|
1991
|
+
var ENTRY_KEYS = Object.freeze(["Ds_SignatureVersion", "Ds_MerchantParameters", "Ds_Signature"]);
|
|
1992
|
+
var REQUIRED2 = Object.freeze([
|
|
1993
|
+
"DS_MERCHANT_AMOUNT",
|
|
1994
|
+
"DS_MERCHANT_CURRENCY",
|
|
1995
|
+
"DS_MERCHANT_MERCHANTCODE",
|
|
1996
|
+
"DS_MERCHANT_ORDER",
|
|
1997
|
+
"DS_MERCHANT_TERMINAL",
|
|
1998
|
+
"DS_MERCHANT_TRANSACTIONTYPE",
|
|
1999
|
+
"DS_MERCHANT_MERCHANTURL",
|
|
2000
|
+
"DS_MERCHANT_URLOK",
|
|
2001
|
+
"DS_MERCHANT_URLKO"
|
|
2002
|
+
]);
|
|
2003
|
+
var STORED = Object.freeze([
|
|
2004
|
+
"DS_MERCHANT_IDENTIFIER",
|
|
2005
|
+
"DS_MERCHANT_GROUP",
|
|
2006
|
+
"DS_MERCHANT_COF_INI",
|
|
2007
|
+
"DS_MERCHANT_COF_TYPE",
|
|
2008
|
+
"DS_MERCHANT_COF_TXNID"
|
|
2009
|
+
]);
|
|
2010
|
+
var SPECIAL = Object.freeze([
|
|
2011
|
+
"DS_MERCHANT_DIRECTPAYMENT",
|
|
2012
|
+
"DS_MERCHANT_SUMTOTAL",
|
|
2013
|
+
"DS_MERCHANT_DATEFRECUENCY",
|
|
2014
|
+
"DS_MERCHANT_CHARGEEXPIRYDATE",
|
|
2015
|
+
"DS_MERCHANT_IDOPER"
|
|
2016
|
+
]);
|
|
2017
|
+
var CARD_PARAMETERS = Object.freeze(["DS_MERCHANT_PAN", "DS_MERCHANT_EXPIRYDATE", "DS_MERCHANT_CVV2"]);
|
|
2018
|
+
var CURRENCIES = Object.freeze({ 978: "eur", 840: "usd", 826: "gbp", 756: "chf" });
|
|
2019
|
+
var MAX_PAGE2 = 256 * 1024;
|
|
2020
|
+
var CARD_FIELDS2 = Object.freeze({
|
|
2021
|
+
shown: "Sis_card-number",
|
|
2022
|
+
expiry: "SIS_card-expiration",
|
|
2023
|
+
cvc: "Sis_Tarjeta_CVV2",
|
|
2024
|
+
holder: "cardholderName",
|
|
2025
|
+
number: "Sis_Numero_Tarjeta",
|
|
2026
|
+
month: "Sis_Caducidad_Tarjeta_Mes",
|
|
2027
|
+
year: "Sis_Caducidad_Tarjeta_Anno"
|
|
2028
|
+
});
|
|
2029
|
+
var BROWSER_FIELDS = Object.freeze([
|
|
2030
|
+
"browserJavaEnabled",
|
|
2031
|
+
"browserJavascriptEnabled",
|
|
2032
|
+
"browserLanguage",
|
|
2033
|
+
"browserColorDepth",
|
|
2034
|
+
"browserScreenHeight",
|
|
2035
|
+
"browserScreenWidth",
|
|
2036
|
+
"browserTZ",
|
|
2037
|
+
"browserUserAgent"
|
|
2038
|
+
]);
|
|
2039
|
+
var AS_SERVED = Object.freeze(["cvvObligatorio", "threeDSCompInd", "fuc", "terminal", "merchantOrder", "bcancel"]);
|
|
2040
|
+
var CARD_PAGE = /* @__PURE__ */ new Set([...Object.values(CARD_FIELDS2), ...BROWSER_FIELDS, ...AS_SERVED]);
|
|
2041
|
+
var VISIBLE2 = /* @__PURE__ */ new Set([CARD_FIELDS2.shown, CARD_FIELDS2.expiry, CARD_FIELDS2.cvc, CARD_FIELDS2.holder]);
|
|
2042
|
+
var METHOD_PAGE = /* @__PURE__ */ new Set(["resultadoMethod", ...BROWSER_FIELDS, "threeDSCompInd"]);
|
|
2043
|
+
var REDSYS_REFUSALS = Object.freeze(["redsys_card_page", "redsys_3ds_challenge", "redsys_declined"]);
|
|
2044
|
+
// src/processors/quickpay.js
|
|
2045
|
+
var QUICKPAY_HOSTS = Object.freeze(["payment.quickpay.net"]);
|
|
2046
|
+
var QUICKPAY_MERCHANTS = Object.freeze([]);
|
|
2047
|
+
var MAX_ENTRY3 = 16 * 1024;
|
|
2048
|
+
var REQUIRED3 = Object.freeze([
|
|
2049
|
+
"version",
|
|
2050
|
+
"merchant_id",
|
|
2051
|
+
"agreement_id",
|
|
2052
|
+
"order_id",
|
|
2053
|
+
"amount",
|
|
2054
|
+
"currency",
|
|
2055
|
+
"continueurl",
|
|
2056
|
+
"cancelurl",
|
|
2057
|
+
"callbackurl",
|
|
2058
|
+
"checksum"
|
|
2059
|
+
]);
|
|
2060
|
+
var SCALARS = /* @__PURE__ */ new Set([
|
|
2061
|
+
...REQUIRED3,
|
|
2062
|
+
"type",
|
|
2063
|
+
"language",
|
|
2064
|
+
"autocapture",
|
|
2065
|
+
"autofee",
|
|
2066
|
+
"subscription",
|
|
2067
|
+
"description",
|
|
2068
|
+
"payment_methods",
|
|
2069
|
+
"acquirer",
|
|
2070
|
+
"branding_id",
|
|
2071
|
+
"google_analytics_tracking_id",
|
|
2072
|
+
"google_analytics_client_id",
|
|
2073
|
+
"deadline",
|
|
2074
|
+
"text_on_statement",
|
|
2075
|
+
"customer_email",
|
|
2076
|
+
"invoice_address_selection",
|
|
2077
|
+
"shipping_address_selection"
|
|
2078
|
+
]);
|
|
2079
|
+
var CURRENCIES2 = Object.freeze({ DKK: "dkk", EUR: "eur", USD: "usd", SEK: "sek", NOK: "nok", GBP: "gbp", CHF: "chf", PLN: "pln" });
|
|
2080
|
+
var MAX_PAGE3 = 256 * 1024;
|
|
2081
|
+
var CARD_FIELDS3 = Object.freeze({ number: "cardnumber", month: "expiration[month]", year: "expiration[year]", cvc: "cvd", holder: "cardholder" });
|
|
2082
|
+
var TYPED = /* @__PURE__ */ new Set([CARD_FIELDS3.number, CARD_FIELDS3.month, CARD_FIELDS3.year, CARD_FIELDS3.cvc]);
|
|
2083
|
+
var CARD_PAGE2 = /* @__PURE__ */ new Set(["session_id", ...TYPED]);
|
|
2084
|
+
var OPTIONAL = Object.freeze({ brand: "radio", "3d": "checkbox", cardholder: "text" });
|
|
2085
|
+
var AUTH_FIELDS = Object.freeze([
|
|
2086
|
+
"[auth]browserColorDepth",
|
|
2087
|
+
"[auth]browserJavaEnabled",
|
|
2088
|
+
"[auth]browserLanguage",
|
|
2089
|
+
"[auth]browserScreenHeight",
|
|
2090
|
+
"[auth]browserScreenWidth",
|
|
2091
|
+
"[auth]browserTZ",
|
|
2092
|
+
"[auth]threeDSCompInd"
|
|
2093
|
+
]);
|
|
2094
|
+
var QUICKPAY_REFUSALS = Object.freeze(["quickpay_card_page", "quickpay_3ds_challenge", "quickpay_cancelled"]);
|
|
1627
2095
|
// src/recognition.js
|
|
1628
2096
|
var PATTERN_WITHOUT_CARD_FIELDS = Object.freeze({
|
|
1629
2097
|
stripe: "api\\.stripe\\.com/v1/(payment_methods|tokens|setup_intents/seti_\\w+/confirm|payment_intents/pi_\\w+/confirm)"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agent-cards/sdk",
|
|
3
|
-
"version": "0.23.
|
|
3
|
+
"version": "0.23.14",
|
|
4
4
|
"description": "Agentcard's SDK: one client, Agentcard, with two modules. checkout pauses a browser purchase and pays it with the person's own card; voice connects a person to your product once and approves a purchase by voice inside it. Card data never enters your process.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -24,11 +24,14 @@
|
|
|
24
24
|
"access": "public"
|
|
25
25
|
},
|
|
26
26
|
"scripts": {
|
|
27
|
-
"_comment_build": "The public SDK keeps zero runtime dependencies. Its build vendors deterministic metadata and substitution artifacts from the internal payment core,
|
|
28
|
-
"build": "node ../payment-core/scripts/build.mjs && node scripts/generate-payment-core.mjs && node scripts/generate-voice-stream.mjs && npx -y -p typescript@5.9.3 tsc && node scripts/generate-preflight-contract.mjs",
|
|
27
|
+
"_comment_build": "The public SDK keeps zero runtime dependencies. Its build vendors deterministic metadata and substitution artifacts from the internal payment core (src/*.generated.ts), the voice streaming door from packages/voice/src/core (the phone package, @agent-cards/voice, ships it to phones), and the Kernel kit's inventory from the built catalog; git ignores every file it writes. TypeScript remains pinned.",
|
|
28
|
+
"build": "node ../payment-core/scripts/build.mjs && node scripts/generate-payment-core.mjs && node scripts/generate-voice-stream.mjs && npx -y -p typescript@5.9.3 tsc && node scripts/generate-preflight-contract.mjs && node scripts/generate-kernel-native-inventory.mjs",
|
|
29
29
|
"prepublishOnly": "pnpm build",
|
|
30
|
-
"
|
|
31
|
-
"
|
|
30
|
+
"_comment_test": "check:built runs first and names the command when a file the build generates (the copies in src/, the preflight contracts in dist/, the Kernel inventory) is missing or stale; verify:pack runs last, on the same dist.",
|
|
31
|
+
"check:built": "node scripts/generate-payment-core.mjs --check && node scripts/generate-voice-stream.mjs --check && node scripts/generate-preflight-contract.mjs --check && node scripts/generate-kernel-native-inventory.mjs --check",
|
|
32
|
+
"verify:pack": "node scripts/verify-pack.mjs",
|
|
33
|
+
"test": "npm run check:built && node test.mjs && node --test lifecycle.test.mjs merchant-abort.test.mjs preparation.test.mjs braintree.test.mjs pre-claim.test.mjs ekashu.test.mjs redsys.test.mjs paypal-hosted-fields.test.mjs cybersource-secure-acceptance.test.mjs ebanx.test.mjs autopilot.test.mjs stripe-checkout.test.mjs stripe-setup.test.mjs stripe-legacy-checkout.test.mjs payment-core.test.mjs prepared-processor.test.mjs merchant-hosted.test.mjs merchant-total.test.mjs sandbox-declaration.test.mjs minimum-delay.test.mjs paysafe.test.mjs payu.test.mjs attachment.test.mjs worker-targets.test.mjs mercado-checkout.test.mjs mercado-polling.test.mjs amadeus.test.mjs pelecard.test.mjs aci.test.mjs primer.test.mjs payrails.test.mjs elavon-converge.test.mjs voice.test.mjs agentcard.test.mjs buy.test.mjs readme.test.mjs gmo.test.mjs cybersource-flex.test.mjs juspay-gate.test.mjs card-endpoint.test.mjs card-endpoint-fastspring.test.mjs card-endpoint-navigation.test.mjs merchant-session-probe.test.mjs datatrans.test.mjs authorize-net-dpm.test.mjs creditguard.test.mjs eprotect.test.mjs wspay.test.mjs shiji-sts.test.mjs worldline-mycheckout.test.mjs verifone.test.mjs gravy.test.mjs paddle-vgs.test.mjs paddle-tokenex.test.mjs lyra.test.mjs redact-url.test.mjs && node --test preflight-package.test.mjs preflight-collector.test.mjs && node --test kernel-native-qualification.test.mjs && node --test ../vault/scripts/recurly-validation/watch-duty-sdk-result.test.mjs && node scripts/verify-pack.mjs",
|
|
34
|
+
"test:browser": "node browser.test.mjs && node stripe-browser.test.mjs && node preparation-browser.test.mjs && node checkout-com-browser.test.mjs && node paysafe-preparation-browser.test.mjs && node owned-shop-browser.test.mjs && node spreedly-browser.test.mjs && node worker-browser.test.mjs && node amadeus-browser.test.mjs && node adyen-merchant-hosted-browser.test.mjs && node adyen-merchant-frames-browser.test.mjs && node fiserv-browser.test.mjs && node gmo-browser.test.mjs && node cybersource-flex-browser.test.mjs && node juspay-browser.test.mjs && node card-endpoint-browser.test.mjs && node datatrans-browser.test.mjs && node authorize-net-dpm-browser.test.mjs && node pelecard-browser.test.mjs && node aci-browser.test.mjs && node creditguard-browser.test.mjs && node primer-browser.test.mjs && node payrails-browser.test.mjs && node elavon-converge-browser.test.mjs && node eprotect-browser.test.mjs && node wspay-browser.test.mjs && node shiji-sts-browser.test.mjs && node worldline-mycheckout-browser.test.mjs && node paypal-hosted-fields-browser.test.mjs && node cybersource-secure-acceptance-browser.test.mjs && node gravy-browser.test.mjs && node ebanx-browser.test.mjs",
|
|
32
35
|
"check:payment-core": "node scripts/generate-payment-core.mjs --check",
|
|
33
36
|
"check:voice-stream": "node scripts/generate-voice-stream.mjs --check",
|
|
34
37
|
"test:preflight": "node --test preflight-package.test.mjs preflight-collector.test.mjs kernel-native-qualification.test.mjs",
|
|
@@ -49,5 +52,5 @@
|
|
|
49
52
|
"engines": {
|
|
50
53
|
"node": ">=22"
|
|
51
54
|
},
|
|
52
|
-
"license": "
|
|
55
|
+
"license": "SEE LICENSE IN LICENSE"
|
|
53
56
|
}
|