Hello!
I am trying to create a bank transaction explanation with a sales_tax_rate of 20
but it fails with:
sales_tax_rate must be the AUTO rate or a rate less than 0
I haven’t changed the way I create explanations and it’s never failed like this before. Has there been a validation change at the FreeAgent end?
The call looks like:
curl https://api.freeagent.com/v2/bank_transaction_explanations \
-H "Authorization: Bearer ..." \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{"bank_transaction_explanation":{"gross_value":2.5,"category":"https://api.freeagent.com/v2/categories/001","description":"Blah blah","sales_tax_rate":20,"bank_transaction":"https://api.freeagent.com/v2/bank_transactions/123456","marked_for_review":true,"dated_on":"2021-07-09"}}' \
-X POST
Here’s the data formatted nicely:
{
"gross_value": 2.5,
"category": "https://api.freeagent.com/v2/categories/001",
"description": "Blah blah",
"sales_tax_rate": 20,
"bank_transaction": "https://api.freeagent.com/v2/bank_transactions/123456",
"marked_for_review": true,
"dated_on": "2021-07-09"
}
Many thanks,
Andrew Stewart