1
A
回答
1
我想你指的是Retrieve all users in a domain:
要檢索所有的用戶在同一域中,請使用以下
GET
請求,包括Authorize requests描述的授權。爲了提高可讀性,這個例子使用換行符:
GET https://www.googleapis.com/admin/directory/v1/users
?domain=primary domain name&pageToken=token for next results page
&maxResults=max number of results per page
&orderBy=email, givenName, or familyName
&sortOrder=ascending or descending
&query=email, givenName, or familyName:the query's value*
默認情況下,系統會返回用戶的電子郵件地址的字母順序排列100個用戶的列表:
GET https://www.googleapis.com/admin/directory/v1/users?domain=example.com&maxResults=2
一個成功的響應返回一個HTTP 200 status code。隨着狀態代碼,響應返回example.com域中的2個用戶帳戶(maxResults=2
):
{
"kind": "directory#users",
"users": [
{
"kind": "directory#user",
"id": "the unique user id",
"primaryEmail": "[email protected]",
"name": {
"givenName": "Liz",
"familyName": "Smith",
"fullName": "Liz Smith"
},
"isAdmin": true,
"isDelegatedAdmin": false,
"lastLoginTime": "2013-02-05T10:30:03.325Z",
"creationTime": "2010-04-05T17:30:04.325Z",
"agreedToTerms": true,
"hashFunction: "SHA-1",
"suspended": false,
"changePasswordAtNextLogin": false,
"ipWhitelisted": false,
"ims": [
{
"type": "work",
"protocol": "gtalk",
"im": "[email protected]",
"primary": true
}
],
"emails": [
{
"address": "[email protected]",
"type": "work",
"customType": "",
"primary": true
}
],
"addresses": [
{
"type": "work",
"customType": "",
"streetAddress": "1600 Amphitheatre Parkway",
"locality": "Mountain View",
"region": "CA",
"postalCode": "94043"
}
],
"externalIds": [
{
"value": "employee number",
"type": "custom",
"customType": "office"
}
],
"relations": [
{
"value": "susan",
"type": "friend",
"customType": ""
}
],
"organizations": [
{
"name": "Google Inc.",
"title": "SWE",
"primary": true,
"customType": "",
"description": "Software engineer"
}
],
"phones": [
{
"value": "+1 nnn nnn nnnn",
"type": "work"
}
],
"aliases": [
"[email protected]",
"[email protected]"
],
"nonEditableAliases: [
"[email protected]"
],
"customerId": "C03az79cb",
"orgUnitPath": "corp/engineering",
"isMailboxSetup": true,
"includeInGlobalAddressList": true
},
{
"kind": "directory#user",
"id": "user unique ID",
"primaryEmail": "[email protected]",
"name": {
"givenName": "admin",
"familyName": "two",
"fullName": "admin two"
},
"isAdmin": true,
"isDelegatedAdmin": true,
"lastLoginTime": "2013-02-05T10:30:03.325Z",
"creationTime": "2010-04-05T17:30:04.325Z",
"agreedToTerms": true,
"hashFunction: "SHA-1",
"suspended": true,
"suspensionReason": "ADMIN",
"changePasswordAtNextLogin": false,
"ipWhitelisted": false,
"emails": [
{
"address": "[email protected]",
"type": "work",
"customType": "",
"primary": true
}
],
"externalIds": [
{
"value": "contractor license number",
"type": "custom",
"customType": "work"
}
],
"relations": [
{
"value": "liz",
"type": "friend",
"customType": ""
}
],
"aliases": [
"[email protected]"
],
"nonEditableAliases: [
"[email protected]"
],
"customerId": "C03az79cb",
"orgUnitPath": "corp/engineering",
"isMailboxSetup": true,
"includeInGlobalAddressList": true
}
],
"nextPageToken": "next page token"
}
您還可以檢查出Retrieve all account users
檢索所有用戶帳戶它可以由多個域組成,請使用以下
GET
請求幷包含Authorize requests中描述的授權。
相關問題
- 1. 如何在沒有域名的情況下獲取用戶名
- 2. 獲取用戶名按ID
- 3. SSO獲取用戶名/域
- 4. phpflickr - 如何通過所有者ID獲取照片所有者的用戶名?
- 5. 獲取所有ID和用戶名會籍ASP網MVC
- 6. 在AppEngine中使用gdata獲取域名的所有用戶名稱
- 7. 獲取用戶名和域名(域\用戶)在ASP.Net C#
- 8. 獲取用戶名和域名在C++
- 9. 所有的ID與用戶名 -
- 10. 可以通過Google +域名API獲取域名下的用戶列表?
- 11. 從它的ID獲取用戶名..?
- 12. 從特定羣組中的所有用戶獲取用戶名
- 13. 使用php獲取任何特定域名的所有baklink域名
- 14. 檢索所有的用戶(用戶ID和用戶名)
- 15. 從用戶獲取用戶名,其中id =「。$ row ['id']。''
- 16. 錯誤甚至後白名單域名獲取用戶ID從信使的WebView
- 17. Rails 3通過ID獲取用戶名
- 18. Codeigniter:獲取用戶名和ID
- 19. jQuery獲取所有ID頁
- 20. 獲取所有領域
- 21. 使用Javascript獲取爲域名打開的所有窗口
- 22. Apache捕獲所有域名並重定向並獲取域名作爲參數
- 23. 如何從WordPress登錄名或用戶名獲取用戶ID
- 24. LDAP通過用戶名和域名獲取用戶DN
- 25. 獲取當前用戶的YouTube內容所有者ID
- 26. 獲取所有用戶ID的朋友給unnexpected結果
- 27. 獲取來自AD域的所有用戶
- 28. 獲取Google App Engine中的所有域用戶
- 29. 獲取用戶ID
- 30. 沒有從codeigniter中的數據庫獲取用戶名和ID