static void Main(string[] args) { // Instantiate the timer job class TenantAPIJob tenantAPIJob = new TenantAPIJob(); // The provided credentials need access to the site collections you want to use tenantAPIJob.UseAppOnlyAuthentication(ClientId, ClientSecret); // set enumeration credentials to allow using search API to find the OD4B sites //tenantAPIJob.SetEnumerationCredentials(User, Password); // In case of SharePoint on-premises use //tenantAPIJob.UseNetworkCredentialsAuthentication(User, Password, Domain); // Add one or more sites to operate on tenantAPIJob.AddSite("https://bertonline.sharepoint.com/sites/dev"); // Print timer job information and then call Run() on the job PrintJobSettingsAndRunJob(tenantAPIJob); }