#romain_api

1 messages ¡ Page 1 of 1 (latest)

chilly currentBOT
#

👋 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/1242858637639024650

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

tacit epoch
#

Hello, yes our Search API can filter based on metadata. One thing to keep in mind is that it takes a minute for objects and changes to be indexed, so if you create an invoice with some metadata and then immediately search for that metadata, the invoice will not show up.
https://docs.stripe.com/api/invoices/search
Apologies for the delay in reply the server is a bit busy.

mossy seal
#

Thank you! But I would like to list invoices based on subscription's metadata. Is it possible in one request?
My metadata is not directly on the invoice, but is on the related subscription

tacit epoch
#

Unfortunately not, I think your two workarounds would be:

  1. Manually set invoice metadata to match subscription metadata, then search via the invoice search API
  2. Search for relevant subscriptions via the subscription search API, then do an invoice search with a filter that includes all of those subscriptions
  3. Same as #2 but making individual invoice list calls per subscription.
#

I understand that those are not ideal, and will put in a feature request for this, but these would be the workarounds for now

chilly currentBOT