Hi
I have been playing around with the freeagent API and have found it very useful for automating some of my processes.
I am having difficulties getting the category from invoices. Any payments into the account, marked as payment on an invoice comes out as
https://api.freeagent.com/v2/categories/681 - rather than the category assigned through the invoice.
is there a way of getting this invoice category via the API?
thanks
Steven
Hi there welcome to the FreeAgent API forum!
Categories for invoices get attributed to the nested invoice items on an invoice. The category
gets returned similarly to payments, as a URI.
You can return invoice items either with a list of invoices as described here or if you query a single invoice.
All the best,
James
amazing - it was the nested nature that was catching me out
https://api.freeagent.com/v2/invoices?nested_invoice_items=true this was the key to getting it to show