예제 #1
0
        public async Task CreateWebhookAsync()
        {
            var callbackUrl = $"{_twitterOptions.WebhookCallbackBaseUrl}/api/twitter/webhook";

            var data = new Dictionary <string, string> {
                { "url", callbackUrl }
            };

            await _twitterClient.PostAsync($"/1.1/account_activity/all/{_twitterOptions.WebhookEnvironment}/webhooks.json", data);
        }
 public Task CreateSubscriptionAsync() =>
 _twitterClient.PostAsync($"/1.1/account_activity/all/{_twitterOptions.WebhookEnvironment}/subscriptions.json", new Dictionary <string, string>());