invertase / stripe-firebase-extensions

Repository of Firebase Extensions built by Stripe.
https://firebase.google.com/products/extensions
Apache License 2.0
438 stars 173 forks source link

Pass through payment_intent_data #641

Open evancaldwell opened 2 weeks ago

evancaldwell commented 2 weeks ago

Feature request

Is your feature request related to a problem? Please describe.

I need to make destination payments as a platform on Stripe. This is done by adding payment_intent_data to the checkoutSession but this extension doesn't pass that data through when creating the checkoutSession

Describe the solution you'd like

Simply pulling payment_intent_data from the snap and adding it to the sessionCreateParams with a check similar to what's already being done for line_items should be enough.

Describe alternatives you've considered

For me the only other solution would be to not use this extension.

Additional context

I saw an old issue about supporting Stripe Connect which was closed. Although this destination payments are part of Stripe Connect I don't think there is a need to support everything, just adding payment_intent_data would bring in some extra functionality. I've tested this by editing the function instance in my Google Cloud and it is working. I submitted the following PR for this feature request: https://github.com/invertase/stripe-firebase-extensions/pull/642

evancaldwell commented 1 week ago

Anyone have a chance to look at this? It's really small change.