Hi, hope you can help
I’m getting 400 errors trying to POST an expense to freeagent through the
api using Curl
My CURL is as follows:
curl https://api.freeagent.com/v2/expenses -H “Authorization: Bearer
xxxxxxxxxxx” -H “Accept: application/xml” -H “Content-Type:
application/xml” -d @new-expenses.txt -X POST -i -v
(the real auth code works fine for eg GET of recent expenses etc, just cant
gt this POST to work)
the new-expenses.txt file contains the following (which seems to parse OK
in XML syntax checkers)
https://api.freeagent.com/v2/projects/1036498
The error I get returned is 400 Bad Request and the detail error is:
<?xml version="1.0" encoding="UTF-8"?> Expense or expenses data requiredWhat am I doing wrong??
many thanks
Stewart