Class HistoryClient
- java.lang.Object
-
- cloud.metaapi.sdk.clients.MetaApiClient
-
- cloud.metaapi.sdk.clients.copy_factory.HistoryClient
-
public class HistoryClient extends MetaApiClient
metaapi.cloud CopyFactory history API (trade copying history API) client (see https://trading-api-v1.project-stock.agiliumlabs.cloud/swagger/#/)
-
-
Field Summary
-
Fields inherited from class cloud.metaapi.sdk.clients.MetaApiClient
host, httpClient, token
-
-
Constructor Summary
Constructors Constructor Description HistoryClient(HttpClient httpClient, String token)Constructs CopyFactory history API client instance.HistoryClient(HttpClient httpClient, String token, String domain)Constructs CopyFactory history API client instance
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CompletableFuture<List<CopyFactoryStrategyIdAndName>>getProvidedStrategies()Returns list of strategies the current user provides to other users https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!CompletableFuture<List<CopyFactoryTransaction>>getProvidedStrategiesTransactions(IsoTime from, IsoTime till)Returns list of transactions on the strategies the current user provides to other users.CompletableFuture<List<CopyFactoryTransaction>>getProvidedStrategiesTransactions(IsoTime from, IsoTime till, List<String> strategyIds, List<String> subscriberIds)Returns list of transactions on the strategies the current user provides to other users.CompletableFuture<List<CopyFactoryTransaction>>getProvidedStrategiesTransactions(IsoTime from, IsoTime till, List<String> strategyIds, List<String> subscriberIds, Integer offset, Integer limit)Returns list of transactions on the strategies the current user provides to other users https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!CompletableFuture<List<CopyFactorySubscriberOrProvider>>getProviders()Returns list of providers providing strategies to the current user https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!CompletableFuture<List<CopyFactoryStrategyIdAndName>>getStrategiesSubscribed()Returns list of strategies the current user is subscribed to https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!CompletableFuture<List<CopyFactoryTransaction>>getStrategiesSubscribedTransactions(IsoTime from, IsoTime till)Returns list of trades on the strategies the current user subscribed to https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!CompletableFuture<List<CopyFactoryTransaction>>getStrategiesSubscribedTransactions(IsoTime from, IsoTime till, List<String> strategyIds, List<String> providerIds)Returns list of trades on the strategies the current user subscribed to https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!CompletableFuture<List<CopyFactoryTransaction>>getStrategiesSubscribedTransactions(IsoTime from, IsoTime till, List<String> strategyIds, List<String> providerIds, Integer offset, Integer limit)Returns list of trades on the strategies the current user subscribed to https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!CompletableFuture<List<CopyFactorySubscriberOrProvider>>getSubscribers()Returns list of subscribers subscribed to the strategies of the current user https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!-
Methods inherited from class cloud.metaapi.sdk.clients.MetaApiClient
getTokenType, handleNoAccessError, isNotAccountToken, isNotJwtToken
-
-
-
-
Constructor Detail
-
HistoryClient
public HistoryClient(HttpClient httpClient, String token)
Constructs CopyFactory history API client instance. Domain is set toagiliumtrade.agiliumtrade.ai- Parameters:
httpClient- HTTP clienttoken- authorization token
-
HistoryClient
public HistoryClient(HttpClient httpClient, String token, String domain)
Constructs CopyFactory history API client instance- Parameters:
httpClient- HTTP clienttoken- authorization tokendomain- domain to connect to
-
-
Method Detail
-
getProviders
public CompletableFuture<List<CopyFactorySubscriberOrProvider>> getProviders()
Returns list of providers providing strategies to the current user https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_providers- Returns:
- completable future resolving with providers found
-
getSubscribers
public CompletableFuture<List<CopyFactorySubscriberOrProvider>> getSubscribers()
Returns list of subscribers subscribed to the strategies of the current user https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_subscribers- Returns:
- completable future resolving with subscribers found
-
getStrategiesSubscribed
public CompletableFuture<List<CopyFactoryStrategyIdAndName>> getStrategiesSubscribed()
Returns list of strategies the current user is subscribed to https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_strategies_subscribed- Returns:
- completable future resolving with strategies found
-
getProvidedStrategies
public CompletableFuture<List<CopyFactoryStrategyIdAndName>> getProvidedStrategies()
Returns list of strategies the current user provides to other users https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_provided_strategies- Returns:
- completable future resolving with strategies found
-
getProvidedStrategiesTransactions
public CompletableFuture<List<CopyFactoryTransaction>> getProvidedStrategiesTransactions(IsoTime from, IsoTime till)
Returns list of transactions on the strategies the current user provides to other users. https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_provided_strategies_transactions Pagination offset is 0 and limit is default 1000. Does not filter by strategies or subscribers.- Parameters:
from- time to load transactions fromtill- time to load transactions till- Returns:
- completable future resolving with transactions found
-
getProvidedStrategiesTransactions
public CompletableFuture<List<CopyFactoryTransaction>> getProvidedStrategiesTransactions(IsoTime from, IsoTime till, List<String> strategyIds, List<String> subscriberIds)
Returns list of transactions on the strategies the current user provides to other users. https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_provided_strategies_transactions Pagination offset is 0 and limit is default 1000.- Parameters:
from- time to load transactions fromtill- time to load transactions tillstrategyIds- optional list of strategy ids to filter transactions by, ornullsubscriberIds- optional list of subscribers to filter transactions by, ornull- Returns:
- completable future resolving with transactions found
-
getProvidedStrategiesTransactions
public CompletableFuture<List<CopyFactoryTransaction>> getProvidedStrategiesTransactions(IsoTime from, IsoTime till, List<String> strategyIds, List<String> subscriberIds, Integer offset, Integer limit)
Returns list of transactions on the strategies the current user provides to other users https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_provided_strategies_transactions- Parameters:
from- time to load transactions fromtill- time to load transactions tillstrategyIds- optional list of strategy ids to filter transactions by, ornullsubscriberIds- optional list of subscribers to filter transactions by, ornulloffset- pagination offset, ornull. Default value is 0limit- pagination limit, ornull. Default value is 10000- Returns:
- completable future resolving with transactions found
-
getStrategiesSubscribedTransactions
public CompletableFuture<List<CopyFactoryTransaction>> getStrategiesSubscribedTransactions(IsoTime from, IsoTime till)
Returns list of trades on the strategies the current user subscribed to https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_strategies_subscribed_transactions Pagination offset is 0 and limit is default 1000. Does not filter by strategies or providers.- Parameters:
from- time to load transactions fromtill- time to load transactions till- Returns:
- completable future resolving with transactions found
-
getStrategiesSubscribedTransactions
public CompletableFuture<List<CopyFactoryTransaction>> getStrategiesSubscribedTransactions(IsoTime from, IsoTime till, List<String> strategyIds, List<String> providerIds)
Returns list of trades on the strategies the current user subscribed to https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_strategies_subscribed_transactions Pagination offset is 0 and limit is default 1000.- Parameters:
from- time to load transactions fromtill- time to load transactions tillstrategyIds- optional list of strategy ids to filter transactions by, ornullproviderIds- optional list of providers to filter transactions by, ornull- Returns:
- completable future resolving with transactions found
-
getStrategiesSubscribedTransactions
public CompletableFuture<List<CopyFactoryTransaction>> getStrategiesSubscribedTransactions(IsoTime from, IsoTime till, List<String> strategyIds, List<String> providerIds, Integer offset, Integer limit)
Returns list of trades on the strategies the current user subscribed to https://trading-api-v1.agiliumtrade.agiliumtrade.ai/swagger/#!/default/get_users_current_strategies_subscribed_transactions- Parameters:
from- time to load transactions fromtill- time to load transactions tillstrategyIds- optional list of strategy ids to filter transactions by, ornullproviderIds- optional list of providers to filter transactions by, ornulloffset- pagination offset, ornull. Default value is 0limit- pagination limit, ornull. Default value is 10000- Returns:
- completable future resolving with transactions found
-
-