Method: admin.directory.v1.customers.chrome.printers.list
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
HTTP 请求
GET https://admin.googleapis.com/admin/directory/v1/{parent=customers/*}/chrome/printers
网址采用 gRPC 转码语法。
路径参数
参数 |
parent |
string
必需。拥有此打印机集合的客户的名称。格式:customers/{customer_id}
|
查询参数
参数 |
pageSize |
integer
要返回的最大对象数。服务返回的值可能小于此值。
|
pageToken |
string
从上一个调用收到的页面令牌。
|
orgUnitId |
string
我们要为其列出打印机的组织部门。如果请求中不存在 org_unit,则会返回(或过滤)客户的所有打印机。 如果请求中存在 org_unit,则系统只会返回此 OU 可用的打印机(自有或继承)。您可以通过查看 Printer.org_unit_id,了解打印机是归此 OU 所有还是继承自此 OU。
|
filter |
string
搜索查询。此 API 和管理控制台打印机页面之间共用搜索语法。
|
orderBy |
string
结果的排序顺序。必须是 displayName、description、makeAndModel 或 createTime 中的一种。默认顺序为升序,但您可以通过将“desc”附加到 orderBy 字段来返回降序。例如,“description desc”会返回按说明降序排序的打印机。
|
响应正文
用于列出打印机的响应。
如果成功,响应正文将包含结构如下的数据:
JSON 表示法 |
{
"printers": [
{
object (Printer )
}
],
"nextPageToken": string
} |
字段 |
printers[] |
object (Printer )
打印机列表。如果请求中提供了 orgUnitId ,则系统只会返回此 OU 可见的打印机。如果请求中未指定 orgUnitId ,则系统会返回所有打印机。
|
nextPageToken |
string
可作为 pageToken 发送并用于检索下一页的令牌。如果省略此字段,则不存在后续页面。
|
授权范围
需要以下 OAuth 范围之一:
https://www.googleapis.com/auth/admin.chrome.printers
https://www.googleapis.com/auth/admin.chrome.printers.readonly
如需了解详情,请参阅授权指南。
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-07-24。
[null,null,["最后更新时间 (UTC):2025-07-24。"],[],[],null,["# Method: admin.directory.v1.customers.chrome.printers.list\n\nList printers configs.\n\n### HTTP request\n\n`GET https://admin.googleapis.com/admin/directory/v1/{parent=customers/*}/chrome/printers`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|----------|-------------------------------------------------------------------------------------------------------------------|\n| `parent` | `string` Required. The name of the customer who owns this collection of printers. Format: customers/{customer_id} |\n\n### Query parameters\n\n| Parameters ||\n|-------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `pageSize` | `integer` The maximum number of objects to return. The service may return fewer than this value. |\n| `pageToken` | `string` A page token, received from a previous call. |\n| `orgUnitId` | `string` Organization Unit that we want to list the printers for. When org_unit is not present in the request then all printers of the customer are returned (or filtered). When org_unit is present in the request then only printers available to this OU will be returned (owned or inherited). You may see if printer is owned or inherited for this OU by looking at Printer.org_unit_id. |\n| `filter` | `string` Search query. Search syntax is shared between this api and Admin Console printers pages. |\n| `orderBy` | `string` The order to sort results by. Must be one of displayName, description, makeAndModel, or createTime. Default order is ascending, but descending order can be returned by appending \"desc\" to the orderBy field. For instance, \"description desc\" will return the printers sorted by description in descending order. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nResponse for listing printers.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"printers\": [ { object (/workspace/admin/chrome-printer/reference/rest/v1/admin.directory.v1.customers.chrome.printers#Printer) } ], \"nextPageToken\": string } ``` |\n\n| Fields ||\n|-----------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `printers[]` | `object (`[Printer](/workspace/admin/chrome-printer/reference/rest/v1/admin.directory.v1.customers.chrome.printers#Printer)`)` List of printers. If `orgUnitId` was given in the request, then only printers visible for this OU will be returned. If `orgUnitId` was not given in the request, then all printers will be returned. |\n| `nextPageToken` | `string` A token, which can be sent as `pageToken` to retrieve the next page. If this field is omitted, there are no subsequent pages. |\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/admin.chrome.printers`\n- `\n https://www.googleapis.com/auth/admin.chrome.printers.readonly`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent)."]]