#ironbeard_api
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/1326652088826204191
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- ironbeard_webhooks, 5 days ago, 9 messages
heyo ๐ e
Good question, looking in to this and will get back to you
thanks ๐
Apologies for the delay, still looking in to this with my colleagues. Will get back with what we can find.
Hi, can you share the exact requirements for the call on upcoming invoices? I'm trying to replicate this on my end as well. Also, can you share the response from the GET request so I can review in the meantime?
Hey sorry I didn't get this alert one sec
Looking at this: (screen shot incoming)
so no mention of discount_amounts there.
No worries, I was able to find an example request id and I was able to replicate what you saw.
Let me review this a bit further
thanks โค๏ธ
Ok, from my tests, you can attain the amount for unit_amount- discount_amount by looking at the total.
I agree, that is not documented on the API reference even on the Upcoming Invoice API, https://docs.stripe.com/api/invoices/upcoming#upcoming_invoice-invoice_items-discounts
I will share this feedback with the team.
It is in the response
You can search to it and you should see the discounted amount there
I'm confused, is InvoiceItem.discounts depreciated, or do I need to expand it? Because my call has an empty list for discounts key, but does contain a discount_amounts list
I'm looking a specifically an invoice line, I was hoping for the total for the line, not the total for the invoice.
I do not think that is possible. On this example, https://dashboard.stripe.com/test/logs/req_ZSIYJd8S3FGafs I found there is only one item right?
I'm testing something else, hang tight
Yeah, correct.
I'm not opposed to calculating it myself, I'm just unsure what the difference between discounts and discount_amounts is
Makes sense. discount_amounts is not documented and I will share this feedback with our team. Thank you for flagging it here
@tulip plinth I was wrong, from further testing and looking at at this we do document it here: https://docs.stripe.com/api/invoice-line-item/object#invoice_line_item_object-discount_amounts