Open API

Q. How do I find my particular Investment Id?

You can call "/openapi/at/v3/investments/me/?TradeLeaderId={TradeLeaderId}". If you do not include the TradeLeaderId={TradeLeaderId}, this will return all of your investments, otherwise it will return an investment in the specified leader. The response will contain account details along with the investment id.

Q. How do I start/update a investment?

Refer below links for staring and updating an investment:

  • Starting  a new investment - Link
  • Update an existing investment - Link

Q: How can I change the Display Name of the Investment made from the default name?

By default the display name will be the name of the Trade Leader. You can change it by invoking the endpoint [PATCH] at/v3/investments/{InvestmentId}. You need to pass the Investment Id along with the request data having  "DisplayName" : "Test1".

Q: How to I request that an account should no longer track/invest and that all current holdings should be liquidated?

Ye can achieve this by invoking the endpoint [PATCH] at/v3/investments/{InvestmentId}. You need to pass the Investment Id along with the request data having "PositionsCloseOnDeactivation" : "True" and "IsActive" : False.

Q: Can I Restart an Investment?

You can restart an Investment by invoking the endpoint [PATCH] at/v3/investments/{InvestmentId}. We need to pass the Investment Id along with the request data having  "IsActive" : True.

You can also pass optional fields in the request data like "FundingAccountKey", "InvestmentShieldAmount", "PendingFunding" .

Q : How can I check Suitability Status of follower?

You can check the Suitability Status of s follower by executing [GET] at/v3/tradeFollowers/me endpoint.

Q: How do I know if an account is still tracking an investment, or whether it is no longer affected by any trades made by the trade leader?

Whether an investment is stopped can be checked by looking at the IsFollowing field. To verify if the investment is stopped, you can call /openapi/at/v3/investments?InvestmentId=<InvestmentID>, for a particular investment, or you may call /openapi/at/v3/investments/me for multiple investment status and check if “IsFollowing” is false.

Q: How do I find the Minimal Account balance which needs to be maintained?

The minimal account balance can be found from the MinimumFunding field returned from the /at/v3/investments/?InvestmentId={InvestmentId} endpoint.

Q: How you find the maximum amount which can be withdrawn?

To get the maximum amount to withdraw, please call the /at/v3/investments/{InvestmentId}/maxWithdrawalAmount endpoint.

Note that this value may change with the market value. If you withdraw the exact amount returned from this endpoint, there is thus a small chance that the withdrawal will be rejected as it would be the account below the minimal account balance.

Q: What API function should be used for making a full withdrawal from a portfolio (account)?

You can only remove the full amount if the portfolio following has been stopped and all positions on the account has been liquidated and the trades on the account have been settled. At that point you can use the  /at/v3/investments/{InvestmentId}/maxWithdrawalAmount to get the full amount, which can be withdrawn (should be the full account value if following has been stopped). 

Q: Can I keep my positions,  even if investment is stopped ?

Yes, you can achieve this by executing the endpoint [PATCH] at/v3/investments/{InvestmentId}. You need to pass the Investment Id along with the request data having "PositionsCloseOnDeactivation" : "False" and "IsActive" : False.

Q: How do I figure out leader performance over the period of time ?

You can call "/openapi/at/v3/tradeLeaders/{TradeLeaderId}/?StandardPeriod={StandardPeriod}" and look for "AccountPerformance" factor. This provides various important values like account summary related values, performance metrics like AccountValue metrics, Balance metrics , TimeWeighted Performance metrics.