简体   繁体   中英

How to initialize a Stripe Connect Express session for user to create a Stripe account?

So I am trying to use Stripe Connect with Express accounts. I've had a look at the documentation located here . I am having some trouble getting started. I've been able to use Stripe Checkout without a problem, but I'm not able to redirect a user to Stripe so they can create an account to sell on my platform. I've been playing around with it, and this is the code that I have so far:

export const sellerOnboard = async () => {
  try {
    await stripe.accounts.create({
      type: 'express'
    });
  } catch (err) {
    console.log(err);
  }
};

sellerOnboard gets called when some text gets pressed on the front end, but nothing happens. Any ideas?

You need to create an Account Link and redirect them to it so they can finish onboarding: https://stripe.com/docs/connect/express-accounts#create-link

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM