#amyamy-invoice-void

1 messages ยท Page 1 of 1 (latest)

valid pythonBOT
sterile walrus
#

amyamy-invoice-void

#

Looking

#

As far as I can tell, something "special" happened to that Invoice internally that forced us to void it

#

it's months old so I can't really figure out what exactly happened but someone internally ran some logic/code that changed that Invoice's status

proud current
#

from an accounting perspective, that is mindboggling. good luck running it through your rev rec tool ๐Ÿ˜‚ (I'm kidding but probably not kidding - it might break some of your other code that assumes voided invoices don't have payments)

#

thanks for confirming that it's extremely rare

#

I'll try to skip it manually on our end!

sterile walrus
#

Yeah I mean I assume someone went and did comms about this

proud current
#

ah, I see, I wouldn't have received the comms because I'm doing accounting for them but I am not a part of their company

sterile walrus
#

Looks like the underlying Subscription was stuck in incomplete_expired despite the Invoice being... paid?

#

yeah that's likely why. I wish there was a "free form notes" feature for stuff like this ๐Ÿ˜ฆ

proud current
#

super weird

#

thank you!

#

I have some unrelated feedback about the Invoices API!

#

I find the List Invoices API pretty painful to use because it doesn't allow me to filter invoices by "status_transitions.finalized_at". It only lets me filter by the created_at time. The time of creation and finalization can be months apart, so there's no clear way for me to request "all invoices finalized in a given month", which is what is relevant from an accounting perspective. (The same is true for the dashboard's filtering options - you can only filter by "created".)

sterile walrus
#

Yeah if you look the vast majority of List APIs only limit by a handful of filters. The more we add the slower the API would get and it's unfortunately something we have to limit quite extensively.

proud current
sterile walrus
#

In theory the Search Invoice API should solve that, but it's also really limited in the kind of filters it supports

#

My advice in cases like this is to ingest all the Invoices once and then cache all the data in your own database and then rely on Events to detect changes.
Or use Sigma

proud current
#

I think it's uniquely painful for invoices because for most other API resources, the created timestamp is actually the time where the resource becomes "real".

sterile walrus
#

yeah it's the same for Subscriptions