#BronsonAM

1 messages · Page 1 of 1 (latest)

slender obsidianBOT
timid python
#

hi! I don't think I can answer anything specific about the accounting part, we don't know about that here, we answer API questions. But the main issue I imagine is there's no link on Stripe's side, we have no idea that the specific PaymentIntent "paid" for that Invoice, that's not modelled at all in our API so it won't reflect in any data we have or export.

snow eagle
#

So it sounds like, from an API perspective, invoices created as paid out of bound are treated as if they do not even exist when reading/exporting the data. If that is the case, that would work well in my case.

I'm not sure that "integrating payments via a one-off invoice" would work in my case as I would like to display the payment_element html object (which requires a payment_intent.client_secret) to the user before finalizing the invoice so that I can easily add or remove invoice line items at this point. And the invoice.payment_intent object is only created once the invoice is finalized ( so a sort of chicken and egg problem)
That's how I came up with creating the payment intent first (which can have the amount easily updated after it has been created) and only finalize the invoice after the payment intent is complete.

timid python
#

So it sounds like, from an API perspective, invoices created as paid out of bound are treated as if they do not even exist when reading/exporting the data.
I don't think that's true, they exist just fine and you get them when you call the List Invoice endpoint etc. Not sure about any other exports/reports we have.

#

to the other points, that's all true enough. A few options :

  • change the flow of your site so the payment page(the one using the PaymentElement and needing the Intent) is only reached after the customer finalises the details of the invoice and selects things and stuff

  • don't use PaymentElement, use the CardElement integration where you submit the PaymentMethod to the backend and create the Invoice at. that point https://stripe.com/docs/payments/accept-a-payment-synchronously?platform=web More work to integrate and can be tricky

  • not a great answer but wait maybe 6 months, we're working on at least two things I'm aware of that will help since this is a known pain point and merchants have requirements for Invoices. We'll be more tightly integrating Checkout with Invoices, and also https://stripe.com/docs/payments/run-custom-actions-before-confirmation will at some become a public feature and might help in cases like this(mounting the PaymentElement before knowing the final details)

snow eagle
#

this is good info, thanks a lot for the help! 🙌