#devio__

1 messages ยท Page 1 of 1 (latest)

weary quarryBOT
latent sky
#

Hello ๐Ÿ‘‹
Not sure I follow

Do you know if its possible with the Stripe API to create a paid invoice with 20% VAT line ? I'm in France and my business clients need that line for accounting.

Are you using Invoicing or just creating Payments by calling PaymentIntents API?

glad birch
#

I'm creating PaymentIntents from API

#

On my back server

latent sky
#

Gotcha. In that case, you could create one-off invoices with the line items you want and mark them as paid by calling the API (since they've already paid)
https://stripe.com/docs/api/invoices/pay#pay_invoice-paid_out_of_band

However, I don't know if that conflicts with the payment stats you see on Stripe dashboard as technically it would be recorded as two different payments (one from invoice and one from PaymentIntent)

glad birch
#

And it's not possible to have VAT in receipt ?

#

Because I set the parameter receipt_email when the PaymentIntent is created

#

And the receipt can do the job for accounting if there is VAT on it

latent sky
#

Right, but I don't think VAT would show up as a separate line item though

glad birch
#

Is there an other way to have an invoice with VAT with payement from Stripe Elements or do you have an other solution ? How your French customers edit an invoice with that line ?

#

I want to send the invoice automatically after payment by email for the business customers

latent sky
#

The merchants who want that, create an invoice first and then use the underlying payment intent w/ PaymentElement to collect payment.

#

Stripe checkout supports post purchase invoices, PaymentIntents don't.

glad birch
#

So, when client want to made a payment on my website, its possible to:

  • Create an Invoice with all needed lines
  • Create a PaymentIntent and attach the invoice to it
  • Pass the PaymentIntent to PaymentElement to pay the invoice from my website ?
latent sky
#

When you create an invoice with all needed lines and finalize it, it automatically generates a PaymentIntent
https://stripe.com/docs/api/invoices/object#invoice_object-payment_intent

So you don't need to create one separately. you can use the same one and pass it to your client-side code

glad birch
#

Its great ! I will do that. Instead of create only a PaymentIntent i will create an invoice. Thanks for your help ๐Ÿ˜