Example #1
0
        async Task IngestTrendingTopicsAsync()
        {
            var trends         = _twitterService.ListLocalTrendsFor(CreateListLocalTrendOptions());
            var trendsInSpain  = _twitterService.ListLocalTrendsFor(CreateListLocalTrendOptions(23424950));
            var trendingTopics = ParseFromTwitterTrends(trends, "Worldwide")
                                 .Concat(ParseFromTwitterTrends(trendsInSpain, "Spain"))
                                 .ToList();

            await _twitterRepository.AddAsync(trendingTopics);
        }