コード例 #1
0
        static void Main(string[] args)
        {
            SymConfig     symConfig = new SymConfigLoader().loadFromFile("config.json");
            SymBotRSAAuth botAuth   = new SymBotRSAAuth(symConfig);

            botAuth.authenticate();
            SymBotClient botClient = SymBotClient.initBot(symConfig, botAuth);

            // start listening for messages
            DatafeedEventsService dataFeedService = botClient.getDatafeedEventsService();
            BotLogic listener = new BotLogic(botClient);

            dataFeedService.addIMListener(listener);
            dataFeedService.getEventsFromDatafeed();
        }
コード例 #2
0
        public void DatafeedCreateTest()
        {
            SymConfig       symConfig       = new SymConfig();
            SymConfigLoader symConfigLoader = new SymConfigLoader();

            symConfig = symConfigLoader.loadFromFile("C:/Users/Michael/Documents/Visual Studio 2017/Projects/apiClientDotNet/apiClientDotNetTest/Resources/testConfig.json");
            apiClientDotNet.Authentication.SymBotAuth botAuth = new apiClientDotNet.Authentication.SymBotAuth(symConfig);
            botAuth.authenticate();
            SymBotClient          botClient             = SymBotClient.initBot(symConfig, botAuth);
            DatafeedEventsService datafeedEventsService = botClient.getDatafeedEventsService();

            //datafeedEventsService.getEventsFromDatafeed();

            //Assert.IsTrue(datafeedEventsService.datafeedId != null);
        }