google-api-client 0.8.7 → 0.9.pre1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (397) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +20 -0
  3. data/.rspec +2 -0
  4. data/.rubocop.yml +7 -0
  5. data/.rubocop_todo.yml +63 -0
  6. data/.travis.yml +21 -0
  7. data/.yardopts +12 -0
  8. data/CHANGELOG.md +6 -3
  9. data/CONTRIBUTING.md +31 -0
  10. data/Gemfile +28 -2
  11. data/MIGRATING.md +171 -0
  12. data/README.md +158 -150
  13. data/Rakefile +1 -40
  14. data/api_names.yaml +872 -0
  15. data/api_names_out.yaml +20843 -0
  16. data/bin/generate-api +93 -0
  17. data/generated/google/apis/adexchangebuyer_v1_3.rb +35 -0
  18. data/generated/google/apis/adexchangebuyer_v1_3/classes.rb +1124 -0
  19. data/generated/google/apis/adexchangebuyer_v1_3/representations.rb +375 -0
  20. data/generated/google/apis/adexchangebuyer_v1_3/service.rb +893 -0
  21. data/generated/google/apis/adexchangeseller_v2_0.rb +38 -0
  22. data/generated/google/apis/adexchangeseller_v2_0/classes.rb +792 -0
  23. data/generated/google/apis/adexchangeseller_v2_0/representations.rb +309 -0
  24. data/generated/google/apis/adexchangeseller_v2_0/service.rb +682 -0
  25. data/generated/google/apis/admin_directory_v1.rb +89 -0
  26. data/generated/google/apis/admin_directory_v1/classes.rb +2389 -0
  27. data/generated/google/apis/admin_directory_v1/representations.rb +780 -0
  28. data/generated/google/apis/admin_directory_v1/service.rb +2805 -0
  29. data/generated/google/apis/admin_reports_v1.rb +38 -0
  30. data/generated/google/apis/admin_reports_v1/classes.rb +582 -0
  31. data/generated/google/apis/admin_reports_v1/representations.rb +231 -0
  32. data/generated/google/apis/admin_reports_v1/service.rb +341 -0
  33. data/generated/google/apis/adsense_v1_4.rb +38 -0
  34. data/generated/google/apis/adsense_v1_4/classes.rb +1279 -0
  35. data/generated/google/apis/adsense_v1_4/representations.rb +493 -0
  36. data/generated/google/apis/adsense_v1_4/service.rb +1752 -0
  37. data/generated/google/apis/adsensehost_v4_1.rb +35 -0
  38. data/generated/google/apis/adsensehost_v4_1/classes.rb +834 -0
  39. data/generated/google/apis/adsensehost_v4_1/representations.rb +327 -0
  40. data/generated/google/apis/adsensehost_v4_1/service.rb +1190 -0
  41. data/generated/google/apis/analytics_v3.rb +49 -0
  42. data/generated/google/apis/analytics_v3/classes.rb +5113 -0
  43. data/generated/google/apis/analytics_v3/representations.rb +1661 -0
  44. data/generated/google/apis/analytics_v3/service.rb +3600 -0
  45. data/generated/google/apis/androidenterprise_v1.rb +34 -0
  46. data/generated/google/apis/androidenterprise_v1/classes.rb +1162 -0
  47. data/generated/google/apis/androidenterprise_v1/representations.rb +431 -0
  48. data/generated/google/apis/androidenterprise_v1/service.rb +1979 -0
  49. data/generated/google/apis/androidpublisher_v2.rb +34 -0
  50. data/generated/google/apis/androidpublisher_v2/classes.rb +1374 -0
  51. data/generated/google/apis/androidpublisher_v2/representations.rb +630 -0
  52. data/generated/google/apis/androidpublisher_v2/service.rb +2390 -0
  53. data/generated/google/apis/appsactivity_v1.rb +46 -0
  54. data/generated/google/apis/appsactivity_v1/classes.rb +392 -0
  55. data/generated/google/apis/appsactivity_v1/representations.rb +184 -0
  56. data/generated/google/apis/appsactivity_v1/service.rb +129 -0
  57. data/generated/google/apis/appstate_v1.rb +34 -0
  58. data/generated/google/apis/appstate_v1/classes.rb +154 -0
  59. data/generated/google/apis/appstate_v1/representations.rb +79 -0
  60. data/generated/google/apis/appstate_v1/service.rb +265 -0
  61. data/generated/google/apis/autoscaler_v1beta2.rb +38 -0
  62. data/generated/google/apis/autoscaler_v1beta2/classes.rb +747 -0
  63. data/generated/google/apis/autoscaler_v1beta2/representations.rb +281 -0
  64. data/generated/google/apis/autoscaler_v1beta2/service.rb +488 -0
  65. data/generated/google/apis/bigquery_v2.rb +49 -0
  66. data/generated/google/apis/bigquery_v2/classes.rb +2255 -0
  67. data/generated/google/apis/bigquery_v2/representations.rb +754 -0
  68. data/generated/google/apis/bigquery_v2/service.rb +1003 -0
  69. data/generated/google/apis/blogger_v3.rb +37 -0
  70. data/generated/google/apis/blogger_v3/classes.rb +1354 -0
  71. data/generated/google/apis/blogger_v3/representations.rb +562 -0
  72. data/generated/google/apis/blogger_v3/service.rb +1620 -0
  73. data/generated/google/apis/books_v1.rb +34 -0
  74. data/generated/google/apis/books_v1/classes.rb +3515 -0
  75. data/generated/google/apis/books_v1/representations.rb +1361 -0
  76. data/generated/google/apis/books_v1/service.rb +2170 -0
  77. data/generated/google/apis/calendar_v3.rb +37 -0
  78. data/generated/google/apis/calendar_v3/classes.rb +1702 -0
  79. data/generated/google/apis/calendar_v3/representations.rb +566 -0
  80. data/generated/google/apis/calendar_v3/service.rb +1943 -0
  81. data/generated/google/apis/civicinfo_v2.rb +31 -0
  82. data/generated/google/apis/civicinfo_v2/classes.rb +1057 -0
  83. data/generated/google/apis/civicinfo_v2/representations.rb +374 -0
  84. data/generated/google/apis/civicinfo_v2/service.rb +284 -0
  85. data/generated/google/apis/cloudmonitoring_v2beta2.rb +34 -0
  86. data/generated/google/apis/cloudmonitoring_v2beta2/classes.rb +679 -0
  87. data/generated/google/apis/cloudmonitoring_v2beta2/representations.rb +311 -0
  88. data/generated/google/apis/cloudmonitoring_v2beta2/service.rb +458 -0
  89. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +38 -0
  90. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +139 -0
  91. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +65 -0
  92. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +301 -0
  93. data/generated/google/apis/compute_v1.rb +49 -0
  94. data/generated/google/apis/compute_v1/classes.rb +6391 -0
  95. data/generated/google/apis/compute_v1/representations.rb +2209 -0
  96. data/generated/google/apis/compute_v1/service.rb +6352 -0
  97. data/generated/google/apis/container_v1beta1.rb +35 -0
  98. data/generated/google/apis/container_v1beta1/classes.rb +466 -0
  99. data/generated/google/apis/container_v1beta1/representations.rb +177 -0
  100. data/generated/google/apis/container_v1beta1/service.rb +394 -0
  101. data/generated/google/apis/content_v2.rb +35 -0
  102. data/generated/google/apis/content_v2/classes.rb +3780 -0
  103. data/generated/google/apis/content_v2/representations.rb +1456 -0
  104. data/generated/google/apis/content_v2/service.rb +1706 -0
  105. data/generated/google/apis/coordinate_v1.rb +37 -0
  106. data/generated/google/apis/coordinate_v1/classes.rb +669 -0
  107. data/generated/google/apis/coordinate_v1/representations.rb +285 -0
  108. data/generated/google/apis/coordinate_v1/service.rb +687 -0
  109. data/{lib/google/api_client/auth/compute_service_account.rb → generated/google/apis/customsearch_v1.rb} +13 -10
  110. data/generated/google/apis/customsearch_v1/classes.rb +771 -0
  111. data/generated/google/apis/customsearch_v1/representations.rb +276 -0
  112. data/generated/google/apis/customsearch_v1/service.rb +208 -0
  113. data/generated/google/apis/datastore_v1beta2.rb +40 -0
  114. data/generated/google/apis/datastore_v1beta2/classes.rb +1186 -0
  115. data/generated/google/apis/datastore_v1beta2/representations.rb +526 -0
  116. data/generated/google/apis/datastore_v1beta2/service.rb +300 -0
  117. data/generated/google/apis/deploymentmanager_v2beta2.rb +41 -0
  118. data/generated/google/apis/deploymentmanager_v2beta2/classes.rb +820 -0
  119. data/generated/google/apis/deploymentmanager_v2beta2/representations.rb +303 -0
  120. data/generated/google/apis/deploymentmanager_v2beta2/service.rb +647 -0
  121. data/generated/google/apis/dfareporting_v2_1.rb +37 -0
  122. data/generated/google/apis/dfareporting_v2_1/classes.rb +10755 -0
  123. data/generated/google/apis/dfareporting_v2_1/representations.rb +3438 -0
  124. data/generated/google/apis/dfareporting_v2_1/service.rb +8775 -0
  125. data/generated/google/apis/discovery_v1.rb +32 -0
  126. data/generated/google/apis/discovery_v1/classes.rb +947 -0
  127. data/generated/google/apis/discovery_v1/representations.rb +355 -0
  128. data/generated/google/apis/discovery_v1/service.rb +144 -0
  129. data/generated/google/apis/dns_v1.rb +41 -0
  130. data/generated/google/apis/dns_v1/classes.rb +406 -0
  131. data/generated/google/apis/dns_v1/representations.rb +151 -0
  132. data/generated/google/apis/dns_v1/service.rb +460 -0
  133. data/{spec/google/api_client/request_spec.rb → generated/google/apis/doubleclickbidmanager_v1.rb} +15 -13
  134. data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +709 -0
  135. data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +297 -0
  136. data/generated/google/apis/doubleclickbidmanager_v1/service.rb +349 -0
  137. data/generated/google/apis/doubleclicksearch_v2.rb +35 -0
  138. data/generated/google/apis/doubleclicksearch_v2/classes.rb +947 -0
  139. data/generated/google/apis/doubleclicksearch_v2/representations.rb +315 -0
  140. data/generated/google/apis/doubleclicksearch_v2/service.rb +490 -0
  141. data/generated/google/apis/drive_v2.rb +55 -0
  142. data/generated/google/apis/drive_v2/classes.rb +2519 -0
  143. data/generated/google/apis/drive_v2/representations.rb +781 -0
  144. data/generated/google/apis/drive_v2/service.rb +2685 -0
  145. data/generated/google/apis/fitness_v1.rb +49 -0
  146. data/generated/google/apis/fitness_v1/classes.rb +809 -0
  147. data/generated/google/apis/fitness_v1/representations.rb +295 -0
  148. data/generated/google/apis/fitness_v1/service.rb +684 -0
  149. data/generated/google/apis/fusiontables_v2.rb +37 -0
  150. data/generated/google/apis/fusiontables_v2/classes.rb +1048 -0
  151. data/generated/google/apis/fusiontables_v2/representations.rb +409 -0
  152. data/generated/google/apis/fusiontables_v2/service.rb +1496 -0
  153. data/generated/google/apis/games_configuration_v1configuration.rb +34 -0
  154. data/generated/google/apis/games_configuration_v1configuration/classes.rb +506 -0
  155. data/generated/google/apis/games_configuration_v1configuration/representations.rb +206 -0
  156. data/generated/google/apis/games_configuration_v1configuration/service.rb +578 -0
  157. data/generated/google/apis/games_v1.rb +40 -0
  158. data/generated/google/apis/games_v1/classes.rb +4578 -0
  159. data/generated/google/apis/games_v1/representations.rb +1570 -0
  160. data/generated/google/apis/games_v1/service.rb +2306 -0
  161. data/generated/google/apis/gan_v1beta1.rb +31 -0
  162. data/generated/google/apis/gan_v1beta1/classes.rb +1428 -0
  163. data/generated/google/apis/gan_v1beta1/representations.rb +428 -0
  164. data/generated/google/apis/gan_v1beta1/service.rb +692 -0
  165. data/generated/google/apis/genomics_v1beta2.rb +46 -0
  166. data/generated/google/apis/genomics_v1beta2/classes.rb +3288 -0
  167. data/generated/google/apis/genomics_v1beta2/representations.rb +1194 -0
  168. data/generated/google/apis/genomics_v1beta2/service.rb +2356 -0
  169. data/generated/google/apis/gmail_v1.rb +49 -0
  170. data/generated/google/apis/gmail_v1/classes.rb +794 -0
  171. data/generated/google/apis/gmail_v1/representations.rb +339 -0
  172. data/generated/google/apis/gmail_v1/service.rb +1502 -0
  173. data/generated/google/apis/groupsmigration_v1.rb +34 -0
  174. data/generated/google/apis/groupsmigration_v1/classes.rb +51 -0
  175. data/generated/google/apis/groupsmigration_v1/representations.rb +38 -0
  176. data/generated/google/apis/groupsmigration_v1/service.rb +111 -0
  177. data/generated/google/apis/groupssettings_v1.rb +34 -0
  178. data/generated/google/apis/groupssettings_v1/classes.rb +221 -0
  179. data/generated/google/apis/groupssettings_v1/representations.rb +64 -0
  180. data/generated/google/apis/groupssettings_v1/service.rb +179 -0
  181. data/generated/google/apis/identitytoolkit_v3.rb +31 -0
  182. data/generated/google/apis/identitytoolkit_v3/classes.rb +1229 -0
  183. data/generated/google/apis/identitytoolkit_v3/representations.rb +422 -0
  184. data/generated/google/apis/identitytoolkit_v3/service.rb +491 -0
  185. data/generated/google/apis/licensing_v1.rb +34 -0
  186. data/generated/google/apis/licensing_v1/classes.rb +132 -0
  187. data/generated/google/apis/licensing_v1/representations.rb +68 -0
  188. data/generated/google/apis/licensing_v1/service.rb +376 -0
  189. data/generated/google/apis/logging_v1beta3.rb +35 -0
  190. data/generated/google/apis/logging_v1beta3/classes.rb +505 -0
  191. data/generated/google/apis/logging_v1beta3/representations.rb +222 -0
  192. data/generated/google/apis/logging_v1beta3/service.rb +670 -0
  193. data/generated/google/apis/manager_v1beta2.rb +50 -0
  194. data/generated/google/apis/manager_v1beta2/classes.rb +1287 -0
  195. data/generated/google/apis/manager_v1beta2/representations.rb +536 -0
  196. data/generated/google/apis/manager_v1beta2/service.rb +380 -0
  197. data/generated/google/apis/mapsengine_v1.rb +38 -0
  198. data/generated/google/apis/mapsengine_v1/classes.rb +2873 -0
  199. data/generated/google/apis/mapsengine_v1/representations.rb +1235 -0
  200. data/generated/google/apis/mapsengine_v1/service.rb +3465 -0
  201. data/generated/google/apis/mirror_v1.rb +37 -0
  202. data/generated/google/apis/mirror_v1/classes.rb +1072 -0
  203. data/generated/google/apis/mirror_v1/representations.rb +350 -0
  204. data/generated/google/apis/mirror_v1/service.rb +1001 -0
  205. data/generated/google/apis/oauth2_v2.rb +43 -0
  206. data/generated/google/apis/oauth2_v2/classes.rb +245 -0
  207. data/generated/google/apis/oauth2_v2/representations.rb +94 -0
  208. data/generated/google/apis/oauth2_v2/service.rb +203 -0
  209. data/generated/google/apis/pagespeedonline_v2.rb +32 -0
  210. data/generated/google/apis/pagespeedonline_v2/classes.rb +614 -0
  211. data/generated/google/apis/pagespeedonline_v2/representations.rb +244 -0
  212. data/generated/google/apis/pagespeedonline_v2/service.rb +120 -0
  213. data/generated/google/apis/plus_domains_v1.rb +61 -0
  214. data/generated/google/apis/plus_domains_v1/classes.rb +2402 -0
  215. data/generated/google/apis/plus_domains_v1/representations.rb +873 -0
  216. data/generated/google/apis/plus_domains_v1/service.rb +924 -0
  217. data/generated/google/apis/plus_v1.rb +43 -0
  218. data/generated/google/apis/plus_v1/classes.rb +2384 -0
  219. data/generated/google/apis/plus_v1/representations.rb +812 -0
  220. data/generated/google/apis/plus_v1/service.rb +616 -0
  221. data/generated/google/apis/prediction_v1_6.rb +44 -0
  222. data/generated/google/apis/prediction_v1_6/classes.rb +751 -0
  223. data/generated/google/apis/prediction_v1_6/representations.rb +327 -0
  224. data/generated/google/apis/prediction_v1_6/service.rb +388 -0
  225. data/generated/google/apis/pubsub_v1beta2.rb +37 -0
  226. data/generated/google/apis/pubsub_v1beta2/classes.rb +824 -0
  227. data/generated/google/apis/pubsub_v1beta2/representations.rb +366 -0
  228. data/generated/google/apis/pubsub_v1beta2/service.rb +778 -0
  229. data/generated/google/apis/qpx_express_v1.rb +31 -0
  230. data/generated/google/apis/qpx_express_v1/classes.rb +1268 -0
  231. data/generated/google/apis/qpx_express_v1/representations.rb +424 -0
  232. data/generated/google/apis/qpx_express_v1/service.rb +101 -0
  233. data/generated/google/apis/replicapool_v1beta2.rb +41 -0
  234. data/generated/google/apis/replicapool_v1beta2/classes.rb +621 -0
  235. data/generated/google/apis/replicapool_v1beta2/representations.rb +235 -0
  236. data/generated/google/apis/replicapool_v1beta2/service.rb +620 -0
  237. data/generated/google/apis/replicapoolupdater_v1beta1.rb +41 -0
  238. data/generated/google/apis/replicapoolupdater_v1beta1/classes.rb +682 -0
  239. data/generated/google/apis/replicapoolupdater_v1beta1/representations.rb +247 -0
  240. data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +472 -0
  241. data/generated/google/apis/reseller_v1.rb +37 -0
  242. data/generated/google/apis/reseller_v1/classes.rb +502 -0
  243. data/generated/google/apis/reseller_v1/representations.rb +199 -0
  244. data/generated/google/apis/reseller_v1/service.rb +637 -0
  245. data/generated/google/apis/resourceviews_v1beta2.rb +47 -0
  246. data/generated/google/apis/resourceviews_v1beta2/classes.rb +660 -0
  247. data/generated/google/apis/resourceviews_v1beta2/representations.rb +269 -0
  248. data/generated/google/apis/resourceviews_v1beta2/service.rb +574 -0
  249. data/generated/google/apis/site_verification_v1.rb +37 -0
  250. data/generated/google/apis/site_verification_v1/classes.rb +185 -0
  251. data/generated/google/apis/site_verification_v1/representations.rb +101 -0
  252. data/generated/google/apis/site_verification_v1/service.rb +322 -0
  253. data/generated/google/apis/sqladmin_v1beta4.rb +37 -0
  254. data/generated/google/apis/sqladmin_v1beta4/classes.rb +1817 -0
  255. data/generated/google/apis/sqladmin_v1beta4/representations.rb +688 -0
  256. data/generated/google/apis/sqladmin_v1beta4/service.rb +1534 -0
  257. data/generated/google/apis/storage_v1.rb +43 -0
  258. data/generated/google/apis/storage_v1/classes.rb +1177 -0
  259. data/generated/google/apis/storage_v1/representations.rb +427 -0
  260. data/generated/google/apis/storage_v1/service.rb +1920 -0
  261. data/generated/google/apis/tagmanager_v1.rb +52 -0
  262. data/generated/google/apis/tagmanager_v1/classes.rb +1226 -0
  263. data/generated/google/apis/tagmanager_v1/representations.rb +461 -0
  264. data/generated/google/apis/tagmanager_v1/service.rb +1978 -0
  265. data/generated/google/apis/taskqueue_v1beta2.rb +37 -0
  266. data/generated/google/apis/taskqueue_v1beta2/classes.rb +254 -0
  267. data/generated/google/apis/taskqueue_v1beta2/representations.rb +114 -0
  268. data/generated/google/apis/taskqueue_v1beta2/service.rb +416 -0
  269. data/generated/google/apis/tasks_v1.rb +37 -0
  270. data/generated/google/apis/tasks_v1/classes.rb +296 -0
  271. data/generated/google/apis/tasks_v1/representations.rb +115 -0
  272. data/generated/google/apis/tasks_v1/service.rb +657 -0
  273. data/generated/google/apis/translate_v2.rb +31 -0
  274. data/generated/google/apis/translate_v2/classes.rb +168 -0
  275. data/generated/google/apis/translate_v2/representations.rb +109 -0
  276. data/generated/google/apis/translate_v2/service.rb +185 -0
  277. data/generated/google/apis/urlshortener_v1.rb +34 -0
  278. data/generated/google/apis/urlshortener_v1/classes.rb +246 -0
  279. data/generated/google/apis/urlshortener_v1/representations.rb +111 -0
  280. data/generated/google/apis/urlshortener_v1/service.rb +179 -0
  281. data/generated/google/apis/webmasters_v3.rb +37 -0
  282. data/generated/google/apis/webmasters_v3/classes.rb +563 -0
  283. data/generated/google/apis/webmasters_v3/representations.rb +250 -0
  284. data/generated/google/apis/webmasters_v3/service.rb +587 -0
  285. data/generated/google/apis/youtube_analytics_v1.rb +46 -0
  286. data/generated/google/apis/youtube_analytics_v1/classes.rb +540 -0
  287. data/generated/google/apis/youtube_analytics_v1/representations.rb +242 -0
  288. data/generated/google/apis/youtube_analytics_v1/service.rb +567 -0
  289. data/generated/google/apis/youtube_v3.rb +49 -0
  290. data/generated/google/apis/youtube_v3/classes.rb +7225 -0
  291. data/generated/google/apis/youtube_v3/representations.rb +2529 -0
  292. data/generated/google/apis/youtube_v3/service.rb +4051 -0
  293. data/google-api-client.gemspec +27 -39
  294. data/lib/google/api_client/auth/storage.rb +3 -2
  295. data/lib/google/api_client/auth/storages/file_store.rb +1 -3
  296. data/lib/google/api_client/auth/storages/redis_store.rb +6 -2
  297. data/lib/google/apis.rb +48 -0
  298. data/lib/google/apis/core/api_command.rb +128 -0
  299. data/lib/google/apis/core/base_service.rb +314 -0
  300. data/lib/google/apis/core/batch.rb +222 -0
  301. data/lib/google/apis/core/download.rb +94 -0
  302. data/lib/google/apis/core/hashable.rb +44 -0
  303. data/lib/google/apis/core/http_command.rb +275 -0
  304. data/lib/google/apis/core/json_representation.rb +122 -0
  305. data/lib/google/{api_client/version.rb → apis/core/logging.rb} +12 -8
  306. data/lib/google/apis/core/multipart.rb +173 -0
  307. data/lib/google/apis/core/upload.rb +275 -0
  308. data/lib/google/{api_client → apis}/errors.rb +32 -28
  309. data/lib/google/apis/generator.rb +70 -0
  310. data/lib/google/apis/generator/annotator.rb +271 -0
  311. data/lib/google/apis/generator/helpers.rb +74 -0
  312. data/lib/google/apis/generator/model.rb +130 -0
  313. data/lib/google/apis/generator/template.rb +124 -0
  314. data/lib/google/apis/generator/templates/_class.tmpl +40 -0
  315. data/lib/google/apis/generator/templates/_method.tmpl +90 -0
  316. data/lib/google/apis/generator/templates/_representation.tmpl +51 -0
  317. data/lib/google/apis/generator/templates/_representation_stub.tmpl +15 -0
  318. data/lib/google/apis/generator/templates/_representation_type.tmpl +10 -0
  319. data/lib/google/{api_client/reference.rb → apis/generator/templates/classes.rb.tmpl} +11 -9
  320. data/lib/google/apis/generator/templates/module.rb.tmpl +40 -0
  321. data/lib/google/apis/generator/templates/representations.rb.tmpl +32 -0
  322. data/lib/google/apis/generator/templates/service.rb.tmpl +60 -0
  323. data/lib/google/apis/options.rb +79 -0
  324. data/lib/google/apis/version.rb +39 -0
  325. data/rakelib/metrics.rake +22 -0
  326. data/rakelib/rubocop.rake +10 -0
  327. data/rakelib/spec.rake +11 -0
  328. data/rakelib/yard.rake +11 -0
  329. data/samples/calendar/calendar.rb +43 -0
  330. data/samples/drive/drive.rb +40 -0
  331. data/samples/pubsub/pubsub.rb +52 -0
  332. data/{lib/google/api_client/discovery.rb → samples/translate/translate.rb} +14 -5
  333. data/script/generate +79 -0
  334. data/script/package +8 -0
  335. data/script/release +15 -0
  336. data/spec/fixtures/files/api_names.yaml +3 -0
  337. data/spec/fixtures/files/auth_stored_credentials.json +8 -0
  338. data/spec/fixtures/files/client_secrets.json +1 -0
  339. data/spec/fixtures/files/test.blah +1 -0
  340. data/spec/fixtures/files/test.txt +1 -0
  341. data/spec/fixtures/files/test_api.json +440 -0
  342. data/spec/google/api_client/auth/storage_spec.rb +1 -3
  343. data/spec/google/api_client/auth/storages/file_store_spec.rb +1 -2
  344. data/spec/google/api_client/auth/storages/redis_store_spec.rb +1 -3
  345. data/spec/google/apis/core/api_command_spec.rb +170 -0
  346. data/spec/google/apis/core/batch_spec.rb +128 -0
  347. data/spec/google/apis/core/download_spec.rb +90 -0
  348. data/spec/google/apis/core/hashable_spec.rb +60 -0
  349. data/spec/google/apis/core/http_command_spec.rb +238 -0
  350. data/spec/google/apis/core/json_representation_spec.rb +192 -0
  351. data/spec/google/apis/core/service_spec.rb +247 -0
  352. data/spec/google/apis/core/upload_spec.rb +238 -0
  353. data/{lib/google/api_client/service_account.rb → spec/google/apis/generated_spec.rb} +14 -8
  354. data/spec/google/apis/generator/generator_spec.rb +272 -0
  355. data/spec/google/apis/logging_spec.rb +45 -0
  356. data/spec/google/apis/options_spec.rb +40 -0
  357. data/spec/integration_tests/drive_spec.rb +35 -0
  358. data/spec/integration_tests/pubsub_spec.rb +48 -0
  359. data/spec/integration_tests/url_shortener_spec.rb +31 -0
  360. data/spec/spec_helper.rb +102 -46
  361. metadata +433 -178
  362. data/lib/compat/multi_json.rb +0 -19
  363. data/lib/google/api_client.rb +0 -750
  364. data/lib/google/api_client/auth/file_storage.rb +0 -59
  365. data/lib/google/api_client/auth/jwt_asserter.rb +0 -126
  366. data/lib/google/api_client/auth/key_utils.rb +0 -93
  367. data/lib/google/api_client/auth/pkcs12.rb +0 -41
  368. data/lib/google/api_client/batch.rb +0 -326
  369. data/lib/google/api_client/charset.rb +0 -33
  370. data/lib/google/api_client/discovery/api.rb +0 -310
  371. data/lib/google/api_client/discovery/media.rb +0 -77
  372. data/lib/google/api_client/discovery/method.rb +0 -363
  373. data/lib/google/api_client/discovery/resource.rb +0 -156
  374. data/lib/google/api_client/discovery/schema.rb +0 -117
  375. data/lib/google/api_client/environment.rb +0 -42
  376. data/lib/google/api_client/gzip.rb +0 -28
  377. data/lib/google/api_client/logging.rb +0 -32
  378. data/lib/google/api_client/media.rb +0 -259
  379. data/lib/google/api_client/railtie.rb +0 -18
  380. data/lib/google/api_client/request.rb +0 -350
  381. data/lib/google/api_client/result.rb +0 -255
  382. data/lib/google/api_client/service.rb +0 -233
  383. data/lib/google/api_client/service/batch.rb +0 -110
  384. data/lib/google/api_client/service/request.rb +0 -144
  385. data/lib/google/api_client/service/resource.rb +0 -40
  386. data/lib/google/api_client/service/result.rb +0 -162
  387. data/lib/google/api_client/service/simple_file_store.rb +0 -151
  388. data/lib/google/api_client/service/stub_generator.rb +0 -61
  389. data/spec/google/api_client/batch_spec.rb +0 -248
  390. data/spec/google/api_client/discovery_spec.rb +0 -708
  391. data/spec/google/api_client/gzip_spec.rb +0 -98
  392. data/spec/google/api_client/media_spec.rb +0 -178
  393. data/spec/google/api_client/result_spec.rb +0 -207
  394. data/spec/google/api_client/service_account_spec.rb +0 -169
  395. data/spec/google/api_client/service_spec.rb +0 -618
  396. data/spec/google/api_client/simple_file_store_spec.rb +0 -133
  397. data/spec/google/api_client_spec.rb +0 -352
