#adi_invoice-fees
1 messages ยท Page 1 of 1 (latest)
๐ Welcome to your new thread!
โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
๐ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1240771558830772295
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
Which Invoice page are you referring to? And what fees specifically do you want it to show?
here's an example payment page for the invoice for one of our customers: https://invoice.stripe.com/i/acct_184HuYKNEK8dUItS/live_YWNjdF8xODRIdVlLTkVLOGRVSXRTLF9RN09mcXc3VVpYU09DNEpwaHZsVjZvTUJzdUpMellULDEwNjQzMzcxNg0200JFo2j9tQ?s=db
(this is a live, production invoice do not run a payment)
how do we a) show the payment processing fee and b) adjust what's shown based on the payment method selected
You can't adjust this dynamically based on the Payment Method type that the customer selects. You would need to know that ahead of time (e.g. before you create the Invoice). As for fees, in order to pass them on to the customer and show them in the Invoice, you would have to create new Invoice Items for each fee you want to charge and attach those to the Invoice at some point before sending the Customer to the hosted invoice page
what about the use case of a customer that doesn't have a payment method when the invoice is created?
how do we know what fee to attach to the invoice?
@sage urchin are you a Stripe developer?
Yes
The hosted Invoice page isn't intended to be this configurable/customizable, so you'd be using this product in a way it isn't really intended. So knowing the Payment Method type ahead of time and adding Invoice Items before sending the customer to the hosted invoice page is kind of a workaround.
That workaround makes sense. So we would only show the link to the hosted invoice page to the end user after a payment method has been selected. We would then create the invoice and then display the hosted invoice page.
Assuming we use a separate flow to collect payment method.
Hey @sage urchin (Adi teammate here), correct me if I'm wrong, but even if a user has a payment method attached to their account, they can still enter a different payment method on the hosted invoice page when we send an invoice, right?
Correct
so what's the workaround for that case?
That's correct. If you have a default Customer with a Payment Method though, you could just create the Invoice and pay it without sending them to the hosted invoice page.
can we disable the ability to select a payment method on the hosted invoice page?
Understood. Our use case is for users who have their payment method stored but want to decide when to pay, rather than being charged automatically. We currently send them a link to the hosted invoice (and additionally a 'Pay Now' button in our mobile app that calls the pay invoice API).
Unfortunately no
@sage urchin how are your other customers doing this? just a quick high-level explaination.
Other customers would do something similar, but would likely not use the hosted invoice page. For this flow they would likely code up a custom workflow where they setup a new Payment Method for future payments via the Payment Element, then create and display the Invoice with all of its corresponding Invoice Items to represent the fees.
makese sense. @stark crater sounds like we may have to unbundle the hosted invoice page, and build out a custom flow.
@sage urchin do you happen to have an example of a customer using this custom flow showing processing fees? would be great for us to view how their invoice flow does this.
I don't unfortunately. It's not a workflow that we see very often
adi_invoice-fees
Still a little unclear on how to handle the case where a customer does not have a payment method upfront but we send them an invoice. Are we able to send out a draft invoice that we can then update after the payment method has been selected (via payment elements)?
update the custom fee line item*
@lost swallow no that's impossible we don't support something like this. And we often discourage anyone from trying this because it's hard to build right really.
In that case you would have to ask them first what payment method they plan to use and then create the Invoice as a result of that. And if they change their mind you would void that Invoice, create a new one for the other payment method, until they pay
@hoary spear so what you are effectively saying is that the payment method has to be collected upfront as a requirement before an invoice can be sent.
if you have a hard requirement of adding fees that is specific to the payment method then yes
got it. ok.
could we do something like: create invoice, send invoice, user selects payment method, void invoice, create new invoice with payment method (all in one session)?
yes that would work
user selects payment method
That would be the tricky part if we use hosted invoices because we wouldn't have a way to know which payment method they selected.
we wouldn't use the hosted invoice page
we create a custom invoice page, with stripe invoice line items.
yeah you have to build it all yourself
at the api-level we would be doing all the creating and voiding and then render it on a custom page.
Maybe we would not even need a stripe invoice when they select their payment method and then void @lost swallow
yea, even that would be custom
yeah that is a good point, if you don't need an Invoice this becomes drastically easier
That would be creating a payment intent directly?
yes
Make sense.
hmm, we still need an invoice as a record of the service.
you can always do your own invoice logic though without Stripe.
You could create an Invoice after the payment too, just not pay it in Stripe and mark it as paid "out of band" https://docs.stripe.com/invoicing/overview#out-of-band-invoices
We don't have a way to tie an Invoice to a previously paid PaymentIntent. I hope we build this in the future because that's exactly what people like you need but it's unlikely to happen soon ๐ฆ
got it ok. so sounds like the best path is to build the invoicing flow ourselves and directly create payment intents?
i.e. not use Stripe Invoicing
yes. Or skip the "overcharge" for the payment method. Increase your fees and bundle the Stripe cost into it.
I know it's easier said than done but it's what everyone else does
Yes, that alternative is a good suggestion.
Thanks @hoary spear