Reputation: 1
I'd like to Schedule a YouTube LIVE Streaming via API from ASP.NET Web API. When I run following code it will prompt for YouTube User Selection:
UserCredential credential;
using (var stream = new FileStream(_youTubeSettings.CredentialFilePath, FileMode.Open, FileAccess.Read))
{
credential = await GoogleWebAuthorizationBroker.AuthorizeAsync(
(await GoogleClientSecrets.FromStreamAsync(stream)).Secrets,
[YouTubeService.Scope.Youtube],
"user",
CancellationToken.None,
new FileDataStore(_youTubeSettings.AppName));
}
But since this is a Web API Application, I would like it without any user interaction, how to achieve this?
Thanks in advance.
Upvotes: 0
Views: 16