CFDs are complex instruments and come with a high risk of losing money rapidly due to leverage. -- % of retail investor accounts lose money when trading CFDs with this provider. You should consider whether you understand how CFDs work and whether you can afford to take the high risk of losing your money.

Trading API

Hi, I was able to get investor ID from
However when I use investor ID for{investorAccountId}/orders/buy it return http error 403.

“status”: “Investor account provided does not belong to the user.”

It happens to me because I reset the DEMO account. I tried with regenerate new access token. It still not working. I have to logout everything, login and regenerate new access token. It only will works. Now working but I don’t know why it not working just now. The only thing I do is logout, login and regenerate.

When I try to reset the account again, it doesn’t work again. I try to logout, login, regenerate. It still doesn’t work.

This is what I tested. Hope it helps.

Hi @guanchuan,

Every time there is a reset in the DEMO account, a new investor account demo is created and provided. Nevertheless, the existing access token might still have the authorization for using the old DEMO account, not allowing the use of the new investor account demo id. Regenerating the access token or revoking and granting new access tokens is not taking the new demo investor account.

Certainly, this is a behaviour we need to fix. Meanwhile, it might need at least one hour until new access tokens are granted with access to the new investor account id.

Thanks for letting us know, and I’ll come back with another answer once this is solved.

Hi @jesusbc,


Besides, I have this request. Is that possible to include D-Score and D-Leverage in the products api? This is because I try to request through API but there is a request limit every minutes. I try to get the data through FTP but it would be great to include in products API.

Hi @guanchuan,

I can see there is a current method for retrieving the D-Score: GET /products/{productName}/dxscore although we are still not providing the D-Leverage in the API.
Would you like these scores as part of the return of any of the existing queries or as another methods?

Hi @jesusbc,

I would like D-Score and D-Leverage be part of the existing API /2.0/products. The reason I requested that is due to request limit. I get http error 429 after I send request around 10 times to /dxscore.


Hi @guanchuan ,
You should be able to reset the demo account (or create new real accounts) and use the new investor account ids now through the API without having to regenerate the token. It may take a maximum of 1 minute to allow that access now.

I’ll come back again with any updates related to d-score or d-leverage on the products API.