#michael.fraser-webhooks
1 messages ยท Page 1 of 1 (latest)
we_1KoSciKLX8auE5d0ckghvk7Y
your Webhook Endpoint only listens to Connect Account events
It's configured to send payment_intent? Or are you saying that it's not configured in the receiving end code?
there are two types of webhook endpoints
and this is really confusing I know and we should document this better in the future
I'm glad you're telling me something new. ๐
when you create a new Webhook endpoint you can either check Listen to events on Connected accounts which basically means that since you are the platform you will get notified when events happens on your Connected Accounts
I think I checked that
(I was thinking that I'd need it checked to receive payout events for the connected accounts)
yes you do
but you also need to create another endpoint for your platform events
this is where the confusion happens
They need to be distinct urls because I assume they have separate secrets?
you could eventually use the same URL
I'm following. I'm a little amiss on which events are platform and which are connected accounts.
but usually our users often separate the handling of the Platform and the Connected Account events
the Platform events are the events relative to what you submit using your API keys
So, payment initiation (e.g. payment_intent) is probably the only platform event I care about.
It really depends that's why I stroke through my last message
Let me give you some examples
If you create Direct Charges
Got it. So, we're creating destination charges. I work for a property management software company. We're collecting rents on behalf of our property managers.
the creation of the Payment Intent payment_intent.created would be a Connect Account event
destination charges
in your case, those events are Platform events
I specifically want the payment_intent.succeeded because it has the payment method, which I need for updating our internal accounting.
Create another webhook endpoint in the stripe dashboard, or code up a new url on our side (or both)?
I suspect the first, but wanted to make sure
especially from "without checking that checkbox" ๐
Create another webhook endpoint in the stripe dashboard
yes
code up a new url on our side
It's recommended to treat Platform and Connect Account events separately
I want to verify signatures, though.. I assume they differ
Precisely. Ok, I'm following. Weird that my local environment (via stripe cli) was getting both platform and connected events
because it's the same endpoint
Right, it's just proxying, not based on the push from Stripe. Gotcha.
Suggestion: update the webhook event selection to warn folks when selecting events that don't match with the registration?
You could still use one endpoint in your code
by adding an extra query param to your URL
and have your code figure out which secret to use
based on your query param
Good call
let me know if you need any more help