I recently attempted to create a new primary bank account (with is_primary=true) via the API, but the is_primary flag is ignored. Unsurprisingly, trying to update the resource with is_primary=true also does nothing, but it does return a 200 response code which is somewhat confusing. Is there a reason this is not currently supported?
Request:
POST /bank_accounts
{
"bank_account": {
"opening_balance": "0.0",
"type": "StandardBankAccount",
"name": "New Primary Bank Account",
"is_personal": false,
"is_primary": true,
"currency": "GBP",
"bank_code": "generic",
"account_number": "123456789",
"sort_code": "000000"
}
}
Response:
{
"bank_account": {
"url": "https://api.sandbox.freeagent.com/v2/bank_accounts/2196",
"opening_balance": "0.0",
"type": "StandardBankAccount",
"name": "New Primary Bank Account",
"is_personal": false,
"is_primary": false,
"currency": "GBP",
"current_balance": "0.0",
"account_number": "123456789",
"sort_code": "000000",
"bank_code": "generic",
"latest_activity_date": "2016-01-01",
"updated_at": "2017-02-01T13:21:44.032Z",
"created_at": "2017-02-01T13:21:44.032Z",
"unexplained_transaction_count": 0,
"marked_for_review_count": 0,
"bank_feed_enabled": false,
"bank_guess_enabled": false
}
}