public override async Task <AccountInformation> GetAccountInformation(ExecutionContext context, [NotNull] CrawlJobData jobData, Guid organizationId, Guid userId, Guid providerDefinitionId)
        {
            if (jobData == null)
            {
                throw new ArgumentNullException(nameof(jobData));
            }

            if (!(jobData is GreenhouseCrawlJobData greenhouseCrawlJobData))
            {
                throw new Exception("Wrong CrawlJobData type");
            }

            var client = _greenhouseClientFactory.CreateNew(greenhouseCrawlJobData);

            return(await Task.FromResult(client.GetAccountInformation()));
        }
        public IEnumerable <object> GetData(CrawlJobData jobData)
        {
            if (!(jobData is GreenhouseCrawlJobData greenhousecrawlJobData))
            {
                yield break;
            }

            var client = clientFactory.CreateNew(greenhousecrawlJobData);

            foreach (var candidate in client.GetCandidates())
            {
                yield return(candidate.Educations);

                yield return(candidate.Attachments);

                yield return(candidate.Applications);

                yield return(candidate.Addresses);

                yield return(candidate);
            }
            //retrieve data from provider and yield objects
        }