blob: 124750a12b359439d26a741c66383b5b7c432b76 [file] [log] [blame]
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +00001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
Nathaniel Manista4f877e52015-06-15 16:44:50 +000075<h1><a href="androidenterprise_v1.html">Google Play EMM API</a> . <a href="androidenterprise_v1.users.html">users</a></h1>
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +000076<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#generateToken">generateToken(enterpriseId, userId)</a></code></p>
79<p class="firstline">Generates a token (activation code) to allow this user to configure their work account in the Android Setup Wizard. Revokes any previously generated token.</p>
80<p class="toc_element">
81 <code><a href="#get">get(enterpriseId, userId)</a></code></p>
82<p class="firstline">Retrieves a user's details.</p>
83<p class="toc_element">
Takashi Matsuo06694102015-09-11 13:55:40 -070084 <code><a href="#getAvailableProductSet">getAvailableProductSet(enterpriseId, userId)</a></code></p>
85<p class="firstline">Retrieves the set of products a user is entitled to access.</p>
86<p class="toc_element">
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +000087 <code><a href="#list">list(enterpriseId, email)</a></code></p>
88<p class="firstline">Looks up a user by email address.</p>
89<p class="toc_element">
90 <code><a href="#revokeToken">revokeToken(enterpriseId, userId)</a></code></p>
91<p class="firstline">Revokes a previously generated token (activation code) for the user.</p>
Takashi Matsuo06694102015-09-11 13:55:40 -070092<p class="toc_element">
93 <code><a href="#setAvailableProductSet">setAvailableProductSet(enterpriseId, userId, body)</a></code></p>
94<p class="firstline">Modifies the set of products a user is entitled to access.</p>
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +000095<h3>Method Details</h3>
96<div class="method">
97 <code class="details" id="generateToken">generateToken(enterpriseId, userId)</code>
98 <pre>Generates a token (activation code) to allow this user to configure their work account in the Android Setup Wizard. Revokes any previously generated token.
99
100Args:
101 enterpriseId: string, The ID of the enterprise. (required)
102 userId: string, The ID of the user. (required)
103
104Returns:
105 An object of the form:
106
107 { # A UserToken is used by a user when setting up a managed device or profile with their work account on a device. When the user enters their email address and token (activation code) the appropriate MDM app can be automatically downloaded.
108 "kind": "androidenterprise#userToken", # Identifies what kind of resource this is. Value: the fixed string "androidenterprise#userToken".
109 "userId": "A String", # The unique ID for the user.
110 "token": "A String", # The token (activation code) to be entered by the user. This consists of a sequence of decimal digits. Note that the leading digit may be 0.
111 }</pre>
112</div>
113
114<div class="method">
115 <code class="details" id="get">get(enterpriseId, userId)</code>
116 <pre>Retrieves a user's details.
117
118Args:
119 enterpriseId: string, The ID of the enterprise. (required)
120 userId: string, The ID of the user. (required)
121
122Returns:
123 An object of the form:
124
125 { # A user resource represents an individual user within the enterprise's domain.
126 #
127 # Note that each user is associated with a Google account based on the user's corporate email address (which must be in one of the enterprise's domains). As part of installing an MDM app to manage a device the Google account must be provisioned to the device, and so the user resource must be created before that. This can be done using the Google Admin SDK Directory API.
128 #
129 # The ID for a user is an opaque string. It can be retrieved using the list method queried by the user's primary email address.
130 "kind": "androidenterprise#user", # Identifies what kind of resource this is. Value: the fixed string "androidenterprise#user".
131 "primaryEmail": "A String", # The user's primary email, e.g. "jsmith@example.com".
132 "id": "A String", # The unique ID for the user.
133 }</pre>
134</div>
135
136<div class="method">
Takashi Matsuo06694102015-09-11 13:55:40 -0700137 <code class="details" id="getAvailableProductSet">getAvailableProductSet(enterpriseId, userId)</code>
138 <pre>Retrieves the set of products a user is entitled to access.
139
140Args:
141 enterpriseId: string, The ID of the enterprise. (required)
142 userId: string, The ID of the user. (required)
143
144Returns:
145 An object of the form:
146
147 { # A set of products.
148 "kind": "androidenterprise#productSet", # Identifies what kind of resource this is. Value: the fixed string "androidenterprise#productSet".
149 "productId": [ # The list of product IDs making up the set of products.
150 "A String",
151 ],
152 }</pre>
153</div>
154
155<div class="method">
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000156 <code class="details" id="list">list(enterpriseId, email)</code>
157 <pre>Looks up a user by email address.
158
159Args:
160 enterpriseId: string, The ID of the enterprise. (required)
161 email: string, The exact primary email address of the user to look up. (required)
162
163Returns:
164 An object of the form:
165
166 { # The matching user resources.
167 "kind": "androidenterprise#usersListResponse", # Identifies what kind of resource this is. Value: the fixed string "androidenterprise#usersListResponse".
168 "user": [ # A user of an enterprise.
169 { # A user resource represents an individual user within the enterprise's domain.
170 #
171 # Note that each user is associated with a Google account based on the user's corporate email address (which must be in one of the enterprise's domains). As part of installing an MDM app to manage a device the Google account must be provisioned to the device, and so the user resource must be created before that. This can be done using the Google Admin SDK Directory API.
172 #
173 # The ID for a user is an opaque string. It can be retrieved using the list method queried by the user's primary email address.
174 "kind": "androidenterprise#user", # Identifies what kind of resource this is. Value: the fixed string "androidenterprise#user".
175 "primaryEmail": "A String", # The user's primary email, e.g. "jsmith@example.com".
176 "id": "A String", # The unique ID for the user.
177 },
178 ],
179 }</pre>
180</div>
181
182<div class="method">
183 <code class="details" id="revokeToken">revokeToken(enterpriseId, userId)</code>
184 <pre>Revokes a previously generated token (activation code) for the user.
185
186Args:
187 enterpriseId: string, The ID of the enterprise. (required)
188 userId: string, The ID of the user. (required)
189</pre>
190</div>
191
Takashi Matsuo06694102015-09-11 13:55:40 -0700192<div class="method">
193 <code class="details" id="setAvailableProductSet">setAvailableProductSet(enterpriseId, userId, body)</code>
194 <pre>Modifies the set of products a user is entitled to access.
195
196Args:
197 enterpriseId: string, The ID of the enterprise. (required)
198 userId: string, The ID of the user. (required)
199 body: object, The request body. (required)
200 The object takes the form of:
201
202{ # A set of products.
203 "kind": "androidenterprise#productSet", # Identifies what kind of resource this is. Value: the fixed string "androidenterprise#productSet".
204 "productId": [ # The list of product IDs making up the set of products.
205 "A String",
206 ],
207 }
208
209
210Returns:
211 An object of the form:
212
213 { # A set of products.
214 "kind": "androidenterprise#productSet", # Identifies what kind of resource this is. Value: the fixed string "androidenterprise#productSet".
215 "productId": [ # The list of product IDs making up the set of products.
216 "A String",
217 ],
218 }</pre>
219</div>
220
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000221</body></html>