#xkernel
1 messages · Page 1 of 1 (latest)
Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
Have you completed the onboarding for the connected account?
no i wasn't aware of that.
So i am not sure what would be the flow exactly. but here is my marketplace flow.
- seller signup with our application
- the application creates Stripe Account for the seller
- the application also creates Stripe Customer
- let the user access out application dashboard.
why i do create Stripe Account & Customer? because i want the seller to be able to sell(get funds on their bank) and be able to by other items from other sellers(using the same bank account to purchase)
You need to onboard the connected properly and ask them to provide necessary information so that they can start accepting payments from customers.
should i redirect them to some url on stripe website?
Yes you can create an account link for the account to onboard with https://stripe.com/docs/connect/standard-accounts#how-to-use-connect-onboarding-for-standard-accounts
actually i am making them express accounts but this doc is about standard account type. does it work?
ok this doc tells me that i need to collect that information from the user such as BusinessType and then in the code, i can just pass it as the parameter.
But you mentioned that i can create a link for them to use the stripe onboarding form instead. right?
Yes, you can use the same account link API
i can't find my answer about the actual values for the URLs on the doc
RefreshURL: stripe.String("https://example.com/reauth"),
ReturnURL: stripe.String("https://example.com/return"),
when i want to redirect my user to do the onboarding, i need to redirect them to the stripe's onboarding form.
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
have you checked the API reference?
yea i read. but still not very clear. What i guess is that i should redirect the user to https://myPlatform.com/reauth and on this page, i should run some sort of Stripe JS code ?
"The URL you specify should attempt to generate a new account link with the same parameters used to create the original account link, then redirect the user to the new account link’s URL so they can continue with Connect Onboarding.'
So when you endpoint receives a request from that URL, it needs to create a new account link and direct your customer to the account link URL
here we have this code in our /signup endpoint so when they fill up the email/password after submitting the code below will be executed.
so i create the account link immediately after the account creation.
// for being a seller and receive funds
sellerParams := &stripe.AccountParams{
Type: stripe.String(string(stripe.AccountTypeExpress)),
Email: stripe.String(sellerEmail),
Capabilities: &stripe.AccountCapabilitiesParams{
CardPayments: &stripe.AccountCapabilitiesCardPaymentsParams{
Requested: stripe.Bool(true),
},
Transfers: &stripe.AccountCapabilitiesTransfersParams{
Requested: stripe.Bool(true),
},
},
BusinessProfile: &stripe.AccountBusinessProfileParams{
MCC: stripe.String("5734"),
},
}
resultAsSeller, err := account.New(sellerParams)
// for being a buyer and spend money to buy other's items
sellerToBuyParams := &stripe.CustomerParams{
Name: stripe.String(sellerName),
Email: stripe.String(sellerEmail),
}
resultAsSellerToBuy, err := customer.New(sellerToBuyParams)
linkParams := &stripe.AccountLinkParams{
Account: stripe.String(resultAsSeller.ID),
RefreshURL: stripe.String("https://example.com/reauth"),
ReturnURL: stripe.String("https://example.com/return"),
Type: stripe.String("account_onboarding"),
}
linkResult, err := accountlink.New(linkParams)
Is your question about how to pass the AccountID to the refreshURL so that it can create another account link with the same params?
no, my question is that should be replaced with "https://example.com/reauth" since i am creating the account in the same backend function.
👋 Taking over this thread, catching up now
"https://example.com/reauth" is an endpoint at your server that creates a new account link on the existing connected account belonging to this connected account holder, so that he/she can complete the onboarding flow in case the onboarding page is being refreshed
Hi River, so in my flow i wanna do it all in one shot. when they fill up the signup form and click on submit, i want all these codes to run automatically.
is it possible to do so?
If the connected account holder doesn't drop off during the onboarding, then this will be the case. However, if he/she refreshes the page or click return, your server should create a new account link for them to continue finishing the onboarding
ok but i am still not getting it. even if i have a separate endpoint for the link creation, how does the user land on stripe's onboarding pre-build form then?
In the same endpoint that you create a new account link, you will redirect to the new account link URL for them to complete the onboarding
no. I mean how to redirect the user to this page? the url is not on my platform. it is on Stripe
this isn't the onboarding form provided by Stripe?
shouldn't redirect the user to that onboarding page in order to change the created account's status from Restricted to "Complete" or something?
Once account link is created, your server will redirect to url from the response: https://stripe.com/docs/api/account_links/object#account_link_object-url
User should complete filling up the information in the onboarding page, then the account will be complete
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
separate question:
i get an error from creating link params.
[ERROR] Request error from Stripe (status 400): {"status":400,"message":"You must update your Connect branding settings with business name, icon, brand col
or in order to create an account link. You can set the missing fields at https://dashboard.stripe.com/settings/connect"
i am using my test-mode keys and in the test-mode dashboard, i am unable to set any of those.