@@ -0,0 +1,34 @@
1
+ # Copyright 2015 Google Inc.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'google/apis/androidenterprise_v1/service.rb'
16
+ require 'google/apis/androidenterprise_v1/classes.rb'
17
+ require 'google/apis/androidenterprise_v1/representations.rb'
18
+
19
+ module Google
20
+ module Apis
21
+ # Google Play EMM API
22
+ #
23
+ # Allows MDMs/EMMs and enterprises to manage the deployment of apps to Android
24
+ # for Work users.
25
+ #
26
+ module AndroidenterpriseV1
27
+ VERSION = 'V1'
28
+ REVISION = '20150303'
29
+
30
+ # Manage corporate Android devices
31
+ AUTH_ANDROIDENTERPRISE = 'https://www.googleapis.com/auth/androidenterprise'
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,1162 @@
1
+ # Copyright 2015 Google Inc.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'date'
16
+ require 'google/apis/core/base_service'
17
+ require 'google/apis/core/json_representation'
18
+ require 'google/apis/core/hashable'
19
+ require 'google/apis/errors'
20
+
21
+ module Google
22
+ module Apis
23
+ module AndroidenterpriseV1
24
+
25
+ # Represents the list of app restrictions available to be pre-configured for the
26
+ # product.
27
+ class AppRestrictionsSchema
28
+ include Google::Apis::Core::Hashable
29
+
30
+ # The set of restrictions that make up this schema.
31
+ # Corresponds to the JSON property `restrictions`
32
+ # @return [Array<Google::Apis::AndroidenterpriseV1::AppRestrictionsSchemaRestriction>]
33
+ attr_accessor :restrictions
34
+
35
+ def initialize(**args)
36
+ update!(**args)
37
+ end
38
+
39
+ # Update properties of this object
40
+ def update!(**args)
41
+ @restrictions = args[:restrictions] unless args[:restrictions].nil?
42
+ end
43
+ end
44
+
45
+ # A restriction in the App Restriction Schema represents a piece of
46
+ # configuration that may be pre-applied.
47
+ class AppRestrictionsSchemaRestriction
48
+ include Google::Apis::Core::Hashable
49
+
50
+ # A typed value for the restriction.
51
+ # Corresponds to the JSON property `defaultValue`
52
+ # @return [Google::Apis::AndroidenterpriseV1::AppRestrictionsSchemaRestrictionRestrictionValue]
53
+ attr_accessor :default_value
54
+
55
+ # A longer description of the restriction, giving more detail of what it affects.
56
+ # Corresponds to the JSON property `description`
57
+ # @return [String]
58
+ attr_accessor :description
59
+
60
+ # For choice or multiselect restrictions, the list of possible entries' human-
61
+ # readable names.
62
+ # Corresponds to the JSON property `entry`
63
+ # @return [Array<String>]
64
+ attr_accessor :entry
65
+
66
+ # For choice or multiselect restrictions, the list of possible entries' machine-
67
+ # readable values.
68
+ # Corresponds to the JSON property `entryValue`
69
+ # @return [Array<String>]
70
+ attr_accessor :entry_value
71
+
72
+ # The unique key that the product uses to identify the restriction, e.g. "com.
73
+ # google.android.gm.fieldname".
74
+ # Corresponds to the JSON property `key`
75
+ # @return [String]
76
+ attr_accessor :key
77
+
78
+ # The type of the restriction.
79
+ # Corresponds to the JSON property `restrictionType`
80
+ # @return [String]
81
+ attr_accessor :restriction_type
82
+
83
+ # The name of the restriction.
84
+ # Corresponds to the JSON property `title`
85
+ # @return [String]
86
+ attr_accessor :title
87
+
88
+ def initialize(**args)
89
+ update!(**args)
90
+ end
91
+
92
+ # Update properties of this object
93
+ def update!(**args)
94
+ @default_value = args[:default_value] unless args[:default_value].nil?
95
+ @description = args[:description] unless args[:description].nil?
96
+ @entry = args[:entry] unless args[:entry].nil?
97
+ @entry_value = args[:entry_value] unless args[:entry_value].nil?
98
+ @key = args[:key] unless args[:key].nil?
99
+ @restriction_type = args[:restriction_type] unless args[:restriction_type].nil?
100
+ @title = args[:title] unless args[:title].nil?
101
+ end
102
+ end
103
+
104
+ # A typed value for the restriction.
105
+ class AppRestrictionsSchemaRestrictionRestrictionValue
106
+ include Google::Apis::Core::Hashable
107
+
108
+ # The type of the value being provided.
109
+ # Corresponds to the JSON property `type`
110
+ # @return [String]
111
+ attr_accessor :type
112
+
113
+ # The boolean value - this will only be present if type is bool.
114
+ # Corresponds to the JSON property `valueBool`
115
+ # @return [Boolean]
116
+ attr_accessor :value_bool
117
+ alias_method :value_bool?, :value_bool
118
+
119
+ # The integer value - this will only be present if type is integer.
120
+ # Corresponds to the JSON property `valueInteger`
121
+ # @return [Fixnum]
122
+ attr_accessor :value_integer
123
+
124
+ # The list of string values - this will only be present if type is multiselect.
125
+ # Corresponds to the JSON property `valueMultiselect`
126
+ # @return [Array<String>]
127
+ attr_accessor :value_multiselect
128
+
129
+ # The string value - this will be present for types string, choice and hidden.
130
+ # Corresponds to the JSON property `valueString`
131
+ # @return [String]
132
+ attr_accessor :value_string
133
+
134
+ def initialize(**args)
135
+ update!(**args)
136
+ end
137
+
138
+ # Update properties of this object
139
+ def update!(**args)
140
+ @type = args[:type] unless args[:type].nil?
141
+ @value_bool = args[:value_bool] unless args[:value_bool].nil?
142
+ @value_integer = args[:value_integer] unless args[:value_integer].nil?
143
+ @value_multiselect = args[:value_multiselect] unless args[:value_multiselect].nil?
144
+ @value_string = args[:value_string] unless args[:value_string].nil?
145
+ end
146
+ end
147
+
148
+ # App version represents a single APK version.
149
+ class AppVersion
150
+ include Google::Apis::Core::Hashable
151
+
152
+ # Unique increasing identifier for the apk version.
153
+ # Corresponds to the JSON property `versionCode`
154
+ # @return [Fixnum]
155
+ attr_accessor :version_code
156
+
157
+ # The string used in the Play Store by the app developer to identify a version
158
+ # of an app. The string is not necessarily unique or localized (e.g. "1.4").
159
+ # Corresponds to the JSON property `versionString`
160
+ # @return [String]
161
+ attr_accessor :version_string
162
+
163
+ def initialize(**args)
164
+ update!(**args)
165
+ end
166
+
167
+ # Update properties of this object
168
+ def update!(**args)
169
+ @version_code = args[:version_code] unless args[:version_code].nil?
170
+ @version_string = args[:version_string] unless args[:version_string].nil?
171
+ end
172
+ end
173
+
174
+ # Information on an approval URL.
175
+ class ApprovalUrlInfo
176
+ include Google::Apis::Core::Hashable
177
+
178
+ # A URL that displays a product's permissions and that can also be used to
179
+ # approve the product with the Products.approve call.
180
+ # Corresponds to the JSON property `approvalUrl`
181
+ # @return [String]
182
+ attr_accessor :approval_url
183
+
184
+ # Identifies what kind of resource this is. Value: the fixed string "
185
+ # androidenterprise#approvalUrlInfo".
186
+ # Corresponds to the JSON property `kind`
187
+ # @return [String]
188
+ attr_accessor :kind
189
+
190
+ def initialize(**args)
191
+ update!(**args)
192
+ end
193
+
194
+ # Update properties of this object
195
+ def update!(**args)
196
+ @approval_url = args[:approval_url] unless args[:approval_url].nil?
197
+ @kind = args[:kind] unless args[:kind].nil?
198
+ end
199
+ end
200
+
201
+ # A collection resource defines a named set of apps that is visible to a set of
202
+ # users in the Google Play Store app running on those users' managed devices.
203
+ # Those users can then install any of those apps if they wish (which will
204
+ # trigger creation of install and entitlement resources). A user cannot install
205
+ # an app on a managed device unless the app is listed in at least one collection
206
+ # that is visible to that user.
207
+ # Note that the API can be used to directly install an app regardless of whether
208
+ # it is in any collection - so an enterprise has a choice of either directly
209
+ # pushing apps to users, or allowing users to install apps if they want. Which
210
+ # is appropriate will depend on the enterprise's policies and the purpose of the
211
+ # apps concerned.
212
+ class Collection
213
+ include Google::Apis::Core::Hashable
214
+
215
+ # Arbitrary unique ID, allocated by the API on creation.
216
+ # Corresponds to the JSON property `collectionId`
217
+ # @return [String]
218
+ attr_accessor :collection_id
219
+
220
+ # Identifies what kind of resource this is. Value: the fixed string "
221
+ # androidenterprise#collection".
222
+ # Corresponds to the JSON property `kind`
223
+ # @return [String]
224
+ attr_accessor :kind
225
+
226
+ # A user-friendly name for the collection (should be unique), e.g. "Accounting
227
+ # apps".
228
+ # Corresponds to the JSON property `name`
229
+ # @return [String]
230
+ attr_accessor :name
231
+
232
+ # The IDs of the products in the collection, in the order in which they should
233
+ # be displayed.
234
+ # Corresponds to the JSON property `productId`
235
+ # @return [Array<String>]
236
+ attr_accessor :product_id
237
+
238
+ # Whether this collection is visible to all users, or only to the users that
239
+ # have been granted access through the collection_viewers api. Even if a
240
+ # collection is visible to allUsers, it is possible to add and remove viewers,
241
+ # but this will have no effect until the collection's visibility changes to
242
+ # viewersOnly.
243
+ # Corresponds to the JSON property `visibility`
244
+ # @return [String]
245
+ attr_accessor :visibility
246
+
247
+ def initialize(**args)
248
+ update!(**args)
249
+ end
250
+
251
+ # Update properties of this object
252
+ def update!(**args)
253
+ @collection_id = args[:collection_id] unless args[:collection_id].nil?
254
+ @kind = args[:kind] unless args[:kind].nil?
255
+ @name = args[:name] unless args[:name].nil?
256
+ @product_id = args[:product_id] unless args[:product_id].nil?
257
+ @visibility = args[:visibility] unless args[:visibility].nil?
258
+ end
259
+ end
260
+
261
+ # The user resources for the collection.
262
+ class ListCollectionViewersResponse
263
+ include Google::Apis::Core::Hashable
264
+
265
+ # Identifies what kind of resource this is. Value: the fixed string "
266
+ # androidenterprise#collectionViewersListResponse".
267
+ # Corresponds to the JSON property `kind`
268
+ # @return [String]
269
+ attr_accessor :kind
270
+
271
+ # A user of an enterprise.
272
+ # Corresponds to the JSON property `user`
273
+ # @return [Array<Google::Apis::AndroidenterpriseV1::User>]
274
+ attr_accessor :user
275
+
276
+ def initialize(**args)
277
+ update!(**args)
278
+ end
279
+
280
+ # Update properties of this object
281
+ def update!(**args)
282
+ @kind = args[:kind] unless args[:kind].nil?
283
+ @user = args[:user] unless args[:user].nil?
284
+ end
285
+ end
286
+
287
+ # The collection resources for the enterprise.
288
+ class ListCollectionsResponse
289
+ include Google::Apis::Core::Hashable
290
+
291
+ # An ordered collection of products which can be made visible on the Google Play
292
+ # Store app to a selected group of users.
293
+ # Corresponds to the JSON property `collection`
294
+ # @return [Array<Google::Apis::AndroidenterpriseV1::Collection>]
295
+ attr_accessor :collection
296
+
297
+ # Identifies what kind of resource this is. Value: the fixed string "
298
+ # androidenterprise#collectionsListResponse".
299
+ # Corresponds to the JSON property `kind`
300
+ # @return [String]
301
+ attr_accessor :kind
302
+
303
+ def initialize(**args)
304
+ update!(**args)
305
+ end
306
+
307
+ # Update properties of this object
308
+ def update!(**args)
309
+ @collection = args[:collection] unless args[:collection].nil?
310
+ @kind = args[:kind] unless args[:kind].nil?
311
+ end
312
+ end
313
+
314
+ # A device resource represents a mobile device managed by the MDM and belonging
315
+ # to a specific enterprise user.
316
+ # This collection cannot be modified via the API; it is automatically populated
317
+ # as devices are set up to be managed.
318
+ class Device
319
+ include Google::Apis::Core::Hashable
320
+
321
+ # The Google Play Services Android ID for the device encoded as a lowercase hex
322
+ # string, e.g. "123456789abcdef0".
323
+ # Corresponds to the JSON property `androidId`
324
+ # @return [String]
325
+ attr_accessor :android_id
326
+
327
+ # Identifies what kind of resource this is. Value: the fixed string "
328
+ # androidenterprise#device".
329
+ # Corresponds to the JSON property `kind`
330
+ # @return [String]
331
+ attr_accessor :kind
332
+
333
+ # The mechanism by which this device is managed by the MDM. "managedDevice"
334
+ # means that the MDM's app is a device owner. "managedProfile" means that the
335
+ # MDM's app is the profile owner (and there is a separate personal profile which
336
+ # is not managed). "containerApp" means that the MDM's app is managing the
337
+ # Android for Work container app on the device.
338
+ # Corresponds to the JSON property `managementType`
339
+ # @return [String]
340
+ attr_accessor :management_type
341
+
342
+ def initialize(**args)
343
+ update!(**args)
344
+ end
345
+
346
+ # Update properties of this object
347
+ def update!(**args)
348
+ @android_id = args[:android_id] unless args[:android_id].nil?
349
+ @kind = args[:kind] unless args[:kind].nil?
350
+ @management_type = args[:management_type] unless args[:management_type].nil?
351
+ end
352
+ end
353
+
354
+ # The state of a user's device, as accessed by the getState and setState methods
355
+ # on device resources.
356
+ class DeviceState
357
+ include Google::Apis::Core::Hashable
358
+
359
+ # The state of the Google account on the device. "enabled" indicates that the
360
+ # Google account on the device can be used to access Google services (including
361
+ # Google Play), while "disabled" means that it cannot. A new device is initially
362
+ # in the "disabled" state.
363
+ # Corresponds to the JSON property `accountState`
364
+ # @return [String]
365
+ attr_accessor :account_state
366
+
367
+ # Identifies what kind of resource this is. Value: the fixed string "
368
+ # androidenterprise#deviceState".
369
+ # Corresponds to the JSON property `kind`
370
+ # @return [String]
371
+ attr_accessor :kind
372
+
373
+ def initialize(**args)
374
+ update!(**args)
375
+ end
376
+
377
+ # Update properties of this object
378
+ def update!(**args)
379
+ @account_state = args[:account_state] unless args[:account_state].nil?
380
+ @kind = args[:kind] unless args[:kind].nil?
381
+ end
382
+ end
383
+
384
+ # The device resources for the user.
385
+ class ListDevicesResponse
386
+ include Google::Apis::Core::Hashable
387
+
388
+ # A managed device.
389
+ # Corresponds to the JSON property `device`
390
+ # @return [Array<Google::Apis::AndroidenterpriseV1::Device>]
391
+ attr_accessor :device
392
+
393
+ # Identifies what kind of resource this is. Value: the fixed string "
394
+ # androidenterprise#devicesListResponse".
395
+ # Corresponds to the JSON property `kind`
396
+ # @return [String]
397
+ attr_accessor :kind
398
+
399
+ def initialize(**args)
400
+ update!(**args)
401
+ end
402
+
403
+ # Update properties of this object
404
+ def update!(**args)
405
+ @device = args[:device] unless args[:device].nil?
406
+ @kind = args[:kind] unless args[:kind].nil?
407
+ end
408
+ end
409
+
410
+ # An enterprise resource represents a binding between an organisation and their
411
+ # MDM.
412
+ # To create an enterprise, an admin of the enterprise must first go through a
413
+ # Play for Work sign-up flow. At the end of this the admin will be presented
414
+ # with a token (a short opaque alphanumeric string). They must then present this
415
+ # to the MDM, who then supplies it to the enroll method. Until this is done the
416
+ # MDM will not have any access to the enterprise.
417
+ # After calling enroll the MDM should call setAccount to specify the service
418
+ # account that will be allowed to act on behalf of the enterprise, which will be
419
+ # required for access to the enterprise's data through this API. Only one call
420
+ # of setAccount is allowed for a given enterprise; the only way to change the
421
+ # account later is to unenroll the enterprise and enroll it again (obtaining a
422
+ # new token).
423
+ # The MDM can unenroll an enterprise in order to sever the binding between them.
424
+ # Re-enrolling an enterprise is possible, but requires a new token to be
425
+ # retrieved. Enterprises.unenroll requires the MDM's credentials (as enroll does)
426
+ # , not the enterprise's. Enterprises.unenroll can only be used for enterprises
427
+ # that were previously enrolled with the enroll call. Any enterprises that were
428
+ # enrolled using the (deprecated) Enterprises.insert call must be unenrolled
429
+ # with Enterprises.delete and can then be re-enrolled using the Enterprises.
430
+ # enroll call.
431
+ # The ID for an enterprise is an opaque string. It is returned by insert and
432
+ # enroll and can also be retrieved if the enterprise's primary domain is known
433
+ # using the list method.
434
+ class Enterprise
435
+ include Google::Apis::Core::Hashable
436
+
437
+ # The unique ID for the enterprise.
438
+ # Corresponds to the JSON property `id`
439
+ # @return [String]
440
+ attr_accessor :id
441
+
442
+ # Identifies what kind of resource this is. Value: the fixed string "
443
+ # androidenterprise#enterprise".
444
+ # Corresponds to the JSON property `kind`
445
+ # @return [String]
446
+ attr_accessor :kind
447
+
448
+ # The name of the enterprise, e.g. "Example Inc".
449
+ # Corresponds to the JSON property `name`
450
+ # @return [String]
451
+ attr_accessor :name
452
+
453
+ # The enterprise's primary domain, e.g. "example.com".
454
+ # Corresponds to the JSON property `primaryDomain`
455
+ # @return [String]
456
+ attr_accessor :primary_domain
457
+
458
+ def initialize(**args)
459
+ update!(**args)
460
+ end
461
+
462
+ # Update properties of this object
463
+ def update!(**args)
464
+ @id = args[:id] unless args[:id].nil?
465
+ @kind = args[:kind] unless args[:kind].nil?
466
+ @name = args[:name] unless args[:name].nil?
467
+ @primary_domain = args[:primary_domain] unless args[:primary_domain].nil?
468
+ end
469
+ end
470
+
471
+ # A service account that can be used to authenticate as the enterprise to API
472
+ # calls that require such authentication.
473
+ class EnterpriseAccount
474
+ include Google::Apis::Core::Hashable
475
+
476
+ # The email address of the service account.
477
+ # Corresponds to the JSON property `accountEmail`
478
+ # @return [String]
479
+ attr_accessor :account_email
480
+
481
+ # Identifies what kind of resource this is. Value: the fixed string "
482
+ # androidenterprise#enterpriseAccount".
483
+ # Corresponds to the JSON property `kind`
484
+ # @return [String]
485
+ attr_accessor :kind
486
+
487
+ def initialize(**args)
488
+ update!(**args)
489
+ end
490
+
491
+ # Update properties of this object
492
+ def update!(**args)
493
+ @account_email = args[:account_email] unless args[:account_email].nil?
494
+ @kind = args[:kind] unless args[:kind].nil?
495
+ end
496
+ end
497
+
498
+ # The matching enterprise resources.
499
+ class ListEnterprisesResponse
500
+ include Google::Apis::Core::Hashable
501
+
502
+ # An enterprise.
503
+ # Corresponds to the JSON property `enterprise`
504
+ # @return [Array<Google::Apis::AndroidenterpriseV1::Enterprise>]
505
+ attr_accessor :enterprise
506
+
507
+ # Identifies what kind of resource this is. Value: the fixed string "
508
+ # androidenterprise#enterprisesListResponse".
509
+ # Corresponds to the JSON property `kind`
510
+ # @return [String]
511
+ attr_accessor :kind
512
+
513
+ def initialize(**args)
514
+ update!(**args)
515
+ end
516
+
517
+ # Update properties of this object
518
+ def update!(**args)
519
+ @enterprise = args[:enterprise] unless args[:enterprise].nil?
520
+ @kind = args[:kind] unless args[:kind].nil?
521
+ end
522
+ end
523
+
524
+ # The existence of an entitlement resource means that a user has the right to
525
+ # use a particular app on any of their devices. This might be because the app is
526
+ # free or because they have been allocated a license to the app from a group
527
+ # license purchased by the enterprise.
528
+ # It should always be true that a user has an app installed on one of their
529
+ # devices only if they have an entitlement to it. So if an entitlement is
530
+ # deleted, the app will be uninstalled from all devices. Similarly if the user
531
+ # installs an app (and is permitted to do so), or the MDM triggers an install of
532
+ # the app, an entitlement to that app is automatically created. If this is
533
+ # impossible - e.g. the enterprise has not purchased sufficient licenses - then
534
+ # installation fails.
535
+ # Note that entitlements are always user specific, not device specific; a user
536
+ # may have an entitlement even though they have not installed the app anywhere.
537
+ # Once they have an entitlement they can install the app on multiple devices.
538
+ # The API can be used to create an entitlement. If the app is a free app, a
539
+ # group license for that app is created. If it's a paid app, creating the
540
+ # entitlement consumes one license; it remains consumed until the entitlement is
541
+ # removed. Optionally an installation of the app on all the user's managed
542
+ # devices can be triggered at the time the entitlement is created. An
543
+ # entitlement cannot be created for an app if the app requires permissions that
544
+ # the enterprise has not yet accepted.
545
+ # Entitlements for paid apps that are due to purchases by the user on a non-
546
+ # managed profile will have "userPurchase" as entitlement reason; those
547
+ # entitlements cannot be removed via the API.
548
+ class Entitlement
549
+ include Google::Apis::Core::Hashable
550
+
551
+ # Identifies what kind of resource this is. Value: the fixed string "
552
+ # androidenterprise#entitlement".
553
+ # Corresponds to the JSON property `kind`
554
+ # @return [String]
555
+ attr_accessor :kind
556
+
557
+ # The ID of the product that the entitlement is for, e.g. "app:com.google.
558
+ # android.gm".
559
+ # Corresponds to the JSON property `productId`
560
+ # @return [String]
561
+ attr_accessor :product_id
562
+
563
+ # The reason for the entitlement, e.g. "free" for free apps. This is temporary,
564
+ # it will be replaced by the acquisition kind field of group licenses.
565
+ # Corresponds to the JSON property `reason`
566
+ # @return [String]
567
+ attr_accessor :reason
568
+
569
+ def initialize(**args)
570
+ update!(**args)
571
+ end
572
+
573
+ # Update properties of this object
574
+ def update!(**args)
575
+ @kind = args[:kind] unless args[:kind].nil?
576
+ @product_id = args[:product_id] unless args[:product_id].nil?
577
+ @reason = args[:reason] unless args[:reason].nil?
578
+ end
579
+ end
580
+
581
+ # The entitlement resources for the user.
582
+ class ListEntitlementsResponse
583
+ include Google::Apis::Core::Hashable
584
+
585
+ # An entitlement of a user to a product (e.g. an app). For example, a free app
586
+ # that they have installed, or a paid app that they have been allocated a
587
+ # license to.
588
+ # Corresponds to the JSON property `entitlement`
589
+ # @return [Array<Google::Apis::AndroidenterpriseV1::Entitlement>]
590
+ attr_accessor :entitlement
591
+
592
+ # Identifies what kind of resource this is. Value: the fixed string "
593
+ # androidenterprise#entitlementsListResponse".
594
+ # Corresponds to the JSON property `kind`
595
+ # @return [String]
596
+ attr_accessor :kind
597
+
598
+ def initialize(**args)
599
+ update!(**args)
600
+ end
601
+
602
+ # Update properties of this object
603
+ def update!(**args)
604
+ @entitlement = args[:entitlement] unless args[:entitlement].nil?
605
+ @kind = args[:kind] unless args[:kind].nil?
606
+ end
607
+ end
608
+
609
+ # A group license object indicates a product that an enterprise admin has
610
+ # approved for use in the enterprise. The product may be free or paid. For free
611
+ # products, a group license object is created in these cases: if the enterprise
612
+ # admin approves a product in Google Play, if the product is added to a
613
+ # collection, or if an entitlement for the product is created for a user via the
614
+ # API. For paid products, a group license object is only created as part of the
615
+ # first bulk purchase of that product in Google Play done by the enterprise
616
+ # admin.
617
+ # The API can be used to query group licenses; the available information
618
+ # includes the total number of licenses purchased (for paid products) and the
619
+ # total number of licenses that have been provisioned, i.e. the total number of
620
+ # user entitlements in existence for the product.
621
+ # Group license objects are never deleted; if e.g. a free app is added to a
622
+ # collection and then removed, the group license will remain, allowing to keep
623
+ # track of any remaining entitlements. An enterprise admin may indicate they are
624
+ # no longer interested in the group license by marking it as unapproved in
625
+ # Google Play.
626
+ class GroupLicense
627
+ include Google::Apis::Core::Hashable
628
+
629
+ # How this group license was acquired. "bulkPurchase" means that this group
630
+ # license object was created because the enterprise purchased licenses for this
631
+ # product; this is "free" otherwise (for free products).
632
+ # Corresponds to the JSON property `acquisitionKind`
633
+ # @return [String]
634
+ attr_accessor :acquisition_kind
635
+
636
+ # Whether the product to which this group license relates is currently approved
637
+ # by the enterprise, as either "approved" or "unapproved". Products are approved
638
+ # when a group license is first created, but this approval may be revoked by an
639
+ # enterprise admin via Google Play. Unapproved products will not be visible to
640
+ # end users in collections and new entitlements to them should not normally be
641
+ # created.
642
+ # Corresponds to the JSON property `approval`
643
+ # @return [String]
644
+ attr_accessor :approval
645
+
646
+ # Identifies what kind of resource this is. Value: the fixed string "
647
+ # androidenterprise#groupLicense".
648
+ # Corresponds to the JSON property `kind`
649
+ # @return [String]
650
+ attr_accessor :kind
651
+
652
+ # The total number of provisioned licenses for this product. Returned by read
653
+ # operations, but ignored in write operations.
654
+ # Corresponds to the JSON property `numProvisioned`
655
+ # @return [Fixnum]
656
+ attr_accessor :num_provisioned
657
+
658
+ # The number of purchased licenses (possibly in multiple purchases). If this
659
+ # field is omitted then there is no limit on the number of licenses that can be
660
+ # provisioned (e.g. if the acquisition kind is "free").
661
+ # Corresponds to the JSON property `numPurchased`
662
+ # @return [Fixnum]
663
+ attr_accessor :num_purchased
664
+
665
+ # The ID of the product that the license is for, e.g. "app:com.google.android.gm"
666
+ # .
667
+ # Corresponds to the JSON property `productId`
668
+ # @return [String]
669
+ attr_accessor :product_id
670
+
671
+ def initialize(**args)
672
+ update!(**args)
673
+ end
674
+
675
+ # Update properties of this object
676
+ def update!(**args)
677
+ @acquisition_kind = args[:acquisition_kind] unless args[:acquisition_kind].nil?
678
+ @approval = args[:approval] unless args[:approval].nil?
679
+ @kind = args[:kind] unless args[:kind].nil?
680
+ @num_provisioned = args[:num_provisioned] unless args[:num_provisioned].nil?
681
+ @num_purchased = args[:num_purchased] unless args[:num_purchased].nil?
682
+ @product_id = args[:product_id] unless args[:product_id].nil?
683
+ end
684
+ end
685
+
686
+ # The user resources for the group license.
687
+ class ListGroupLicenseUsersResponse
688
+ include Google::Apis::Core::Hashable
689
+
690
+ # Identifies what kind of resource this is. Value: the fixed string "
691
+ # androidenterprise#groupLicenseUsersListResponse".
692
+ # Corresponds to the JSON property `kind`
693
+ # @return [String]
694
+ attr_accessor :kind
695
+
696
+ # A user of an enterprise.
697
+ # Corresponds to the JSON property `user`
698
+ # @return [Array<Google::Apis::AndroidenterpriseV1::User>]
699
+ attr_accessor :user
700
+
701
+ def initialize(**args)
702
+ update!(**args)
703
+ end
704
+
705
+ # Update properties of this object
706
+ def update!(**args)
707
+ @kind = args[:kind] unless args[:kind].nil?
708
+ @user = args[:user] unless args[:user].nil?
709
+ end
710
+ end
711
+
712
+ # The grouplicense resources for the enterprise.
713
+ class ListGroupLicensesResponse
714
+ include Google::Apis::Core::Hashable
715
+
716
+ # A group license for a product approved for use in the enterprise.
717
+ # Corresponds to the JSON property `groupLicense`
718
+ # @return [Array<Google::Apis::AndroidenterpriseV1::GroupLicense>]
719
+ attr_accessor :group_license
720
+
721
+ # Identifies what kind of resource this is. Value: the fixed string "
722
+ # androidenterprise#groupLicensesListResponse".
723
+ # Corresponds to the JSON property `kind`
724
+ # @return [String]
725
+ attr_accessor :kind
726
+
727
+ def initialize(**args)
728
+ update!(**args)
729
+ end
730
+
731
+ # Update properties of this object
732
+ def update!(**args)
733
+ @group_license = args[:group_license] unless args[:group_license].nil?
734
+ @kind = args[:kind] unless args[:kind].nil?
735
+ end
736
+ end
737
+
738
+ # The existence of an install resource indicates that an app is installed on a
739
+ # particular device (or that an install is pending).
740
+ # The API can be used to create an install resource using the update method.
741
+ # This triggers the actual install of the app on the device. If the user does
742
+ # not already have an entitlement for the app then an attempt is made to create
743
+ # one. If this fails (e.g. because the app is not free and there is no available
744
+ # license) then the creation of the install fails.
745
+ # The API can also be used to update an installed app. If the update method is
746
+ # used on an existing install then the app will be updated to the latest
747
+ # available version.
748
+ # Note that it is not possible to force the installation of a specific version
749
+ # of an app; the version code is read-only.
750
+ # If a user installs an app themselves (as permitted by the enterprise), then
751
+ # again an install resource and possibly an entitlement resource are
752
+ # automatically created.
753
+ # The API can also be used to delete an install resource, which triggers the
754
+ # removal of the app from the device. Note that deleting an install does not
755
+ # automatically remove the corresponding entitlement, even if there are no
756
+ # remaining installs. The install resource will also be deleted if the user
757
+ # uninstalls the app themselves.
758
+ class Install
759
+ include Google::Apis::Core::Hashable
760
+
761
+ # Install state. The state "installPending" means that an install request has
762
+ # recently been made and download to the device is in progress. The state "
763
+ # installed" means that the app has been installed. This field is read-only.
764
+ # Corresponds to the JSON property `installState`
765
+ # @return [String]
766
+ attr_accessor :install_state
767
+
768
+ # Identifies what kind of resource this is. Value: the fixed string "
769
+ # androidenterprise#install".
770
+ # Corresponds to the JSON property `kind`
771
+ # @return [String]
772
+ attr_accessor :kind
773
+
774
+ # The ID of the product that the install is for, e.g. "app:com.google.android.gm"
775
+ # .
776
+ # Corresponds to the JSON property `productId`
777
+ # @return [String]
778
+ attr_accessor :product_id
779
+
780
+ # The version of the installed product. Guaranteed to be set only if the install
781
+ # state is "installed".
782
+ # Corresponds to the JSON property `versionCode`
783
+ # @return [Fixnum]
784
+ attr_accessor :version_code
785
+
786
+ def initialize(**args)
787
+ update!(**args)
788
+ end
789
+
790
+ # Update properties of this object
791
+ def update!(**args)
792
+ @install_state = args[:install_state] unless args[:install_state].nil?
793
+ @kind = args[:kind] unless args[:kind].nil?
794
+ @product_id = args[:product_id] unless args[:product_id].nil?
795
+ @version_code = args[:version_code] unless args[:version_code].nil?
796
+ end
797
+ end
798
+
799
+ # The install resources for the device.
800
+ class ListInstallsResponse
801
+ include Google::Apis::Core::Hashable
802
+
803
+ # An installation of an app for a user on a specific device. The existence of an
804
+ # install implies that the user must have an entitlement to the app.
805
+ # Corresponds to the JSON property `install`
806
+ # @return [Array<Google::Apis::AndroidenterpriseV1::Install>]
807
+ attr_accessor :install
808
+
809
+ # Identifies what kind of resource this is. Value: the fixed string "
810
+ # androidenterprise#installsListResponse".
811
+ # Corresponds to the JSON property `kind`
812
+ # @return [String]
813
+ attr_accessor :kind
814
+
815
+ def initialize(**args)
816
+ update!(**args)
817
+ end
818
+
819
+ # Update properties of this object
820
+ def update!(**args)
821
+ @install = args[:install] unless args[:install].nil?
822
+ @kind = args[:kind] unless args[:kind].nil?
823
+ end
824
+ end
825
+
826
+ # A permission represents some extra capability, to be granted to an Android app,
827
+ # which requires explicit consent. An enterprise admin must consent to these
828
+ # permissions on behalf of their users before an entitlement for the app can be
829
+ # created.
830
+ # The permissions collection is read-only. The information provided for each
831
+ # permission (localized name and description) is intended to be used in the MDM
832
+ # user interface when obtaining consent from the enterprise.
833
+ class Permission
834
+ include Google::Apis::Core::Hashable
835
+
836
+ # A longer description of the permissions giving more details of what it affects.
837
+ # Corresponds to the JSON property `description`
838
+ # @return [String]
839
+ attr_accessor :description
840
+
841
+ # Identifies what kind of resource this is. Value: the fixed string "
842
+ # androidenterprise#permission".
843
+ # Corresponds to the JSON property `kind`
844
+ # @return [String]
845
+ attr_accessor :kind
846
+
847
+ # The name of the permission.
848
+ # Corresponds to the JSON property `name`
849
+ # @return [String]
850
+ attr_accessor :name
851
+
852
+ # An opaque string uniquely identifying the permission.
853
+ # Corresponds to the JSON property `permissionId`
854
+ # @return [String]
855
+ attr_accessor :permission_id
856
+
857
+ def initialize(**args)
858
+ update!(**args)
859
+ end
860
+
861
+ # Update properties of this object
862
+ def update!(**args)
863
+ @description = args[:description] unless args[:description].nil?
864
+ @kind = args[:kind] unless args[:kind].nil?
865
+ @name = args[:name] unless args[:name].nil?
866
+ @permission_id = args[:permission_id] unless args[:permission_id].nil?
867
+ end
868
+ end
869
+
870
+ # A product represents an app in the Google Play Store that is available to at
871
+ # least some users in the enterprise. (Some apps are restricted to a single
872
+ # enterprise, and no information about them is made available outside that
873
+ # enterprise.)
874
+ # The information provided for each product (localized name, icon, link to the
875
+ # full Google Play details page) is intended to allow a basic representation of
876
+ # the product within an MDM user interface.
877
+ class Product
878
+ include Google::Apis::Core::Hashable
879
+
880
+ # List of app versions available for this product. The returned list contains
881
+ # only public versions. E.g. alpha, beta or canary versions will not be included.
882
+ # Corresponds to the JSON property `appVersion`
883
+ # @return [Array<Google::Apis::AndroidenterpriseV1::AppVersion>]
884
+ attr_accessor :app_version
885
+
886
+ # The name of the author of the product (e.g. the app developer).
887
+ # Corresponds to the JSON property `authorName`
888
+ # @return [String]
889
+ attr_accessor :author_name
890
+
891
+ # A link to the (consumer) Google Play details page for the product.
892
+ # Corresponds to the JSON property `detailsUrl`
893
+ # @return [String]
894
+ attr_accessor :details_url
895
+
896
+ # How and to whom the package is made available.
897
+ # Corresponds to the JSON property `distributionChannel`
898
+ # @return [String]
899
+ attr_accessor :distribution_channel
900
+
901
+ # A link to an image that can be used as an icon for the product.
902
+ # Corresponds to the JSON property `iconUrl`
903
+ # @return [String]
904
+ attr_accessor :icon_url
905
+
906
+ # Identifies what kind of resource this is. Value: the fixed string "
907
+ # androidenterprise#product".
908
+ # Corresponds to the JSON property `kind`
909
+ # @return [String]
910
+ attr_accessor :kind
911
+
912
+ # A string of the form "app:
913
+ # " - e.g. "app:com.google.android.gm" represents the GMail app.
914
+ # Corresponds to the JSON property `productId`
915
+ # @return [String]
916
+ attr_accessor :product_id
917
+
918
+ # Whether this app can only be installed on devices using the Android for Work
919
+ # container app.
920
+ # Corresponds to the JSON property `requiresContainerApp`
921
+ # @return [Boolean]
922
+ attr_accessor :requires_container_app
923
+ alias_method :requires_container_app?, :requires_container_app
924
+
925
+ # The name of the product.
926
+ # Corresponds to the JSON property `title`
927
+ # @return [String]
928
+ attr_accessor :title
929
+
930
+ # A link to the Google Play for Work details page for the product, for use by an
931
+ # Enterprise administrator.
932
+ # Corresponds to the JSON property `workDetailsUrl`
933
+ # @return [String]
934
+ attr_accessor :work_details_url
935
+
936
+ def initialize(**args)
937
+ update!(**args)
938
+ end
939
+
940
+ # Update properties of this object
941
+ def update!(**args)
942
+ @app_version = args[:app_version] unless args[:app_version].nil?
943
+ @author_name = args[:author_name] unless args[:author_name].nil?
944
+ @details_url = args[:details_url] unless args[:details_url].nil?
945
+ @distribution_channel = args[:distribution_channel] unless args[:distribution_channel].nil?
946
+ @icon_url = args[:icon_url] unless args[:icon_url].nil?
947
+ @kind = args[:kind] unless args[:kind].nil?
948
+ @product_id = args[:product_id] unless args[:product_id].nil?
949
+ @requires_container_app = args[:requires_container_app] unless args[:requires_container_app].nil?
950
+ @title = args[:title] unless args[:title].nil?
951
+ @work_details_url = args[:work_details_url] unless args[:work_details_url].nil?
952
+ end
953
+ end
954
+
955
+ # A product permissions resource represents the set of permissions required by a
956
+ # specific app and whether or not they have been accepted by an enterprise admin.
957
+ # The API can be used to read the set of permissions, and also to update the set
958
+ # to indicate that permissions have been accepted.
959
+ class ProductPermission
960
+ include Google::Apis::Core::Hashable
961
+
962
+ # An opaque string uniquely identifying the permission.
963
+ # Corresponds to the JSON property `permissionId`
964
+ # @return [String]
965
+ attr_accessor :permission_id
966
+
967
+ # Whether the permission has been accepted or not.
968
+ # Corresponds to the JSON property `state`
969
+ # @return [String]
970
+ attr_accessor :state
971
+
972
+ def initialize(**args)
973
+ update!(**args)
974
+ end
975
+
976
+ # Update properties of this object
977
+ def update!(**args)
978
+ @permission_id = args[:permission_id] unless args[:permission_id].nil?
979
+ @state = args[:state] unless args[:state].nil?
980
+ end
981
+ end
982
+
983
+ # Information about the permissions required by a specific app and whether they
984
+ # have been accepted by the enterprise.
985
+ class ProductPermissions
986
+ include Google::Apis::Core::Hashable
987
+
988
+ # Identifies what kind of resource this is. Value: the fixed string "
989
+ # androidenterprise#productPermissions".
990
+ # Corresponds to the JSON property `kind`
991
+ # @return [String]
992
+ attr_accessor :kind
993
+
994
+ # The permissions required by the app.
995
+ # Corresponds to the JSON property `permission`
996
+ # @return [Array<Google::Apis::AndroidenterpriseV1::ProductPermission>]
997
+ attr_accessor :permission
998
+
999
+ # The ID of the app that the permissions relate to, e.g. "app:com.google.android.
1000
+ # gm".
1001
+ # Corresponds to the JSON property `productId`
1002
+ # @return [String]
1003
+ attr_accessor :product_id
1004
+
1005
+ def initialize(**args)
1006
+ update!(**args)
1007
+ end
1008
+
1009
+ # Update properties of this object
1010
+ def update!(**args)
1011
+ @kind = args[:kind] unless args[:kind].nil?
1012
+ @permission = args[:permission] unless args[:permission].nil?
1013
+ @product_id = args[:product_id] unless args[:product_id].nil?
1014
+ end
1015
+ end
1016
+
1017
+ #
1018
+ class ApproveProductRequest
1019
+ include Google::Apis::Core::Hashable
1020
+
1021
+ # Information on an approval URL.
1022
+ # Corresponds to the JSON property `approvalUrlInfo`
1023
+ # @return [Google::Apis::AndroidenterpriseV1::ApprovalUrlInfo]
1024
+ attr_accessor :approval_url_info
1025
+
1026
+ def initialize(**args)
1027
+ update!(**args)
1028
+ end
1029
+
1030
+ # Update properties of this object
1031
+ def update!(**args)
1032
+ @approval_url_info = args[:approval_url_info] unless args[:approval_url_info].nil?
1033
+ end
1034
+ end
1035
+
1036
+ #
1037
+ class GenerateProductApprovalUrlResponse
1038
+ include Google::Apis::Core::Hashable
1039
+
1040
+ # A iframe-able URL that displays a product's permissions (if any). This URL can
1041
+ # be used to approve the product only once and for a limited time (1 hour),
1042
+ # using the Products.approve call. If the product is not currently approved and
1043
+ # has no permissions, this URL will point to an empty page. If the product is
1044
+ # currently approved and all of its permissions (if any) are also approved, this
1045
+ # field will not be populated.
1046
+ # Corresponds to the JSON property `url`
1047
+ # @return [String]
1048
+ attr_accessor :url
1049
+
1050
+ def initialize(**args)
1051
+ update!(**args)
1052
+ end
1053
+
1054
+ # Update properties of this object
1055
+ def update!(**args)
1056
+ @url = args[:url] unless args[:url].nil?
1057
+ end
1058
+ end
1059
+
1060
+ # A user resource represents an individual user within the enterprise's domain.
1061
+ # Note that each user is associated with a Google account based on the user's
1062
+ # corporate email address (which must be in one of the enterprise's domains). As
1063
+ # part of installing an MDM app to manage a device the Google account must be
1064
+ # provisioned to the device, and so the user resource must be created before
1065
+ # that. This can be done using the Google Admin SDK Directory API.
1066
+ # The ID for a user is an opaque string. It can be retrieved using the list
1067
+ # method queried by the user's primary email address.
1068
+ class User
1069
+ include Google::Apis::Core::Hashable
1070
+
1071
+ # The unique ID for the user.
1072
+ # Corresponds to the JSON property `id`
1073
+ # @return [String]
1074
+ attr_accessor :id
1075
+
1076
+ # Identifies what kind of resource this is. Value: the fixed string "
1077
+ # androidenterprise#user".
1078
+ # Corresponds to the JSON property `kind`
1079
+ # @return [String]
1080
+ attr_accessor :kind
1081
+
1082
+ # The user's primary email, e.g. "jsmith@example.com".
1083
+ # Corresponds to the JSON property `primaryEmail`
1084
+ # @return [String]
1085
+ attr_accessor :primary_email
1086
+
1087
+ def initialize(**args)
1088
+ update!(**args)
1089
+ end
1090
+
1091
+ # Update properties of this object
1092
+ def update!(**args)
1093
+ @id = args[:id] unless args[:id].nil?
1094
+ @kind = args[:kind] unless args[:kind].nil?
1095
+ @primary_email = args[:primary_email] unless args[:primary_email].nil?
1096
+ end
1097
+ end
1098
+
1099
+ # A UserToken is used by a user when setting up a managed device or profile with
1100
+ # their work account on a device. When the user enters their email address and
1101
+ # token (activation code) the appropriate MDM app can be automatically
1102
+ # downloaded.
1103
+ class UserToken
1104
+ include Google::Apis::Core::Hashable
1105
+
1106
+ # Identifies what kind of resource this is. Value: the fixed string "
1107
+ # androidenterprise#userToken".
1108
+ # Corresponds to the JSON property `kind`
1109
+ # @return [String]
1110
+ attr_accessor :kind
1111
+
1112
+ # The token (activation code) to be entered by the user. This consists of a
1113
+ # sequence of decimal digits. Note that the leading digit may be 0.
1114
+ # Corresponds to the JSON property `token`
1115
+ # @return [String]
1116
+ attr_accessor :token
1117
+
1118
+ # The unique ID for the user.
1119
+ # Corresponds to the JSON property `userId`
1120
+ # @return [String]
1121
+ attr_accessor :user_id
1122
+
1123
+ def initialize(**args)
1124
+ update!(**args)
1125
+ end
1126
+
1127
+ # Update properties of this object
1128
+ def update!(**args)
1129
+ @kind = args[:kind] unless args[:kind].nil?
1130
+ @token = args[:token] unless args[:token].nil?
1131
+ @user_id = args[:user_id] unless args[:user_id].nil?
1132
+ end
1133
+ end
1134
+
1135
+ # The matching user resources.
1136
+ class ListUsersResponse
1137
+ include Google::Apis::Core::Hashable
1138
+
1139
+ # Identifies what kind of resource this is. Value: the fixed string "
1140
+ # androidenterprise#usersListResponse".
1141
+ # Corresponds to the JSON property `kind`
1142
+ # @return [String]
1143
+ attr_accessor :kind
1144
+
1145
+ # A user of an enterprise.
1146
+ # Corresponds to the JSON property `user`
1147
+ # @return [Array<Google::Apis::AndroidenterpriseV1::User>]
1148
+ attr_accessor :user
1149
+
1150
+ def initialize(**args)
1151
+ update!(**args)
1152
+ end
1153
+
1154
+ # Update properties of this object
1155
+ def update!(**args)
1156
+ @kind = args[:kind] unless args[:kind].nil?
1157
+ @user = args[:user] unless args[:user].nil?
1158
+ end
1159
+ end
1160
+ end
1161
+ end
1162
+ end