list method
Returns information about running and completed transfer runs.
Request parameters:
parent
- Required. Name of transfer configuration for which transfer
runs should be retrieved. Format of transfer configuration resource name
is: projects/{project_id}/transferConfigs/{config_id}
or
projects/{project_id}/locations/{location_id}/transferConfigs/{config_id}
.
Value must have pattern
^projects/\[^/\]+/locations/\[^/\]+/transferConfigs/\[^/\]+$
.
pageSize
- Page size. The default page size is the maximum value of 1000
results.
pageToken
- Pagination token, which can be used to request a specific
page of ListTransferRunsRequest
list results. For multiple-page results,
ListTransferRunsResponse
outputs a next_page
token, which can be used
as the page_token
value to request the next page of list results.
runAttempt
- Indicates how run attempts are to be pulled.
Possible string values are:
- "RUN_ATTEMPT_UNSPECIFIED" : All runs should be returned.
- "LATEST" : Only latest run per day should be returned.
states
- When specified, only transfer runs with requested states are
returned.
$fields
- Selector specifying which fields to include in a partial
response.
Completes with a ListTransferRunsResponse.
Completes with a commons.ApiRequestError if the API endpoint returned an error.
If the used http.Client
completes with an error when making a REST call,
this method will complete with the same error.
Implementation
async.Future<ListTransferRunsResponse> list(
core.String parent, {
core.int? pageSize,
core.String? pageToken,
core.String? runAttempt,
core.List<core.String>? states,
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
if (pageSize != null) 'pageSize': ['${pageSize}'],
if (pageToken != null) 'pageToken': [pageToken],
if (runAttempt != null) 'runAttempt': [runAttempt],
if (states != null) 'states': states,
if ($fields != null) 'fields': [$fields],
};
final url_ = 'v1/' + core.Uri.encodeFull('$parent') + '/runs';
final response_ = await _requester.request(
url_,
'GET',
queryParams: queryParams_,
);
return ListTransferRunsResponse.fromJson(
response_ as core.Map<core.String, core.dynamic>);
}