Get invoices written off

Hi,
I can’t see a view that includes items processed with mark_as_cancelled, ie written off items. Once written off I don’t know how to list them programatically.

I would like to get a list of invoice url’s that are written off for a particular client and then adjust the written off date to match the correct financial year. These invoices were previously written off in the wrong financial year and there are many of them.

The bit I can’t do is list the written off invoices. If i do the following i get an error
response = requests.get(url=“https://api.freeagent.com/v2/invoices?contact="+url+"&view=unpaid_written_off&per_page=100&sort=-created_at&page=”+str§, headers=header)

I do the following to list open_or_overdue and it works fine

response = requests.get(url=“https://api.freeagent.com/v2/invoices?contact="+url+"&view=open_or_overdue&per_page=100&sort=-created_at&page=”+str§, headers=header)

Hi James,

Ewa from FreeAgent Engineering Team here :wave: I’m afraid we don’t have a filter for written off invoices on the GET /v2/invoices endpoint (just as there isn’t one in the web UI), but I’ll flag it to the relevant product team as an improvement request; I can absolutely see how it would be useful.

Best wishes,

Ewa