#nukesforbreakfast_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/1219096149135462482
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
These are the docs I'm looking at for the list endpoint: https://docs.stripe.com/api/invoiceitems/list
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
List Invoice Items API doesn't support search by metadata or period. It only supports listing the invoice items by when it is created.
I'm afraid we don't have any API support searching invoice item by period or metadata.
Can you share what you're trying to do?
yes
so I have a billing system I'm trying to port to stripe where we bill for false alarm activations. I want to tie each false alarm activation that should generate a fine to an invoice item. I was planning on doing that via metadata within the invoice item itself, so that I would not need a separate data storage to tie false alarm IDs to a invoice item.
However, due to the nature of the way the alarm ordinances are structured, a City deciding to waive an old alarm on appeal could cascade forward and change invoice items that came after the one that was waived. So I need a way to query the invoice items based on their period value, so I can find all the invoice items that come after a waived one in order to either delete them if the invoice is draft, or issue credit notes if the invoice is finalized.
I see the invoice itself has a search endpoint.
can a metadata value be an array, or can it only be a string?
Thanks for sharing! Invoice Item doesn't have a search endpoint, only an Invoice does.
For your use case, the only way will be saving the metadata and period of an invoice item within your database and search within it.
can a metadata value be an array, or can it only be a string?
Metadata value should be a string