Method: enterprises.enrollmentTokens.list
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
แสดงรายการโทเค็นการลงทะเบียนที่ใช้งานอยู่และยังไม่หมดอายุขององค์กรหนึ่งๆ รายการในลิสต์มีเพียงมุมมองบางส่วนของออบเจ็กต์ EnrollmentToken ระบบจะป้อนข้อมูลในช่องต่อไปนี้เท่านั้น name
, expirationTimestamp
, allowPersonalUsage
, value
, qrCode
วิธีนี้มีไว้เพื่อช่วยจัดการวงจรของโทเค็นการลงทะเบียนที่ใช้งานอยู่ เราขอแนะนำให้delete
โทเค็นการลงทะเบียนที่ใช้งานอยู่ทันทีที่ไม่ต้องการใช้อีกต่อไปเพื่อความปลอดภัย
คำขอ HTTP
GET https://androidmanagement.googleapis.com/v1/{parent=enterprises/*}/enrollmentTokens
URL ใช้ไวยากรณ์การแปลง gRPC
พารามิเตอร์เส้นทาง
พารามิเตอร์ |
parent |
string
ต้องระบุ ชื่อองค์กรในรูปแบบ enterprises/{enterpriseId}
|
พารามิเตอร์การค้นหา
พารามิเตอร์ |
pageSize |
integer
ขนาดหน้าเว็บที่ขอ บริการอาจแสดงผลน้อยกว่าค่านี้ หากไม่ระบุ ระบบจะแสดงผลรายการสูงสุด 10 รายการ ค่าสูงสุดคือ 100 ค่าที่มากกว่า 100 จะเปลี่ยนเป็น 100
|
pageToken |
string
โทเค็นที่ระบุหน้าผลการค้นหาที่เซิร์ฟเวอร์แสดง
|
เนื้อหาของคำขอ
เนื้อหาของคำขอต้องว่างเปล่า
เนื้อหาการตอบกลับ
การตอบสนองต่อคำขอแสดงโทเค็นการลงทะเบียนสำหรับองค์กรหนึ่งๆ
หากทำสำเร็จ เนื้อหาการตอบกลับจะมีข้อมูลซึ่งมีโครงสร้างดังต่อไปนี้
การแสดง JSON |
{
"enrollmentTokens": [
{
object (EnrollmentToken )
}
],
"nextPageToken": string
} |
ช่อง |
enrollmentTokens[] |
object (EnrollmentToken )
รายการโทเค็นการลงทะเบียน
|
nextPageToken |
string
หากมีผลการค้นหาเพิ่มเติม โทเค็นเพื่อดึงข้อมูลหน้าถัดไปของผลการค้นหา
|
ขอบเขตการให้สิทธิ์
ต้องใช้ขอบเขต OAuth ต่อไปนี้
https://www.googleapis.com/auth/androidmanagement
ดูข้อมูลเพิ่มเติมได้ที่ OAuth 2.0 Overview
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-07-26 UTC
[null,null,["อัปเดตล่าสุด 2025-07-26 UTC"],[[["\u003cp\u003eThis operation lists active, unexpired enrollment tokens for a given enterprise, providing a partial view of the EnrollmentToken object with specific fields populated.\u003c/p\u003e\n"],["\u003cp\u003eThe request requires the enterprise ID as a path parameter and allows for pagination using query parameters \u003ccode\u003epageSize\u003c/code\u003e and \u003ccode\u003epageToken\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe response includes a list of enrollment tokens and a token for retrieving the next page of results if available.\u003c/p\u003e\n"],["\u003cp\u003eFor security, it is recommended to delete active enrollment tokens when they are no longer needed.\u003c/p\u003e\n"],["\u003cp\u003eAuthorization requires the \u003ccode\u003ehttps://www.googleapis.com/auth/androidmanagement\u003c/code\u003e OAuth scope.\u003c/p\u003e\n"]]],["This document outlines the process of listing active enrollment tokens for an enterprise using a `GET` request. The request targets `enterprises/{enterpriseId}/enrollmentTokens` and requires a `parent` path parameter specifying the enterprise ID. Optional query parameters, `pageSize` and `pageToken`, manage result pagination. The request body must be empty. A successful response includes a list of `enrollmentTokens`, containing fields like name, expiration, usage allowance, value and qr code, and an optional `nextPageToken` for subsequent pages. This action requires the `androidmanagement` OAuth scope.\n"],null,["# Method: enterprises.enrollmentTokens.list\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n - [JSON representation](#body.ListEnrollmentTokensResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nLists active, unexpired enrollment tokens for a given enterprise. The list items contain only a partial view of EnrollmentToken object. Only the following fields are populated: [`name`](/android/management/reference/rest/v1/enterprises.enrollmentTokens#EnrollmentToken.FIELDS.name), [`expirationTimestamp`](/android/management/reference/rest/v1/enterprises.enrollmentTokens#EnrollmentToken.FIELDS.expiration_timestamp), [`allowPersonalUsage`](/android/management/reference/rest/v1/enterprises.enrollmentTokens#EnrollmentToken.FIELDS.allow_personal_usage), [`value`](/android/management/reference/rest/v1/enterprises.enrollmentTokens#EnrollmentToken.FIELDS.value), [`qrCode`](/android/management/reference/rest/v1/enterprises.enrollmentTokens#EnrollmentToken.FIELDS.qr_code). This method is meant to help manage active enrollment tokens lifecycle. For security reasons, it's recommended to [delete](/android/management/reference/rest/v1/enterprises.enrollmentTokens/delete#google.android.devicemanagement.v1.DeviceManagementService.DeleteEnrollmentToken) active enrollment tokens as soon as they're not intended to be used anymore.\n\n### HTTP request\n\n`GET https://androidmanagement.googleapis.com/v1/{parent=enterprises/*}/enrollmentTokens`\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 enterprise in the form `enterprises/{enterpriseId}`. |\n\n### Query parameters\n\n| Parameters ||\n|-------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `pageSize` | `integer` The requested page size. The service may return fewer than this value. If unspecified, at most 10 items will be returned. The maximum value is 100; values above 100 will be coerced to 100. |\n| `pageToken` | `string` A token identifying a page of results returned by the server. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nResponse to a request to list enrollment tokens for a given enterprise.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"enrollmentTokens\": [ { object (/android/management/reference/rest/v1/enterprises.enrollmentTokens#EnrollmentToken) } ], \"nextPageToken\": string } ``` |\n\n| Fields ||\n|----------------------|---------------------------------------------------------------------------------------------------------------------------------------------------|\n| `enrollmentTokens[]` | `object (`[EnrollmentToken](/android/management/reference/rest/v1/enterprises.enrollmentTokens#EnrollmentToken)`)` The list of enrollment tokens. |\n| `nextPageToken` | `string` If there are more results, a token to retrieve next page of results. |\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/androidmanagement`\n\nFor more information, see the [OAuth 2.0 Overview](/identity/protocols/OAuth2)."]]