public override void Invoke(AWSCredentials creds, RegionEndpoint region, int maxItems) { AmazonSimpleWorkflowConfig config = new AmazonSimpleWorkflowConfig(); config.RegionEndpoint = region; ConfigureClient(config); AmazonSimpleWorkflowClient client = new AmazonSimpleWorkflowClient(creds, config); WorkflowExecutionInfos resp = new WorkflowExecutionInfos(); do { ListClosedWorkflowExecutionsRequest req = new ListClosedWorkflowExecutionsRequest { NextPageToken = resp.NextPageToken , MaximumPageSize = maxItems }; resp = client.ListClosedWorkflowExecutions(req); CheckError(resp.HttpStatusCode, "200"); foreach (var obj in resp.ExecutionInfos) { AddObject(obj); } }while (!string.IsNullOrEmpty(resp.NextPageToken)); }