#Maxime Beaudry-cancel-subscription
1 messages ยท Page 1 of 1 (latest)
Hi ๐ do you happen to have the request ID from that failure?
Nevermind, I believe I've found it. It does not look like a fix has yet been developed and released for this behavior.
I'm going to report this most recent occurrence to the team that is looking into this.
Thank you for raising this to our attention.
Thanks @radiant dagger !
I am trying to create a credit note for a line item that has taxes. The amount of the item is 2500 + taxes (125 + 249) = 2874 as you can see in the first image.
I then configure my CreditNoteCreateOptions like this where refundAmount = 2452:
var creditNoteOptions = new CreditNoteCreateOptions
{
Invoice = latestInvoice.Id,
Lines = new List<CreditNoteLineOptions>
{
new CreditNoteLineOptions
{
Type = "invoice_line_item",
Amount = refundAmount,
InvoiceLineItem = lineItemToRefund.Id,
},
},
Reason = "order_change",
RefundAmount = refundAmount,
};
In other words, I want to refund 2452 out of the 2500 original charge (before taxes).
Then, when I call the Create Credit Note API, I get this error:
The sum of credit amount, refund amount and out of band amount ($24.52) must equal the credit note amount ($28.19)
Do you have any idea how to fix this? Where is that 28.19 coming from?
Hi ๐ Thanks for moving this question here. It's helpful in keeping our channels neat and easy to track.
I think that I found the solution. When I use the "Preview Credit Note" API, it computes the amount (including taxes) that I have to set on CreditNoteCreateOptions.RefundAmount . Here's what the Preview API returns:
Yes I was just finding that in our docs. https://stripe.com/docs/invoicing/integration/programmatic-credit-notes