listScriptProcesses method
- int? pageSize,
- String? pageToken,
- String? scriptId,
- String? scriptProcessFilter_deploymentId,
- String? scriptProcessFilter_endTime,
- String? scriptProcessFilter_functionName,
- String? scriptProcessFilter_startTime,
- List<
String> ? scriptProcessFilter_statuses, - List<
String> ? scriptProcessFilter_types, - List<
String> ? scriptProcessFilter_userAccessLevels, - String? $fields,
List information about a script's executed processes, such as process type and current status.
Request parameters:
pageSize - The maximum number of returned processes per page of results.
Defaults to 50.
pageToken - The token for continuing a previous list request on the next
page. This should be set to the value of nextPageToken from a previous
response.
scriptId - The script ID of the project whose processes are listed.
scriptProcessFilter_deploymentId - Optional field used to limit returned
processes to those originating from projects with a specific deployment
ID.
scriptProcessFilter_endTime - Optional field used to limit returned
processes to those that completed on or before the given timestamp.
scriptProcessFilter_functionName - Optional field used to limit returned
processes to those originating from a script function with the given
function name.
scriptProcessFilter_startTime - Optional field used to limit returned
processes to those that were started on or after the given timestamp.
scriptProcessFilter_statuses - Optional field used to limit returned
processes to those having one of the specified process statuses.
scriptProcessFilter_types - Optional field used to limit returned
processes to those having one of the specified process types.
scriptProcessFilter_userAccessLevels - Optional field used to limit
returned processes to those having one of the specified user access
levels.
$fields - Selector specifying which fields to include in a partial
response.
Completes with a ListScriptProcessesResponse.
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<ListScriptProcessesResponse> listScriptProcesses({
core.int? pageSize,
core.String? pageToken,
core.String? scriptId,
core.String? scriptProcessFilter_deploymentId,
core.String? scriptProcessFilter_endTime,
core.String? scriptProcessFilter_functionName,
core.String? scriptProcessFilter_startTime,
core.List<core.String>? scriptProcessFilter_statuses,
core.List<core.String>? scriptProcessFilter_types,
core.List<core.String>? scriptProcessFilter_userAccessLevels,
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
'pageSize': ?pageSize == null ? null : ['${pageSize}'],
'pageToken': ?pageToken == null ? null : [pageToken],
'scriptId': ?scriptId == null ? null : [scriptId],
'scriptProcessFilter.deploymentId':
?scriptProcessFilter_deploymentId == null
? null
: [scriptProcessFilter_deploymentId],
'scriptProcessFilter.endTime': ?scriptProcessFilter_endTime == null
? null
: [scriptProcessFilter_endTime],
'scriptProcessFilter.functionName':
?scriptProcessFilter_functionName == null
? null
: [scriptProcessFilter_functionName],
'scriptProcessFilter.startTime': ?scriptProcessFilter_startTime == null
? null
: [scriptProcessFilter_startTime],
'scriptProcessFilter.statuses': ?scriptProcessFilter_statuses,
'scriptProcessFilter.types': ?scriptProcessFilter_types,
'scriptProcessFilter.userAccessLevels':
?scriptProcessFilter_userAccessLevels,
'fields': ?$fields == null ? null : [$fields],
};
const url_ = 'v1/processes:listScriptProcesses';
final response_ = await _requester.request(
url_,
'GET',
queryParams: queryParams_,
);
return ListScriptProcessesResponse.fromJson(
response_ as core.Map<core.String, core.dynamic>,
);
}