list method
Lists print server configurations.
Request parameters:
parent - Required. The
unique ID
of the customer's Google Workspace account. Format: customers/{id}
Value must have pattern ^customers/\[^/\]+$.
filter - Search query in
Common Expression Language syntax.
Supported filters are display_name, description, and uri. Example:
printServer.displayName=='marketing-queue'.
orderBy - Sort order for results. Supported values are display_name,
description, or create_time. Default order is ascending, but
descending order can be returned by appending "desc" to the order_by
field. For instance, orderBy=='description desc' returns the print
servers sorted by description in descending order.
orgUnitId - If org_unit_id is present in the request, only print
servers owned or inherited by the organizational unit (OU) are returned.
If the PrintServer resource's org_unit_id matches the one in the
request, the OU owns the server. If org_unit_id is not specified in the
request, all print servers are returned or filtered against.
pageSize - The maximum number of objects to return (default 100, max
100). The service might return fewer than this value.
pageToken - A generated token to paginate results (the next_page_token
from a previous call).
$fields - Selector specifying which fields to include in a partial
response.
Completes with a ListPrintServersResponse.
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<ListPrintServersResponse> list(
core.String parent, {
core.String? filter,
core.String? orderBy,
core.String? orgUnitId,
core.int? pageSize,
core.String? pageToken,
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
'filter': ?filter == null ? null : [filter],
'orderBy': ?orderBy == null ? null : [orderBy],
'orgUnitId': ?orgUnitId == null ? null : [orgUnitId],
'pageSize': ?pageSize == null ? null : ['${pageSize}'],
'pageToken': ?pageToken == null ? null : [pageToken],
'fields': ?$fields == null ? null : [$fields],
};
final url_ =
'admin/directory/v1/' +
core.Uri.encodeFull('$parent') +
'/chrome/printServers';
final response_ = await _requester.request(
url_,
'GET',
queryParams: queryParams_,
);
return ListPrintServersResponse.fromJson(
response_ as core.Map<core.String, core.dynamic>,
);
}