Cloudflare

Announcing native support for Stripe’s JavaScript SDK in Cloudflare Workers

Nov 19, 2021Kristian Freeman
Announcing native support for Stripe’s JavaScript SDK in Cloudflare Workers
SummaryAI, from the source post

Introduced native support for the Stripe Node.js SDK within Cloudflare Workers and Cloudflare Pages. This enables developers to use the Stripe JavaScript library directly, including features like automatic type-checking and simplified function calls, rather than relying solely on the REST API. The post provides code examples for initiating Stripe Checkout sessions and securely validating incoming Stripe webhooks within a Workers function, leveraging `Stripe.createFetchHttpClient()` and `Stripe.createSubtleCryptoProvider()` for compatibility with the Workers runtime.

More from the Edge Computing with Cloudflare Workers trail