Method: users.watch
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
उपयोगकर्ताओं की सूची में होने वाले बदलावों को देखता है.
एचटीटीपी अनुरोध
POST https://admin.googleapis.com/admin/directory/v1/users/watch
यूआरएल में gRPC ट्रांसकोडिंग सिंटैक्स का इस्तेमाल किया गया है.
क्वेरी पैरामीटर
पैरामीटर |
domain |
string
डोमेन का नाम. सिर्फ़ इस डोमेन के उपयोगकर्ताओं को शामिल करने के लिए, यह फ़ील्ड भरें. एक से ज़्यादा डोमेन वाले ग्राहक फ़ील्ड में सभी उपयोगकर्ताओं को दिखाने के लिए."
|
customer |
string
Google Workspace खाते का ऐसा आईडी जिसे बदला नहीं जा सकता. एक से ज़्यादा डोमेन के मामले में, किसी ग्राहक के सभी उपयोगकर्ताओं को फ़ेच करने के लिए, डोमेन के बजाय यह फ़ील्ड भरें.
|
event |
enum (EventType )
ऐसे इवेंट जिन पर ध्यान देना ज़रूरी है.
|
customFieldMask |
string
स्कीमा के नामों की कॉमा लगाकर अलग की गई सूची. इन स्कीमा के सभी फ़ील्ड फ़ेच किए जाते हैं. इसे सिर्फ़ तब सेट किया जाना चाहिए, जब projection=custom हो.
|
maxResults |
integer
कितने नतीजे दिखाने हैं.
|
orderBy |
enum (OrderBy )
नतीजों को क्रम से लगाने के लिए इस्तेमाल किया जाने वाला कॉलम
|
pageToken |
string
सूची में अगले पेज की जानकारी देने वाला टोकन
|
projection |
enum (Projection )
इस उपयोगकर्ता के लिए, फ़ील्ड का कौनसा सबसेट फ़ेच करना है.
|
query |
string
क्वेरी स्ट्रिंग खोज. यह "" फ़ॉर्मैट में होना चाहिए. पूरा दस्तावेज़ https: //developers.google.com/workspace/admin/directory/v1/guides/search-users पर उपलब्ध है
|
showDeleted |
string
अगर इस विकल्प को 'सही है' पर सेट किया जाता है, तो मिटाए गए उपयोगकर्ताओं की सूची वापस मिलती है. (डिफ़ॉल्ट: गलत)
|
sortOrder |
enum (SortOrder )
नतीजों को बढ़ते या घटते क्रम में दिखाना है या नहीं.
|
viewType |
enum (ViewType )
उपयोगकर्ता का सिर्फ़ एडमिन व्यू फ़ेच करना है या डोमेन के सभी उपयोगकर्ताओं के लिए उपलब्ध सार्वजनिक व्यू. ज़्यादा जानकारी के लिए, किसी उपयोगकर्ता को एडमिन के तौर पर वापस लाना लेख पढ़ें.
|
अनुरोध का मुख्य भाग
अनुरोध के मुख्य भाग में SubscriptionChannel
का उदाहरण है.
जवाब का मुख्य भाग
कामयाब रहने पर, जवाब के मुख्य हिस्से में SubscriptionChannel
का एक इंस्टेंस शामिल किया जाता है.
अनुमति के दायरे
इसके लिए, OAuth के इनमें से किसी एक स्कोप की ज़रूरत होती है:
https://www.googleapis.com/auth/admin.directory.user
https://www.googleapis.com/auth/admin.directory.user.readonly
https://www.googleapis.com/auth/cloud-platform
ज़्यादा जानकारी के लिए, अनुमति से जुड़ी गाइड देखें.
EventType
Enums |
ADD |
उपयोगकर्ता का बनाया हुआ इवेंट |
DELETE |
उपयोगकर्ता का खाता मिटाने से जुड़ा इवेंट |
MAKE_ADMIN |
उपयोगकर्ता के एडमिन स्टेटस में बदलाव होने का इवेंट |
UNDELETE |
उपयोगकर्ता को अनब्लॉक करने से जुड़ा इवेंट |
UPDATE |
उपयोगकर्ता की जानकारी अपडेट करने वाला इवेंट |
OrderBy
Enums |
EMAIL |
उपयोगकर्ता का प्राइमरी ईमेल पता. |
FAMILY_NAME |
उपयोगकर्ता का उपनाम. |
GIVEN_NAME |
उपयोगकर्ता का नाम. |
अनुमान
Enums |
BASIC |
उपयोगकर्ता के लिए कोई कस्टम फ़ील्ड शामिल न करें. |
CUSTOM |
customFieldMask में बताए गए स्कीमा से कस्टम फ़ील्ड शामिल करें. |
FULL |
इस उपयोगकर्ता से जुड़े सभी फ़ील्ड शामिल करें. |
SortOrder
Enums |
ASCENDING |
बढ़ते क्रम में. |
DESCENDING |
घटते क्रम में. |
ViewType
Enums |
admin_view |
नतीजों में, सिर्फ़ एडमिन के लिए उपलब्ध और डोमेन के लिए सार्वजनिक फ़ील्ड, दोनों शामिल होते हैं. |
domain_public |
नतीजों में, उपयोगकर्ता के सिर्फ़ वे फ़ील्ड शामिल होते हैं जो डोमेन के दूसरे उपयोगकर्ताओं को सार्वजनिक तौर पर दिखते हैं. |
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2025-07-25 (UTC) को अपडेट किया गया.
[null,null,["आखिरी बार 2025-07-25 (UTC) को अपडेट किया गया."],[],[],null,["# Method: users.watch\n\nWatches for changes in users list.\n\n### HTTP request\n\n`POST https://admin.googleapis.com/admin/directory/v1/users/watch`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Query parameters\n\n| Parameters ||\n|-------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `domain` | `string` Name of the domain. Fill this field to get users from only this domain. To return all users in a multi-domain fill customer field instead.\" |\n| `customer` | `string` Immutable ID of the Google Workspace account. In case of multi-domain, to fetch all users for a customer, fill this field instead of domain. |\n| `event` | `enum (`[EventType](/workspace/admin/directory/reference/rest/v1/users/watch#EventType)`)` Events to watch for. |\n| `customFieldMask` | `string` Comma-separated list of schema names. All fields from these schemas are fetched. This should only be set when projection=custom. |\n| `maxResults` | `integer` Maximum number of results to return. |\n| `orderBy` | `enum (`[OrderBy](/workspace/admin/directory/reference/rest/v1/users/watch#OrderBy)`)` Column to use for sorting results |\n| `pageToken` | `string` Token to specify next page in the list |\n| `projection` | `enum (`[Projection](/workspace/admin/directory/reference/rest/v1/users/watch#Projection)`)` What subset of fields to fetch for this user. |\n| `query` | `string` Query string search. Should be of the form \"\". Complete documentation is at https: //developers.google.com/workspace/admin/directory/v1/guides/search-users |\n| `showDeleted` | `string` If set to true, retrieves the list of deleted users. (Default: false) |\n| `sortOrder` | `enum (`[SortOrder](/workspace/admin/directory/reference/rest/v1/users/watch#SortOrder)`)` Whether to return results in ascending or descending order. |\n| `viewType` | `enum (`[ViewType](/workspace/admin/directory/reference/rest/v1/users/watch#ViewType)`)` Whether to fetch the administrator-only or domain-wide public view of the user. For more information, see [Retrieve a user as a non-administrator](https://developers.google.com/workspace/admin/directory/v1/guides/manage-users#retrieve_users_non_admin). |\n\n### Request body\n\nThe request body contains an instance of [SubscriptionChannel](/workspace/admin/directory/reference/rest/v1/SubscriptionChannel).\n\n### Response body\n\nIf successful, the response body contains an instance of [SubscriptionChannel](/workspace/admin/directory/reference/rest/v1/SubscriptionChannel).\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/admin.directory.user`\n- `\n https://www.googleapis.com/auth/admin.directory.user.readonly`\n- `\n https://www.googleapis.com/auth/cloud-platform`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent).\n\nEventType\n---------\n\nType of the Subscription event\n\n| Enums ||\n|--------------|--------------------------------|\n| `ADD` | User Created Event |\n| `DELETE` | User Deleted Event |\n| `MAKE_ADMIN` | User Admin Status Change Event |\n| `UNDELETE` | User Undeleted Event |\n| `UPDATE` | User Updated Event |\n\nOrderBy\n-------\n\n| Enums ||\n|---------------|----------------------------|\n| `EMAIL` | Primary email of the user. |\n| `FAMILY_NAME` | User's family name. |\n| `GIVEN_NAME` | User's given name. |\n\nProjection\n----------\n\n| Enums ||\n|----------|------------------------------------------------------------------|\n| `BASIC` | Do not include any custom fields for the user. |\n| `CUSTOM` | Include custom fields from schemas mentioned in customFieldMask. |\n| `FULL` | Include all fields associated with this user. |\n\nSortOrder\n---------\n\n| Enums ||\n|--------------|-------------------|\n| `ASCENDING` | Ascending order. |\n| `DESCENDING` | Descending order. |\n\nViewType\n--------\n\n| Enums ||\n|-----------------|--------------------------------------------------------------------------------------------------|\n| `admin_view` | Results include both administrator-only and domain-public fields. |\n| `domain_public` | Results only include fields for the user that are publicly visible to other users in the domain. |"]]