public GoogleCalendarScheduler(GoogleCalendarConfig config)
        {
            _ = config ?? throw new ArgumentNullException(nameof(config));
            _googleCalendarId = config.GoogleCalendarId;

            var credential = new ServiceAccountCredential(
                new ServiceAccountCredential.Initializer(config.GoogleCalendarAccount)
            {
                Scopes = new[] { CalendarService.Scope.Calendar, },
            }
                .FromPrivateKey(config.Pkcs8PrivateKey));

            var service = new CalendarService(new BaseClientService.Initializer
            {
                HttpClientFactory     = new Google.Apis.Http.HttpClientFactory(),
                HttpClientInitializer = credential,
                ApplicationName       = "FlexKids Rooster",
            });

            _calendarService = new GoogleCalendarService(service);
        }
 public CalendarReportScheduleChange(ILogger logger, GoogleCalendarConfig config)
 {
     _logger = logger ?? throw new ArgumentNullException(nameof(logger));
     _config = config ?? throw new ArgumentNullException(nameof(config));
 }