#guimatos_api
1 messages ¡ Page 1 of 1 (latest)
đ Welcome to your new thread!
â˛ď¸ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
âąď¸ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
đ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1354079692159979571
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
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.
- guimatos_api, 11 hours ago, 9 messages
- guimatos_api, 16 hours ago, 36 messages
I already use the collectionOptions, works in the first time, but now the documents steps is not loading anymore and the creation of accounts are still with "Restricted" label
exports.createSessionAccount = functions.region("southamerica-east1").https.onCall(async (data, context) => {
// Check if the user is authenticated
try {
// Uncomment and use the below line if user ID is passed in the function context
// const uid = context.auth.uid; // Get the user ID from the context
const {uid} = context.auth; // Assume the user ID is passed through the data payload
const userData = await admin.firestore().collection("users").doc(uid).get();
if (!userData?.data()?.stripeAccountId) throw new Error('No stripe account id configured');
const {stripeAccountId} = userData.data();
const accountSession = await stripe.accountSessions.create({
account: stripeAccountId, // Ensure correct casing and data key names
components: {
account_onboarding: {
enabled: true,
features: {
external_account_collection: false,
},
},
documents: {
enabled: true,
features: {},
},
},
});
// Return the session details and user info in the object
return {
message: "Stripe account session created successfully.",
clientSecret: accountSession.client_secret,
userId: uid,
};
}
});
<ConnectComponentsProvider
connectInstance={stripeConnectInstance}
>
<ConnectAccountOnboarding
onExit={(exitData) => handleNextStep(exitData)}
collectionOptions={{
fields: 'eventually_due',
futureRequirements: 'include',
}}
/>
</ConnectComponentsProvider>
const stripe = require("stripe")(functions.config().stripe.secret);
const admin = require("firebase-admin");
exports.createSessionAccount = functions.region("southamerica-east1").https.onCall(async (data, context) => {
// Check if the user is authenticated
try {
const {uid} = context.auth; // Assume the user ID is passed through the data payload
const userData = await admin.firestore().collection("users").doc(uid).get();
if (!userData?.data()?.stripeAccountId) throw new Error('No stripe account id configured');
const {stripeAccountId} = userData.data();
const accountSession = await stripe.accountSessions.create({
account: stripeAccountId, // Ensure correct casing and data key names
components: {
account_onboarding: {
enabled: true,
features: {
external_account_collection: false,
},
},
documents: {
enabled: true,
features: {},
},
},
});
// Return the session details and user info in the object
return {
message: "Stripe account session created successfully.",
clientSecret: accountSession.client_secret,
userId: uid,
};
} catch (error) {}
});
Yes, it looks like in the latest account.updated event that there was an issue with the test verification document and that needs to be re-uploaded.
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
You're saying the embedded components are not prompting for this?
Exactly. Even using the collectionOptions, is not prompting
I see you're enabling the documents component in the account session, but that's for downloading documents not uploading (and I don't see it in your component tree anyways)
https://docs.stripe.com/connect/supported-embedded-components/documents
I'm wondering if this verification is considered post-onboarding
Can you try implementing the notification banner?
https://docs.stripe.com/connect/supported-embedded-components/notification-banner
My understanding is that this is what's to be used to resolve post-onboarding verification issues with submitted data.