public class TradingClient
extends cloud.metaapi.sdk.clients.MetaApiClient
| Constructor and Description |
|---|
TradingClient(cloud.metaapi.sdk.clients.HttpClient httpClient,
String token)
Constructs CopyFactory trading API client instance.
|
TradingClient(cloud.metaapi.sdk.clients.HttpClient httpClient,
String token,
String domain)
Constructs CopyFactory trading API client instance
|
| Modifier and Type | Method and Description |
|---|---|
CompletableFuture<List<CopyFactoryStrategyStopout>> |
getStopouts(String accountId)
Returns subscriber account stopouts.
|
CompletableFuture<List<CopyFactoryUserLogRecord>> |
getUserLog(String accountId)
Returns copy trading user log for an account and time range.
|
CompletableFuture<List<CopyFactoryUserLogRecord>> |
getUserLog(String accountId,
cloud.metaapi.sdk.clients.models.IsoTime startTime,
cloud.metaapi.sdk.clients.models.IsoTime endTime)
Returns copy trading user log for an account and time range.
|
CompletableFuture<List<CopyFactoryUserLogRecord>> |
getUserLog(String accountId,
cloud.metaapi.sdk.clients.models.IsoTime startTime,
cloud.metaapi.sdk.clients.models.IsoTime endTime,
Integer offset,
Integer limit)
Returns copy trading user log for an account and time range.
|
CompletableFuture<Void> |
resetStopouts(String accountId,
String strategyId,
String reason)
Resets strategy stopouts.
|
CompletableFuture<Void> |
resynchronize(String accountId,
List<String> strategyIds)
Resynchronizes the account.
|
public TradingClient(cloud.metaapi.sdk.clients.HttpClient httpClient,
String token)
agiliumtrade.agiliumtrade.aihttpClient - HTTP clienttoken - authorization tokenpublic CompletableFuture<Void> resynchronize(String accountId, List<String> strategyIds)
accountId - account idstrategyIds - optional array of strategy ids to recynchronize, or null.
Default is to synchronize all strategiespublic CompletableFuture<List<CopyFactoryStrategyStopout>> getStopouts(String accountId)
accountId - account idpublic CompletableFuture<Void> resetStopouts(String accountId, String strategyId, String reason)
accountId - account idstrategyId - strategy idreason - stopout reason to reset. One of yearly-balance, monthly-balance, daily-balance,
yearly-equity, monthly-equity, daily-equity, max-drawdownpublic CompletableFuture<List<CopyFactoryUserLogRecord>> getUserLog(String accountId)
accountId - account idpublic CompletableFuture<List<CopyFactoryUserLogRecord>> getUserLog(String accountId, cloud.metaapi.sdk.clients.models.IsoTime startTime, cloud.metaapi.sdk.clients.models.IsoTime endTime)
accountId - account idstartTime - time to start loading data from, or nullendTime - time to stop loading data at, or nullpublic CompletableFuture<List<CopyFactoryUserLogRecord>> getUserLog(String accountId, cloud.metaapi.sdk.clients.models.IsoTime startTime, cloud.metaapi.sdk.clients.models.IsoTime endTime, Integer offset, Integer limit)
accountId - account idstartTime - time to start loading data from, or nullendTime - time to stop loading data at, or nulloffset - pagination offset, or null. Default is 0limit - pagination limit, or null. Default is 1000Copyright © 2023. All rights reserved.