#mtanzi-multiple-webhooks
1 messages ยท Page 1 of 1 (latest)
sure!
Are you using one of our libraries to handle the signature verification?
yes I am using the ruby library
I think the easiest approach is to just try verifying the event with each endpoint signing secret, and stop trying when one succeeds.
I am using the following API:
event = Stripe::Webhook.construct_event(@payload, @signature, @signing_key)
mmm this sounds like a brute force approach.. is there not anything nicer? ๐
Sorry, juggling a lot of threads so it took a second to remember the better approach. You can add query params at the end of the URL you provide for your webhook endpoint (a unique value for each account), and then consume this param on your end to determine which account sent the event.