0
votes

I am trying to upgrade my checkout.js for Stripe to the new js.stripe.com/v3/

I tried to upgrade it but I had to create a session on the backend `

$checkout_session = \Stripe\Checkout\Session::create([
    'success_url' => $domain . '/order?session_id=',
    'cancel_url' => $domain . '/',
    'payment_method_types' => ['card'],
    'mode' => 'payment',
    'line_items' => []
  ]);

` My issue is that line_items has to be an array of products that are listed on your Stripe account. In my case I do not own the products on my website and they get setup by customers.

How do I go about this?

Also, how do I get this working with Connect so these product owners get a cut of the payment?

1

1 Answers