untitled notebook

node v10.24.1
version: 1.0.0
endpointsharetweet
// Require the Stripe library with a test secret key. const stripe = require('stripe')('sk_test_BQokikJOvBiI2HlWgH4olfQ2'); // Create a payment intent to start a purchase flow. let paymentIntent = await stripe.paymentIntents.create({ amount: 200, currency: 'usd', description: 'My first payment', }); // Complete the payment using a test card. paymentIntent = await stripe.paymentIntents.confirm(paymentIntent.id, { payment_method: 'pm_card_visa', }); // Click “▶ run” to try this code live and create your first payment.
Created from: https://stripe.com/
Loading…

no comments

    sign in to comment