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>>{
if (filter != null) 'filter': [filter],
if (orderBy != null) 'orderBy': [orderBy],
if (orgUnitId != null) 'orgUnitId': [orgUnitId],
if (pageSize != null) 'pageSize': ['${pageSize}'],
if (pageToken != null) 'pageToken': [pageToken],
if ($fields != null) 'fields': [$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>);
}