OptionalcspA Content-Security-Policy nonce for the Stripe.js <script> the adapter
injects, set as its nonce attribute before the tag is inserted, so a
script-src that allows scripts by nonce without 'strict-dynamic' runs
it. Stripe.js reads no nonce itself: it loads its lazy chunks from
https://js.stripe.com without one, which such a policy blocks unless it
also lists that host. Pass the value alone, as in the policy's
'nonce-<value>' source; the constructor refuses anything else. The
adapter never reads a nonce from the page, and a loadScript seam loads
the script without it.
Explicit, mirrors the server adapter — never inferred from key prefixes.
OptionalgetOptionalhideHides the testing assistant Stripe.js shows at the bottom right of a
sandbox page with Elements, on by default for the Payment Intents API from
the clover build on, by passing developerTools: { assistant: { enabled: false } } to Stripe(). Live mode never shows it. Unset or false leaves
Stripe's default.
OptionalloadTest seams: script injection + global lookup. loadScript receives the
URL of the build apiVersion names, and is called again by the next
loadSdk() after an attempt that rejects or leaves the SDK global missing,
so it must be safe to call more than once. What getStripeGlobal returns
is used as window.Stripe is.
OptionallocaleOptionalpaymentOverride the capability list per account/currency instead of hardcoding.
OptionalreturnUsed for redirect-based methods; card/3DS flows stay inline (redirect: "if_required").
The Stripe API version the server adapter pins, such as
"2026-08-26.dahlia"or"2024-06-20", or, while the server is on a release this adapter does not know yet, a version of the newest release it knows. Required: it picks the Stripe.js build, which decides the API version the browser half speaks.https://js.stripe.com/<release>/stripe.js, for the releases this adapter knows: acacia, basil, clover and dahlia. Stripe pins each build to an API version of its release and lets nothing override it, so the browser speaks the release, not necessarily the date: a field or code a later monthly version of the release added may reach the server and not the browser.https://js.stripe.com/v3and passes the version toStripe()asapiVersion, an option only v3 takes, so the browser speaks exactly it.A Stripe.js the page already runs is used instead of loading this build (see
loadSdk()). The constructor refuses withinvalid_requesta missing or malformed version, a date that does not exist, a date alone from 2024-09-30 on and a release name with an earlier date, a release this adapter knows no build for, a preview version and a version carrying beta headers ("…; name=v1"), as no Stripe.js build speaks the last two.