#Aniket - connect endpoints

1 messages · Page 1 of 1 (latest)

acoustic patio
#

Hello, that endpoint will receive events for the accounts that are connected to that admin account (but not events on the admin account itself unless you connected it to itself)

#

Are you seeing something different or just asking to make sure you are setting up right?

keen gate
#

While making a checkout session, I'm passing a stripe account header so that the payments can be reflected in that specific connected account and that is happening.
const session = await stripe.checkout.sessions.create( { line_items: [ { price_data: { product_data: { name: serviceProduct.name, description: serviceProduct.description, images: serviceProduct.productImages, // max 8 image URLs }, currency: 'usd', unit_amount: serviceProduct.unitAmount, // A non-negative integer in cents }, quantity: 1, }, ], success_url: REDIRECT_URL, cancel_url: REDIRECT_URL, client_reference_id: sessionId, mode: 'payment', payment_intent_data: { metadata: { hostConnectedAccountId: connectedAccountId, sessionId, }, }, }, { stripeAccount: connectedAccountId, } );

So according to you that webhook hosted in admin account should work for other connected acc's events.

#

So just confirming that's how it works. Am I right?

acoustic patio
#

Yes, when you create a Checkout session like that, the webhook endpoint that you set up should get a payment_intent.succeeded event when the session completes