private void OnOutboundSessionMsgEventHandler(object sender, OutboundSessionMsgEventArgs e)
        {
            var outgoingMsg = e.Msg;

            if (outgoingMsg.Type == MsgType.Logon)
            {
                var sendingTime = outgoingMsg.Get(Tags.SendingTime);
                var msgSeqNum   = outgoingMsg.Get(Tags.MsgSeqNum);

                var rawData = ComposeRawData(sendingTime, MsgType.Logon, msgSeqNum,
                                             SettingsManager.Get(ExchangeProvider.GDAX, "APIKey"), "Coinbase",
                                             SettingsManager.Get(ExchangeProvider.GDAX, "Passphrase"));

                // 96	RawData	Client message signature (see below)
                outgoingMsg.Set(Tags.RawData, rawData);
                e.ModifiedMsg = outgoingMsg;
            }

            _logger.Add("Outbound session message: " + e.Msg);
        }
示例#2
0
 void session_OutboundSessionMsgEvent(object sender, OutboundSessionMsgEventArgs args)
 {
     eventView.LogOutgoingMessage(args.Msg);
 }