public Mantle.Fix44.IClientMessage AccountInfoRequest() { switch (_cfg.Extensions) { case Extensions.OkCoin: { var res = new Mantle.Fix44.OkCoinAccountInfoRequest() { StandardHeader = StandardHeader() }; res.Account.Value = _cfg.Account; res.AccReqID.Value = Guid.NewGuid().ToString(); return res; } case Extensions.Huobi: { var res = new Mantle.Fix44.HuobiAccountInfoRequest() { StandardHeader = StandardHeader(), HuobiSignature = HuobiSignature ( new KeyValuePair<string, string>[] { new KeyValuePair<string, string>("method", "get_account_info") } ) }; res.Account.Value = _cfg.Account; res.HuobiAccReqID.Value = Guid.NewGuid().ToString(); return res; } } throw new UnsupportedOperationException( "AccountInfoRequest requires FIX extensions. If your exchange supports this operation, " + "make sure you are passing correct value of iFix.Crust.Fix44.Config.Extensions"); }
public Mantle.Fix44.IClientMessage AccountInfoRequest() { switch (_cfg.Extensions) { case Extensions.OkCoin: { var res = new Mantle.Fix44.OkCoinAccountInfoRequest() { StandardHeader = StandardHeader() }; res.Account.Value = _cfg.Account; res.AccReqID.Value = Guid.NewGuid().ToString(); return(res); } case Extensions.Huobi: { var res = new Mantle.Fix44.HuobiAccountInfoRequest() { StandardHeader = StandardHeader(), HuobiSignature = HuobiSignature ( new KeyValuePair <string, string>[] { new KeyValuePair <string, string>("method", "get_account_info") } ) }; res.Account.Value = _cfg.Account; res.HuobiAccReqID.Value = Guid.NewGuid().ToString(); return(res); } case Extensions.Btcc: { var res = new Mantle.Fix44.BtccAccountInfoRequest() { StandardHeader = StandardHeader(), }; res.Account.Value = BtccSignature(_cfg.Account, _cfg.SecretKey, "getAccountInfo¶ms=balance"); res.BtccAccReqID.Value = Guid.NewGuid().ToString(); return(res); } } throw new UnsupportedOperationException( "AccountInfoRequest requires FIX extensions. If your exchange supports this operation, " + "make sure you are passing correct value of iFix.Crust.Fix44.Config.Extensions"); }