400 errors

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)

<?xml version='1.0' encoding='UTF-8'?> https://api.freeagent.com/v2/users/393275 https://api.freeagent.com/v2/projects/1036498 https://api.freeagent.com/v2/categories/249 2015-11-16 wickes2 130.0 2 0 Over 2000cc Petrol Car 130.0 1 0.45 0.45 true cost

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 required

What am I doing wrong??

many thanks
Stewart