| OLD | NEW |
| 1 // This is a generated file (see the discoveryapis_generator project). | 1 // This is a generated file (see the discoveryapis_generator project). |
| 2 | 2 |
| 3 library googleapis.androidenterprise.v1; | 3 library googleapis.androidenterprise.v1; |
| 4 | 4 |
| 5 import 'dart:core' as core; | 5 import 'dart:core' as core; |
| 6 import 'dart:async' as async; | 6 import 'dart:async' as async; |
| 7 import 'dart:convert' as convert; | 7 import 'dart:convert' as convert; |
| 8 | 8 |
| 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; | 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
| 10 import 'package:http/http.dart' as http; | 10 import 'package:http/http.dart' as http; |
| 11 | 11 |
| 12 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show | 12 export 'package:_discoveryapis_commons/_discoveryapis_commons.dart' show |
| 13 ApiRequestError, DetailedApiRequestError; | 13 ApiRequestError, DetailedApiRequestError; |
| 14 | 14 |
| 15 const core.String USER_AGENT = 'dart-api-client androidenterprise/v1'; | 15 const core.String USER_AGENT = 'dart-api-client androidenterprise/v1'; |
| 16 | 16 |
| 17 /** Manages the deployment of apps to Android for Work users. */ | 17 /** Manages the deployment of apps to Android for Work users. */ |
| 18 class AndroidenterpriseApi { | 18 class AndroidenterpriseApi { |
| 19 /** Manage corporate Android devices */ | 19 /** Manage corporate Android devices */ |
| 20 static const AndroidenterpriseScope = "https://www.googleapis.com/auth/android
enterprise"; | 20 static const AndroidenterpriseScope = "https://www.googleapis.com/auth/android
enterprise"; |
| 21 | 21 |
| 22 | 22 |
| 23 final commons.ApiRequester _requester; | 23 final commons.ApiRequester _requester; |
| 24 | 24 |
| 25 CollectionsResourceApi get collections => new CollectionsResourceApi(_requeste
r); | |
| 26 CollectionviewersResourceApi get collectionviewers => new CollectionviewersRes
ourceApi(_requester); | |
| 27 DevicesResourceApi get devices => new DevicesResourceApi(_requester); | 25 DevicesResourceApi get devices => new DevicesResourceApi(_requester); |
| 28 EnterprisesResourceApi get enterprises => new EnterprisesResourceApi(_requeste
r); | 26 EnterprisesResourceApi get enterprises => new EnterprisesResourceApi(_requeste
r); |
| 29 EntitlementsResourceApi get entitlements => new EntitlementsResourceApi(_reque
ster); | 27 EntitlementsResourceApi get entitlements => new EntitlementsResourceApi(_reque
ster); |
| 30 GrouplicensesResourceApi get grouplicenses => new GrouplicensesResourceApi(_re
quester); | 28 GrouplicensesResourceApi get grouplicenses => new GrouplicensesResourceApi(_re
quester); |
| 31 GrouplicenseusersResourceApi get grouplicenseusers => new GrouplicenseusersRes
ourceApi(_requester); | 29 GrouplicenseusersResourceApi get grouplicenseusers => new GrouplicenseusersRes
ourceApi(_requester); |
| 32 InstallsResourceApi get installs => new InstallsResourceApi(_requester); | 30 InstallsResourceApi get installs => new InstallsResourceApi(_requester); |
| 33 ManagedconfigurationsfordeviceResourceApi get managedconfigurationsfordevice =
> new ManagedconfigurationsfordeviceResourceApi(_requester); | 31 ManagedconfigurationsfordeviceResourceApi get managedconfigurationsfordevice =
> new ManagedconfigurationsfordeviceResourceApi(_requester); |
| 34 ManagedconfigurationsforuserResourceApi get managedconfigurationsforuser => ne
w ManagedconfigurationsforuserResourceApi(_requester); | 32 ManagedconfigurationsforuserResourceApi get managedconfigurationsforuser => ne
w ManagedconfigurationsforuserResourceApi(_requester); |
| 35 PermissionsResourceApi get permissions => new PermissionsResourceApi(_requeste
r); | 33 PermissionsResourceApi get permissions => new PermissionsResourceApi(_requeste
r); |
| 36 ProductsResourceApi get products => new ProductsResourceApi(_requester); | 34 ProductsResourceApi get products => new ProductsResourceApi(_requester); |
| 37 ServiceaccountkeysResourceApi get serviceaccountkeys => new Serviceaccountkeys
ResourceApi(_requester); | 35 ServiceaccountkeysResourceApi get serviceaccountkeys => new Serviceaccountkeys
ResourceApi(_requester); |
| 38 StorelayoutclustersResourceApi get storelayoutclusters => new Storelayoutclust
ersResourceApi(_requester); | 36 StorelayoutclustersResourceApi get storelayoutclusters => new Storelayoutclust
ersResourceApi(_requester); |
| 39 StorelayoutpagesResourceApi get storelayoutpages => new StorelayoutpagesResour
ceApi(_requester); | 37 StorelayoutpagesResourceApi get storelayoutpages => new StorelayoutpagesResour
ceApi(_requester); |
| 40 UsersResourceApi get users => new UsersResourceApi(_requester); | 38 UsersResourceApi get users => new UsersResourceApi(_requester); |
| 41 | 39 |
| 42 AndroidenterpriseApi(http.Client client, {core.String rootUrl: "https://www.go
ogleapis.com/", core.String servicePath: "androidenterprise/v1/"}) : | 40 AndroidenterpriseApi(http.Client client, {core.String rootUrl: "https://www.go
ogleapis.com/", core.String servicePath: "androidenterprise/v1/"}) : |
| 43 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A
GENT); | 41 _requester = new commons.ApiRequester(client, rootUrl, servicePath, USER_A
GENT); |
| 44 } | 42 } |
| 45 | 43 |
| 46 | 44 |
| 47 class CollectionsResourceApi { | |
| 48 final commons.ApiRequester _requester; | |
| 49 | |
| 50 CollectionsResourceApi(commons.ApiRequester client) : | |
| 51 _requester = client; | |
| 52 | |
| 53 /** | |
| 54 * Deletes a collection. | |
| 55 * | |
| 56 * Request parameters: | |
| 57 * | |
| 58 * [enterpriseId] - The ID of the enterprise. | |
| 59 * | |
| 60 * [collectionId] - The ID of the collection. | |
| 61 * | |
| 62 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 63 * error. | |
| 64 * | |
| 65 * If the used [http.Client] completes with an error when making a REST call, | |
| 66 * this method will complete with the same error. | |
| 67 */ | |
| 68 async.Future delete(core.String enterpriseId, core.String collectionId) { | |
| 69 var _url = null; | |
| 70 var _queryParams = new core.Map(); | |
| 71 var _uploadMedia = null; | |
| 72 var _uploadOptions = null; | |
| 73 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 74 var _body = null; | |
| 75 | |
| 76 if (enterpriseId == null) { | |
| 77 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 78 } | |
| 79 if (collectionId == null) { | |
| 80 throw new core.ArgumentError("Parameter collectionId is required."); | |
| 81 } | |
| 82 | |
| 83 _downloadOptions = null; | |
| 84 | |
| 85 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections/' + commons.Escaper.ecapeVariable('$collectionId'); | |
| 86 | |
| 87 var _response = _requester.request(_url, | |
| 88 "DELETE", | |
| 89 body: _body, | |
| 90 queryParams: _queryParams, | |
| 91 uploadOptions: _uploadOptions, | |
| 92 uploadMedia: _uploadMedia, | |
| 93 downloadOptions: _downloadOptions); | |
| 94 return _response.then((data) => null); | |
| 95 } | |
| 96 | |
| 97 /** | |
| 98 * Retrieves the details of a collection. | |
| 99 * | |
| 100 * Request parameters: | |
| 101 * | |
| 102 * [enterpriseId] - The ID of the enterprise. | |
| 103 * | |
| 104 * [collectionId] - The ID of the collection. | |
| 105 * | |
| 106 * Completes with a [Collection]. | |
| 107 * | |
| 108 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 109 * error. | |
| 110 * | |
| 111 * If the used [http.Client] completes with an error when making a REST call, | |
| 112 * this method will complete with the same error. | |
| 113 */ | |
| 114 async.Future<Collection> get(core.String enterpriseId, core.String collectionI
d) { | |
| 115 var _url = null; | |
| 116 var _queryParams = new core.Map(); | |
| 117 var _uploadMedia = null; | |
| 118 var _uploadOptions = null; | |
| 119 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 120 var _body = null; | |
| 121 | |
| 122 if (enterpriseId == null) { | |
| 123 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 124 } | |
| 125 if (collectionId == null) { | |
| 126 throw new core.ArgumentError("Parameter collectionId is required."); | |
| 127 } | |
| 128 | |
| 129 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections/' + commons.Escaper.ecapeVariable('$collectionId'); | |
| 130 | |
| 131 var _response = _requester.request(_url, | |
| 132 "GET", | |
| 133 body: _body, | |
| 134 queryParams: _queryParams, | |
| 135 uploadOptions: _uploadOptions, | |
| 136 uploadMedia: _uploadMedia, | |
| 137 downloadOptions: _downloadOptions); | |
| 138 return _response.then((data) => new Collection.fromJson(data)); | |
| 139 } | |
| 140 | |
| 141 /** | |
| 142 * Creates a new collection. | |
| 143 * | |
| 144 * [request] - The metadata request object. | |
| 145 * | |
| 146 * Request parameters: | |
| 147 * | |
| 148 * [enterpriseId] - The ID of the enterprise. | |
| 149 * | |
| 150 * Completes with a [Collection]. | |
| 151 * | |
| 152 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 153 * error. | |
| 154 * | |
| 155 * If the used [http.Client] completes with an error when making a REST call, | |
| 156 * this method will complete with the same error. | |
| 157 */ | |
| 158 async.Future<Collection> insert(Collection request, core.String enterpriseId)
{ | |
| 159 var _url = null; | |
| 160 var _queryParams = new core.Map(); | |
| 161 var _uploadMedia = null; | |
| 162 var _uploadOptions = null; | |
| 163 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 164 var _body = null; | |
| 165 | |
| 166 if (request != null) { | |
| 167 _body = convert.JSON.encode((request).toJson()); | |
| 168 } | |
| 169 if (enterpriseId == null) { | |
| 170 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 171 } | |
| 172 | |
| 173 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections'; | |
| 174 | |
| 175 var _response = _requester.request(_url, | |
| 176 "POST", | |
| 177 body: _body, | |
| 178 queryParams: _queryParams, | |
| 179 uploadOptions: _uploadOptions, | |
| 180 uploadMedia: _uploadMedia, | |
| 181 downloadOptions: _downloadOptions); | |
| 182 return _response.then((data) => new Collection.fromJson(data)); | |
| 183 } | |
| 184 | |
| 185 /** | |
| 186 * Retrieves the IDs of all the collections for an enterprise. | |
| 187 * | |
| 188 * Request parameters: | |
| 189 * | |
| 190 * [enterpriseId] - The ID of the enterprise. | |
| 191 * | |
| 192 * Completes with a [CollectionsListResponse]. | |
| 193 * | |
| 194 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 195 * error. | |
| 196 * | |
| 197 * If the used [http.Client] completes with an error when making a REST call, | |
| 198 * this method will complete with the same error. | |
| 199 */ | |
| 200 async.Future<CollectionsListResponse> list(core.String enterpriseId) { | |
| 201 var _url = null; | |
| 202 var _queryParams = new core.Map(); | |
| 203 var _uploadMedia = null; | |
| 204 var _uploadOptions = null; | |
| 205 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 206 var _body = null; | |
| 207 | |
| 208 if (enterpriseId == null) { | |
| 209 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 210 } | |
| 211 | |
| 212 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections'; | |
| 213 | |
| 214 var _response = _requester.request(_url, | |
| 215 "GET", | |
| 216 body: _body, | |
| 217 queryParams: _queryParams, | |
| 218 uploadOptions: _uploadOptions, | |
| 219 uploadMedia: _uploadMedia, | |
| 220 downloadOptions: _downloadOptions); | |
| 221 return _response.then((data) => new CollectionsListResponse.fromJson(data)); | |
| 222 } | |
| 223 | |
| 224 /** | |
| 225 * Updates a collection. This method supports patch semantics. | |
| 226 * | |
| 227 * [request] - The metadata request object. | |
| 228 * | |
| 229 * Request parameters: | |
| 230 * | |
| 231 * [enterpriseId] - The ID of the enterprise. | |
| 232 * | |
| 233 * [collectionId] - The ID of the collection. | |
| 234 * | |
| 235 * Completes with a [Collection]. | |
| 236 * | |
| 237 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 238 * error. | |
| 239 * | |
| 240 * If the used [http.Client] completes with an error when making a REST call, | |
| 241 * this method will complete with the same error. | |
| 242 */ | |
| 243 async.Future<Collection> patch(Collection request, core.String enterpriseId, c
ore.String collectionId) { | |
| 244 var _url = null; | |
| 245 var _queryParams = new core.Map(); | |
| 246 var _uploadMedia = null; | |
| 247 var _uploadOptions = null; | |
| 248 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 249 var _body = null; | |
| 250 | |
| 251 if (request != null) { | |
| 252 _body = convert.JSON.encode((request).toJson()); | |
| 253 } | |
| 254 if (enterpriseId == null) { | |
| 255 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 256 } | |
| 257 if (collectionId == null) { | |
| 258 throw new core.ArgumentError("Parameter collectionId is required."); | |
| 259 } | |
| 260 | |
| 261 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections/' + commons.Escaper.ecapeVariable('$collectionId'); | |
| 262 | |
| 263 var _response = _requester.request(_url, | |
| 264 "PATCH", | |
| 265 body: _body, | |
| 266 queryParams: _queryParams, | |
| 267 uploadOptions: _uploadOptions, | |
| 268 uploadMedia: _uploadMedia, | |
| 269 downloadOptions: _downloadOptions); | |
| 270 return _response.then((data) => new Collection.fromJson(data)); | |
| 271 } | |
| 272 | |
| 273 /** | |
| 274 * Updates a collection. | |
| 275 * | |
| 276 * [request] - The metadata request object. | |
| 277 * | |
| 278 * Request parameters: | |
| 279 * | |
| 280 * [enterpriseId] - The ID of the enterprise. | |
| 281 * | |
| 282 * [collectionId] - The ID of the collection. | |
| 283 * | |
| 284 * Completes with a [Collection]. | |
| 285 * | |
| 286 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 287 * error. | |
| 288 * | |
| 289 * If the used [http.Client] completes with an error when making a REST call, | |
| 290 * this method will complete with the same error. | |
| 291 */ | |
| 292 async.Future<Collection> update(Collection request, core.String enterpriseId,
core.String collectionId) { | |
| 293 var _url = null; | |
| 294 var _queryParams = new core.Map(); | |
| 295 var _uploadMedia = null; | |
| 296 var _uploadOptions = null; | |
| 297 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 298 var _body = null; | |
| 299 | |
| 300 if (request != null) { | |
| 301 _body = convert.JSON.encode((request).toJson()); | |
| 302 } | |
| 303 if (enterpriseId == null) { | |
| 304 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 305 } | |
| 306 if (collectionId == null) { | |
| 307 throw new core.ArgumentError("Parameter collectionId is required."); | |
| 308 } | |
| 309 | |
| 310 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections/' + commons.Escaper.ecapeVariable('$collectionId'); | |
| 311 | |
| 312 var _response = _requester.request(_url, | |
| 313 "PUT", | |
| 314 body: _body, | |
| 315 queryParams: _queryParams, | |
| 316 uploadOptions: _uploadOptions, | |
| 317 uploadMedia: _uploadMedia, | |
| 318 downloadOptions: _downloadOptions); | |
| 319 return _response.then((data) => new Collection.fromJson(data)); | |
| 320 } | |
| 321 | |
| 322 } | |
| 323 | |
| 324 | |
| 325 class CollectionviewersResourceApi { | |
| 326 final commons.ApiRequester _requester; | |
| 327 | |
| 328 CollectionviewersResourceApi(commons.ApiRequester client) : | |
| 329 _requester = client; | |
| 330 | |
| 331 /** | |
| 332 * Removes the user from the list of those specifically allowed to see the | |
| 333 * collection. If the collection's visibility is set to viewersOnly then only | |
| 334 * such users will see the collection. | |
| 335 * | |
| 336 * Request parameters: | |
| 337 * | |
| 338 * [enterpriseId] - The ID of the enterprise. | |
| 339 * | |
| 340 * [collectionId] - The ID of the collection. | |
| 341 * | |
| 342 * [userId] - The ID of the user. | |
| 343 * | |
| 344 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 345 * error. | |
| 346 * | |
| 347 * If the used [http.Client] completes with an error when making a REST call, | |
| 348 * this method will complete with the same error. | |
| 349 */ | |
| 350 async.Future delete(core.String enterpriseId, core.String collectionId, core.S
tring userId) { | |
| 351 var _url = null; | |
| 352 var _queryParams = new core.Map(); | |
| 353 var _uploadMedia = null; | |
| 354 var _uploadOptions = null; | |
| 355 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 356 var _body = null; | |
| 357 | |
| 358 if (enterpriseId == null) { | |
| 359 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 360 } | |
| 361 if (collectionId == null) { | |
| 362 throw new core.ArgumentError("Parameter collectionId is required."); | |
| 363 } | |
| 364 if (userId == null) { | |
| 365 throw new core.ArgumentError("Parameter userId is required."); | |
| 366 } | |
| 367 | |
| 368 _downloadOptions = null; | |
| 369 | |
| 370 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections/' + commons.Escaper.ecapeVariable('$collectionId') + '/users/' + comm
ons.Escaper.ecapeVariable('$userId'); | |
| 371 | |
| 372 var _response = _requester.request(_url, | |
| 373 "DELETE", | |
| 374 body: _body, | |
| 375 queryParams: _queryParams, | |
| 376 uploadOptions: _uploadOptions, | |
| 377 uploadMedia: _uploadMedia, | |
| 378 downloadOptions: _downloadOptions); | |
| 379 return _response.then((data) => null); | |
| 380 } | |
| 381 | |
| 382 /** | |
| 383 * Retrieves the ID of the user if they have been specifically allowed to see | |
| 384 * the collection. If the collection's visibility is set to viewersOnly then | |
| 385 * only these users will see the collection. | |
| 386 * | |
| 387 * Request parameters: | |
| 388 * | |
| 389 * [enterpriseId] - The ID of the enterprise. | |
| 390 * | |
| 391 * [collectionId] - The ID of the collection. | |
| 392 * | |
| 393 * [userId] - The ID of the user. | |
| 394 * | |
| 395 * Completes with a [User]. | |
| 396 * | |
| 397 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 398 * error. | |
| 399 * | |
| 400 * If the used [http.Client] completes with an error when making a REST call, | |
| 401 * this method will complete with the same error. | |
| 402 */ | |
| 403 async.Future<User> get(core.String enterpriseId, core.String collectionId, cor
e.String userId) { | |
| 404 var _url = null; | |
| 405 var _queryParams = new core.Map(); | |
| 406 var _uploadMedia = null; | |
| 407 var _uploadOptions = null; | |
| 408 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 409 var _body = null; | |
| 410 | |
| 411 if (enterpriseId == null) { | |
| 412 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 413 } | |
| 414 if (collectionId == null) { | |
| 415 throw new core.ArgumentError("Parameter collectionId is required."); | |
| 416 } | |
| 417 if (userId == null) { | |
| 418 throw new core.ArgumentError("Parameter userId is required."); | |
| 419 } | |
| 420 | |
| 421 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections/' + commons.Escaper.ecapeVariable('$collectionId') + '/users/' + comm
ons.Escaper.ecapeVariable('$userId'); | |
| 422 | |
| 423 var _response = _requester.request(_url, | |
| 424 "GET", | |
| 425 body: _body, | |
| 426 queryParams: _queryParams, | |
| 427 uploadOptions: _uploadOptions, | |
| 428 uploadMedia: _uploadMedia, | |
| 429 downloadOptions: _downloadOptions); | |
| 430 return _response.then((data) => new User.fromJson(data)); | |
| 431 } | |
| 432 | |
| 433 /** | |
| 434 * Retrieves the IDs of the users who have been specifically allowed to see | |
| 435 * the collection. If the collection's visibility is set to viewersOnly then | |
| 436 * only these users will see the collection. | |
| 437 * | |
| 438 * Request parameters: | |
| 439 * | |
| 440 * [enterpriseId] - The ID of the enterprise. | |
| 441 * | |
| 442 * [collectionId] - The ID of the collection. | |
| 443 * | |
| 444 * Completes with a [CollectionViewersListResponse]. | |
| 445 * | |
| 446 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 447 * error. | |
| 448 * | |
| 449 * If the used [http.Client] completes with an error when making a REST call, | |
| 450 * this method will complete with the same error. | |
| 451 */ | |
| 452 async.Future<CollectionViewersListResponse> list(core.String enterpriseId, cor
e.String collectionId) { | |
| 453 var _url = null; | |
| 454 var _queryParams = new core.Map(); | |
| 455 var _uploadMedia = null; | |
| 456 var _uploadOptions = null; | |
| 457 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 458 var _body = null; | |
| 459 | |
| 460 if (enterpriseId == null) { | |
| 461 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 462 } | |
| 463 if (collectionId == null) { | |
| 464 throw new core.ArgumentError("Parameter collectionId is required."); | |
| 465 } | |
| 466 | |
| 467 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections/' + commons.Escaper.ecapeVariable('$collectionId') + '/users'; | |
| 468 | |
| 469 var _response = _requester.request(_url, | |
| 470 "GET", | |
| 471 body: _body, | |
| 472 queryParams: _queryParams, | |
| 473 uploadOptions: _uploadOptions, | |
| 474 uploadMedia: _uploadMedia, | |
| 475 downloadOptions: _downloadOptions); | |
| 476 return _response.then((data) => new CollectionViewersListResponse.fromJson(d
ata)); | |
| 477 } | |
| 478 | |
| 479 /** | |
| 480 * Adds the user to the list of those specifically allowed to see the | |
| 481 * collection. If the collection's visibility is set to viewersOnly then only | |
| 482 * such users will see the collection. This method supports patch semantics. | |
| 483 * | |
| 484 * [request] - The metadata request object. | |
| 485 * | |
| 486 * Request parameters: | |
| 487 * | |
| 488 * [enterpriseId] - The ID of the enterprise. | |
| 489 * | |
| 490 * [collectionId] - The ID of the collection. | |
| 491 * | |
| 492 * [userId] - The ID of the user. | |
| 493 * | |
| 494 * Completes with a [User]. | |
| 495 * | |
| 496 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 497 * error. | |
| 498 * | |
| 499 * If the used [http.Client] completes with an error when making a REST call, | |
| 500 * this method will complete with the same error. | |
| 501 */ | |
| 502 async.Future<User> patch(User request, core.String enterpriseId, core.String c
ollectionId, core.String userId) { | |
| 503 var _url = null; | |
| 504 var _queryParams = new core.Map(); | |
| 505 var _uploadMedia = null; | |
| 506 var _uploadOptions = null; | |
| 507 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 508 var _body = null; | |
| 509 | |
| 510 if (request != null) { | |
| 511 _body = convert.JSON.encode((request).toJson()); | |
| 512 } | |
| 513 if (enterpriseId == null) { | |
| 514 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 515 } | |
| 516 if (collectionId == null) { | |
| 517 throw new core.ArgumentError("Parameter collectionId is required."); | |
| 518 } | |
| 519 if (userId == null) { | |
| 520 throw new core.ArgumentError("Parameter userId is required."); | |
| 521 } | |
| 522 | |
| 523 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections/' + commons.Escaper.ecapeVariable('$collectionId') + '/users/' + comm
ons.Escaper.ecapeVariable('$userId'); | |
| 524 | |
| 525 var _response = _requester.request(_url, | |
| 526 "PATCH", | |
| 527 body: _body, | |
| 528 queryParams: _queryParams, | |
| 529 uploadOptions: _uploadOptions, | |
| 530 uploadMedia: _uploadMedia, | |
| 531 downloadOptions: _downloadOptions); | |
| 532 return _response.then((data) => new User.fromJson(data)); | |
| 533 } | |
| 534 | |
| 535 /** | |
| 536 * Adds the user to the list of those specifically allowed to see the | |
| 537 * collection. If the collection's visibility is set to viewersOnly then only | |
| 538 * such users will see the collection. | |
| 539 * | |
| 540 * [request] - The metadata request object. | |
| 541 * | |
| 542 * Request parameters: | |
| 543 * | |
| 544 * [enterpriseId] - The ID of the enterprise. | |
| 545 * | |
| 546 * [collectionId] - The ID of the collection. | |
| 547 * | |
| 548 * [userId] - The ID of the user. | |
| 549 * | |
| 550 * Completes with a [User]. | |
| 551 * | |
| 552 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | |
| 553 * error. | |
| 554 * | |
| 555 * If the used [http.Client] completes with an error when making a REST call, | |
| 556 * this method will complete with the same error. | |
| 557 */ | |
| 558 async.Future<User> update(User request, core.String enterpriseId, core.String
collectionId, core.String userId) { | |
| 559 var _url = null; | |
| 560 var _queryParams = new core.Map(); | |
| 561 var _uploadMedia = null; | |
| 562 var _uploadOptions = null; | |
| 563 var _downloadOptions = commons.DownloadOptions.Metadata; | |
| 564 var _body = null; | |
| 565 | |
| 566 if (request != null) { | |
| 567 _body = convert.JSON.encode((request).toJson()); | |
| 568 } | |
| 569 if (enterpriseId == null) { | |
| 570 throw new core.ArgumentError("Parameter enterpriseId is required."); | |
| 571 } | |
| 572 if (collectionId == null) { | |
| 573 throw new core.ArgumentError("Parameter collectionId is required."); | |
| 574 } | |
| 575 if (userId == null) { | |
| 576 throw new core.ArgumentError("Parameter userId is required."); | |
| 577 } | |
| 578 | |
| 579 _url = 'enterprises/' + commons.Escaper.ecapeVariable('$enterpriseId') + '/c
ollections/' + commons.Escaper.ecapeVariable('$collectionId') + '/users/' + comm
ons.Escaper.ecapeVariable('$userId'); | |
| 580 | |
| 581 var _response = _requester.request(_url, | |
| 582 "PUT", | |
| 583 body: _body, | |
| 584 queryParams: _queryParams, | |
| 585 uploadOptions: _uploadOptions, | |
| 586 uploadMedia: _uploadMedia, | |
| 587 downloadOptions: _downloadOptions); | |
| 588 return _response.then((data) => new User.fromJson(data)); | |
| 589 } | |
| 590 | |
| 591 } | |
| 592 | |
| 593 | |
| 594 class DevicesResourceApi { | 45 class DevicesResourceApi { |
| 595 final commons.ApiRequester _requester; | 46 final commons.ApiRequester _requester; |
| 596 | 47 |
| 597 DevicesResourceApi(commons.ApiRequester client) : | 48 DevicesResourceApi(commons.ApiRequester client) : |
| 598 _requester = client; | 49 _requester = client; |
| 599 | 50 |
| 600 /** | 51 /** |
| 601 * Retrieves the details of a device. | 52 * Retrieves the details of a device. |
| 602 * | 53 * |
| 603 * Request parameters: | 54 * Request parameters: |
| (...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 894 body: _body, | 345 body: _body, |
| 895 queryParams: _queryParams, | 346 queryParams: _queryParams, |
| 896 uploadOptions: _uploadOptions, | 347 uploadOptions: _uploadOptions, |
| 897 uploadMedia: _uploadMedia, | 348 uploadMedia: _uploadMedia, |
| 898 downloadOptions: _downloadOptions); | 349 downloadOptions: _downloadOptions); |
| 899 return _response.then((data) => new Enterprise.fromJson(data)); | 350 return _response.then((data) => new Enterprise.fromJson(data)); |
| 900 } | 351 } |
| 901 | 352 |
| 902 /** | 353 /** |
| 903 * Returns a unique token to access an embeddable UI. To generate a web UI, | 354 * Returns a unique token to access an embeddable UI. To generate a web UI, |
| 904 * pass the generated token into the Play for Work javascript API. Each token | 355 * pass the generated token into the managed Google Play javascript API. Each |
| 905 * may only be used to start one UI session. See the javascript API | 356 * token may only be used to start one UI session. See the javascript API |
| 906 * documentation for further information. | 357 * documentation for further information. |
| 907 * | 358 * |
| 908 * [request] - The metadata request object. | 359 * [request] - The metadata request object. |
| 909 * | 360 * |
| 910 * Request parameters: | 361 * Request parameters: |
| 911 * | 362 * |
| 912 * [enterpriseId] - The ID of the enterprise. | 363 * [enterpriseId] - The ID of the enterprise. |
| 913 * | 364 * |
| 914 * Completes with a [AdministratorWebToken]. | 365 * Completes with a [AdministratorWebToken]. |
| 915 * | 366 * |
| (...skipping 539 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1455 queryParams: _queryParams, | 906 queryParams: _queryParams, |
| 1456 uploadOptions: _uploadOptions, | 907 uploadOptions: _uploadOptions, |
| 1457 uploadMedia: _uploadMedia, | 908 uploadMedia: _uploadMedia, |
| 1458 downloadOptions: _downloadOptions); | 909 downloadOptions: _downloadOptions); |
| 1459 return _response.then((data) => new EnterpriseAccount.fromJson(data)); | 910 return _response.then((data) => new EnterpriseAccount.fromJson(data)); |
| 1460 } | 911 } |
| 1461 | 912 |
| 1462 /** | 913 /** |
| 1463 * Sets the store layout for the enterprise. By default, storeLayoutType is | 914 * Sets the store layout for the enterprise. By default, storeLayoutType is |
| 1464 * set to "basic" and the basic store layout is enabled. The basic layout only | 915 * set to "basic" and the basic store layout is enabled. The basic layout only |
| 1465 * contains apps approved by the administrator, and that have been added to | 916 * contains apps approved by the admin, and that have been added to the |
| 1466 * the available product set for a user (using the setAvailableProductSet | 917 * available product set for a user (using the setAvailableProductSet call). |
| 1467 * call). Apps on the page are sorted in order of their product ID value. If | 918 * Apps on the page are sorted in order of their product ID value. If you |
| 1468 * you create a custom store layout (by setting storeLayoutType = "custom"), | 919 * create a custom store layout (by setting storeLayoutType = "custom"), the |
| 1469 * the basic store layout is disabled. | 920 * basic store layout is disabled. |
| 1470 * | 921 * |
| 1471 * [request] - The metadata request object. | 922 * [request] - The metadata request object. |
| 1472 * | 923 * |
| 1473 * Request parameters: | 924 * Request parameters: |
| 1474 * | 925 * |
| 1475 * [enterpriseId] - The ID of the enterprise. | 926 * [enterpriseId] - The ID of the enterprise. |
| 1476 * | 927 * |
| 1477 * Completes with a [StoreLayout]. | 928 * Completes with a [StoreLayout]. |
| 1478 * | 929 * |
| 1479 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 930 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| (...skipping 1409 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2889 final commons.ApiRequester _requester; | 2340 final commons.ApiRequester _requester; |
| 2890 | 2341 |
| 2891 ProductsResourceApi(commons.ApiRequester client) : | 2342 ProductsResourceApi(commons.ApiRequester client) : |
| 2892 _requester = client; | 2343 _requester = client; |
| 2893 | 2344 |
| 2894 /** | 2345 /** |
| 2895 * Approves the specified product and the relevant app permissions, if any. | 2346 * Approves the specified product and the relevant app permissions, if any. |
| 2896 * The maximum number of products that you can approve per enterprise customer | 2347 * The maximum number of products that you can approve per enterprise customer |
| 2897 * is 1,000. | 2348 * is 1,000. |
| 2898 * | 2349 * |
| 2899 * To learn how to use Google Play for Work to design and create a store | 2350 * To learn how to use managed Google Play to design and create a store layout |
| 2900 * layout to display approved products to your users, see Store Layout Design. | 2351 * to display approved products to your users, see Store Layout Design. |
| 2901 * | 2352 * |
| 2902 * [request] - The metadata request object. | 2353 * [request] - The metadata request object. |
| 2903 * | 2354 * |
| 2904 * Request parameters: | 2355 * Request parameters: |
| 2905 * | 2356 * |
| 2906 * [enterpriseId] - The ID of the enterprise. | 2357 * [enterpriseId] - The ID of the enterprise. |
| 2907 * | 2358 * |
| 2908 * [productId] - The ID of the product. | 2359 * [productId] - The ID of the product. |
| 2909 * | 2360 * |
| 2910 * Completes with a [commons.ApiRequestError] if the API endpoint returned an | 2361 * Completes with a [commons.ApiRequestError] if the API endpoint returned an |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3051 uploadOptions: _uploadOptions, | 2502 uploadOptions: _uploadOptions, |
| 3052 uploadMedia: _uploadMedia, | 2503 uploadMedia: _uploadMedia, |
| 3053 downloadOptions: _downloadOptions); | 2504 downloadOptions: _downloadOptions); |
| 3054 return _response.then((data) => new Product.fromJson(data)); | 2505 return _response.then((data) => new Product.fromJson(data)); |
| 3055 } | 2506 } |
| 3056 | 2507 |
| 3057 /** | 2508 /** |
| 3058 * Retrieves the schema that defines the configurable properties for this | 2509 * Retrieves the schema that defines the configurable properties for this |
| 3059 * product. All products have a schema, but this schema may be empty if no | 2510 * product. All products have a schema, but this schema may be empty if no |
| 3060 * managed configurations have been defined. This schema can be used to | 2511 * managed configurations have been defined. This schema can be used to |
| 3061 * populate a UI that allows an administrator to configure the product. To | 2512 * populate a UI that allows an admin to configure the product. To apply a |
| 3062 * apply a managed configuration based on the schema obtained using this API, | 2513 * managed configuration based on the schema obtained using this API, see |
| 3063 * see Managed Configurations through Play. | 2514 * Managed Configurations through Play. |
| 3064 * | 2515 * |
| 3065 * Request parameters: | 2516 * Request parameters: |
| 3066 * | 2517 * |
| 3067 * [enterpriseId] - The ID of the enterprise. | 2518 * [enterpriseId] - The ID of the enterprise. |
| 3068 * | 2519 * |
| 3069 * [productId] - The ID of the product. | 2520 * [productId] - The ID of the product. |
| 3070 * | 2521 * |
| 3071 * [language] - The BCP47 tag for the user's preferred language (e.g. "en-US", | 2522 * [language] - The BCP47 tag for the user's preferred language (e.g. "en-US", |
| 3072 * "de"). | 2523 * "de"). |
| 3073 * | 2524 * |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3166 * supported, and should be specified. | 2617 * supported, and should be specified. |
| 3167 * | 2618 * |
| 3168 * [language] - The BCP47 tag for the user's preferred language (e.g. "en-US", | 2619 * [language] - The BCP47 tag for the user's preferred language (e.g. "en-US", |
| 3169 * "de"). Results are returned in the language best matching the preferred | 2620 * "de"). Results are returned in the language best matching the preferred |
| 3170 * language. | 2621 * language. |
| 3171 * | 2622 * |
| 3172 * [maxResults] - Specifies the maximum number of products that can be | 2623 * [maxResults] - Specifies the maximum number of products that can be |
| 3173 * returned per request. If not specified, uses a default value of 100, which | 2624 * returned per request. If not specified, uses a default value of 100, which |
| 3174 * is also the maximum retrievable within a single response. | 2625 * is also the maximum retrievable within a single response. |
| 3175 * | 2626 * |
| 3176 * [query] - The search query as typed in the Google Play Store search box. If | 2627 * [query] - The search query as typed in the Google Play store search box. If |
| 3177 * omitted, all approved apps will be returned (using the pagination | 2628 * omitted, all approved apps will be returned (using the pagination |
| 3178 * parameters), including apps that are not available in the store (e.g. | 2629 * parameters), including apps that are not available in the store (e.g. |
| 3179 * unpublished apps). | 2630 * unpublished apps). |
| 3180 * | 2631 * |
| 3181 * [token] - A pagination token is contained in a requestÂ’s response when | 2632 * [token] - A pagination token is contained in a requestÂ’s response when |
| 3182 * there are more products. The token can be used in a subsequent request to | 2633 * there are more products. The token can be used in a subsequent request to |
| 3183 * obtain more products, and so forth. This parameter cannot be used in the | 2634 * obtain more products, and so forth. This parameter cannot be used in the |
| 3184 * initial request. | 2635 * initial request. |
| 3185 * | 2636 * |
| 3186 * Completes with a [ProductsListResponse]. | 2637 * Completes with a [ProductsListResponse]. |
| (...skipping 973 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4160 body: _body, | 3611 body: _body, |
| 4161 queryParams: _queryParams, | 3612 queryParams: _queryParams, |
| 4162 uploadOptions: _uploadOptions, | 3613 uploadOptions: _uploadOptions, |
| 4163 uploadMedia: _uploadMedia, | 3614 uploadMedia: _uploadMedia, |
| 4164 downloadOptions: _downloadOptions); | 3615 downloadOptions: _downloadOptions); |
| 4165 return _response.then((data) => new AuthenticationToken.fromJson(data)); | 3616 return _response.then((data) => new AuthenticationToken.fromJson(data)); |
| 4166 } | 3617 } |
| 4167 | 3618 |
| 4168 /** | 3619 /** |
| 4169 * Generates a token (activation code) to allow this user to configure their | 3620 * Generates a token (activation code) to allow this user to configure their |
| 4170 * work account in the Android Setup Wizard. Revokes any previously generated | 3621 * managed account in the Android Setup Wizard. Revokes any previously |
| 4171 * token. | 3622 * generated token. |
| 4172 * | 3623 * |
| 4173 * This call only works with Google managed accounts. | 3624 * This call only works with Google managed accounts. |
| 4174 * | 3625 * |
| 4175 * Request parameters: | 3626 * Request parameters: |
| 4176 * | 3627 * |
| 4177 * [enterpriseId] - The ID of the enterprise. | 3628 * [enterpriseId] - The ID of the enterprise. |
| 4178 * | 3629 * |
| 4179 * [userId] - The ID of the user. | 3630 * [userId] - The ID of the user. |
| 4180 * | 3631 * |
| 4181 * Completes with a [UserToken]. | 3632 * Completes with a [UserToken]. |
| (...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4597 uploadMedia: _uploadMedia, | 4048 uploadMedia: _uploadMedia, |
| 4598 downloadOptions: _downloadOptions); | 4049 downloadOptions: _downloadOptions); |
| 4599 return _response.then((data) => new User.fromJson(data)); | 4050 return _response.then((data) => new User.fromJson(data)); |
| 4600 } | 4051 } |
| 4601 | 4052 |
| 4602 } | 4053 } |
| 4603 | 4054 |
| 4604 | 4055 |
| 4605 | 4056 |
| 4606 /** | 4057 /** |
| 4607 * This represents an enterprise administrator who can manage the enterprise in | 4058 * This represents an enterprise admin who can manage the enterprise in the |
| 4608 * the Google Play for Work Store. | 4059 * managed Google Play store. |
| 4609 */ | 4060 */ |
| 4610 class Administrator { | 4061 class Administrator { |
| 4611 /** The administrator's email address. */ | 4062 /** The admin's email address. */ |
| 4612 core.String email; | 4063 core.String email; |
| 4613 | 4064 |
| 4614 Administrator(); | 4065 Administrator(); |
| 4615 | 4066 |
| 4616 Administrator.fromJson(core.Map _json) { | 4067 Administrator.fromJson(core.Map _json) { |
| 4617 if (_json.containsKey("email")) { | 4068 if (_json.containsKey("email")) { |
| 4618 email = _json["email"]; | 4069 email = _json["email"]; |
| 4619 } | 4070 } |
| 4620 } | 4071 } |
| 4621 | 4072 |
| 4622 core.Map toJson() { | 4073 core.Map toJson() { |
| 4623 var _json = new core.Map(); | 4074 var _json = new core.Map(); |
| 4624 if (email != null) { | 4075 if (email != null) { |
| 4625 _json["email"] = email; | 4076 _json["email"] = email; |
| 4626 } | 4077 } |
| 4627 return _json; | 4078 return _json; |
| 4628 } | 4079 } |
| 4629 } | 4080 } |
| 4630 | 4081 |
| 4631 /** A token authorizing an administrator to access an iframe. */ | 4082 /** A token authorizing an admin to access an iframe. */ |
| 4632 class AdministratorWebToken { | 4083 class AdministratorWebToken { |
| 4633 /** | 4084 /** |
| 4634 * Identifies what kind of resource this is. Value: the fixed string | 4085 * Identifies what kind of resource this is. Value: the fixed string |
| 4635 * "androidenterprise#administratorWebToken". | 4086 * "androidenterprise#administratorWebToken". |
| 4636 */ | 4087 */ |
| 4637 core.String kind; | 4088 core.String kind; |
| 4638 /** | 4089 /** |
| 4639 * An opaque token to be passed to the Play front-end to generate an iframe. | 4090 * An opaque token to be passed to the Play front-end to generate an iframe. |
| 4640 */ | 4091 */ |
| 4641 core.String token; | 4092 core.String token; |
| (...skipping 329 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4971 } | 4422 } |
| 4972 return _json; | 4423 return _json; |
| 4973 } | 4424 } |
| 4974 } | 4425 } |
| 4975 | 4426 |
| 4976 /** This represents a single version of the app. */ | 4427 /** This represents a single version of the app. */ |
| 4977 class AppVersion { | 4428 class AppVersion { |
| 4978 /** Unique increasing identifier for the app version. */ | 4429 /** Unique increasing identifier for the app version. */ |
| 4979 core.int versionCode; | 4430 core.int versionCode; |
| 4980 /** | 4431 /** |
| 4981 * The string used in the Play Store by the app developer to identify the | 4432 * The string used in the Play store by the app developer to identify the |
| 4982 * version. The string is not necessarily unique or localized (for example, | 4433 * version. The string is not necessarily unique or localized (for example, |
| 4983 * the string could be "1.4"). | 4434 * the string could be "1.4"). |
| 4984 */ | 4435 */ |
| 4985 core.String versionString; | 4436 core.String versionString; |
| 4986 | 4437 |
| 4987 AppVersion(); | 4438 AppVersion(); |
| 4988 | 4439 |
| 4989 AppVersion.fromJson(core.Map _json) { | 4440 AppVersion.fromJson(core.Map _json) { |
| 4990 if (_json.containsKey("versionCode")) { | 4441 if (_json.containsKey("versionCode")) { |
| 4991 versionCode = _json["versionCode"]; | 4442 versionCode = _json["versionCode"]; |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5077 _json["kind"] = kind; | 4528 _json["kind"] = kind; |
| 5078 } | 4529 } |
| 5079 if (token != null) { | 4530 if (token != null) { |
| 5080 _json["token"] = token; | 4531 _json["token"] = token; |
| 5081 } | 4532 } |
| 5082 return _json; | 4533 return _json; |
| 5083 } | 4534 } |
| 5084 } | 4535 } |
| 5085 | 4536 |
| 5086 /** | 4537 /** |
| 5087 * A collection resource defines a named set of apps that is visible to a set of | |
| 5088 * users in the Google Play Store app running on those users' managed devices. | |
| 5089 * Those users can then install any of those apps if they wish (which will | |
| 5090 * trigger creation of install and entitlement resources). A user cannot install | |
| 5091 * an app on a managed device unless the app is listed in at least one | |
| 5092 * collection that is visible to that user. | |
| 5093 * | |
| 5094 * Note that the API can be used to directly install an app regardless of | |
| 5095 * whether it is in any collection - so an enterprise has a choice of either | |
| 5096 * directly pushing apps to users, or allowing users to install apps if they | |
| 5097 * want. Which is appropriate will depend on the enterprise's policies and the | |
| 5098 * purpose of the apps concerned. | |
| 5099 */ | |
| 5100 class Collection { | |
| 5101 /** Arbitrary unique ID, allocated by the API on creation. */ | |
| 5102 core.String collectionId; | |
| 5103 /** | |
| 5104 * Identifies what kind of resource this is. Value: the fixed string | |
| 5105 * "androidenterprise#collection". | |
| 5106 */ | |
| 5107 core.String kind; | |
| 5108 /** | |
| 5109 * A user-friendly name for the collection (should be unique), e.g. | |
| 5110 * "Accounting apps". | |
| 5111 */ | |
| 5112 core.String name; | |
| 5113 /** | |
| 5114 * The IDs of the products in the collection, in the order in which they | |
| 5115 * should be displayed. | |
| 5116 */ | |
| 5117 core.List<core.String> productId; | |
| 5118 /** | |
| 5119 * Whether this collection is visible to all users, or only to the users that | |
| 5120 * have been granted access through the "Collectionviewers" API. With the | |
| 5121 * launch of the "setAvailableProductSet" API, this property should always be | |
| 5122 * set to "viewersOnly", as the "allUsers" option will bypass the | |
| 5123 * "availableProductSet" for all users within a domain. | |
| 5124 * | |
| 5125 * The "allUsers" setting is deprecated, and will be removed. | |
| 5126 */ | |
| 5127 core.String visibility; | |
| 5128 | |
| 5129 Collection(); | |
| 5130 | |
| 5131 Collection.fromJson(core.Map _json) { | |
| 5132 if (_json.containsKey("collectionId")) { | |
| 5133 collectionId = _json["collectionId"]; | |
| 5134 } | |
| 5135 if (_json.containsKey("kind")) { | |
| 5136 kind = _json["kind"]; | |
| 5137 } | |
| 5138 if (_json.containsKey("name")) { | |
| 5139 name = _json["name"]; | |
| 5140 } | |
| 5141 if (_json.containsKey("productId")) { | |
| 5142 productId = _json["productId"]; | |
| 5143 } | |
| 5144 if (_json.containsKey("visibility")) { | |
| 5145 visibility = _json["visibility"]; | |
| 5146 } | |
| 5147 } | |
| 5148 | |
| 5149 core.Map toJson() { | |
| 5150 var _json = new core.Map(); | |
| 5151 if (collectionId != null) { | |
| 5152 _json["collectionId"] = collectionId; | |
| 5153 } | |
| 5154 if (kind != null) { | |
| 5155 _json["kind"] = kind; | |
| 5156 } | |
| 5157 if (name != null) { | |
| 5158 _json["name"] = name; | |
| 5159 } | |
| 5160 if (productId != null) { | |
| 5161 _json["productId"] = productId; | |
| 5162 } | |
| 5163 if (visibility != null) { | |
| 5164 _json["visibility"] = visibility; | |
| 5165 } | |
| 5166 return _json; | |
| 5167 } | |
| 5168 } | |
| 5169 | |
| 5170 /** The user resources for the collection. */ | |
| 5171 class CollectionViewersListResponse { | |
| 5172 /** | |
| 5173 * Identifies what kind of resource this is. Value: the fixed string | |
| 5174 * "androidenterprise#collectionViewersListResponse". | |
| 5175 */ | |
| 5176 core.String kind; | |
| 5177 /** A user of an enterprise. */ | |
| 5178 core.List<User> user; | |
| 5179 | |
| 5180 CollectionViewersListResponse(); | |
| 5181 | |
| 5182 CollectionViewersListResponse.fromJson(core.Map _json) { | |
| 5183 if (_json.containsKey("kind")) { | |
| 5184 kind = _json["kind"]; | |
| 5185 } | |
| 5186 if (_json.containsKey("user")) { | |
| 5187 user = _json["user"].map((value) => new User.fromJson(value)).toList(); | |
| 5188 } | |
| 5189 } | |
| 5190 | |
| 5191 core.Map toJson() { | |
| 5192 var _json = new core.Map(); | |
| 5193 if (kind != null) { | |
| 5194 _json["kind"] = kind; | |
| 5195 } | |
| 5196 if (user != null) { | |
| 5197 _json["user"] = user.map((value) => (value).toJson()).toList(); | |
| 5198 } | |
| 5199 return _json; | |
| 5200 } | |
| 5201 } | |
| 5202 | |
| 5203 /** The collection resources for the enterprise. */ | |
| 5204 class CollectionsListResponse { | |
| 5205 /** | |
| 5206 * An ordered collection of products which can be made visible on the Google | |
| 5207 * Play Store to a selected group of users. | |
| 5208 */ | |
| 5209 core.List<Collection> collection; | |
| 5210 /** | |
| 5211 * Identifies what kind of resource this is. Value: the fixed string | |
| 5212 * "androidenterprise#collectionsListResponse". | |
| 5213 */ | |
| 5214 core.String kind; | |
| 5215 | |
| 5216 CollectionsListResponse(); | |
| 5217 | |
| 5218 CollectionsListResponse.fromJson(core.Map _json) { | |
| 5219 if (_json.containsKey("collection")) { | |
| 5220 collection = _json["collection"].map((value) => new Collection.fromJson(va
lue)).toList(); | |
| 5221 } | |
| 5222 if (_json.containsKey("kind")) { | |
| 5223 kind = _json["kind"]; | |
| 5224 } | |
| 5225 } | |
| 5226 | |
| 5227 core.Map toJson() { | |
| 5228 var _json = new core.Map(); | |
| 5229 if (collection != null) { | |
| 5230 _json["collection"] = collection.map((value) => (value).toJson()).toList()
; | |
| 5231 } | |
| 5232 if (kind != null) { | |
| 5233 _json["kind"] = kind; | |
| 5234 } | |
| 5235 return _json; | |
| 5236 } | |
| 5237 } | |
| 5238 | |
| 5239 /** | |
| 5240 * A device resource represents a mobile device managed by the EMM and belonging | 4538 * A device resource represents a mobile device managed by the EMM and belonging |
| 5241 * to a specific enterprise user. | 4539 * to a specific enterprise user. |
| 5242 * | 4540 * |
| 5243 * This collection cannot be modified via the API; it is automatically populated | 4541 * This collection cannot be modified via the API; it is automatically populated |
| 5244 * as devices are set up to be managed. | 4542 * as devices are set up to be managed. |
| 5245 */ | 4543 */ |
| 5246 class Device { | 4544 class Device { |
| 5247 /** | 4545 /** |
| 5248 * The Google Play Services Android ID for the device encoded as a lowercase | 4546 * The Google Play Services Android ID for the device encoded as a lowercase |
| 5249 * hex string, e.g. "123456789abcdef0". | 4547 * hex string, e.g. "123456789abcdef0". |
| 5250 */ | 4548 */ |
| 5251 core.String androidId; | 4549 core.String androidId; |
| 5252 /** | 4550 /** |
| 5253 * Identifies what kind of resource this is. Value: the fixed string | 4551 * Identifies what kind of resource this is. Value: the fixed string |
| 5254 * "androidenterprise#device". | 4552 * "androidenterprise#device". |
| 5255 */ | 4553 */ |
| 5256 core.String kind; | 4554 core.String kind; |
| 5257 /** | 4555 /** |
| 5258 * Identifies the extent to which the device is controlled by an Android for | 4556 * Identifies the extent to which the device is controlled by a managed Google |
| 5259 * Work EMM in various deployment configurations. | 4557 * Play EMM in various deployment configurations. |
| 5260 * | 4558 * |
| 5261 * Possible values include: | 4559 * Possible values include: |
| 5262 * - "managedDevice", a device that has the EMM's device policy controller | 4560 * - "managedDevice", a device that has the EMM's device policy controller |
| 5263 * (DPC) as the device owner, | 4561 * (DPC) as the device owner, |
| 5264 * - "managedProfile", a device that has a work profile managed by the DPC | 4562 * - "managedProfile", a device that has a profile managed by the DPC (DPC is |
| 5265 * (DPC is profile owner) in addition to a separate, personal profile that is | 4563 * profile owner) in addition to a separate, personal profile that is |
| 5266 * unavailable to the DPC, | 4564 * unavailable to the DPC, |
| 5267 * - "containerApp", a device running the Android for Work App. The Android | 4565 * - "containerApp", a device running the container App. The container App is |
| 5268 * for Work App is managed by the DPC, | 4566 * managed by the DPC, |
| 5269 * - "unmanagedProfile", a device that has been allowed (by the domain's | 4567 * - "unmanagedProfile", a device that has been allowed (by the domain's |
| 5270 * admin, using the Admin Console to enable the privilege) to use Android for | 4568 * admin, using the Admin Console to enable the privilege) to use managed |
| 5271 * Work apps or Google Apps for Work, but the profile is itself not owned by a | 4569 * Google Play, but the profile is itself not owned by a DPC. |
| 5272 * DPC. | |
| 5273 */ | 4570 */ |
| 5274 core.String managementType; | 4571 core.String managementType; |
| 5275 | 4572 |
| 5276 Device(); | 4573 Device(); |
| 5277 | 4574 |
| 5278 Device.fromJson(core.Map _json) { | 4575 Device.fromJson(core.Map _json) { |
| 5279 if (_json.containsKey("androidId")) { | 4576 if (_json.containsKey("androidId")) { |
| 5280 androidId = _json["androidId"]; | 4577 androidId = _json["androidId"]; |
| 5281 } | 4578 } |
| 5282 if (_json.containsKey("kind")) { | 4579 if (_json.containsKey("kind")) { |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5377 } | 4674 } |
| 5378 | 4675 |
| 5379 /** | 4676 /** |
| 5380 * An Enterprises resource represents the binding between an EMM and a specific | 4677 * An Enterprises resource represents the binding between an EMM and a specific |
| 5381 * organization. That binding can be instantiated in one of two different ways | 4678 * organization. That binding can be instantiated in one of two different ways |
| 5382 * using this API as follows: | 4679 * using this API as follows: |
| 5383 * - For Google managed domain customers, the process involves using | 4680 * - For Google managed domain customers, the process involves using |
| 5384 * Enterprises.enroll and Enterprises.setAccount (in conjunction with artifacts | 4681 * Enterprises.enroll and Enterprises.setAccount (in conjunction with artifacts |
| 5385 * obtained from the Admin console and the Google API Console) and submitted to | 4682 * obtained from the Admin console and the Google API Console) and submitted to |
| 5386 * the EMM through a more-or-less manual process. | 4683 * the EMM through a more-or-less manual process. |
| 5387 * - For Android for Work Accounts customers, the process involves using | 4684 * - For managed Google Play Accounts customers, the process involves using |
| 5388 * Enterprises.generateSignupUrl and Enterprises.completeSignup in conjunction | 4685 * Enterprises.generateSignupUrl and Enterprises.completeSignup in conjunction |
| 5389 * with the Android for Work Sign-up UI (Google-provided mechanism) to create | 4686 * with the managed Google Play sign-up UI (Google-provided mechanism) to create |
| 5390 * the binding without manual steps. As an EMM, you can support either or both | 4687 * the binding without manual steps. As an EMM, you can support either or both |
| 5391 * approaches in your EMM console. See Create an Enterprise for details. | 4688 * approaches in your EMM console. See Create an Enterprise for details. |
| 5392 */ | 4689 */ |
| 5393 class Enterprise { | 4690 class Enterprise { |
| 5394 /** | 4691 /** |
| 5395 * Administrators of the enterprise. This is only supported for enterprises | 4692 * Admins of the enterprise. This is only supported for enterprises created |
| 5396 * created via the EMM-initiated flow. | 4693 * via the EMM-initiated flow. |
| 5397 */ | 4694 */ |
| 5398 core.List<Administrator> administrator; | 4695 core.List<Administrator> administrator; |
| 5399 /** The unique ID for the enterprise. */ | 4696 /** The unique ID for the enterprise. */ |
| 5400 core.String id; | 4697 core.String id; |
| 5401 /** | 4698 /** |
| 5402 * Identifies what kind of resource this is. Value: the fixed string | 4699 * Identifies what kind of resource this is. Value: the fixed string |
| 5403 * "androidenterprise#enterprise". | 4700 * "androidenterprise#enterprise". |
| 5404 */ | 4701 */ |
| 5405 core.String kind; | 4702 core.String kind; |
| 5406 /** The name of the enterprise, for example, "Example, Inc". */ | 4703 /** The name of the enterprise, for example, "Example, Inc". */ |
| (...skipping 861 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6268 | 5565 |
| 6269 core.Map toJson() { | 5566 core.Map toJson() { |
| 6270 var _json = new core.Map(); | 5567 var _json = new core.Map(); |
| 6271 if (managedProperty != null) { | 5568 if (managedProperty != null) { |
| 6272 _json["managedProperty"] = managedProperty.map((value) => (value).toJson()
).toList(); | 5569 _json["managedProperty"] = managedProperty.map((value) => (value).toJson()
).toList(); |
| 6273 } | 5570 } |
| 6274 return _json; | 5571 return _json; |
| 6275 } | 5572 } |
| 6276 } | 5573 } |
| 6277 | 5574 |
| 5575 /** An event generated when a new device is ready to be managed. */ |
| 5576 class NewDeviceEvent { |
| 5577 /** The Android ID of the device. This field will always be present. */ |
| 5578 core.String deviceId; |
| 5579 /** |
| 5580 * Identifies the extent to which the device is controlled by an Android for |
| 5581 * Work EMM in various deployment configurations. |
| 5582 * |
| 5583 * Possible values include: |
| 5584 * - "managedDevice", a device that has the EMM's device policy controller |
| 5585 * (DPC) as the device owner, |
| 5586 * - "managedProfile", a device that has a work profile managed by the DPC |
| 5587 * (DPC is profile owner) in addition to a separate, personal profile that is |
| 5588 * unavailable to the DPC, |
| 5589 */ |
| 5590 core.String managementType; |
| 5591 /** The ID of the user. This field will always be present. */ |
| 5592 core.String userId; |
| 5593 |
| 5594 NewDeviceEvent(); |
| 5595 |
| 5596 NewDeviceEvent.fromJson(core.Map _json) { |
| 5597 if (_json.containsKey("deviceId")) { |
| 5598 deviceId = _json["deviceId"]; |
| 5599 } |
| 5600 if (_json.containsKey("managementType")) { |
| 5601 managementType = _json["managementType"]; |
| 5602 } |
| 5603 if (_json.containsKey("userId")) { |
| 5604 userId = _json["userId"]; |
| 5605 } |
| 5606 } |
| 5607 |
| 5608 core.Map toJson() { |
| 5609 var _json = new core.Map(); |
| 5610 if (deviceId != null) { |
| 5611 _json["deviceId"] = deviceId; |
| 5612 } |
| 5613 if (managementType != null) { |
| 5614 _json["managementType"] = managementType; |
| 5615 } |
| 5616 if (userId != null) { |
| 5617 _json["userId"] = userId; |
| 5618 } |
| 5619 return _json; |
| 5620 } |
| 5621 } |
| 5622 |
| 6278 /** An event generated when new permissions are added to an app. */ | 5623 /** An event generated when new permissions are added to an app. */ |
| 6279 class NewPermissionsEvent { | 5624 class NewPermissionsEvent { |
| 6280 /** | 5625 /** |
| 6281 * The set of permissions that the enterprise admin has already approved for | 5626 * The set of permissions that the enterprise admin has already approved for |
| 6282 * this application. Use Permissions.Get on the EMM API to retrieve details | 5627 * this application. Use Permissions.Get on the EMM API to retrieve details |
| 6283 * about these permissions. | 5628 * about these permissions. |
| 6284 */ | 5629 */ |
| 6285 core.List<core.String> approvedPermissions; | 5630 core.List<core.String> approvedPermissions; |
| 6286 /** | 5631 /** |
| 6287 * The id of the product (e.g. "app:com.google.android.gm") for which new | 5632 * The id of the product (e.g. "app:com.google.android.gm") for which new |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6329 AppRestrictionsSchemaChangeEvent appRestrictionsSchemaChangeEvent; | 5674 AppRestrictionsSchemaChangeEvent appRestrictionsSchemaChangeEvent; |
| 6330 /** Notifications about app updates. */ | 5675 /** Notifications about app updates. */ |
| 6331 AppUpdateEvent appUpdateEvent; | 5676 AppUpdateEvent appUpdateEvent; |
| 6332 /** | 5677 /** |
| 6333 * The ID of the enterprise for which the notification is sent. This will | 5678 * The ID of the enterprise for which the notification is sent. This will |
| 6334 * always be present. | 5679 * always be present. |
| 6335 */ | 5680 */ |
| 6336 core.String enterpriseId; | 5681 core.String enterpriseId; |
| 6337 /** Notifications about an app installation failure. */ | 5682 /** Notifications about an app installation failure. */ |
| 6338 InstallFailureEvent installFailureEvent; | 5683 InstallFailureEvent installFailureEvent; |
| 5684 /** Notifications about new devices. */ |
| 5685 NewDeviceEvent newDeviceEvent; |
| 6339 /** Notifications about new app permissions. */ | 5686 /** Notifications about new app permissions. */ |
| 6340 NewPermissionsEvent newPermissionsEvent; | 5687 NewPermissionsEvent newPermissionsEvent; |
| 6341 /** Notifications about changes to a product's approval status. */ | 5688 /** Notifications about changes to a product's approval status. */ |
| 6342 ProductApprovalEvent productApprovalEvent; | 5689 ProductApprovalEvent productApprovalEvent; |
| 6343 /** Notifications about product availability changes. */ | 5690 /** Notifications about product availability changes. */ |
| 6344 ProductAvailabilityChangeEvent productAvailabilityChangeEvent; | 5691 ProductAvailabilityChangeEvent productAvailabilityChangeEvent; |
| 6345 /** | 5692 /** |
| 6346 * The time when the notification was published in milliseconds since | 5693 * The time when the notification was published in milliseconds since |
| 6347 * 1970-01-01T00:00:00Z. This will always be present. | 5694 * 1970-01-01T00:00:00Z. This will always be present. |
| 6348 */ | 5695 */ |
| 6349 core.String timestampMillis; | 5696 core.String timestampMillis; |
| 6350 | 5697 |
| 6351 Notification(); | 5698 Notification(); |
| 6352 | 5699 |
| 6353 Notification.fromJson(core.Map _json) { | 5700 Notification.fromJson(core.Map _json) { |
| 6354 if (_json.containsKey("appRestrictionsSchemaChangeEvent")) { | 5701 if (_json.containsKey("appRestrictionsSchemaChangeEvent")) { |
| 6355 appRestrictionsSchemaChangeEvent = new AppRestrictionsSchemaChangeEvent.fr
omJson(_json["appRestrictionsSchemaChangeEvent"]); | 5702 appRestrictionsSchemaChangeEvent = new AppRestrictionsSchemaChangeEvent.fr
omJson(_json["appRestrictionsSchemaChangeEvent"]); |
| 6356 } | 5703 } |
| 6357 if (_json.containsKey("appUpdateEvent")) { | 5704 if (_json.containsKey("appUpdateEvent")) { |
| 6358 appUpdateEvent = new AppUpdateEvent.fromJson(_json["appUpdateEvent"]); | 5705 appUpdateEvent = new AppUpdateEvent.fromJson(_json["appUpdateEvent"]); |
| 6359 } | 5706 } |
| 6360 if (_json.containsKey("enterpriseId")) { | 5707 if (_json.containsKey("enterpriseId")) { |
| 6361 enterpriseId = _json["enterpriseId"]; | 5708 enterpriseId = _json["enterpriseId"]; |
| 6362 } | 5709 } |
| 6363 if (_json.containsKey("installFailureEvent")) { | 5710 if (_json.containsKey("installFailureEvent")) { |
| 6364 installFailureEvent = new InstallFailureEvent.fromJson(_json["installFailu
reEvent"]); | 5711 installFailureEvent = new InstallFailureEvent.fromJson(_json["installFailu
reEvent"]); |
| 6365 } | 5712 } |
| 5713 if (_json.containsKey("newDeviceEvent")) { |
| 5714 newDeviceEvent = new NewDeviceEvent.fromJson(_json["newDeviceEvent"]); |
| 5715 } |
| 6366 if (_json.containsKey("newPermissionsEvent")) { | 5716 if (_json.containsKey("newPermissionsEvent")) { |
| 6367 newPermissionsEvent = new NewPermissionsEvent.fromJson(_json["newPermissio
nsEvent"]); | 5717 newPermissionsEvent = new NewPermissionsEvent.fromJson(_json["newPermissio
nsEvent"]); |
| 6368 } | 5718 } |
| 6369 if (_json.containsKey("productApprovalEvent")) { | 5719 if (_json.containsKey("productApprovalEvent")) { |
| 6370 productApprovalEvent = new ProductApprovalEvent.fromJson(_json["productApp
rovalEvent"]); | 5720 productApprovalEvent = new ProductApprovalEvent.fromJson(_json["productApp
rovalEvent"]); |
| 6371 } | 5721 } |
| 6372 if (_json.containsKey("productAvailabilityChangeEvent")) { | 5722 if (_json.containsKey("productAvailabilityChangeEvent")) { |
| 6373 productAvailabilityChangeEvent = new ProductAvailabilityChangeEvent.fromJs
on(_json["productAvailabilityChangeEvent"]); | 5723 productAvailabilityChangeEvent = new ProductAvailabilityChangeEvent.fromJs
on(_json["productAvailabilityChangeEvent"]); |
| 6374 } | 5724 } |
| 6375 if (_json.containsKey("timestampMillis")) { | 5725 if (_json.containsKey("timestampMillis")) { |
| 6376 timestampMillis = _json["timestampMillis"]; | 5726 timestampMillis = _json["timestampMillis"]; |
| 6377 } | 5727 } |
| 6378 } | 5728 } |
| 6379 | 5729 |
| 6380 core.Map toJson() { | 5730 core.Map toJson() { |
| 6381 var _json = new core.Map(); | 5731 var _json = new core.Map(); |
| 6382 if (appRestrictionsSchemaChangeEvent != null) { | 5732 if (appRestrictionsSchemaChangeEvent != null) { |
| 6383 _json["appRestrictionsSchemaChangeEvent"] = (appRestrictionsSchemaChangeEv
ent).toJson(); | 5733 _json["appRestrictionsSchemaChangeEvent"] = (appRestrictionsSchemaChangeEv
ent).toJson(); |
| 6384 } | 5734 } |
| 6385 if (appUpdateEvent != null) { | 5735 if (appUpdateEvent != null) { |
| 6386 _json["appUpdateEvent"] = (appUpdateEvent).toJson(); | 5736 _json["appUpdateEvent"] = (appUpdateEvent).toJson(); |
| 6387 } | 5737 } |
| 6388 if (enterpriseId != null) { | 5738 if (enterpriseId != null) { |
| 6389 _json["enterpriseId"] = enterpriseId; | 5739 _json["enterpriseId"] = enterpriseId; |
| 6390 } | 5740 } |
| 6391 if (installFailureEvent != null) { | 5741 if (installFailureEvent != null) { |
| 6392 _json["installFailureEvent"] = (installFailureEvent).toJson(); | 5742 _json["installFailureEvent"] = (installFailureEvent).toJson(); |
| 6393 } | 5743 } |
| 5744 if (newDeviceEvent != null) { |
| 5745 _json["newDeviceEvent"] = (newDeviceEvent).toJson(); |
| 5746 } |
| 6394 if (newPermissionsEvent != null) { | 5747 if (newPermissionsEvent != null) { |
| 6395 _json["newPermissionsEvent"] = (newPermissionsEvent).toJson(); | 5748 _json["newPermissionsEvent"] = (newPermissionsEvent).toJson(); |
| 6396 } | 5749 } |
| 6397 if (productApprovalEvent != null) { | 5750 if (productApprovalEvent != null) { |
| 6398 _json["productApprovalEvent"] = (productApprovalEvent).toJson(); | 5751 _json["productApprovalEvent"] = (productApprovalEvent).toJson(); |
| 6399 } | 5752 } |
| 6400 if (productAvailabilityChangeEvent != null) { | 5753 if (productAvailabilityChangeEvent != null) { |
| 6401 _json["productAvailabilityChangeEvent"] = (productAvailabilityChangeEvent)
.toJson(); | 5754 _json["productAvailabilityChangeEvent"] = (productAvailabilityChangeEvent)
.toJson(); |
| 6402 } | 5755 } |
| 6403 if (timestampMillis != null) { | 5756 if (timestampMillis != null) { |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6545 _json["name"] = name; | 5898 _json["name"] = name; |
| 6546 } | 5899 } |
| 6547 if (permissionId != null) { | 5900 if (permissionId != null) { |
| 6548 _json["permissionId"] = permissionId; | 5901 _json["permissionId"] = permissionId; |
| 6549 } | 5902 } |
| 6550 return _json; | 5903 return _json; |
| 6551 } | 5904 } |
| 6552 } | 5905 } |
| 6553 | 5906 |
| 6554 /** | 5907 /** |
| 6555 * A Products resource represents an app in the Google Play Store that is | 5908 * A Products resource represents an app in the Google Play store that is |
| 6556 * available to at least some users in the enterprise. (Some apps are restricted | 5909 * available to at least some users in the enterprise. (Some apps are restricted |
| 6557 * to a single enterprise, and no information about them is made available | 5910 * to a single enterprise, and no information about them is made available |
| 6558 * outside that enterprise.) | 5911 * outside that enterprise.) |
| 6559 * | 5912 * |
| 6560 * The information provided for each product (localized name, icon, link to the | 5913 * The information provided for each product (localized name, icon, link to the |
| 6561 * full Google Play details page) is intended to allow a basic representation of | 5914 * full Google Play details page) is intended to allow a basic representation of |
| 6562 * the product within an EMM user interface. | 5915 * the product within an EMM user interface. |
| 6563 */ | 5916 */ |
| 6564 class Product { | 5917 class Product { |
| 6565 /** | 5918 /** |
| 6566 * App versions currently available for this product. The returned list | 5919 * App versions currently available for this product. The returned list |
| 6567 * contains only public versions. Alpha and beta versions are not included. | 5920 * contains only public versions. Alpha and beta versions are not included. |
| 6568 */ | 5921 */ |
| 6569 core.List<AppVersion> appVersion; | 5922 core.List<AppVersion> appVersion; |
| 6570 /** The name of the author of the product (e.g. the app developer). */ | 5923 /** The name of the author of the product (e.g. the app developer). */ |
| 6571 core.String authorName; | 5924 core.String authorName; |
| 6572 /** A link to the (consumer) Google Play details page for the product. */ | 5925 /** A link to the (consumer) Google Play details page for the product. */ |
| 6573 core.String detailsUrl; | 5926 core.String detailsUrl; |
| 6574 /** | 5927 /** |
| 6575 * How and to whom the package is made available. The value publicGoogleHosted | 5928 * How and to whom the package is made available. The value publicGoogleHosted |
| 6576 * means that the package is available through the Play Store and not | 5929 * means that the package is available through the Play store and not |
| 6577 * restricted to a specific enterprise. The value privateGoogleHosted means | 5930 * restricted to a specific enterprise. The value privateGoogleHosted means |
| 6578 * that the package is a private app (restricted to an enterprise) but hosted | 5931 * that the package is a private app (restricted to an enterprise) but hosted |
| 6579 * by Google. The value privateSelfHosted means that the package is a private | 5932 * by Google. The value privateSelfHosted means that the package is a private |
| 6580 * app (restricted to an enterprise) and is privately hosted. | 5933 * app (restricted to an enterprise) and is privately hosted. |
| 6581 */ | 5934 */ |
| 6582 core.String distributionChannel; | 5935 core.String distributionChannel; |
| 6583 /** | 5936 /** |
| 6584 * A link to an image that can be used as an icon for the product. This image | 5937 * A link to an image that can be used as an icon for the product. This image |
| 6585 * is suitable for use at up to 512px x 512px. | 5938 * is suitable for use at up to 512px x 512px. |
| 6586 */ | 5939 */ |
| 6587 core.String iconUrl; | 5940 core.String iconUrl; |
| 6588 /** | 5941 /** |
| 6589 * Identifies what kind of resource this is. Value: the fixed string | 5942 * Identifies what kind of resource this is. Value: the fixed string |
| 6590 * "androidenterprise#product". | 5943 * "androidenterprise#product". |
| 6591 */ | 5944 */ |
| 6592 core.String kind; | 5945 core.String kind; |
| 6593 /** | 5946 /** |
| 6594 * A string of the form app:<package name>. For example, | 5947 * A string of the form app:<package name>. For example, |
| 6595 * app:com.google.android.gm represents the Gmail app. | 5948 * app:com.google.android.gm represents the Gmail app. |
| 6596 */ | 5949 */ |
| 6597 core.String productId; | 5950 core.String productId; |
| 6598 /** | 5951 /** |
| 6599 * Whether this product is free, free with in-app purchases, or paid. If the | 5952 * Whether this product is free, free with in-app purchases, or paid. If the |
| 6600 * pricing is unknown, this means the product is not generally available | 5953 * pricing is unknown, this means the product is not generally available |
| 6601 * anymore (even though it might still be available to people who own it). | 5954 * anymore (even though it might still be available to people who own it). |
| 6602 */ | 5955 */ |
| 6603 core.String productPricing; | 5956 core.String productPricing; |
| 6604 /** | 5957 /** |
| 6605 * Whether this app can only be installed on devices using the Android for | 5958 * Whether this app can only be installed on devices using the Android |
| 6606 * Work container app. | 5959 * container app. |
| 6607 */ | 5960 */ |
| 6608 core.bool requiresContainerApp; | 5961 core.bool requiresContainerApp; |
| 6609 /** | 5962 /** |
| 6610 * A link to a smaller image that can be used as an icon for the product. This | 5963 * A link to a smaller image that can be used as an icon for the product. This |
| 6611 * image is suitable for use at up to 128px x 128px. | 5964 * image is suitable for use at up to 128px x 128px. |
| 6612 */ | 5965 */ |
| 6613 core.String smallIconUrl; | 5966 core.String smallIconUrl; |
| 6614 /** The name of the product. */ | 5967 /** The name of the product. */ |
| 6615 core.String title; | 5968 core.String title; |
| 6616 /** | 5969 /** |
| 6617 * A link to the Google Play for Work details page for the product, for use by | 5970 * A link to the managed Google Play details page for the product, for use by |
| 6618 * an Enterprise administrator. | 5971 * an Enterprise admin. |
| 6619 */ | 5972 */ |
| 6620 core.String workDetailsUrl; | 5973 core.String workDetailsUrl; |
| 6621 | 5974 |
| 6622 Product(); | 5975 Product(); |
| 6623 | 5976 |
| 6624 Product.fromJson(core.Map _json) { | 5977 Product.fromJson(core.Map _json) { |
| 6625 if (_json.containsKey("appVersion")) { | 5978 if (_json.containsKey("appVersion")) { |
| 6626 appVersion = _json["appVersion"].map((value) => new AppVersion.fromJson(va
lue)).toList(); | 5979 appVersion = _json["appVersion"].map((value) => new AppVersion.fromJson(va
lue)).toList(); |
| 6627 } | 5980 } |
| 6628 if (_json.containsKey("authorName")) { | 5981 if (_json.containsKey("authorName")) { |
| (...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6964 /** The matching products. */ | 6317 /** The matching products. */ |
| 6965 class ProductsListResponse { | 6318 class ProductsListResponse { |
| 6966 /** | 6319 /** |
| 6967 * Identifies what kind of resource this is. Value: the fixed string | 6320 * Identifies what kind of resource this is. Value: the fixed string |
| 6968 * "androidenterprise#productsListResponse". | 6321 * "androidenterprise#productsListResponse". |
| 6969 */ | 6322 */ |
| 6970 core.String kind; | 6323 core.String kind; |
| 6971 /** General pagination information. */ | 6324 /** General pagination information. */ |
| 6972 PageInfo pageInfo; | 6325 PageInfo pageInfo; |
| 6973 /** | 6326 /** |
| 6974 * Information about a product (e.g. an app) in the Google Play Store, for | 6327 * Information about a product (e.g. an app) in the Google Play store, for |
| 6975 * display to an enterprise admin. | 6328 * display to an enterprise admin. |
| 6976 */ | 6329 */ |
| 6977 core.List<Product> product; | 6330 core.List<Product> product; |
| 6978 /** Pagination information for token pagination. */ | 6331 /** Pagination information for token pagination. */ |
| 6979 TokenPagination tokenPagination; | 6332 TokenPagination tokenPagination; |
| 6980 | 6333 |
| 6981 ProductsListResponse(); | 6334 ProductsListResponse(); |
| 6982 | 6335 |
| 6983 ProductsListResponse.fromJson(core.Map _json) { | 6336 ProductsListResponse.fromJson(core.Map _json) { |
| 6984 if (_json.containsKey("kind")) { | 6337 if (_json.containsKey("kind")) { |
| (...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7194 _json["kind"] = kind; | 6547 _json["kind"] = kind; |
| 7195 } | 6548 } |
| 7196 if (url != null) { | 6549 if (url != null) { |
| 7197 _json["url"] = url; | 6550 _json["url"] = url; |
| 7198 } | 6551 } |
| 7199 return _json; | 6552 return _json; |
| 7200 } | 6553 } |
| 7201 } | 6554 } |
| 7202 | 6555 |
| 7203 /** | 6556 /** |
| 7204 * Definition of a Google Play for Work store cluster, a list of products | 6557 * Definition of a managed Google Play store cluster, a list of products |
| 7205 * displayed as part of a store page. | 6558 * displayed as part of a store page. |
| 7206 */ | 6559 */ |
| 7207 class StoreCluster { | 6560 class StoreCluster { |
| 7208 /** | 6561 /** |
| 7209 * Unique ID of this cluster. Assigned by the server. Immutable once assigned. | 6562 * Unique ID of this cluster. Assigned by the server. Immutable once assigned. |
| 7210 */ | 6563 */ |
| 7211 core.String id; | 6564 core.String id; |
| 7212 /** | 6565 /** |
| 7213 * Identifies what kind of resource this is. Value: the fixed string | 6566 * Identifies what kind of resource this is. Value: the fixed string |
| 7214 * "androidenterprise#storeCluster". | 6567 * "androidenterprise#storeCluster". |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7271 _json["orderInPage"] = orderInPage; | 6624 _json["orderInPage"] = orderInPage; |
| 7272 } | 6625 } |
| 7273 if (productId != null) { | 6626 if (productId != null) { |
| 7274 _json["productId"] = productId; | 6627 _json["productId"] = productId; |
| 7275 } | 6628 } |
| 7276 return _json; | 6629 return _json; |
| 7277 } | 6630 } |
| 7278 } | 6631 } |
| 7279 | 6632 |
| 7280 /** | 6633 /** |
| 7281 * General setting for the Google Play for Work store layout, currently only | 6634 * General setting for the managed Google Play store layout, currently only |
| 7282 * specifying the page to display the first time the store is opened. | 6635 * specifying the page to display the first time the store is opened. |
| 7283 */ | 6636 */ |
| 7284 class StoreLayout { | 6637 class StoreLayout { |
| 7285 /** | 6638 /** |
| 7286 * The ID of the store page to be used as the homepage. The homepage will be | 6639 * The ID of the store page to be used as the homepage. The homepage will be |
| 7287 * used as the first page shown in the Google Play for Work store. | 6640 * used as the first page shown in the managed Google Play store. |
| 7288 * | 6641 * |
| 7289 * If a homepage has not been set, the Play store shown on devices will be | 6642 * If a homepage has not been set, the Play store shown on devices will be |
| 7290 * empty. Not specifying a homepage on a store layout effectively empties the | 6643 * empty. Not specifying a homepage on a store layout effectively empties the |
| 7291 * store. | 6644 * store. |
| 7292 * | 6645 * |
| 7293 * If there exists at least one page, this field must be set to the ID of a | 6646 * If there exists at least one page, this field must be set to the ID of a |
| 7294 * valid page. | 6647 * valid page. |
| 7295 */ | 6648 */ |
| 7296 core.String homepageId; | 6649 core.String homepageId; |
| 7297 /** | 6650 /** |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7399 _json["kind"] = kind; | 6752 _json["kind"] = kind; |
| 7400 } | 6753 } |
| 7401 if (page != null) { | 6754 if (page != null) { |
| 7402 _json["page"] = page.map((value) => (value).toJson()).toList(); | 6755 _json["page"] = page.map((value) => (value).toJson()).toList(); |
| 7403 } | 6756 } |
| 7404 return _json; | 6757 return _json; |
| 7405 } | 6758 } |
| 7406 } | 6759 } |
| 7407 | 6760 |
| 7408 /** | 6761 /** |
| 7409 * Definition of a Google Play for Work store page, made of a localized name and | 6762 * Definition of a managed Google Play store page, made of a localized name and |
| 7410 * links to other pages. A page also contains clusters defined as a | 6763 * links to other pages. A page also contains clusters defined as a |
| 7411 * subcollection. | 6764 * subcollection. |
| 7412 */ | 6765 */ |
| 7413 class StorePage { | 6766 class StorePage { |
| 7414 /** | 6767 /** |
| 7415 * Unique ID of this page. Assigned by the server. Immutable once assigned. | 6768 * Unique ID of this page. Assigned by the server. Immutable once assigned. |
| 7416 */ | 6769 */ |
| 7417 core.String id; | 6770 core.String id; |
| 7418 /** | 6771 /** |
| 7419 * Identifies what kind of resource this is. Value: the fixed string | 6772 * Identifies what kind of resource this is. Value: the fixed string |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7497 _json["previousPageToken"] = previousPageToken; | 6850 _json["previousPageToken"] = previousPageToken; |
| 7498 } | 6851 } |
| 7499 return _json; | 6852 return _json; |
| 7500 } | 6853 } |
| 7501 } | 6854 } |
| 7502 | 6855 |
| 7503 /** | 6856 /** |
| 7504 * A Users resource represents an account associated with an enterprise. The | 6857 * A Users resource represents an account associated with an enterprise. The |
| 7505 * account may be specific to a device or to an individual user (who can then | 6858 * account may be specific to a device or to an individual user (who can then |
| 7506 * use the account across multiple devices). The account may provide access to | 6859 * use the account across multiple devices). The account may provide access to |
| 7507 * Google Play for Work only, or to other Google services, depending on the | 6860 * managed Google Play only, or to other Google services, depending on the |
| 7508 * identity model: | 6861 * identity model: |
| 7509 * - Google managed domain identity model requires synchronization to Google | 6862 * - The Google managed domain identity model requires synchronization to Google |
| 7510 * account sources (via primaryEmail). | 6863 * account sources (via primaryEmail). |
| 7511 * - Android for Work Accounts identity model provides a dynamic means for | 6864 * - The managed Google Play Accounts identity model provides a dynamic means |
| 7512 * enterprises to create user or device accounts as needed. These accounts | 6865 * for enterprises to create user or device accounts as needed. These accounts |
| 7513 * provide access to Google Play for Work only. | 6866 * provide access to managed Google Play. |
| 7514 */ | 6867 */ |
| 7515 class User { | 6868 class User { |
| 7516 /** | 6869 /** |
| 7517 * A unique identifier you create for this user, such as "user342" or | 6870 * A unique identifier you create for this user, such as "user342" or |
| 7518 * "asset#44418". Do not use personally identifiable information (PII) for | 6871 * "asset#44418". Do not use personally identifiable information (PII) for |
| 7519 * this property. Must always be set for EMM-managed users. Not set for | 6872 * this property. Must always be set for EMM-managed users. Not set for |
| 7520 * Google-managed users. | 6873 * Google-managed users. |
| 7521 */ | 6874 */ |
| 7522 core.String accountIdentifier; | 6875 core.String accountIdentifier; |
| 7523 /** | 6876 /** |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7602 } | 6955 } |
| 7603 if (primaryEmail != null) { | 6956 if (primaryEmail != null) { |
| 7604 _json["primaryEmail"] = primaryEmail; | 6957 _json["primaryEmail"] = primaryEmail; |
| 7605 } | 6958 } |
| 7606 return _json; | 6959 return _json; |
| 7607 } | 6960 } |
| 7608 } | 6961 } |
| 7609 | 6962 |
| 7610 /** | 6963 /** |
| 7611 * A UserToken is used by a user when setting up a managed device or profile | 6964 * A UserToken is used by a user when setting up a managed device or profile |
| 7612 * with their work account on a device. When the user enters their email address | 6965 * with their managed Google Play account on a device. When the user enters |
| 7613 * and token (activation code) the appropriate EMM app can be automatically | 6966 * their email address and token (activation code) the appropriate EMM app can |
| 7614 * downloaded. | 6967 * be automatically downloaded. |
| 7615 */ | 6968 */ |
| 7616 class UserToken { | 6969 class UserToken { |
| 7617 /** | 6970 /** |
| 7618 * Identifies what kind of resource this is. Value: the fixed string | 6971 * Identifies what kind of resource this is. Value: the fixed string |
| 7619 * "androidenterprise#userToken". | 6972 * "androidenterprise#userToken". |
| 7620 */ | 6973 */ |
| 7621 core.String kind; | 6974 core.String kind; |
| 7622 /** | 6975 /** |
| 7623 * The token (activation code) to be entered by the user. This consists of a | 6976 * The token (activation code) to be entered by the user. This consists of a |
| 7624 * sequence of decimal digits. Note that the leading digit may be 0. | 6977 * sequence of decimal digits. Note that the leading digit may be 0. |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7681 var _json = new core.Map(); | 7034 var _json = new core.Map(); |
| 7682 if (kind != null) { | 7035 if (kind != null) { |
| 7683 _json["kind"] = kind; | 7036 _json["kind"] = kind; |
| 7684 } | 7037 } |
| 7685 if (user != null) { | 7038 if (user != null) { |
| 7686 _json["user"] = user.map((value) => (value).toJson()).toList(); | 7039 _json["user"] = user.map((value) => (value).toJson()).toList(); |
| 7687 } | 7040 } |
| 7688 return _json; | 7041 return _json; |
| 7689 } | 7042 } |
| 7690 } | 7043 } |
| OLD | NEW |