예제 #1
0
        /// <summary>Initializes a new instance of the <see cref="BitfinexService" /> class.</summary>
        /// <param name="configuration">The configuration.</param>
        /// <param name="loggerService">The logger service.</param>
        /// <param name="dbOrderService">The database order service.</param>
        public BitfinexService(IConfiguration configuration, ILoggerService loggerService, IDbOrderService dbOrderService)
        {
            _configuration  = configuration;
            _loggerService  = loggerService;
            _dbOrderService = dbOrderService;

            BitfinexClient.SetDefaultOptions(new BitfinexClientOptions
            {
                ApiCredentials =
                    new ApiCredentials(
                        _configuration["BitfinexClient:Key"],
                        _configuration["BitfinexClient:Secret"]),
            });

            _bitfinexClient = new BitfinexClient();
        }
예제 #2
0
 public Server(IDbItemService itemService, IDbOrderService orderService)
 {
     this.itemService  = itemService;
     this.orderService = orderService;
 }