コード例 #1
0
 public Subscriptions(ILogger <Subscriptions> logger, TtsDbContext db)
 {
     _logger         = logger;
     _db             = db;
     _clientId       = BotDataAccess.ClientId;
     _appAccessToken = BotDataAccess.GetAppAccessToken(_db.BotData);
 }
コード例 #2
0
ファイル: Users.cs プロジェクト: icecreamdatabase/TtsApi
        public async Task <List <TwitchUser> > GetList(string[] userIdsToCheck = null, string[] userLoginsToCheck = null)
        {
            string clientId       = BotDataAccess.ClientId;
            string appAccessToken = BotDataAccess.GetAppAccessToken(_db.BotData);

            // Try first time
            DataHolder <TwitchUser> rewardData =
                await UsersStatics.Users(clientId, appAccessToken, userIdsToCheck, userLoginsToCheck);

            // If we don't have an Unauthorized result return it
            if (rewardData is not {
                Status : (int)HttpStatusCode.Unauthorized
            })