Xero SDK - A validation exception occurred, DELETE method cannot be used on Bank accounts - xero-api

I am trying to delete account or updating account using xero api. Api is giving me exception with status code like 400
A validation exception occurred, DELETE method cannot be used on Bank
accounts.
Attached is the code.
//deleting account using unique id
xeroClient.deleteAccount("XXXXX-XxxxX-Xxxx-XXXX-XXXXXXX");
//setting deleted status via update()
Account account=new Account();
account.setAccountID("XXXXX-XxxxX-Xxxx-XXXX-XXXXXXX");
account.setStatus(AccountStatus.DELETED);
updateList.add(account);
xeroClient.updateAccount(updateList);
May I know why the exception I am getting while deleting account via Xero API

According to the Xero Documentation;
Accounts of type 'BANK' cannot be updated
It would appear that you have to do it manually through the web interface.

Related

I am creating the integration flow for crating Shopify transaction to bank deposit in NetSuite using integrator.io?But i get following error message?

I am creating the integration flow for importing Shopify transaction to bank deposit in NetSuite using celigo integrator.io?But i get following error message?
'Please enter value(s) for: Account'
but i already mapped account field in field mapping.Please find the attached images for that.
Error Image
Mapping Image
Not sure if you already resolved this. My 2 cents: this is typically a NetSuite user error. I'd suggest creating a Deposit via NetSuite and see if you encounter this error or perhaps update your mappings to use the field Account (InternalId) of Type HardCoded instead of Account (Name).

Yodlee get_accounts sometimes returns zero result / empty response

Here is the scenario:
User logins to the bank successfully (via Fastlink)
Right after user logs in, I get user's provider_accounts (via /providerAccounts API)
Then when I call to get the accounts, (via /accounts) I sometimes get empty response (zero accounts found?)
When I try later (seconds or minutes after) I get some accounts information back.
Is this because Yodlee is still trying to gather account information when I'm making /accounts api call?
This is because the accounts are still being added/linked.
Using the requestId and providerAccountId provided by FastLink callback, you need to poll continuously to know the refresh status of the account linking process and once it's done, you can call the get accounts.
Read more about the refresh status in the "Add/Update Account Process Status" section.
Yodlee makes things easier now with webhooks. Read more here:
Using Webhooks with the Yodlee Core API
TL/DR: You need to wait for the add/link completion before retrieving the accounts.

Why do I get a REFRESH_COMPLETED_WITH_UNCERTAIN_ACCOUNT?

It's not clear to me why I'm getting this error: REFRESH_COMPLETED_WITH_UNCERTAIN_ACCOUNT
The authentication workflow went through, but I can't get any summaries for the added site.
When you add a site , all the different types of accounts under the provided credentials will be added. Like - saving, credit card account, loan account etc.
When the refresh is completed but there is a failure in refresh for one of the different types of account present for that site for a user because of either data agent or Site error then this status is set. Hence this status has to be treated same as REFRESH_COMPLETED and you should be able to get summary details.

Invalid account details accepts while adding new site account in yodlee live API

I'm using yodlee live API to link the bank transaction details.
Invalid bank account details accepts, when we add new site account in yodlee via live API, For example, the the account details like xxxxx and yyyyy, then the account added successful.
It's normal or any settings to be turned on in yodlee account or API parameters?
How can i validate the account details? while user add new site account?
Thanks in advance.
Though Yodlee accepts the invalid details/credentials, the account would fail. This would be represented by an Error code such as 402, which would mean that the credentials are wrong.
This is normal setting and teh only way you can validate if the details are right is by checking the status of the account. The error code should be "0" if everything is right.
Hope this helps. You can get more details on error codes under different scenarios #Error Code
Hope this helps
-Vijay
In short: Yodlee doesn't know the username/password entered during add account are correct or not; it has to validate the same with Bank website.
To explain you the process:
When you are adding a particular Bank account, you provides the username/password(it may be correct or incorrect) Yodlee doesn't know and can't validate at the time of submission. Yodlee takes the inputs(username/password) and submits the same to the Bank website(which consumer had selected); meanwhile you'll receive a response from API- addSiteAccount1, which will have the code as 801 (Refresh Never Done and Yodlee is going to update your account).
Once Bank website validate the same and found them incorrect Yodlee return 402 error code(invalid credentials), you need to call getSiteRefreshInfo API to check the same in loops each of 3-4sec.

Yodlee REST API: How to resolve CobrandUserAccountLockedException?

Currently, I am making the following POST call:
https://rest.developer.yodlee.com/services/srest/restserver/v1.0/authenticate/coblogin?cobrandLogin=sbCobFoo&cobrandPassword=Bar
(Note that I inserted a fake login and password for the purpose of this post). I am getting the following response:
{"Error":[{"errorDetail":"The account for user sbCobFoo is locked"}]}
I wasn't able to find anything in the Yodlee documentation, other than that this error represents CobrandUserAccountLockedException. Has any one encountered this error and/or know how to resolve it (i.e. unlock my account)?
You will need to reach out to your Yodlee Customer Service representative to get your credentials unlocked. Yodlee does not provide any API to unlock user/cobrand account(s).