lemboy-google-api-client 0.9.26

Sign up to get free protection for your applications and to get access to all the features.
Files changed (555) hide show
  1. checksums.yaml +7 -0
  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 +27 -0
  7. data/.yardopts +12 -0
  8. data/CHANGELOG.md +309 -0
  9. data/CONTRIBUTING.md +31 -0
  10. data/Gemfile +53 -0
  11. data/LICENSE +202 -0
  12. data/MIGRATING.md +171 -0
  13. data/README.md +327 -0
  14. data/Rakefile +2 -0
  15. data/api_names.yaml +36215 -0
  16. data/bin/generate-api +109 -0
  17. data/generated/google/apis/adexchangebuyer2_v2beta1.rb +35 -0
  18. data/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb +298 -0
  19. data/generated/google/apis/adexchangebuyer2_v2beta1/representations.rb +122 -0
  20. data/generated/google/apis/adexchangebuyer2_v2beta1/service.rb +458 -0
  21. data/generated/google/apis/adexchangebuyer_v1_3.rb +35 -0
  22. data/generated/google/apis/adexchangebuyer_v1_3/classes.rb +1335 -0
  23. data/generated/google/apis/adexchangebuyer_v1_3/representations.rb +446 -0
  24. data/generated/google/apis/adexchangebuyer_v1_3/service.rb +872 -0
  25. data/generated/google/apis/adexchangebuyer_v1_4.rb +35 -0
  26. data/generated/google/apis/adexchangebuyer_v1_4/classes.rb +3550 -0
  27. data/generated/google/apis/adexchangebuyer_v1_4/representations.rb +1421 -0
  28. data/generated/google/apis/adexchangebuyer_v1_4/service.rb +1538 -0
  29. data/generated/google/apis/adexchangeseller_v2_0.rb +37 -0
  30. data/generated/google/apis/adexchangeseller_v2_0/classes.rb +792 -0
  31. data/generated/google/apis/adexchangeseller_v2_0/representations.rb +347 -0
  32. data/generated/google/apis/adexchangeseller_v2_0/service.rb +667 -0
  33. data/generated/google/apis/admin_datatransfer_v1.rb +37 -0
  34. data/generated/google/apis/admin_datatransfer_v1/classes.rb +267 -0
  35. data/generated/google/apis/admin_datatransfer_v1/representations.rb +130 -0
  36. data/generated/google/apis/admin_datatransfer_v1/service.rb +262 -0
  37. data/generated/google/apis/admin_directory_v1.rb +113 -0
  38. data/generated/google/apis/admin_directory_v1/classes.rb +3241 -0
  39. data/generated/google/apis/admin_directory_v1/representations.rb +1172 -0
  40. data/generated/google/apis/admin_directory_v1/service.rb +3857 -0
  41. data/generated/google/apis/admin_reports_v1.rb +38 -0
  42. data/generated/google/apis/admin_reports_v1/classes.rb +582 -0
  43. data/generated/google/apis/admin_reports_v1/representations.rb +257 -0
  44. data/generated/google/apis/admin_reports_v1/service.rb +336 -0
  45. data/generated/google/apis/adsense_v1_4.rb +37 -0
  46. data/generated/google/apis/adsense_v1_4/classes.rb +1280 -0
  47. data/generated/google/apis/adsense_v1_4/representations.rb +555 -0
  48. data/generated/google/apis/adsense_v1_4/service.rb +1713 -0
  49. data/generated/google/apis/adsensehost_v4_1.rb +35 -0
  50. data/generated/google/apis/adsensehost_v4_1/classes.rb +836 -0
  51. data/generated/google/apis/adsensehost_v4_1/representations.rb +367 -0
  52. data/generated/google/apis/adsensehost_v4_1/service.rb +1164 -0
  53. data/generated/google/apis/analytics_v3.rb +49 -0
  54. data/generated/google/apis/analytics_v3/classes.rb +5536 -0
  55. data/generated/google/apis/analytics_v3/representations.rb +1992 -0
  56. data/generated/google/apis/analytics_v3/service.rb +3785 -0
  57. data/generated/google/apis/analyticsreporting_v4.rb +37 -0
  58. data/generated/google/apis/analyticsreporting_v4/classes.rb +1420 -0
  59. data/generated/google/apis/analyticsreporting_v4/representations.rb +598 -0
  60. data/generated/google/apis/analyticsreporting_v4/service.rb +88 -0
  61. data/generated/google/apis/androidenterprise_v1.rb +34 -0
  62. data/generated/google/apis/androidenterprise_v1/classes.rb +2250 -0
  63. data/generated/google/apis/androidenterprise_v1/representations.rb +970 -0
  64. data/generated/google/apis/androidenterprise_v1/service.rb +3267 -0
  65. data/generated/google/apis/androidpublisher_v2.rb +34 -0
  66. data/generated/google/apis/androidpublisher_v2/classes.rb +1941 -0
  67. data/generated/google/apis/androidpublisher_v2/representations.rb +975 -0
  68. data/generated/google/apis/androidpublisher_v2/service.rb +2572 -0
  69. data/generated/google/apis/appengine_v1beta4.rb +35 -0
  70. data/generated/google/apis/appengine_v1beta4/classes.rb +1585 -0
  71. data/generated/google/apis/appengine_v1beta4/representations.rb +542 -0
  72. data/generated/google/apis/appengine_v1beta4/service.rb +477 -0
  73. data/generated/google/apis/appengine_v1beta5.rb +40 -0
  74. data/generated/google/apis/appengine_v1beta5/classes.rb +1984 -0
  75. data/generated/google/apis/appengine_v1beta5/representations.rb +765 -0
  76. data/generated/google/apis/appengine_v1beta5/service.rb +864 -0
  77. data/generated/google/apis/appsactivity_v1.rb +46 -0
  78. data/generated/google/apis/appsactivity_v1/classes.rb +415 -0
  79. data/generated/google/apis/appsactivity_v1/representations.rb +209 -0
  80. data/generated/google/apis/appsactivity_v1/service.rb +128 -0
  81. data/generated/google/apis/appstate_v1.rb +34 -0
  82. data/generated/google/apis/appstate_v1/classes.rb +154 -0
  83. data/generated/google/apis/appstate_v1/representations.rb +87 -0
  84. data/generated/google/apis/appstate_v1/service.rb +260 -0
  85. data/generated/google/apis/autoscaler_v1beta2.rb +38 -0
  86. data/generated/google/apis/autoscaler_v1beta2/classes.rb +710 -0
  87. data/generated/google/apis/autoscaler_v1beta2/representations.rb +296 -0
  88. data/generated/google/apis/autoscaler_v1beta2/service.rb +478 -0
  89. data/generated/google/apis/bigquery_v2.rb +52 -0
  90. data/generated/google/apis/bigquery_v2/classes.rb +3081 -0
  91. data/generated/google/apis/bigquery_v2/representations.rb +1094 -0
  92. data/generated/google/apis/bigquery_v2/service.rb +988 -0
  93. data/generated/google/apis/blogger_v3.rb +37 -0
  94. data/generated/google/apis/blogger_v3/classes.rb +1354 -0
  95. data/generated/google/apis/blogger_v3/representations.rb +632 -0
  96. data/generated/google/apis/blogger_v3/service.rb +1587 -0
  97. data/generated/google/apis/books_v1.rb +34 -0
  98. data/generated/google/apis/books_v1/classes.rb +4160 -0
  99. data/generated/google/apis/books_v1/representations.rb +1799 -0
  100. data/generated/google/apis/books_v1/service.rb +2300 -0
  101. data/generated/google/apis/calendar_v3.rb +37 -0
  102. data/generated/google/apis/calendar_v3/classes.rb +1742 -0
  103. data/generated/google/apis/calendar_v3/representations.rb +631 -0
  104. data/generated/google/apis/calendar_v3/service.rb +1968 -0
  105. data/generated/google/apis/civicinfo_v2.rb +32 -0
  106. data/generated/google/apis/civicinfo_v2/classes.rb +1499 -0
  107. data/generated/google/apis/civicinfo_v2/representations.rb +572 -0
  108. data/generated/google/apis/civicinfo_v2/service.rb +300 -0
  109. data/generated/google/apis/classroom_v1.rb +70 -0
  110. data/generated/google/apis/classroom_v1/classes.rb +1572 -0
  111. data/generated/google/apis/classroom_v1/representations.rb +729 -0
  112. data/generated/google/apis/classroom_v1/service.rb +1945 -0
  113. data/generated/google/apis/classroom_v1beta1.rb +49 -0
  114. data/generated/google/apis/classroom_v1beta1/classes.rb +447 -0
  115. data/generated/google/apis/classroom_v1beta1/representations.rb +190 -0
  116. data/generated/google/apis/classroom_v1beta1/service.rb +791 -0
  117. data/generated/google/apis/cloudbilling_v1.rb +35 -0
  118. data/generated/google/apis/cloudbilling_v1/classes.rb +169 -0
  119. data/generated/google/apis/cloudbilling_v1/representations.rb +87 -0
  120. data/generated/google/apis/cloudbilling_v1/service.rb +258 -0
  121. data/generated/google/apis/cloudbuild_v1.rb +34 -0
  122. data/generated/google/apis/cloudbuild_v1/classes.rb +919 -0
  123. data/generated/google/apis/cloudbuild_v1/representations.rb +364 -0
  124. data/generated/google/apis/cloudbuild_v1/service.rb +492 -0
  125. data/generated/google/apis/clouddebugger_v2.rb +38 -0
  126. data/generated/google/apis/clouddebugger_v2/classes.rb +1081 -0
  127. data/generated/google/apis/clouddebugger_v2/representations.rb +465 -0
  128. data/generated/google/apis/clouddebugger_v2/service.rb +396 -0
  129. data/generated/google/apis/cloudkms_v1beta1.rb +34 -0
  130. data/generated/google/apis/cloudkms_v1beta1/classes.rb +999 -0
  131. data/generated/google/apis/cloudkms_v1beta1/representations.rb +448 -0
  132. data/generated/google/apis/cloudkms_v1beta1/service.rb +932 -0
  133. data/generated/google/apis/cloudlatencytest_v2.rb +34 -0
  134. data/generated/google/apis/cloudlatencytest_v2/classes.rb +195 -0
  135. data/generated/google/apis/cloudlatencytest_v2/representations.rb +127 -0
  136. data/generated/google/apis/cloudlatencytest_v2/service.rb +135 -0
  137. data/generated/google/apis/cloudmonitoring_v2beta2.rb +37 -0
  138. data/generated/google/apis/cloudmonitoring_v2beta2/classes.rb +679 -0
  139. data/generated/google/apis/cloudmonitoring_v2beta2/representations.rb +353 -0
  140. data/generated/google/apis/cloudmonitoring_v2beta2/service.rb +452 -0
  141. data/generated/google/apis/cloudresourcemanager_v1.rb +38 -0
  142. data/generated/google/apis/cloudresourcemanager_v1/classes.rb +886 -0
  143. data/generated/google/apis/cloudresourcemanager_v1/representations.rb +359 -0
  144. data/generated/google/apis/cloudresourcemanager_v1/service.rb +686 -0
  145. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +38 -0
  146. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +682 -0
  147. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +312 -0
  148. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +710 -0
  149. data/generated/google/apis/cloudtrace_v1.rb +43 -0
  150. data/generated/google/apis/cloudtrace_v1/classes.rb +188 -0
  151. data/generated/google/apis/cloudtrace_v1/representations.rb +102 -0
  152. data/generated/google/apis/cloudtrace_v1/service.rb +192 -0
  153. data/generated/google/apis/clouduseraccounts_beta.rb +44 -0
  154. data/generated/google/apis/clouduseraccounts_beta/classes.rb +845 -0
  155. data/generated/google/apis/clouduseraccounts_beta/representations.rb +352 -0
  156. data/generated/google/apis/clouduseraccounts_beta/service.rb +907 -0
  157. data/generated/google/apis/compute_beta.rb +49 -0
  158. data/generated/google/apis/compute_beta/classes.rb +12261 -0
  159. data/generated/google/apis/compute_beta/representations.rb +4615 -0
  160. data/generated/google/apis/compute_beta/service.rb +15330 -0
  161. data/generated/google/apis/compute_v1.rb +49 -0
  162. data/generated/google/apis/compute_v1/classes.rb +11179 -0
  163. data/generated/google/apis/compute_v1/representations.rb +4203 -0
  164. data/generated/google/apis/compute_v1/service.rb +12937 -0
  165. data/generated/google/apis/container_v1.rb +35 -0
  166. data/generated/google/apis/container_v1/classes.rb +1040 -0
  167. data/generated/google/apis/container_v1/representations.rb +415 -0
  168. data/generated/google/apis/container_v1/service.rb +659 -0
  169. data/generated/google/apis/container_v1beta1.rb +35 -0
  170. data/generated/google/apis/container_v1beta1/classes.rb +466 -0
  171. data/generated/google/apis/container_v1beta1/representations.rb +177 -0
  172. data/generated/google/apis/container_v1beta1/service.rb +394 -0
  173. data/generated/google/apis/content_v2.rb +35 -0
  174. data/generated/google/apis/content_v2/classes.rb +6887 -0
  175. data/generated/google/apis/content_v2/representations.rb +2963 -0
  176. data/generated/google/apis/content_v2/service.rb +2653 -0
  177. data/generated/google/apis/coordinate_v1.rb +37 -0
  178. data/generated/google/apis/coordinate_v1/classes.rb +669 -0
  179. data/generated/google/apis/coordinate_v1/representations.rb +321 -0
  180. data/generated/google/apis/coordinate_v1/service.rb +678 -0
  181. data/generated/google/apis/customsearch_v1.rb +31 -0
  182. data/generated/google/apis/customsearch_v1/classes.rb +771 -0
  183. data/generated/google/apis/customsearch_v1/representations.rb +302 -0
  184. data/generated/google/apis/customsearch_v1/service.rb +207 -0
  185. data/generated/google/apis/dataflow_v1b3.rb +37 -0
  186. data/generated/google/apis/dataflow_v1b3/classes.rb +4225 -0
  187. data/generated/google/apis/dataflow_v1b3/representations.rb +1809 -0
  188. data/generated/google/apis/dataflow_v1b3/service.rb +874 -0
  189. data/generated/google/apis/dataproc_v1.rb +34 -0
  190. data/generated/google/apis/dataproc_v1/classes.rb +1716 -0
  191. data/generated/google/apis/dataproc_v1/representations.rb +678 -0
  192. data/generated/google/apis/dataproc_v1/service.rb +670 -0
  193. data/generated/google/apis/datastore_v1.rb +38 -0
  194. data/generated/google/apis/datastore_v1/classes.rb +1289 -0
  195. data/generated/google/apis/datastore_v1/representations.rb +572 -0
  196. data/generated/google/apis/datastore_v1/service.rb +259 -0
  197. data/generated/google/apis/datastore_v1beta2.rb +40 -0
  198. data/generated/google/apis/datastore_v1beta2/classes.rb +1186 -0
  199. data/generated/google/apis/datastore_v1beta2/representations.rb +594 -0
  200. data/generated/google/apis/datastore_v1beta2/service.rb +294 -0
  201. data/generated/google/apis/datastore_v1beta3.rb +38 -0
  202. data/generated/google/apis/datastore_v1beta3/classes.rb +1284 -0
  203. data/generated/google/apis/datastore_v1beta3/representations.rb +572 -0
  204. data/generated/google/apis/datastore_v1beta3/service.rb +259 -0
  205. data/generated/google/apis/deploymentmanager_v2.rb +43 -0
  206. data/generated/google/apis/deploymentmanager_v2/classes.rb +1582 -0
  207. data/generated/google/apis/deploymentmanager_v2/representations.rb +686 -0
  208. data/generated/google/apis/deploymentmanager_v2/service.rb +1026 -0
  209. data/generated/google/apis/deploymentmanager_v2beta2.rb +44 -0
  210. data/generated/google/apis/deploymentmanager_v2beta2/classes.rb +843 -0
  211. data/generated/google/apis/deploymentmanager_v2beta2/representations.rb +306 -0
  212. data/generated/google/apis/deploymentmanager_v2beta2/service.rb +689 -0
  213. data/generated/google/apis/dfareporting_v2_1.rb +37 -0
  214. data/generated/google/apis/dfareporting_v2_1/classes.rb +10770 -0
  215. data/generated/google/apis/dfareporting_v2_1/representations.rb +3438 -0
  216. data/generated/google/apis/dfareporting_v2_1/service.rb +8585 -0
  217. data/generated/google/apis/dfareporting_v2_3.rb +37 -0
  218. data/generated/google/apis/dfareporting_v2_3/classes.rb +10839 -0
  219. data/generated/google/apis/dfareporting_v2_3/representations.rb +3829 -0
  220. data/generated/google/apis/dfareporting_v2_3/service.rb +8581 -0
  221. data/generated/google/apis/dfareporting_v2_5.rb +40 -0
  222. data/generated/google/apis/dfareporting_v2_5/classes.rb +11225 -0
  223. data/generated/google/apis/dfareporting_v2_5/representations.rb +3982 -0
  224. data/generated/google/apis/dfareporting_v2_5/service.rb +8755 -0
  225. data/generated/google/apis/dfareporting_v2_6.rb +40 -0
  226. data/generated/google/apis/dfareporting_v2_6/classes.rb +11586 -0
  227. data/generated/google/apis/dfareporting_v2_6/representations.rb +4119 -0
  228. data/generated/google/apis/dfareporting_v2_6/service.rb +9025 -0
  229. data/generated/google/apis/dfareporting_v2_7.rb +40 -0
  230. data/generated/google/apis/dfareporting_v2_7/classes.rb +11876 -0
  231. data/generated/google/apis/dfareporting_v2_7/representations.rb +4243 -0
  232. data/generated/google/apis/dfareporting_v2_7/service.rb +9095 -0
  233. data/generated/google/apis/discovery_v1.rb +32 -0
  234. data/generated/google/apis/discovery_v1/classes.rb +961 -0
  235. data/generated/google/apis/discovery_v1/representations.rb +397 -0
  236. data/generated/google/apis/discovery_v1/service.rb +142 -0
  237. data/generated/google/apis/dns_v1.rb +43 -0
  238. data/generated/google/apis/dns_v1/classes.rb +406 -0
  239. data/generated/google/apis/dns_v1/representations.rb +167 -0
  240. data/generated/google/apis/dns_v1/service.rb +453 -0
  241. data/generated/google/apis/dns_v2beta1.rb +43 -0
  242. data/generated/google/apis/dns_v2beta1/classes.rb +915 -0
  243. data/generated/google/apis/dns_v2beta1/representations.rb +368 -0
  244. data/generated/google/apis/dns_v2beta1/service.rb +768 -0
  245. data/generated/google/apis/doubleclickbidmanager_v1.rb +31 -0
  246. data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +795 -0
  247. data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +368 -0
  248. data/generated/google/apis/doubleclickbidmanager_v1/service.rb +376 -0
  249. data/generated/google/apis/doubleclicksearch_v2.rb +35 -0
  250. data/generated/google/apis/doubleclicksearch_v2/classes.rb +960 -0
  251. data/generated/google/apis/doubleclicksearch_v2/representations.rb +350 -0
  252. data/generated/google/apis/doubleclicksearch_v2/service.rb +480 -0
  253. data/generated/google/apis/drive_v2.rb +59 -0
  254. data/generated/google/apis/drive_v2/classes.rb +2633 -0
  255. data/generated/google/apis/drive_v2/representations.rb +885 -0
  256. data/generated/google/apis/drive_v2/service.rb +2754 -0
  257. data/generated/google/apis/drive_v3.rb +56 -0
  258. data/generated/google/apis/drive_v3/classes.rb +1611 -0
  259. data/generated/google/apis/drive_v3/representations.rb +555 -0
  260. data/generated/google/apis/drive_v3/service.rb +1553 -0
  261. data/generated/google/apis/fitness_v1.rb +85 -0
  262. data/generated/google/apis/fitness_v1/classes.rb +943 -0
  263. data/generated/google/apis/fitness_v1/representations.rb +380 -0
  264. data/generated/google/apis/fitness_v1/service.rb +674 -0
  265. data/generated/google/apis/fusiontables_v2.rb +37 -0
  266. data/generated/google/apis/fusiontables_v2/classes.rb +1049 -0
  267. data/generated/google/apis/fusiontables_v2/representations.rb +457 -0
  268. data/generated/google/apis/fusiontables_v2/service.rb +1463 -0
  269. data/generated/google/apis/games_configuration_v1configuration.rb +34 -0
  270. data/generated/google/apis/games_configuration_v1configuration/classes.rb +506 -0
  271. data/generated/google/apis/games_configuration_v1configuration/representations.rb +228 -0
  272. data/generated/google/apis/games_configuration_v1configuration/service.rb +565 -0
  273. data/generated/google/apis/games_management_v1management.rb +37 -0
  274. data/generated/google/apis/games_management_v1management/classes.rb +567 -0
  275. data/generated/google/apis/games_management_v1management/representations.rb +278 -0
  276. data/generated/google/apis/games_management_v1management/service.rb +994 -0
  277. data/generated/google/apis/games_v1.rb +40 -0
  278. data/generated/google/apis/games_v1/classes.rb +4667 -0
  279. data/generated/google/apis/games_v1/representations.rb +1800 -0
  280. data/generated/google/apis/games_v1/service.rb +2449 -0
  281. data/generated/google/apis/gan_v1beta1.rb +31 -0
  282. data/generated/google/apis/gan_v1beta1/classes.rb +1428 -0
  283. data/generated/google/apis/gan_v1beta1/representations.rb +462 -0
  284. data/generated/google/apis/gan_v1beta1/service.rb +682 -0
  285. data/generated/google/apis/genomics_v1.rb +46 -0
  286. data/generated/google/apis/genomics_v1/classes.rb +3477 -0
  287. data/generated/google/apis/genomics_v1/representations.rb +1284 -0
  288. data/generated/google/apis/genomics_v1/service.rb +2207 -0
  289. data/generated/google/apis/genomics_v1beta2.rb +46 -0
  290. data/generated/google/apis/genomics_v1beta2/classes.rb +3288 -0
  291. data/generated/google/apis/genomics_v1beta2/representations.rb +1194 -0
  292. data/generated/google/apis/genomics_v1beta2/service.rb +2392 -0
  293. data/generated/google/apis/gmail_v1.rb +61 -0
  294. data/generated/google/apis/gmail_v1/classes.rb +1382 -0
  295. data/generated/google/apis/gmail_v1/representations.rb +624 -0
  296. data/generated/google/apis/gmail_v1/service.rb +2447 -0
  297. data/generated/google/apis/groupsmigration_v1.rb +34 -0
  298. data/generated/google/apis/groupsmigration_v1/classes.rb +51 -0
  299. data/generated/google/apis/groupsmigration_v1/representations.rb +40 -0
  300. data/generated/google/apis/groupsmigration_v1/service.rb +110 -0
  301. data/generated/google/apis/groupssettings_v1.rb +34 -0
  302. data/generated/google/apis/groupssettings_v1/classes.rb +240 -0
  303. data/generated/google/apis/groupssettings_v1/representations.rb +69 -0
  304. data/generated/google/apis/groupssettings_v1/service.rb +179 -0
  305. data/generated/google/apis/iam_v1.rb +36 -0
  306. data/generated/google/apis/iam_v1/classes.rb +640 -0
  307. data/generated/google/apis/iam_v1/representations.rb +316 -0
  308. data/generated/google/apis/iam_v1/service.rb +554 -0
  309. data/generated/google/apis/identitytoolkit_v3.rb +37 -0
  310. data/generated/google/apis/identitytoolkit_v3/classes.rb +2182 -0
  311. data/generated/google/apis/identitytoolkit_v3/representations.rb +742 -0
  312. data/generated/google/apis/identitytoolkit_v3/service.rb +657 -0
  313. data/generated/google/apis/kgsearch_v1.rb +31 -0
  314. data/generated/google/apis/kgsearch_v1/classes.rb +59 -0
  315. data/generated/google/apis/kgsearch_v1/representations.rb +41 -0
  316. data/generated/google/apis/kgsearch_v1/service.rb +113 -0
  317. data/generated/google/apis/language_v1beta1.rb +36 -0
  318. data/generated/google/apis/language_v1beta1/classes.rb +757 -0
  319. data/generated/google/apis/language_v1beta1/representations.rb +339 -0
  320. data/generated/google/apis/language_v1beta1/service.rb +184 -0
  321. data/generated/google/apis/licensing_v1.rb +34 -0
  322. data/generated/google/apis/licensing_v1/classes.rb +132 -0
  323. data/generated/google/apis/licensing_v1/representations.rb +74 -0
  324. data/generated/google/apis/licensing_v1/service.rb +369 -0
  325. data/generated/google/apis/logging_v1beta3.rb +47 -0
  326. data/generated/google/apis/logging_v1beta3/classes.rb +1079 -0
  327. data/generated/google/apis/logging_v1beta3/representations.rb +366 -0
  328. data/generated/google/apis/logging_v1beta3/service.rb +1001 -0
  329. data/generated/google/apis/logging_v2beta1.rb +46 -0
  330. data/generated/google/apis/logging_v2beta1/classes.rb +1254 -0
  331. data/generated/google/apis/logging_v2beta1/representations.rb +421 -0
  332. data/generated/google/apis/logging_v2beta1/service.rb +788 -0
  333. data/generated/google/apis/manager_v1beta2.rb +53 -0
  334. data/generated/google/apis/manager_v1beta2/classes.rb +1287 -0
  335. data/generated/google/apis/manager_v1beta2/representations.rb +606 -0
  336. data/generated/google/apis/manager_v1beta2/service.rb +372 -0
  337. data/generated/google/apis/manufacturers_v1.rb +34 -0
  338. data/generated/google/apis/manufacturers_v1/classes.rb +258 -0
  339. data/generated/google/apis/manufacturers_v1/representations.rb +103 -0
  340. data/generated/google/apis/manufacturers_v1/service.rb +138 -0
  341. data/generated/google/apis/mirror_v1.rb +37 -0
  342. data/generated/google/apis/mirror_v1/classes.rb +1072 -0
  343. data/generated/google/apis/mirror_v1/representations.rb +390 -0
  344. data/generated/google/apis/mirror_v1/service.rb +977 -0
  345. data/generated/google/apis/monitoring_v3.rb +45 -0
  346. data/generated/google/apis/monitoring_v3/classes.rb +1335 -0
  347. data/generated/google/apis/monitoring_v3/representations.rb +516 -0
  348. data/generated/google/apis/monitoring_v3/service.rb +706 -0
  349. data/generated/google/apis/mybusiness_v3.rb +32 -0
  350. data/generated/google/apis/mybusiness_v3/classes.rb +1864 -0
  351. data/generated/google/apis/mybusiness_v3/representations.rb +741 -0
  352. data/generated/google/apis/mybusiness_v3/service.rb +960 -0
  353. data/generated/google/apis/oauth2_v2.rb +43 -0
  354. data/generated/google/apis/oauth2_v2/classes.rb +245 -0
  355. data/generated/google/apis/oauth2_v2/representations.rb +102 -0
  356. data/generated/google/apis/oauth2_v2/service.rb +199 -0
  357. data/generated/google/apis/pagespeedonline_v2.rb +32 -0
  358. data/generated/google/apis/pagespeedonline_v2/classes.rb +614 -0
  359. data/generated/google/apis/pagespeedonline_v2/representations.rb +272 -0
  360. data/generated/google/apis/pagespeedonline_v2/service.rb +119 -0
  361. data/generated/google/apis/partners_v2.rb +32 -0
  362. data/generated/google/apis/partners_v2/classes.rb +942 -0
  363. data/generated/google/apis/partners_v2/representations.rb +454 -0
  364. data/generated/google/apis/partners_v2/service.rb +400 -0
  365. data/generated/google/apis/people_v1.rb +59 -0
  366. data/generated/google/apis/people_v1/classes.rb +1521 -0
  367. data/generated/google/apis/people_v1/representations.rb +663 -0
  368. data/generated/google/apis/people_v1/service.rb +189 -0
  369. data/generated/google/apis/plus_domains_v1.rb +61 -0
  370. data/generated/google/apis/plus_domains_v1/classes.rb +2609 -0
  371. data/generated/google/apis/plus_domains_v1/representations.rb +1111 -0
  372. data/generated/google/apis/plus_domains_v1/service.rb +904 -0
  373. data/generated/google/apis/plus_v1.rb +43 -0
  374. data/generated/google/apis/plus_v1/classes.rb +2094 -0
  375. data/generated/google/apis/plus_v1/representations.rb +907 -0
  376. data/generated/google/apis/plus_v1/service.rb +470 -0
  377. data/generated/google/apis/prediction_v1_6.rb +47 -0
  378. data/generated/google/apis/prediction_v1_6/classes.rb +751 -0
  379. data/generated/google/apis/prediction_v1_6/representations.rb +369 -0
  380. data/generated/google/apis/prediction_v1_6/service.rb +380 -0
  381. data/generated/google/apis/proximitybeacon_v1beta1.rb +34 -0
  382. data/generated/google/apis/proximitybeacon_v1beta1/classes.rb +786 -0
  383. data/generated/google/apis/proximitybeacon_v1beta1/representations.rb +347 -0
  384. data/generated/google/apis/proximitybeacon_v1beta1/service.rb +806 -0
  385. data/generated/google/apis/pubsub_v1.rb +37 -0
  386. data/generated/google/apis/pubsub_v1/classes.rb +676 -0
  387. data/generated/google/apis/pubsub_v1/representations.rb +323 -0
  388. data/generated/google/apis/pubsub_v1/service.rb +900 -0
  389. data/generated/google/apis/pubsub_v1beta2.rb +37 -0
  390. data/generated/google/apis/pubsub_v1beta2/classes.rb +620 -0
  391. data/generated/google/apis/pubsub_v1beta2/representations.rb +282 -0
  392. data/generated/google/apis/pubsub_v1beta2/service.rb +774 -0
  393. data/generated/google/apis/qpx_express_v1.rb +31 -0
  394. data/generated/google/apis/qpx_express_v1/classes.rb +1274 -0
  395. data/generated/google/apis/qpx_express_v1/representations.rb +473 -0
  396. data/generated/google/apis/qpx_express_v1/service.rb +100 -0
  397. data/generated/google/apis/replicapool_v1beta2.rb +44 -0
  398. data/generated/google/apis/replicapool_v1beta2/classes.rb +631 -0
  399. data/generated/google/apis/replicapool_v1beta2/representations.rb +264 -0
  400. data/generated/google/apis/replicapool_v1beta2/service.rb +608 -0
  401. data/generated/google/apis/replicapoolupdater_v1beta1.rb +45 -0
  402. data/generated/google/apis/replicapoolupdater_v1beta1/classes.rb +733 -0
  403. data/generated/google/apis/replicapoolupdater_v1beta1/representations.rb +294 -0
  404. data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +509 -0
  405. data/generated/google/apis/reseller_v1.rb +37 -0
  406. data/generated/google/apis/reseller_v1/classes.rb +540 -0
  407. data/generated/google/apis/reseller_v1/representations.rb +225 -0
  408. data/generated/google/apis/reseller_v1/service.rb +623 -0
  409. data/generated/google/apis/resourceviews_v1beta2.rb +50 -0
  410. data/generated/google/apis/resourceviews_v1beta2/classes.rb +660 -0
  411. data/generated/google/apis/resourceviews_v1beta2/representations.rb +301 -0
  412. data/generated/google/apis/resourceviews_v1beta2/service.rb +563 -0
  413. data/generated/google/apis/script_v1.rb +64 -0
  414. data/generated/google/apis/script_v1/classes.rb +265 -0
  415. data/generated/google/apis/script_v1/representations.rb +119 -0
  416. data/generated/google/apis/script_v1/service.rb +98 -0
  417. data/generated/google/apis/sheets_v4.rb +43 -0
  418. data/generated/google/apis/sheets_v4/classes.rb +6368 -0
  419. data/generated/google/apis/sheets_v4/representations.rb +2289 -0
  420. data/generated/google/apis/sheets_v4/service.rb +569 -0
  421. data/generated/google/apis/site_verification_v1.rb +37 -0
  422. data/generated/google/apis/site_verification_v1/classes.rb +185 -0
  423. data/generated/google/apis/site_verification_v1/representations.rb +113 -0
  424. data/generated/google/apis/site_verification_v1/service.rb +315 -0
  425. data/generated/google/apis/slides_v1.rb +49 -0
  426. data/generated/google/apis/slides_v1/classes.rb +4044 -0
  427. data/generated/google/apis/slides_v1/representations.rb +1765 -0
  428. data/generated/google/apis/slides_v1/service.rb +202 -0
  429. data/generated/google/apis/speech_v1beta1.rb +34 -0
  430. data/generated/google/apis/speech_v1beta1/classes.rb +513 -0
  431. data/generated/google/apis/speech_v1beta1/representations.rb +218 -0
  432. data/generated/google/apis/speech_v1beta1/service.rb +273 -0
  433. data/generated/google/apis/sqladmin_v1beta4.rb +38 -0
  434. data/generated/google/apis/sqladmin_v1beta4/classes.rb +2142 -0
  435. data/generated/google/apis/sqladmin_v1beta4/representations.rb +893 -0
  436. data/generated/google/apis/sqladmin_v1beta4/service.rb +1709 -0
  437. data/generated/google/apis/storage_v1.rb +46 -0
  438. data/generated/google/apis/storage_v1/classes.rb +1255 -0
  439. data/generated/google/apis/storage_v1/representations.rb +502 -0
  440. data/generated/google/apis/storage_v1/service.rb +1906 -0
  441. data/generated/google/apis/storagetransfer_v1.rb +35 -0
  442. data/generated/google/apis/storagetransfer_v1/classes.rb +1046 -0
  443. data/generated/google/apis/storagetransfer_v1/representations.rb +418 -0
  444. data/generated/google/apis/storagetransfer_v1/service.rb +473 -0
  445. data/generated/google/apis/tagmanager_v1.rb +52 -0
  446. data/generated/google/apis/tagmanager_v1/classes.rb +1494 -0
  447. data/generated/google/apis/tagmanager_v1/representations.rb +611 -0
  448. data/generated/google/apis/tagmanager_v1/service.rb +2119 -0
  449. data/generated/google/apis/taskqueue_v1beta2.rb +37 -0
  450. data/generated/google/apis/taskqueue_v1beta2/classes.rb +254 -0
  451. data/generated/google/apis/taskqueue_v1beta2/representations.rb +126 -0
  452. data/generated/google/apis/taskqueue_v1beta2/service.rb +408 -0
  453. data/generated/google/apis/tasks_v1.rb +37 -0
  454. data/generated/google/apis/tasks_v1/classes.rb +296 -0
  455. data/generated/google/apis/tasks_v1/representations.rb +125 -0
  456. data/generated/google/apis/tasks_v1/service.rb +643 -0
  457. data/generated/google/apis/translate_v2.rb +31 -0
  458. data/generated/google/apis/translate_v2/classes.rb +168 -0
  459. data/generated/google/apis/translate_v2/representations.rb +121 -0
  460. data/generated/google/apis/translate_v2/service.rb +182 -0
  461. data/generated/google/apis/urlshortener_v1.rb +34 -0
  462. data/generated/google/apis/urlshortener_v1/classes.rb +246 -0
  463. data/generated/google/apis/urlshortener_v1/representations.rb +121 -0
  464. data/generated/google/apis/urlshortener_v1/service.rb +176 -0
  465. data/generated/google/apis/vision_v1.rb +36 -0
  466. data/generated/google/apis/vision_v1/classes.rb +1267 -0
  467. data/generated/google/apis/vision_v1/representations.rb +418 -0
  468. data/generated/google/apis/vision_v1/service.rb +90 -0
  469. data/generated/google/apis/webmasters_v3.rb +37 -0
  470. data/generated/google/apis/webmasters_v3/classes.rb +570 -0
  471. data/generated/google/apis/webmasters_v3/representations.rb +283 -0
  472. data/generated/google/apis/webmasters_v3/service.rb +573 -0
  473. data/generated/google/apis/youtube_analytics_v1.rb +46 -0
  474. data/generated/google/apis/youtube_analytics_v1/classes.rb +337 -0
  475. data/generated/google/apis/youtube_analytics_v1/representations.rb +174 -0
  476. data/generated/google/apis/youtube_analytics_v1/service.rb +486 -0
  477. data/generated/google/apis/youtube_partner_v1.rb +37 -0
  478. data/generated/google/apis/youtube_partner_v1/classes.rb +3854 -0
  479. data/generated/google/apis/youtube_partner_v1/representations.rb +1537 -0
  480. data/generated/google/apis/youtube_partner_v1/service.rb +3269 -0
  481. data/generated/google/apis/youtube_v3.rb +50 -0
  482. data/generated/google/apis/youtube_v3/classes.rb +8375 -0
  483. data/generated/google/apis/youtube_v3/representations.rb +3273 -0
  484. data/generated/google/apis/youtube_v3/service.rb +4440 -0
  485. data/generated/google/apis/youtubereporting_v1.rb +38 -0
  486. data/generated/google/apis/youtubereporting_v1/classes.rb +302 -0
  487. data/generated/google/apis/youtubereporting_v1/representations.rb +149 -0
  488. data/generated/google/apis/youtubereporting_v1/service.rb +385 -0
  489. data/google-api-client.gemspec +33 -0
  490. data/lib/cacerts.pem +2183 -0
  491. data/lib/google/api_client/auth/installed_app.rb +128 -0
  492. data/lib/google/api_client/auth/key_utils.rb +94 -0
  493. data/lib/google/api_client/auth/storage.rb +104 -0
  494. data/lib/google/api_client/auth/storages/file_store.rb +57 -0
  495. data/lib/google/api_client/auth/storages/redis_store.rb +59 -0
  496. data/lib/google/api_client/client_secrets.rb +177 -0
  497. data/lib/google/apis.rb +58 -0
  498. data/lib/google/apis/core/api_command.rb +146 -0
  499. data/lib/google/apis/core/base_service.rb +401 -0
  500. data/lib/google/apis/core/batch.rb +239 -0
  501. data/lib/google/apis/core/download.rb +108 -0
  502. data/lib/google/apis/core/hashable.rb +44 -0
  503. data/lib/google/apis/core/http_client_adapter.rb +82 -0
  504. data/lib/google/apis/core/http_command.rb +332 -0
  505. data/lib/google/apis/core/json_representation.rb +145 -0
  506. data/lib/google/apis/core/logging.rb +30 -0
  507. data/lib/google/apis/core/multipart.rb +187 -0
  508. data/lib/google/apis/core/upload.rb +295 -0
  509. data/lib/google/apis/errors.rb +80 -0
  510. data/lib/google/apis/generator.rb +70 -0
  511. data/lib/google/apis/generator/annotator.rb +301 -0
  512. data/lib/google/apis/generator/helpers.rb +74 -0
  513. data/lib/google/apis/generator/model.rb +143 -0
  514. data/lib/google/apis/generator/template.rb +124 -0
  515. data/lib/google/apis/generator/templates/_class.tmpl +40 -0
  516. data/lib/google/apis/generator/templates/_method.tmpl +92 -0
  517. data/lib/google/apis/generator/templates/_representation.tmpl +51 -0
  518. data/lib/google/apis/generator/templates/_representation_stub.tmpl +17 -0
  519. data/lib/google/apis/generator/templates/_representation_type.tmpl +10 -0
  520. data/lib/google/apis/generator/templates/classes.rb.tmpl +29 -0
  521. data/lib/google/apis/generator/templates/module.rb.tmpl +40 -0
  522. data/lib/google/apis/generator/templates/representations.rb.tmpl +32 -0
  523. data/lib/google/apis/generator/templates/service.rb.tmpl +60 -0
  524. data/lib/google/apis/options.rb +85 -0
  525. data/lib/google/apis/version.rb +39 -0
  526. data/rakelib/metrics.rake +22 -0
  527. data/rakelib/rubocop.rake +10 -0
  528. data/rakelib/spec.rake +11 -0
  529. data/rakelib/yard.rake +11 -0
  530. data/samples/cli/.env +4 -0
  531. data/samples/cli/Gemfile +7 -0
  532. data/samples/cli/README.md +51 -0
  533. data/samples/cli/google-api-samples +32 -0
  534. data/samples/cli/lib/base_cli.rb +95 -0
  535. data/samples/cli/lib/samples/analytics.rb +62 -0
  536. data/samples/cli/lib/samples/androidpublisher.rb +47 -0
  537. data/samples/cli/lib/samples/bigquery.rb +101 -0
  538. data/samples/cli/lib/samples/calendar.rb +83 -0
  539. data/samples/cli/lib/samples/drive.rb +82 -0
  540. data/samples/cli/lib/samples/gmail.rb +124 -0
  541. data/samples/cli/lib/samples/pubsub.rb +114 -0
  542. data/samples/cli/lib/samples/sheets.rb +61 -0
  543. data/samples/cli/lib/samples/translate.rb +44 -0
  544. data/samples/cli/lib/samples/you_tube.rb +44 -0
  545. data/samples/web/.env +2 -0
  546. data/samples/web/Gemfile +7 -0
  547. data/samples/web/README.md +44 -0
  548. data/samples/web/app.rb +120 -0
  549. data/samples/web/views/calendar.erb +34 -0
  550. data/samples/web/views/drive.erb +33 -0
  551. data/samples/web/views/home.erb +34 -0
  552. data/samples/web/views/layout.erb +40 -0
  553. data/sync.rb +71 -0
  554. data/third_party/hurley_patches.rb +103 -0
  555. metadata +735 -0
@@ -0,0 +1,2449 @@
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/core/base_service'
16
+ require 'google/apis/core/json_representation'
17
+ require 'google/apis/core/hashable'
18
+ require 'google/apis/errors'
19
+
20
+ module Google
21
+ module Apis
22
+ module GamesV1
23
+ # Google Play Game Services API
24
+ #
25
+ # The API for Google Play Game Services.
26
+ #
27
+ # @example
28
+ # require 'google/apis/games_v1'
29
+ #
30
+ # Games = Google::Apis::GamesV1 # Alias the module
31
+ # service = Games::GamesService.new
32
+ #
33
+ # @see https://developers.google.com/games/services/
34
+ class GamesService < Google::Apis::Core::BaseService
35
+ # @return [String]
36
+ # API key. Your API key identifies your project and provides you with API access,
37
+ # quota, and reports. Required unless you provide an OAuth 2.0 token.
38
+ attr_accessor :key
39
+
40
+ # @return [String]
41
+ # Available to use for quota purposes for server-side applications. Can be any
42
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
43
+ # Overrides userIp if both are provided.
44
+ attr_accessor :quota_user
45
+
46
+ # @return [String]
47
+ # IP address of the site where the request originates. Use this if you want to
48
+ # enforce per-user limits.
49
+ attr_accessor :user_ip
50
+
51
+ def initialize
52
+ super('https://www.googleapis.com/', 'games/v1/')
53
+ end
54
+
55
+ # Lists all the achievement definitions for your application.
56
+ # @param [String] consistency_token
57
+ # The last-seen mutation timestamp.
58
+ # @param [String] language
59
+ # The preferred language to use for strings returned by this method.
60
+ # @param [Fixnum] max_results
61
+ # The maximum number of achievement resources to return in the response, used
62
+ # for paging. For any response, the actual number of achievement resources
63
+ # returned may be less than the specified maxResults.
64
+ # @param [String] page_token
65
+ # The token returned by the previous request.
66
+ # @param [String] fields
67
+ # Selector specifying which fields to include in a partial response.
68
+ # @param [String] quota_user
69
+ # Available to use for quota purposes for server-side applications. Can be any
70
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
71
+ # Overrides userIp if both are provided.
72
+ # @param [String] user_ip
73
+ # IP address of the site where the request originates. Use this if you want to
74
+ # enforce per-user limits.
75
+ # @param [Google::Apis::RequestOptions] options
76
+ # Request-specific options
77
+ #
78
+ # @yield [result, err] Result & error if block supplied
79
+ # @yieldparam result [Google::Apis::GamesV1::ListAchievementDefinitionsResponse] parsed result object
80
+ # @yieldparam err [StandardError] error object if request failed
81
+ #
82
+ # @return [Google::Apis::GamesV1::ListAchievementDefinitionsResponse]
83
+ #
84
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
85
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
86
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
87
+ def list_achievement_definitions(consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
88
+ command = make_simple_command(:get, 'achievements', options)
89
+ command.response_representation = Google::Apis::GamesV1::ListAchievementDefinitionsResponse::Representation
90
+ command.response_class = Google::Apis::GamesV1::ListAchievementDefinitionsResponse
91
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
92
+ command.query['language'] = language unless language.nil?
93
+ command.query['maxResults'] = max_results unless max_results.nil?
94
+ command.query['pageToken'] = page_token unless page_token.nil?
95
+ command.query['fields'] = fields unless fields.nil?
96
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
97
+ command.query['userIp'] = user_ip unless user_ip.nil?
98
+ execute_or_queue_command(command, &block)
99
+ end
100
+
101
+ # Increments the steps of the achievement with the given ID for the currently
102
+ # authenticated player.
103
+ # @param [String] achievement_id
104
+ # The ID of the achievement used by this method.
105
+ # @param [Fixnum] steps_to_increment
106
+ # The number of steps to increment.
107
+ # @param [String] consistency_token
108
+ # The last-seen mutation timestamp.
109
+ # @param [String] request_id
110
+ # A randomly generated numeric ID for each request specified by the caller. This
111
+ # number is used at the server to ensure that the request is handled correctly
112
+ # across retries.
113
+ # @param [String] fields
114
+ # Selector specifying which fields to include in a partial response.
115
+ # @param [String] quota_user
116
+ # Available to use for quota purposes for server-side applications. Can be any
117
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
118
+ # Overrides userIp if both are provided.
119
+ # @param [String] user_ip
120
+ # IP address of the site where the request originates. Use this if you want to
121
+ # enforce per-user limits.
122
+ # @param [Google::Apis::RequestOptions] options
123
+ # Request-specific options
124
+ #
125
+ # @yield [result, err] Result & error if block supplied
126
+ # @yieldparam result [Google::Apis::GamesV1::AchievementIncrementResponse] parsed result object
127
+ # @yieldparam err [StandardError] error object if request failed
128
+ #
129
+ # @return [Google::Apis::GamesV1::AchievementIncrementResponse]
130
+ #
131
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
132
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
133
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
134
+ def increment_achievement(achievement_id, steps_to_increment, consistency_token: nil, request_id: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
135
+ command = make_simple_command(:post, 'achievements/{achievementId}/increment', options)
136
+ command.response_representation = Google::Apis::GamesV1::AchievementIncrementResponse::Representation
137
+ command.response_class = Google::Apis::GamesV1::AchievementIncrementResponse
138
+ command.params['achievementId'] = achievement_id unless achievement_id.nil?
139
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
140
+ command.query['requestId'] = request_id unless request_id.nil?
141
+ command.query['stepsToIncrement'] = steps_to_increment unless steps_to_increment.nil?
142
+ command.query['fields'] = fields unless fields.nil?
143
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
144
+ command.query['userIp'] = user_ip unless user_ip.nil?
145
+ execute_or_queue_command(command, &block)
146
+ end
147
+
148
+ # Lists the progress for all your application's achievements for the currently
149
+ # authenticated player.
150
+ # @param [String] player_id
151
+ # A player ID. A value of me may be used in place of the authenticated player's
152
+ # ID.
153
+ # @param [String] consistency_token
154
+ # The last-seen mutation timestamp.
155
+ # @param [String] language
156
+ # The preferred language to use for strings returned by this method.
157
+ # @param [Fixnum] max_results
158
+ # The maximum number of achievement resources to return in the response, used
159
+ # for paging. For any response, the actual number of achievement resources
160
+ # returned may be less than the specified maxResults.
161
+ # @param [String] page_token
162
+ # The token returned by the previous request.
163
+ # @param [String] state
164
+ # Tells the server to return only achievements with the specified state. If this
165
+ # parameter isn't specified, all achievements are returned.
166
+ # @param [String] fields
167
+ # Selector specifying which fields to include in a partial response.
168
+ # @param [String] quota_user
169
+ # Available to use for quota purposes for server-side applications. Can be any
170
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
171
+ # Overrides userIp if both are provided.
172
+ # @param [String] user_ip
173
+ # IP address of the site where the request originates. Use this if you want to
174
+ # enforce per-user limits.
175
+ # @param [Google::Apis::RequestOptions] options
176
+ # Request-specific options
177
+ #
178
+ # @yield [result, err] Result & error if block supplied
179
+ # @yieldparam result [Google::Apis::GamesV1::ListPlayerAchievementResponse] parsed result object
180
+ # @yieldparam err [StandardError] error object if request failed
181
+ #
182
+ # @return [Google::Apis::GamesV1::ListPlayerAchievementResponse]
183
+ #
184
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
185
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
186
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
187
+ def list_achievements(player_id, consistency_token: nil, language: nil, max_results: nil, page_token: nil, state: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
188
+ command = make_simple_command(:get, 'players/{playerId}/achievements', options)
189
+ command.response_representation = Google::Apis::GamesV1::ListPlayerAchievementResponse::Representation
190
+ command.response_class = Google::Apis::GamesV1::ListPlayerAchievementResponse
191
+ command.params['playerId'] = player_id unless player_id.nil?
192
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
193
+ command.query['language'] = language unless language.nil?
194
+ command.query['maxResults'] = max_results unless max_results.nil?
195
+ command.query['pageToken'] = page_token unless page_token.nil?
196
+ command.query['state'] = state unless state.nil?
197
+ command.query['fields'] = fields unless fields.nil?
198
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
199
+ command.query['userIp'] = user_ip unless user_ip.nil?
200
+ execute_or_queue_command(command, &block)
201
+ end
202
+
203
+ # Sets the state of the achievement with the given ID to REVEALED for the
204
+ # currently authenticated player.
205
+ # @param [String] achievement_id
206
+ # The ID of the achievement used by this method.
207
+ # @param [String] consistency_token
208
+ # The last-seen mutation timestamp.
209
+ # @param [String] fields
210
+ # Selector specifying which fields to include in a partial response.
211
+ # @param [String] quota_user
212
+ # Available to use for quota purposes for server-side applications. Can be any
213
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
214
+ # Overrides userIp if both are provided.
215
+ # @param [String] user_ip
216
+ # IP address of the site where the request originates. Use this if you want to
217
+ # enforce per-user limits.
218
+ # @param [Google::Apis::RequestOptions] options
219
+ # Request-specific options
220
+ #
221
+ # @yield [result, err] Result & error if block supplied
222
+ # @yieldparam result [Google::Apis::GamesV1::AchievementRevealResponse] parsed result object
223
+ # @yieldparam err [StandardError] error object if request failed
224
+ #
225
+ # @return [Google::Apis::GamesV1::AchievementRevealResponse]
226
+ #
227
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
228
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
229
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
230
+ def reveal_achievement(achievement_id, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
231
+ command = make_simple_command(:post, 'achievements/{achievementId}/reveal', options)
232
+ command.response_representation = Google::Apis::GamesV1::AchievementRevealResponse::Representation
233
+ command.response_class = Google::Apis::GamesV1::AchievementRevealResponse
234
+ command.params['achievementId'] = achievement_id unless achievement_id.nil?
235
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
236
+ command.query['fields'] = fields unless fields.nil?
237
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
238
+ command.query['userIp'] = user_ip unless user_ip.nil?
239
+ execute_or_queue_command(command, &block)
240
+ end
241
+
242
+ # Sets the steps for the currently authenticated player towards unlocking an
243
+ # achievement. If the steps parameter is less than the current number of steps
244
+ # that the player already gained for the achievement, the achievement is not
245
+ # modified.
246
+ # @param [String] achievement_id
247
+ # The ID of the achievement used by this method.
248
+ # @param [Fixnum] steps
249
+ # The minimum value to set the steps to.
250
+ # @param [String] consistency_token
251
+ # The last-seen mutation timestamp.
252
+ # @param [String] fields
253
+ # Selector specifying which fields to include in a partial response.
254
+ # @param [String] quota_user
255
+ # Available to use for quota purposes for server-side applications. Can be any
256
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
257
+ # Overrides userIp if both are provided.
258
+ # @param [String] user_ip
259
+ # IP address of the site where the request originates. Use this if you want to
260
+ # enforce per-user limits.
261
+ # @param [Google::Apis::RequestOptions] options
262
+ # Request-specific options
263
+ #
264
+ # @yield [result, err] Result & error if block supplied
265
+ # @yieldparam result [Google::Apis::GamesV1::AchievementSetStepsAtLeastResponse] parsed result object
266
+ # @yieldparam err [StandardError] error object if request failed
267
+ #
268
+ # @return [Google::Apis::GamesV1::AchievementSetStepsAtLeastResponse]
269
+ #
270
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
271
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
272
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
273
+ def set_achievement_steps_at_least(achievement_id, steps, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
274
+ command = make_simple_command(:post, 'achievements/{achievementId}/setStepsAtLeast', options)
275
+ command.response_representation = Google::Apis::GamesV1::AchievementSetStepsAtLeastResponse::Representation
276
+ command.response_class = Google::Apis::GamesV1::AchievementSetStepsAtLeastResponse
277
+ command.params['achievementId'] = achievement_id unless achievement_id.nil?
278
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
279
+ command.query['steps'] = steps unless steps.nil?
280
+ command.query['fields'] = fields unless fields.nil?
281
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
282
+ command.query['userIp'] = user_ip unless user_ip.nil?
283
+ execute_or_queue_command(command, &block)
284
+ end
285
+
286
+ # Unlocks this achievement for the currently authenticated player.
287
+ # @param [String] achievement_id
288
+ # The ID of the achievement used by this method.
289
+ # @param [String] consistency_token
290
+ # The last-seen mutation timestamp.
291
+ # @param [String] fields
292
+ # Selector specifying which fields to include in a partial response.
293
+ # @param [String] quota_user
294
+ # Available to use for quota purposes for server-side applications. Can be any
295
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
296
+ # Overrides userIp if both are provided.
297
+ # @param [String] user_ip
298
+ # IP address of the site where the request originates. Use this if you want to
299
+ # enforce per-user limits.
300
+ # @param [Google::Apis::RequestOptions] options
301
+ # Request-specific options
302
+ #
303
+ # @yield [result, err] Result & error if block supplied
304
+ # @yieldparam result [Google::Apis::GamesV1::AchievementUnlockResponse] parsed result object
305
+ # @yieldparam err [StandardError] error object if request failed
306
+ #
307
+ # @return [Google::Apis::GamesV1::AchievementUnlockResponse]
308
+ #
309
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
310
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
311
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
312
+ def unlock_achievement(achievement_id, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
313
+ command = make_simple_command(:post, 'achievements/{achievementId}/unlock', options)
314
+ command.response_representation = Google::Apis::GamesV1::AchievementUnlockResponse::Representation
315
+ command.response_class = Google::Apis::GamesV1::AchievementUnlockResponse
316
+ command.params['achievementId'] = achievement_id unless achievement_id.nil?
317
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
318
+ command.query['fields'] = fields unless fields.nil?
319
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
320
+ command.query['userIp'] = user_ip unless user_ip.nil?
321
+ execute_or_queue_command(command, &block)
322
+ end
323
+
324
+ # Updates multiple achievements for the currently authenticated player.
325
+ # @param [Google::Apis::GamesV1::AchievementUpdateMultipleRequest] achievement_update_multiple_request_object
326
+ # @param [String] consistency_token
327
+ # The last-seen mutation timestamp.
328
+ # @param [String] fields
329
+ # Selector specifying which fields to include in a partial response.
330
+ # @param [String] quota_user
331
+ # Available to use for quota purposes for server-side applications. Can be any
332
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
333
+ # Overrides userIp if both are provided.
334
+ # @param [String] user_ip
335
+ # IP address of the site where the request originates. Use this if you want to
336
+ # enforce per-user limits.
337
+ # @param [Google::Apis::RequestOptions] options
338
+ # Request-specific options
339
+ #
340
+ # @yield [result, err] Result & error if block supplied
341
+ # @yieldparam result [Google::Apis::GamesV1::AchievementUpdateMultipleResponse] parsed result object
342
+ # @yieldparam err [StandardError] error object if request failed
343
+ #
344
+ # @return [Google::Apis::GamesV1::AchievementUpdateMultipleResponse]
345
+ #
346
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
347
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
348
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
349
+ def update_multiple_achievements(achievement_update_multiple_request_object = nil, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
350
+ command = make_simple_command(:post, 'achievements/updateMultiple', options)
351
+ command.request_representation = Google::Apis::GamesV1::AchievementUpdateMultipleRequest::Representation
352
+ command.request_object = achievement_update_multiple_request_object
353
+ command.response_representation = Google::Apis::GamesV1::AchievementUpdateMultipleResponse::Representation
354
+ command.response_class = Google::Apis::GamesV1::AchievementUpdateMultipleResponse
355
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
356
+ command.query['fields'] = fields unless fields.nil?
357
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
358
+ command.query['userIp'] = user_ip unless user_ip.nil?
359
+ execute_or_queue_command(command, &block)
360
+ end
361
+
362
+ # Retrieves the metadata of the application with the given ID. If the requested
363
+ # application is not available for the specified platformType, the returned
364
+ # response will not include any instance data.
365
+ # @param [String] application_id
366
+ # The application ID from the Google Play developer console.
367
+ # @param [String] consistency_token
368
+ # The last-seen mutation timestamp.
369
+ # @param [String] language
370
+ # The preferred language to use for strings returned by this method.
371
+ # @param [String] platform_type
372
+ # Restrict application details returned to the specific platform.
373
+ # @param [String] fields
374
+ # Selector specifying which fields to include in a partial response.
375
+ # @param [String] quota_user
376
+ # Available to use for quota purposes for server-side applications. Can be any
377
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
378
+ # Overrides userIp if both are provided.
379
+ # @param [String] user_ip
380
+ # IP address of the site where the request originates. Use this if you want to
381
+ # enforce per-user limits.
382
+ # @param [Google::Apis::RequestOptions] options
383
+ # Request-specific options
384
+ #
385
+ # @yield [result, err] Result & error if block supplied
386
+ # @yieldparam result [Google::Apis::GamesV1::Application] parsed result object
387
+ # @yieldparam err [StandardError] error object if request failed
388
+ #
389
+ # @return [Google::Apis::GamesV1::Application]
390
+ #
391
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
392
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
393
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
394
+ def get_application(application_id, consistency_token: nil, language: nil, platform_type: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
395
+ command = make_simple_command(:get, 'applications/{applicationId}', options)
396
+ command.response_representation = Google::Apis::GamesV1::Application::Representation
397
+ command.response_class = Google::Apis::GamesV1::Application
398
+ command.params['applicationId'] = application_id unless application_id.nil?
399
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
400
+ command.query['language'] = language unless language.nil?
401
+ command.query['platformType'] = platform_type unless platform_type.nil?
402
+ command.query['fields'] = fields unless fields.nil?
403
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
404
+ command.query['userIp'] = user_ip unless user_ip.nil?
405
+ execute_or_queue_command(command, &block)
406
+ end
407
+
408
+ # Indicate that the the currently authenticated user is playing your application.
409
+ # @param [String] consistency_token
410
+ # The last-seen mutation timestamp.
411
+ # @param [String] fields
412
+ # Selector specifying which fields to include in a partial response.
413
+ # @param [String] quota_user
414
+ # Available to use for quota purposes for server-side applications. Can be any
415
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
416
+ # Overrides userIp if both are provided.
417
+ # @param [String] user_ip
418
+ # IP address of the site where the request originates. Use this if you want to
419
+ # enforce per-user limits.
420
+ # @param [Google::Apis::RequestOptions] options
421
+ # Request-specific options
422
+ #
423
+ # @yield [result, err] Result & error if block supplied
424
+ # @yieldparam result [NilClass] No result returned for this method
425
+ # @yieldparam err [StandardError] error object if request failed
426
+ #
427
+ # @return [void]
428
+ #
429
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
430
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
431
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
432
+ def played_application(consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
433
+ command = make_simple_command(:post, 'applications/played', options)
434
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
435
+ command.query['fields'] = fields unless fields.nil?
436
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
437
+ command.query['userIp'] = user_ip unless user_ip.nil?
438
+ execute_or_queue_command(command, &block)
439
+ end
440
+
441
+ # Verifies the auth token provided with this request is for the application with
442
+ # the specified ID, and returns the ID of the player it was granted for.
443
+ # @param [String] application_id
444
+ # The application ID from the Google Play developer console.
445
+ # @param [String] consistency_token
446
+ # The last-seen mutation timestamp.
447
+ # @param [String] fields
448
+ # Selector specifying which fields to include in a partial response.
449
+ # @param [String] quota_user
450
+ # Available to use for quota purposes for server-side applications. Can be any
451
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
452
+ # Overrides userIp if both are provided.
453
+ # @param [String] user_ip
454
+ # IP address of the site where the request originates. Use this if you want to
455
+ # enforce per-user limits.
456
+ # @param [Google::Apis::RequestOptions] options
457
+ # Request-specific options
458
+ #
459
+ # @yield [result, err] Result & error if block supplied
460
+ # @yieldparam result [Google::Apis::GamesV1::ApplicationVerifyResponse] parsed result object
461
+ # @yieldparam err [StandardError] error object if request failed
462
+ #
463
+ # @return [Google::Apis::GamesV1::ApplicationVerifyResponse]
464
+ #
465
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
466
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
467
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
468
+ def verify_application(application_id, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
469
+ command = make_simple_command(:get, 'applications/{applicationId}/verify', options)
470
+ command.response_representation = Google::Apis::GamesV1::ApplicationVerifyResponse::Representation
471
+ command.response_class = Google::Apis::GamesV1::ApplicationVerifyResponse
472
+ command.params['applicationId'] = application_id unless application_id.nil?
473
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
474
+ command.query['fields'] = fields unless fields.nil?
475
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
476
+ command.query['userIp'] = user_ip unless user_ip.nil?
477
+ execute_or_queue_command(command, &block)
478
+ end
479
+
480
+ # Returns a list showing the current progress on events in this application for
481
+ # the currently authenticated user.
482
+ # @param [String] consistency_token
483
+ # The last-seen mutation timestamp.
484
+ # @param [String] language
485
+ # The preferred language to use for strings returned by this method.
486
+ # @param [Fixnum] max_results
487
+ # The maximum number of events to return in the response, used for paging. For
488
+ # any response, the actual number of events to return may be less than the
489
+ # specified maxResults.
490
+ # @param [String] page_token
491
+ # The token returned by the previous request.
492
+ # @param [String] fields
493
+ # Selector specifying which fields to include in a partial response.
494
+ # @param [String] quota_user
495
+ # Available to use for quota purposes for server-side applications. Can be any
496
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
497
+ # Overrides userIp if both are provided.
498
+ # @param [String] user_ip
499
+ # IP address of the site where the request originates. Use this if you want to
500
+ # enforce per-user limits.
501
+ # @param [Google::Apis::RequestOptions] options
502
+ # Request-specific options
503
+ #
504
+ # @yield [result, err] Result & error if block supplied
505
+ # @yieldparam result [Google::Apis::GamesV1::ListPlayerEventResponse] parsed result object
506
+ # @yieldparam err [StandardError] error object if request failed
507
+ #
508
+ # @return [Google::Apis::GamesV1::ListPlayerEventResponse]
509
+ #
510
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
511
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
512
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
513
+ def list_event_by_player(consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
514
+ command = make_simple_command(:get, 'events', options)
515
+ command.response_representation = Google::Apis::GamesV1::ListPlayerEventResponse::Representation
516
+ command.response_class = Google::Apis::GamesV1::ListPlayerEventResponse
517
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
518
+ command.query['language'] = language unless language.nil?
519
+ command.query['maxResults'] = max_results unless max_results.nil?
520
+ command.query['pageToken'] = page_token unless page_token.nil?
521
+ command.query['fields'] = fields unless fields.nil?
522
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
523
+ command.query['userIp'] = user_ip unless user_ip.nil?
524
+ execute_or_queue_command(command, &block)
525
+ end
526
+
527
+ # Returns a list of the event definitions in this application.
528
+ # @param [String] consistency_token
529
+ # The last-seen mutation timestamp.
530
+ # @param [String] language
531
+ # The preferred language to use for strings returned by this method.
532
+ # @param [Fixnum] max_results
533
+ # The maximum number of event definitions to return in the response, used for
534
+ # paging. For any response, the actual number of event definitions to return may
535
+ # be less than the specified maxResults.
536
+ # @param [String] page_token
537
+ # The token returned by the previous request.
538
+ # @param [String] fields
539
+ # Selector specifying which fields to include in a partial response.
540
+ # @param [String] quota_user
541
+ # Available to use for quota purposes for server-side applications. Can be any
542
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
543
+ # Overrides userIp if both are provided.
544
+ # @param [String] user_ip
545
+ # IP address of the site where the request originates. Use this if you want to
546
+ # enforce per-user limits.
547
+ # @param [Google::Apis::RequestOptions] options
548
+ # Request-specific options
549
+ #
550
+ # @yield [result, err] Result & error if block supplied
551
+ # @yieldparam result [Google::Apis::GamesV1::ListEventDefinitionResponse] parsed result object
552
+ # @yieldparam err [StandardError] error object if request failed
553
+ #
554
+ # @return [Google::Apis::GamesV1::ListEventDefinitionResponse]
555
+ #
556
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
557
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
558
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
559
+ def list_event_definitions(consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
560
+ command = make_simple_command(:get, 'eventDefinitions', options)
561
+ command.response_representation = Google::Apis::GamesV1::ListEventDefinitionResponse::Representation
562
+ command.response_class = Google::Apis::GamesV1::ListEventDefinitionResponse
563
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
564
+ command.query['language'] = language unless language.nil?
565
+ command.query['maxResults'] = max_results unless max_results.nil?
566
+ command.query['pageToken'] = page_token unless page_token.nil?
567
+ command.query['fields'] = fields unless fields.nil?
568
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
569
+ command.query['userIp'] = user_ip unless user_ip.nil?
570
+ execute_or_queue_command(command, &block)
571
+ end
572
+
573
+ # Records a batch of changes to the number of times events have occurred for the
574
+ # currently authenticated user of this application.
575
+ # @param [Google::Apis::GamesV1::EventRecordRequest] event_record_request_object
576
+ # @param [String] consistency_token
577
+ # The last-seen mutation timestamp.
578
+ # @param [String] language
579
+ # The preferred language to use for strings returned by this method.
580
+ # @param [String] fields
581
+ # Selector specifying which fields to include in a partial response.
582
+ # @param [String] quota_user
583
+ # Available to use for quota purposes for server-side applications. Can be any
584
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
585
+ # Overrides userIp if both are provided.
586
+ # @param [String] user_ip
587
+ # IP address of the site where the request originates. Use this if you want to
588
+ # enforce per-user limits.
589
+ # @param [Google::Apis::RequestOptions] options
590
+ # Request-specific options
591
+ #
592
+ # @yield [result, err] Result & error if block supplied
593
+ # @yieldparam result [Google::Apis::GamesV1::UpdateEventResponse] parsed result object
594
+ # @yieldparam err [StandardError] error object if request failed
595
+ #
596
+ # @return [Google::Apis::GamesV1::UpdateEventResponse]
597
+ #
598
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
599
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
600
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
601
+ def record_event(event_record_request_object = nil, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
602
+ command = make_simple_command(:post, 'events', options)
603
+ command.request_representation = Google::Apis::GamesV1::EventRecordRequest::Representation
604
+ command.request_object = event_record_request_object
605
+ command.response_representation = Google::Apis::GamesV1::UpdateEventResponse::Representation
606
+ command.response_class = Google::Apis::GamesV1::UpdateEventResponse
607
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
608
+ command.query['language'] = language unless language.nil?
609
+ command.query['fields'] = fields unless fields.nil?
610
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
611
+ command.query['userIp'] = user_ip unless user_ip.nil?
612
+ execute_or_queue_command(command, &block)
613
+ end
614
+
615
+ # Retrieves the metadata of the leaderboard with the given ID.
616
+ # @param [String] leaderboard_id
617
+ # The ID of the leaderboard.
618
+ # @param [String] consistency_token
619
+ # The last-seen mutation timestamp.
620
+ # @param [String] language
621
+ # The preferred language to use for strings returned by this method.
622
+ # @param [String] fields
623
+ # Selector specifying which fields to include in a partial response.
624
+ # @param [String] quota_user
625
+ # Available to use for quota purposes for server-side applications. Can be any
626
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
627
+ # Overrides userIp if both are provided.
628
+ # @param [String] user_ip
629
+ # IP address of the site where the request originates. Use this if you want to
630
+ # enforce per-user limits.
631
+ # @param [Google::Apis::RequestOptions] options
632
+ # Request-specific options
633
+ #
634
+ # @yield [result, err] Result & error if block supplied
635
+ # @yieldparam result [Google::Apis::GamesV1::Leaderboard] parsed result object
636
+ # @yieldparam err [StandardError] error object if request failed
637
+ #
638
+ # @return [Google::Apis::GamesV1::Leaderboard]
639
+ #
640
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
641
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
642
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
643
+ def get_leaderboard(leaderboard_id, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
644
+ command = make_simple_command(:get, 'leaderboards/{leaderboardId}', options)
645
+ command.response_representation = Google::Apis::GamesV1::Leaderboard::Representation
646
+ command.response_class = Google::Apis::GamesV1::Leaderboard
647
+ command.params['leaderboardId'] = leaderboard_id unless leaderboard_id.nil?
648
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
649
+ command.query['language'] = language unless language.nil?
650
+ command.query['fields'] = fields unless fields.nil?
651
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
652
+ command.query['userIp'] = user_ip unless user_ip.nil?
653
+ execute_or_queue_command(command, &block)
654
+ end
655
+
656
+ # Lists all the leaderboard metadata for your application.
657
+ # @param [String] consistency_token
658
+ # The last-seen mutation timestamp.
659
+ # @param [String] language
660
+ # The preferred language to use for strings returned by this method.
661
+ # @param [Fixnum] max_results
662
+ # The maximum number of leaderboards to return in the response. For any response,
663
+ # the actual number of leaderboards returned may be less than the specified
664
+ # maxResults.
665
+ # @param [String] page_token
666
+ # The token returned by the previous request.
667
+ # @param [String] fields
668
+ # Selector specifying which fields to include in a partial response.
669
+ # @param [String] quota_user
670
+ # Available to use for quota purposes for server-side applications. Can be any
671
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
672
+ # Overrides userIp if both are provided.
673
+ # @param [String] user_ip
674
+ # IP address of the site where the request originates. Use this if you want to
675
+ # enforce per-user limits.
676
+ # @param [Google::Apis::RequestOptions] options
677
+ # Request-specific options
678
+ #
679
+ # @yield [result, err] Result & error if block supplied
680
+ # @yieldparam result [Google::Apis::GamesV1::ListLeaderboardResponse] parsed result object
681
+ # @yieldparam err [StandardError] error object if request failed
682
+ #
683
+ # @return [Google::Apis::GamesV1::ListLeaderboardResponse]
684
+ #
685
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
686
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
687
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
688
+ def list_leaderboards(consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
689
+ command = make_simple_command(:get, 'leaderboards', options)
690
+ command.response_representation = Google::Apis::GamesV1::ListLeaderboardResponse::Representation
691
+ command.response_class = Google::Apis::GamesV1::ListLeaderboardResponse
692
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
693
+ command.query['language'] = language unless language.nil?
694
+ command.query['maxResults'] = max_results unless max_results.nil?
695
+ command.query['pageToken'] = page_token unless page_token.nil?
696
+ command.query['fields'] = fields unless fields.nil?
697
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
698
+ command.query['userIp'] = user_ip unless user_ip.nil?
699
+ execute_or_queue_command(command, &block)
700
+ end
701
+
702
+ # Return the metagame configuration data for the calling application.
703
+ # @param [String] consistency_token
704
+ # The last-seen mutation timestamp.
705
+ # @param [String] fields
706
+ # Selector specifying which fields to include in a partial response.
707
+ # @param [String] quota_user
708
+ # Available to use for quota purposes for server-side applications. Can be any
709
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
710
+ # Overrides userIp if both are provided.
711
+ # @param [String] user_ip
712
+ # IP address of the site where the request originates. Use this if you want to
713
+ # enforce per-user limits.
714
+ # @param [Google::Apis::RequestOptions] options
715
+ # Request-specific options
716
+ #
717
+ # @yield [result, err] Result & error if block supplied
718
+ # @yieldparam result [Google::Apis::GamesV1::MetagameConfig] parsed result object
719
+ # @yieldparam err [StandardError] error object if request failed
720
+ #
721
+ # @return [Google::Apis::GamesV1::MetagameConfig]
722
+ #
723
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
724
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
725
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
726
+ def get_metagame_config(consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
727
+ command = make_simple_command(:get, 'metagameConfig', options)
728
+ command.response_representation = Google::Apis::GamesV1::MetagameConfig::Representation
729
+ command.response_class = Google::Apis::GamesV1::MetagameConfig
730
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
731
+ command.query['fields'] = fields unless fields.nil?
732
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
733
+ command.query['userIp'] = user_ip unless user_ip.nil?
734
+ execute_or_queue_command(command, &block)
735
+ end
736
+
737
+ # List play data aggregated per category for the player corresponding to
738
+ # playerId.
739
+ # @param [String] player_id
740
+ # A player ID. A value of me may be used in place of the authenticated player's
741
+ # ID.
742
+ # @param [String] collection
743
+ # The collection of categories for which data will be returned.
744
+ # @param [String] consistency_token
745
+ # The last-seen mutation timestamp.
746
+ # @param [String] language
747
+ # The preferred language to use for strings returned by this method.
748
+ # @param [Fixnum] max_results
749
+ # The maximum number of category resources to return in the response, used for
750
+ # paging. For any response, the actual number of category resources returned may
751
+ # be less than the specified maxResults.
752
+ # @param [String] page_token
753
+ # The token returned by the previous request.
754
+ # @param [String] fields
755
+ # Selector specifying which fields to include in a partial response.
756
+ # @param [String] quota_user
757
+ # Available to use for quota purposes for server-side applications. Can be any
758
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
759
+ # Overrides userIp if both are provided.
760
+ # @param [String] user_ip
761
+ # IP address of the site where the request originates. Use this if you want to
762
+ # enforce per-user limits.
763
+ # @param [Google::Apis::RequestOptions] options
764
+ # Request-specific options
765
+ #
766
+ # @yield [result, err] Result & error if block supplied
767
+ # @yieldparam result [Google::Apis::GamesV1::ListCategoryResponse] parsed result object
768
+ # @yieldparam err [StandardError] error object if request failed
769
+ #
770
+ # @return [Google::Apis::GamesV1::ListCategoryResponse]
771
+ #
772
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
773
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
774
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
775
+ def list_metagame_categories_by_player(player_id, collection, consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
776
+ command = make_simple_command(:get, 'players/{playerId}/categories/{collection}', options)
777
+ command.response_representation = Google::Apis::GamesV1::ListCategoryResponse::Representation
778
+ command.response_class = Google::Apis::GamesV1::ListCategoryResponse
779
+ command.params['playerId'] = player_id unless player_id.nil?
780
+ command.params['collection'] = collection unless collection.nil?
781
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
782
+ command.query['language'] = language unless language.nil?
783
+ command.query['maxResults'] = max_results unless max_results.nil?
784
+ command.query['pageToken'] = page_token unless page_token.nil?
785
+ command.query['fields'] = fields unless fields.nil?
786
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
787
+ command.query['userIp'] = user_ip unless user_ip.nil?
788
+ execute_or_queue_command(command, &block)
789
+ end
790
+
791
+ # Retrieves the Player resource with the given ID. To retrieve the player for
792
+ # the currently authenticated user, set playerId to me.
793
+ # @param [String] player_id
794
+ # A player ID. A value of me may be used in place of the authenticated player's
795
+ # ID.
796
+ # @param [String] consistency_token
797
+ # The last-seen mutation timestamp.
798
+ # @param [String] language
799
+ # The preferred language to use for strings returned by this method.
800
+ # @param [String] fields
801
+ # Selector specifying which fields to include in a partial response.
802
+ # @param [String] quota_user
803
+ # Available to use for quota purposes for server-side applications. Can be any
804
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
805
+ # Overrides userIp if both are provided.
806
+ # @param [String] user_ip
807
+ # IP address of the site where the request originates. Use this if you want to
808
+ # enforce per-user limits.
809
+ # @param [Google::Apis::RequestOptions] options
810
+ # Request-specific options
811
+ #
812
+ # @yield [result, err] Result & error if block supplied
813
+ # @yieldparam result [Google::Apis::GamesV1::Player] parsed result object
814
+ # @yieldparam err [StandardError] error object if request failed
815
+ #
816
+ # @return [Google::Apis::GamesV1::Player]
817
+ #
818
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
819
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
820
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
821
+ def get_player(player_id, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
822
+ command = make_simple_command(:get, 'players/{playerId}', options)
823
+ command.response_representation = Google::Apis::GamesV1::Player::Representation
824
+ command.response_class = Google::Apis::GamesV1::Player
825
+ command.params['playerId'] = player_id unless player_id.nil?
826
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
827
+ command.query['language'] = language unless language.nil?
828
+ command.query['fields'] = fields unless fields.nil?
829
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
830
+ command.query['userIp'] = user_ip unless user_ip.nil?
831
+ execute_or_queue_command(command, &block)
832
+ end
833
+
834
+ # Get the collection of players for the currently authenticated user.
835
+ # @param [String] collection
836
+ # Collection of players being retrieved
837
+ # @param [String] consistency_token
838
+ # The last-seen mutation timestamp.
839
+ # @param [String] language
840
+ # The preferred language to use for strings returned by this method.
841
+ # @param [Fixnum] max_results
842
+ # The maximum number of player resources to return in the response, used for
843
+ # paging. For any response, the actual number of player resources returned may
844
+ # be less than the specified maxResults.
845
+ # @param [String] page_token
846
+ # The token returned by the previous request.
847
+ # @param [String] fields
848
+ # Selector specifying which fields to include in a partial response.
849
+ # @param [String] quota_user
850
+ # Available to use for quota purposes for server-side applications. Can be any
851
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
852
+ # Overrides userIp if both are provided.
853
+ # @param [String] user_ip
854
+ # IP address of the site where the request originates. Use this if you want to
855
+ # enforce per-user limits.
856
+ # @param [Google::Apis::RequestOptions] options
857
+ # Request-specific options
858
+ #
859
+ # @yield [result, err] Result & error if block supplied
860
+ # @yieldparam result [Google::Apis::GamesV1::ListPlayerResponse] parsed result object
861
+ # @yieldparam err [StandardError] error object if request failed
862
+ #
863
+ # @return [Google::Apis::GamesV1::ListPlayerResponse]
864
+ #
865
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
866
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
867
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
868
+ def list_players(collection, consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
869
+ command = make_simple_command(:get, 'players/me/players/{collection}', options)
870
+ command.response_representation = Google::Apis::GamesV1::ListPlayerResponse::Representation
871
+ command.response_class = Google::Apis::GamesV1::ListPlayerResponse
872
+ command.params['collection'] = collection unless collection.nil?
873
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
874
+ command.query['language'] = language unless language.nil?
875
+ command.query['maxResults'] = max_results unless max_results.nil?
876
+ command.query['pageToken'] = page_token unless page_token.nil?
877
+ command.query['fields'] = fields unless fields.nil?
878
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
879
+ command.query['userIp'] = user_ip unless user_ip.nil?
880
+ execute_or_queue_command(command, &block)
881
+ end
882
+
883
+ # Removes a push token for the current user and application. Removing a non-
884
+ # existent push token will report success.
885
+ # @param [Google::Apis::GamesV1::PushTokenId] push_token_id_object
886
+ # @param [String] consistency_token
887
+ # The last-seen mutation timestamp.
888
+ # @param [String] fields
889
+ # Selector specifying which fields to include in a partial response.
890
+ # @param [String] quota_user
891
+ # Available to use for quota purposes for server-side applications. Can be any
892
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
893
+ # Overrides userIp if both are provided.
894
+ # @param [String] user_ip
895
+ # IP address of the site where the request originates. Use this if you want to
896
+ # enforce per-user limits.
897
+ # @param [Google::Apis::RequestOptions] options
898
+ # Request-specific options
899
+ #
900
+ # @yield [result, err] Result & error if block supplied
901
+ # @yieldparam result [NilClass] No result returned for this method
902
+ # @yieldparam err [StandardError] error object if request failed
903
+ #
904
+ # @return [void]
905
+ #
906
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
907
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
908
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
909
+ def remove_pushtoken(push_token_id_object = nil, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
910
+ command = make_simple_command(:post, 'pushtokens/remove', options)
911
+ command.request_representation = Google::Apis::GamesV1::PushTokenId::Representation
912
+ command.request_object = push_token_id_object
913
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
914
+ command.query['fields'] = fields unless fields.nil?
915
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
916
+ command.query['userIp'] = user_ip unless user_ip.nil?
917
+ execute_or_queue_command(command, &block)
918
+ end
919
+
920
+ # Registers a push token for the current user and application.
921
+ # @param [Google::Apis::GamesV1::PushToken] push_token_object
922
+ # @param [String] consistency_token
923
+ # The last-seen mutation timestamp.
924
+ # @param [String] fields
925
+ # Selector specifying which fields to include in a partial response.
926
+ # @param [String] quota_user
927
+ # Available to use for quota purposes for server-side applications. Can be any
928
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
929
+ # Overrides userIp if both are provided.
930
+ # @param [String] user_ip
931
+ # IP address of the site where the request originates. Use this if you want to
932
+ # enforce per-user limits.
933
+ # @param [Google::Apis::RequestOptions] options
934
+ # Request-specific options
935
+ #
936
+ # @yield [result, err] Result & error if block supplied
937
+ # @yieldparam result [NilClass] No result returned for this method
938
+ # @yieldparam err [StandardError] error object if request failed
939
+ #
940
+ # @return [void]
941
+ #
942
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
943
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
944
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
945
+ def update_pushtoken(push_token_object = nil, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
946
+ command = make_simple_command(:put, 'pushtokens', options)
947
+ command.request_representation = Google::Apis::GamesV1::PushToken::Representation
948
+ command.request_object = push_token_object
949
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
950
+ command.query['fields'] = fields unless fields.nil?
951
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
952
+ command.query['userIp'] = user_ip unless user_ip.nil?
953
+ execute_or_queue_command(command, &block)
954
+ end
955
+
956
+ # Report that a reward for the milestone corresponding to milestoneId for the
957
+ # quest corresponding to questId has been claimed by the currently authorized
958
+ # user.
959
+ # @param [String] quest_id
960
+ # The ID of the quest.
961
+ # @param [String] milestone_id
962
+ # The ID of the milestone.
963
+ # @param [String] request_id
964
+ # A numeric ID to ensure that the request is handled correctly across retries.
965
+ # Your client application must generate this ID randomly.
966
+ # @param [String] consistency_token
967
+ # The last-seen mutation timestamp.
968
+ # @param [String] fields
969
+ # Selector specifying which fields to include in a partial response.
970
+ # @param [String] quota_user
971
+ # Available to use for quota purposes for server-side applications. Can be any
972
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
973
+ # Overrides userIp if both are provided.
974
+ # @param [String] user_ip
975
+ # IP address of the site where the request originates. Use this if you want to
976
+ # enforce per-user limits.
977
+ # @param [Google::Apis::RequestOptions] options
978
+ # Request-specific options
979
+ #
980
+ # @yield [result, err] Result & error if block supplied
981
+ # @yieldparam result [NilClass] No result returned for this method
982
+ # @yieldparam err [StandardError] error object if request failed
983
+ #
984
+ # @return [void]
985
+ #
986
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
987
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
988
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
989
+ def claim_quest_milestone(quest_id, milestone_id, request_id, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
990
+ command = make_simple_command(:put, 'quests/{questId}/milestones/{milestoneId}/claim', options)
991
+ command.params['questId'] = quest_id unless quest_id.nil?
992
+ command.params['milestoneId'] = milestone_id unless milestone_id.nil?
993
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
994
+ command.query['requestId'] = request_id unless request_id.nil?
995
+ command.query['fields'] = fields unless fields.nil?
996
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
997
+ command.query['userIp'] = user_ip unless user_ip.nil?
998
+ execute_or_queue_command(command, &block)
999
+ end
1000
+
1001
+ # Indicates that the currently authorized user will participate in the quest.
1002
+ # @param [String] quest_id
1003
+ # The ID of the quest.
1004
+ # @param [String] consistency_token
1005
+ # The last-seen mutation timestamp.
1006
+ # @param [String] language
1007
+ # The preferred language to use for strings returned by this method.
1008
+ # @param [String] fields
1009
+ # Selector specifying which fields to include in a partial response.
1010
+ # @param [String] quota_user
1011
+ # Available to use for quota purposes for server-side applications. Can be any
1012
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1013
+ # Overrides userIp if both are provided.
1014
+ # @param [String] user_ip
1015
+ # IP address of the site where the request originates. Use this if you want to
1016
+ # enforce per-user limits.
1017
+ # @param [Google::Apis::RequestOptions] options
1018
+ # Request-specific options
1019
+ #
1020
+ # @yield [result, err] Result & error if block supplied
1021
+ # @yieldparam result [Google::Apis::GamesV1::Quest] parsed result object
1022
+ # @yieldparam err [StandardError] error object if request failed
1023
+ #
1024
+ # @return [Google::Apis::GamesV1::Quest]
1025
+ #
1026
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1027
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1028
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1029
+ def accept_quest(quest_id, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1030
+ command = make_simple_command(:post, 'quests/{questId}/accept', options)
1031
+ command.response_representation = Google::Apis::GamesV1::Quest::Representation
1032
+ command.response_class = Google::Apis::GamesV1::Quest
1033
+ command.params['questId'] = quest_id unless quest_id.nil?
1034
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1035
+ command.query['language'] = language unless language.nil?
1036
+ command.query['fields'] = fields unless fields.nil?
1037
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1038
+ command.query['userIp'] = user_ip unless user_ip.nil?
1039
+ execute_or_queue_command(command, &block)
1040
+ end
1041
+
1042
+ # Get a list of quests for your application and the currently authenticated
1043
+ # player.
1044
+ # @param [String] player_id
1045
+ # A player ID. A value of me may be used in place of the authenticated player's
1046
+ # ID.
1047
+ # @param [String] consistency_token
1048
+ # The last-seen mutation timestamp.
1049
+ # @param [String] language
1050
+ # The preferred language to use for strings returned by this method.
1051
+ # @param [Fixnum] max_results
1052
+ # The maximum number of quest resources to return in the response, used for
1053
+ # paging. For any response, the actual number of quest resources returned may be
1054
+ # less than the specified maxResults. Acceptable values are 1 to 50, inclusive. (
1055
+ # Default: 50).
1056
+ # @param [String] page_token
1057
+ # The token returned by the previous request.
1058
+ # @param [String] fields
1059
+ # Selector specifying which fields to include in a partial response.
1060
+ # @param [String] quota_user
1061
+ # Available to use for quota purposes for server-side applications. Can be any
1062
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1063
+ # Overrides userIp if both are provided.
1064
+ # @param [String] user_ip
1065
+ # IP address of the site where the request originates. Use this if you want to
1066
+ # enforce per-user limits.
1067
+ # @param [Google::Apis::RequestOptions] options
1068
+ # Request-specific options
1069
+ #
1070
+ # @yield [result, err] Result & error if block supplied
1071
+ # @yieldparam result [Google::Apis::GamesV1::ListQuestResponse] parsed result object
1072
+ # @yieldparam err [StandardError] error object if request failed
1073
+ #
1074
+ # @return [Google::Apis::GamesV1::ListQuestResponse]
1075
+ #
1076
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1077
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1078
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1079
+ def list_quests(player_id, consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1080
+ command = make_simple_command(:get, 'players/{playerId}/quests', options)
1081
+ command.response_representation = Google::Apis::GamesV1::ListQuestResponse::Representation
1082
+ command.response_class = Google::Apis::GamesV1::ListQuestResponse
1083
+ command.params['playerId'] = player_id unless player_id.nil?
1084
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1085
+ command.query['language'] = language unless language.nil?
1086
+ command.query['maxResults'] = max_results unless max_results.nil?
1087
+ command.query['pageToken'] = page_token unless page_token.nil?
1088
+ command.query['fields'] = fields unless fields.nil?
1089
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1090
+ command.query['userIp'] = user_ip unless user_ip.nil?
1091
+ execute_or_queue_command(command, &block)
1092
+ end
1093
+
1094
+ # Checks whether the games client is out of date.
1095
+ # @param [String] client_revision
1096
+ # The revision of the client SDK used by your application. Format:
1097
+ # [PLATFORM_TYPE]:[VERSION_NUMBER]. Possible values of PLATFORM_TYPE are:
1098
+ #
1099
+ # - "ANDROID" - Client is running the Android SDK.
1100
+ # - "IOS" - Client is running the iOS SDK.
1101
+ # - "WEB_APP" - Client is running as a Web App.
1102
+ # @param [String] consistency_token
1103
+ # The last-seen mutation timestamp.
1104
+ # @param [String] fields
1105
+ # Selector specifying which fields to include in a partial response.
1106
+ # @param [String] quota_user
1107
+ # Available to use for quota purposes for server-side applications. Can be any
1108
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1109
+ # Overrides userIp if both are provided.
1110
+ # @param [String] user_ip
1111
+ # IP address of the site where the request originates. Use this if you want to
1112
+ # enforce per-user limits.
1113
+ # @param [Google::Apis::RequestOptions] options
1114
+ # Request-specific options
1115
+ #
1116
+ # @yield [result, err] Result & error if block supplied
1117
+ # @yieldparam result [Google::Apis::GamesV1::CheckRevisionResponse] parsed result object
1118
+ # @yieldparam err [StandardError] error object if request failed
1119
+ #
1120
+ # @return [Google::Apis::GamesV1::CheckRevisionResponse]
1121
+ #
1122
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1123
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1124
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1125
+ def check_revision(client_revision, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1126
+ command = make_simple_command(:get, 'revisions/check', options)
1127
+ command.response_representation = Google::Apis::GamesV1::CheckRevisionResponse::Representation
1128
+ command.response_class = Google::Apis::GamesV1::CheckRevisionResponse
1129
+ command.query['clientRevision'] = client_revision unless client_revision.nil?
1130
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1131
+ command.query['fields'] = fields unless fields.nil?
1132
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1133
+ command.query['userIp'] = user_ip unless user_ip.nil?
1134
+ execute_or_queue_command(command, &block)
1135
+ end
1136
+
1137
+ # Create a room. For internal use by the Games SDK only. Calling this method
1138
+ # directly is unsupported.
1139
+ # @param [Google::Apis::GamesV1::CreateRoomRequest] create_room_request_object
1140
+ # @param [String] consistency_token
1141
+ # The last-seen mutation timestamp.
1142
+ # @param [String] language
1143
+ # The preferred language to use for strings returned by this method.
1144
+ # @param [String] fields
1145
+ # Selector specifying which fields to include in a partial response.
1146
+ # @param [String] quota_user
1147
+ # Available to use for quota purposes for server-side applications. Can be any
1148
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1149
+ # Overrides userIp if both are provided.
1150
+ # @param [String] user_ip
1151
+ # IP address of the site where the request originates. Use this if you want to
1152
+ # enforce per-user limits.
1153
+ # @param [Google::Apis::RequestOptions] options
1154
+ # Request-specific options
1155
+ #
1156
+ # @yield [result, err] Result & error if block supplied
1157
+ # @yieldparam result [Google::Apis::GamesV1::Room] parsed result object
1158
+ # @yieldparam err [StandardError] error object if request failed
1159
+ #
1160
+ # @return [Google::Apis::GamesV1::Room]
1161
+ #
1162
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1163
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1164
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1165
+ def create_room(create_room_request_object = nil, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1166
+ command = make_simple_command(:post, 'rooms/create', options)
1167
+ command.request_representation = Google::Apis::GamesV1::CreateRoomRequest::Representation
1168
+ command.request_object = create_room_request_object
1169
+ command.response_representation = Google::Apis::GamesV1::Room::Representation
1170
+ command.response_class = Google::Apis::GamesV1::Room
1171
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1172
+ command.query['language'] = language unless language.nil?
1173
+ command.query['fields'] = fields unless fields.nil?
1174
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1175
+ command.query['userIp'] = user_ip unless user_ip.nil?
1176
+ execute_or_queue_command(command, &block)
1177
+ end
1178
+
1179
+ # Decline an invitation to join a room. For internal use by the Games SDK only.
1180
+ # Calling this method directly is unsupported.
1181
+ # @param [String] room_id
1182
+ # The ID of the room.
1183
+ # @param [String] consistency_token
1184
+ # The last-seen mutation timestamp.
1185
+ # @param [String] language
1186
+ # The preferred language to use for strings returned by this method.
1187
+ # @param [String] fields
1188
+ # Selector specifying which fields to include in a partial response.
1189
+ # @param [String] quota_user
1190
+ # Available to use for quota purposes for server-side applications. Can be any
1191
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1192
+ # Overrides userIp if both are provided.
1193
+ # @param [String] user_ip
1194
+ # IP address of the site where the request originates. Use this if you want to
1195
+ # enforce per-user limits.
1196
+ # @param [Google::Apis::RequestOptions] options
1197
+ # Request-specific options
1198
+ #
1199
+ # @yield [result, err] Result & error if block supplied
1200
+ # @yieldparam result [Google::Apis::GamesV1::Room] parsed result object
1201
+ # @yieldparam err [StandardError] error object if request failed
1202
+ #
1203
+ # @return [Google::Apis::GamesV1::Room]
1204
+ #
1205
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1206
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1207
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1208
+ def decline_room(room_id, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1209
+ command = make_simple_command(:post, 'rooms/{roomId}/decline', options)
1210
+ command.response_representation = Google::Apis::GamesV1::Room::Representation
1211
+ command.response_class = Google::Apis::GamesV1::Room
1212
+ command.params['roomId'] = room_id unless room_id.nil?
1213
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1214
+ command.query['language'] = language unless language.nil?
1215
+ command.query['fields'] = fields unless fields.nil?
1216
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1217
+ command.query['userIp'] = user_ip unless user_ip.nil?
1218
+ execute_or_queue_command(command, &block)
1219
+ end
1220
+
1221
+ # Dismiss an invitation to join a room. For internal use by the Games SDK only.
1222
+ # Calling this method directly is unsupported.
1223
+ # @param [String] room_id
1224
+ # The ID of the room.
1225
+ # @param [String] consistency_token
1226
+ # The last-seen mutation timestamp.
1227
+ # @param [String] fields
1228
+ # Selector specifying which fields to include in a partial response.
1229
+ # @param [String] quota_user
1230
+ # Available to use for quota purposes for server-side applications. Can be any
1231
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1232
+ # Overrides userIp if both are provided.
1233
+ # @param [String] user_ip
1234
+ # IP address of the site where the request originates. Use this if you want to
1235
+ # enforce per-user limits.
1236
+ # @param [Google::Apis::RequestOptions] options
1237
+ # Request-specific options
1238
+ #
1239
+ # @yield [result, err] Result & error if block supplied
1240
+ # @yieldparam result [NilClass] No result returned for this method
1241
+ # @yieldparam err [StandardError] error object if request failed
1242
+ #
1243
+ # @return [void]
1244
+ #
1245
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1246
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1247
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1248
+ def dismiss_room(room_id, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1249
+ command = make_simple_command(:post, 'rooms/{roomId}/dismiss', options)
1250
+ command.params['roomId'] = room_id unless room_id.nil?
1251
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1252
+ command.query['fields'] = fields unless fields.nil?
1253
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1254
+ command.query['userIp'] = user_ip unless user_ip.nil?
1255
+ execute_or_queue_command(command, &block)
1256
+ end
1257
+
1258
+ # Get the data for a room.
1259
+ # @param [String] room_id
1260
+ # The ID of the room.
1261
+ # @param [String] consistency_token
1262
+ # The last-seen mutation timestamp.
1263
+ # @param [String] language
1264
+ # The preferred language to use for strings returned by this method.
1265
+ # @param [String] fields
1266
+ # Selector specifying which fields to include in a partial response.
1267
+ # @param [String] quota_user
1268
+ # Available to use for quota purposes for server-side applications. Can be any
1269
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1270
+ # Overrides userIp if both are provided.
1271
+ # @param [String] user_ip
1272
+ # IP address of the site where the request originates. Use this if you want to
1273
+ # enforce per-user limits.
1274
+ # @param [Google::Apis::RequestOptions] options
1275
+ # Request-specific options
1276
+ #
1277
+ # @yield [result, err] Result & error if block supplied
1278
+ # @yieldparam result [Google::Apis::GamesV1::Room] parsed result object
1279
+ # @yieldparam err [StandardError] error object if request failed
1280
+ #
1281
+ # @return [Google::Apis::GamesV1::Room]
1282
+ #
1283
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1284
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1285
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1286
+ def get_room(room_id, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1287
+ command = make_simple_command(:get, 'rooms/{roomId}', options)
1288
+ command.response_representation = Google::Apis::GamesV1::Room::Representation
1289
+ command.response_class = Google::Apis::GamesV1::Room
1290
+ command.params['roomId'] = room_id unless room_id.nil?
1291
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1292
+ command.query['language'] = language unless language.nil?
1293
+ command.query['fields'] = fields unless fields.nil?
1294
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1295
+ command.query['userIp'] = user_ip unless user_ip.nil?
1296
+ execute_or_queue_command(command, &block)
1297
+ end
1298
+
1299
+ # Join a room. For internal use by the Games SDK only. Calling this method
1300
+ # directly is unsupported.
1301
+ # @param [String] room_id
1302
+ # The ID of the room.
1303
+ # @param [Google::Apis::GamesV1::JoinRoomRequest] join_room_request_object
1304
+ # @param [String] consistency_token
1305
+ # The last-seen mutation timestamp.
1306
+ # @param [String] language
1307
+ # The preferred language to use for strings returned by this method.
1308
+ # @param [String] fields
1309
+ # Selector specifying which fields to include in a partial response.
1310
+ # @param [String] quota_user
1311
+ # Available to use for quota purposes for server-side applications. Can be any
1312
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1313
+ # Overrides userIp if both are provided.
1314
+ # @param [String] user_ip
1315
+ # IP address of the site where the request originates. Use this if you want to
1316
+ # enforce per-user limits.
1317
+ # @param [Google::Apis::RequestOptions] options
1318
+ # Request-specific options
1319
+ #
1320
+ # @yield [result, err] Result & error if block supplied
1321
+ # @yieldparam result [Google::Apis::GamesV1::Room] parsed result object
1322
+ # @yieldparam err [StandardError] error object if request failed
1323
+ #
1324
+ # @return [Google::Apis::GamesV1::Room]
1325
+ #
1326
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1327
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1328
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1329
+ def join_room(room_id, join_room_request_object = nil, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1330
+ command = make_simple_command(:post, 'rooms/{roomId}/join', options)
1331
+ command.request_representation = Google::Apis::GamesV1::JoinRoomRequest::Representation
1332
+ command.request_object = join_room_request_object
1333
+ command.response_representation = Google::Apis::GamesV1::Room::Representation
1334
+ command.response_class = Google::Apis::GamesV1::Room
1335
+ command.params['roomId'] = room_id unless room_id.nil?
1336
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1337
+ command.query['language'] = language unless language.nil?
1338
+ command.query['fields'] = fields unless fields.nil?
1339
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1340
+ command.query['userIp'] = user_ip unless user_ip.nil?
1341
+ execute_or_queue_command(command, &block)
1342
+ end
1343
+
1344
+ # Leave a room. For internal use by the Games SDK only. Calling this method
1345
+ # directly is unsupported.
1346
+ # @param [String] room_id
1347
+ # The ID of the room.
1348
+ # @param [Google::Apis::GamesV1::LeaveRoomRequest] leave_room_request_object
1349
+ # @param [String] consistency_token
1350
+ # The last-seen mutation timestamp.
1351
+ # @param [String] language
1352
+ # The preferred language to use for strings returned by this method.
1353
+ # @param [String] fields
1354
+ # Selector specifying which fields to include in a partial response.
1355
+ # @param [String] quota_user
1356
+ # Available to use for quota purposes for server-side applications. Can be any
1357
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1358
+ # Overrides userIp if both are provided.
1359
+ # @param [String] user_ip
1360
+ # IP address of the site where the request originates. Use this if you want to
1361
+ # enforce per-user limits.
1362
+ # @param [Google::Apis::RequestOptions] options
1363
+ # Request-specific options
1364
+ #
1365
+ # @yield [result, err] Result & error if block supplied
1366
+ # @yieldparam result [Google::Apis::GamesV1::Room] parsed result object
1367
+ # @yieldparam err [StandardError] error object if request failed
1368
+ #
1369
+ # @return [Google::Apis::GamesV1::Room]
1370
+ #
1371
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1372
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1373
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1374
+ def leave_room(room_id, leave_room_request_object = nil, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1375
+ command = make_simple_command(:post, 'rooms/{roomId}/leave', options)
1376
+ command.request_representation = Google::Apis::GamesV1::LeaveRoomRequest::Representation
1377
+ command.request_object = leave_room_request_object
1378
+ command.response_representation = Google::Apis::GamesV1::Room::Representation
1379
+ command.response_class = Google::Apis::GamesV1::Room
1380
+ command.params['roomId'] = room_id unless room_id.nil?
1381
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1382
+ command.query['language'] = language unless language.nil?
1383
+ command.query['fields'] = fields unless fields.nil?
1384
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1385
+ command.query['userIp'] = user_ip unless user_ip.nil?
1386
+ execute_or_queue_command(command, &block)
1387
+ end
1388
+
1389
+ # Returns invitations to join rooms.
1390
+ # @param [String] consistency_token
1391
+ # The last-seen mutation timestamp.
1392
+ # @param [String] language
1393
+ # The preferred language to use for strings returned by this method.
1394
+ # @param [Fixnum] max_results
1395
+ # The maximum number of rooms to return in the response, used for paging. For
1396
+ # any response, the actual number of rooms to return may be less than the
1397
+ # specified maxResults.
1398
+ # @param [String] page_token
1399
+ # The token returned by the previous request.
1400
+ # @param [String] fields
1401
+ # Selector specifying which fields to include in a partial response.
1402
+ # @param [String] quota_user
1403
+ # Available to use for quota purposes for server-side applications. Can be any
1404
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1405
+ # Overrides userIp if both are provided.
1406
+ # @param [String] user_ip
1407
+ # IP address of the site where the request originates. Use this if you want to
1408
+ # enforce per-user limits.
1409
+ # @param [Google::Apis::RequestOptions] options
1410
+ # Request-specific options
1411
+ #
1412
+ # @yield [result, err] Result & error if block supplied
1413
+ # @yieldparam result [Google::Apis::GamesV1::RoomList] parsed result object
1414
+ # @yieldparam err [StandardError] error object if request failed
1415
+ #
1416
+ # @return [Google::Apis::GamesV1::RoomList]
1417
+ #
1418
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1419
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1420
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1421
+ def list_rooms(consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1422
+ command = make_simple_command(:get, 'rooms', options)
1423
+ command.response_representation = Google::Apis::GamesV1::RoomList::Representation
1424
+ command.response_class = Google::Apis::GamesV1::RoomList
1425
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1426
+ command.query['language'] = language unless language.nil?
1427
+ command.query['maxResults'] = max_results unless max_results.nil?
1428
+ command.query['pageToken'] = page_token unless page_token.nil?
1429
+ command.query['fields'] = fields unless fields.nil?
1430
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1431
+ command.query['userIp'] = user_ip unless user_ip.nil?
1432
+ execute_or_queue_command(command, &block)
1433
+ end
1434
+
1435
+ # Updates sent by a client reporting the status of peers in a room. For internal
1436
+ # use by the Games SDK only. Calling this method directly is unsupported.
1437
+ # @param [String] room_id
1438
+ # The ID of the room.
1439
+ # @param [Google::Apis::GamesV1::RoomP2PStatuses] room_p2_p_statuses_object
1440
+ # @param [String] consistency_token
1441
+ # The last-seen mutation timestamp.
1442
+ # @param [String] language
1443
+ # The preferred language to use for strings returned by this method.
1444
+ # @param [String] fields
1445
+ # Selector specifying which fields to include in a partial response.
1446
+ # @param [String] quota_user
1447
+ # Available to use for quota purposes for server-side applications. Can be any
1448
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1449
+ # Overrides userIp if both are provided.
1450
+ # @param [String] user_ip
1451
+ # IP address of the site where the request originates. Use this if you want to
1452
+ # enforce per-user limits.
1453
+ # @param [Google::Apis::RequestOptions] options
1454
+ # Request-specific options
1455
+ #
1456
+ # @yield [result, err] Result & error if block supplied
1457
+ # @yieldparam result [Google::Apis::GamesV1::RoomStatus] parsed result object
1458
+ # @yieldparam err [StandardError] error object if request failed
1459
+ #
1460
+ # @return [Google::Apis::GamesV1::RoomStatus]
1461
+ #
1462
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1463
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1464
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1465
+ def report_room_status(room_id, room_p2_p_statuses_object = nil, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1466
+ command = make_simple_command(:post, 'rooms/{roomId}/reportstatus', options)
1467
+ command.request_representation = Google::Apis::GamesV1::RoomP2PStatuses::Representation
1468
+ command.request_object = room_p2_p_statuses_object
1469
+ command.response_representation = Google::Apis::GamesV1::RoomStatus::Representation
1470
+ command.response_class = Google::Apis::GamesV1::RoomStatus
1471
+ command.params['roomId'] = room_id unless room_id.nil?
1472
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1473
+ command.query['language'] = language unless language.nil?
1474
+ command.query['fields'] = fields unless fields.nil?
1475
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1476
+ command.query['userIp'] = user_ip unless user_ip.nil?
1477
+ execute_or_queue_command(command, &block)
1478
+ end
1479
+
1480
+ # Get high scores, and optionally ranks, in leaderboards for the currently
1481
+ # authenticated player. For a specific time span, leaderboardId can be set to
1482
+ # ALL to retrieve data for all leaderboards in a given time span.
1483
+ # NOTE: You cannot ask for 'ALL' leaderboards and 'ALL' timeSpans in the same
1484
+ # request; only one parameter may be set to 'ALL'.
1485
+ # @param [String] player_id
1486
+ # A player ID. A value of me may be used in place of the authenticated player's
1487
+ # ID.
1488
+ # @param [String] leaderboard_id
1489
+ # The ID of the leaderboard. Can be set to 'ALL' to retrieve data for all
1490
+ # leaderboards for this application.
1491
+ # @param [String] time_span
1492
+ # The time span for the scores and ranks you're requesting.
1493
+ # @param [String] consistency_token
1494
+ # The last-seen mutation timestamp.
1495
+ # @param [String] include_rank_type
1496
+ # The types of ranks to return. If the parameter is omitted, no ranks will be
1497
+ # returned.
1498
+ # @param [String] language
1499
+ # The preferred language to use for strings returned by this method.
1500
+ # @param [Fixnum] max_results
1501
+ # The maximum number of leaderboard scores to return in the response. For any
1502
+ # response, the actual number of leaderboard scores returned may be less than
1503
+ # the specified maxResults.
1504
+ # @param [String] page_token
1505
+ # The token returned by the previous request.
1506
+ # @param [String] fields
1507
+ # Selector specifying which fields to include in a partial response.
1508
+ # @param [String] quota_user
1509
+ # Available to use for quota purposes for server-side applications. Can be any
1510
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1511
+ # Overrides userIp if both are provided.
1512
+ # @param [String] user_ip
1513
+ # IP address of the site where the request originates. Use this if you want to
1514
+ # enforce per-user limits.
1515
+ # @param [Google::Apis::RequestOptions] options
1516
+ # Request-specific options
1517
+ #
1518
+ # @yield [result, err] Result & error if block supplied
1519
+ # @yieldparam result [Google::Apis::GamesV1::ListPlayerLeaderboardScoreResponse] parsed result object
1520
+ # @yieldparam err [StandardError] error object if request failed
1521
+ #
1522
+ # @return [Google::Apis::GamesV1::ListPlayerLeaderboardScoreResponse]
1523
+ #
1524
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1525
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1526
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1527
+ def get_score(player_id, leaderboard_id, time_span, consistency_token: nil, include_rank_type: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1528
+ command = make_simple_command(:get, 'players/{playerId}/leaderboards/{leaderboardId}/scores/{timeSpan}', options)
1529
+ command.response_representation = Google::Apis::GamesV1::ListPlayerLeaderboardScoreResponse::Representation
1530
+ command.response_class = Google::Apis::GamesV1::ListPlayerLeaderboardScoreResponse
1531
+ command.params['playerId'] = player_id unless player_id.nil?
1532
+ command.params['leaderboardId'] = leaderboard_id unless leaderboard_id.nil?
1533
+ command.params['timeSpan'] = time_span unless time_span.nil?
1534
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1535
+ command.query['includeRankType'] = include_rank_type unless include_rank_type.nil?
1536
+ command.query['language'] = language unless language.nil?
1537
+ command.query['maxResults'] = max_results unless max_results.nil?
1538
+ command.query['pageToken'] = page_token unless page_token.nil?
1539
+ command.query['fields'] = fields unless fields.nil?
1540
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1541
+ command.query['userIp'] = user_ip unless user_ip.nil?
1542
+ execute_or_queue_command(command, &block)
1543
+ end
1544
+
1545
+ # Lists the scores in a leaderboard, starting from the top.
1546
+ # @param [String] leaderboard_id
1547
+ # The ID of the leaderboard.
1548
+ # @param [String] collection
1549
+ # The collection of scores you're requesting.
1550
+ # @param [String] time_span
1551
+ # The time span for the scores and ranks you're requesting.
1552
+ # @param [String] consistency_token
1553
+ # The last-seen mutation timestamp.
1554
+ # @param [String] language
1555
+ # The preferred language to use for strings returned by this method.
1556
+ # @param [Fixnum] max_results
1557
+ # The maximum number of leaderboard scores to return in the response. For any
1558
+ # response, the actual number of leaderboard scores returned may be less than
1559
+ # the specified maxResults.
1560
+ # @param [String] page_token
1561
+ # The token returned by the previous request.
1562
+ # @param [String] fields
1563
+ # Selector specifying which fields to include in a partial response.
1564
+ # @param [String] quota_user
1565
+ # Available to use for quota purposes for server-side applications. Can be any
1566
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1567
+ # Overrides userIp if both are provided.
1568
+ # @param [String] user_ip
1569
+ # IP address of the site where the request originates. Use this if you want to
1570
+ # enforce per-user limits.
1571
+ # @param [Google::Apis::RequestOptions] options
1572
+ # Request-specific options
1573
+ #
1574
+ # @yield [result, err] Result & error if block supplied
1575
+ # @yieldparam result [Google::Apis::GamesV1::LeaderboardScores] parsed result object
1576
+ # @yieldparam err [StandardError] error object if request failed
1577
+ #
1578
+ # @return [Google::Apis::GamesV1::LeaderboardScores]
1579
+ #
1580
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1581
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1582
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1583
+ def list_scores(leaderboard_id, collection, time_span, consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1584
+ command = make_simple_command(:get, 'leaderboards/{leaderboardId}/scores/{collection}', options)
1585
+ command.response_representation = Google::Apis::GamesV1::LeaderboardScores::Representation
1586
+ command.response_class = Google::Apis::GamesV1::LeaderboardScores
1587
+ command.params['leaderboardId'] = leaderboard_id unless leaderboard_id.nil?
1588
+ command.params['collection'] = collection unless collection.nil?
1589
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1590
+ command.query['language'] = language unless language.nil?
1591
+ command.query['maxResults'] = max_results unless max_results.nil?
1592
+ command.query['pageToken'] = page_token unless page_token.nil?
1593
+ command.query['timeSpan'] = time_span unless time_span.nil?
1594
+ command.query['fields'] = fields unless fields.nil?
1595
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1596
+ command.query['userIp'] = user_ip unless user_ip.nil?
1597
+ execute_or_queue_command(command, &block)
1598
+ end
1599
+
1600
+ # Lists the scores in a leaderboard around (and including) a player's score.
1601
+ # @param [String] leaderboard_id
1602
+ # The ID of the leaderboard.
1603
+ # @param [String] collection
1604
+ # The collection of scores you're requesting.
1605
+ # @param [String] time_span
1606
+ # The time span for the scores and ranks you're requesting.
1607
+ # @param [String] consistency_token
1608
+ # The last-seen mutation timestamp.
1609
+ # @param [String] language
1610
+ # The preferred language to use for strings returned by this method.
1611
+ # @param [Fixnum] max_results
1612
+ # The maximum number of leaderboard scores to return in the response. For any
1613
+ # response, the actual number of leaderboard scores returned may be less than
1614
+ # the specified maxResults.
1615
+ # @param [String] page_token
1616
+ # The token returned by the previous request.
1617
+ # @param [Fixnum] results_above
1618
+ # The preferred number of scores to return above the player's score. More scores
1619
+ # may be returned if the player is at the bottom of the leaderboard; fewer may
1620
+ # be returned if the player is at the top. Must be less than or equal to
1621
+ # maxResults.
1622
+ # @param [Boolean] return_top_if_absent
1623
+ # True if the top scores should be returned when the player is not in the
1624
+ # leaderboard. Defaults to true.
1625
+ # @param [String] fields
1626
+ # Selector specifying which fields to include in a partial response.
1627
+ # @param [String] quota_user
1628
+ # Available to use for quota purposes for server-side applications. Can be any
1629
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1630
+ # Overrides userIp if both are provided.
1631
+ # @param [String] user_ip
1632
+ # IP address of the site where the request originates. Use this if you want to
1633
+ # enforce per-user limits.
1634
+ # @param [Google::Apis::RequestOptions] options
1635
+ # Request-specific options
1636
+ #
1637
+ # @yield [result, err] Result & error if block supplied
1638
+ # @yieldparam result [Google::Apis::GamesV1::LeaderboardScores] parsed result object
1639
+ # @yieldparam err [StandardError] error object if request failed
1640
+ #
1641
+ # @return [Google::Apis::GamesV1::LeaderboardScores]
1642
+ #
1643
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1644
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1645
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1646
+ def list_score_window(leaderboard_id, collection, time_span, consistency_token: nil, language: nil, max_results: nil, page_token: nil, results_above: nil, return_top_if_absent: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1647
+ command = make_simple_command(:get, 'leaderboards/{leaderboardId}/window/{collection}', options)
1648
+ command.response_representation = Google::Apis::GamesV1::LeaderboardScores::Representation
1649
+ command.response_class = Google::Apis::GamesV1::LeaderboardScores
1650
+ command.params['leaderboardId'] = leaderboard_id unless leaderboard_id.nil?
1651
+ command.params['collection'] = collection unless collection.nil?
1652
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1653
+ command.query['language'] = language unless language.nil?
1654
+ command.query['maxResults'] = max_results unless max_results.nil?
1655
+ command.query['pageToken'] = page_token unless page_token.nil?
1656
+ command.query['resultsAbove'] = results_above unless results_above.nil?
1657
+ command.query['returnTopIfAbsent'] = return_top_if_absent unless return_top_if_absent.nil?
1658
+ command.query['timeSpan'] = time_span unless time_span.nil?
1659
+ command.query['fields'] = fields unless fields.nil?
1660
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1661
+ command.query['userIp'] = user_ip unless user_ip.nil?
1662
+ execute_or_queue_command(command, &block)
1663
+ end
1664
+
1665
+ # Submits a score to the specified leaderboard.
1666
+ # @param [String] leaderboard_id
1667
+ # The ID of the leaderboard.
1668
+ # @param [String] score
1669
+ # The score you're submitting. The submitted score is ignored if it is worse
1670
+ # than a previously submitted score, where worse depends on the leaderboard sort
1671
+ # order. The meaning of the score value depends on the leaderboard format type.
1672
+ # For fixed-point, the score represents the raw value. For time, the score
1673
+ # represents elapsed time in milliseconds. For currency, the score represents a
1674
+ # value in micro units.
1675
+ # @param [String] consistency_token
1676
+ # The last-seen mutation timestamp.
1677
+ # @param [String] language
1678
+ # The preferred language to use for strings returned by this method.
1679
+ # @param [String] score_tag
1680
+ # Additional information about the score you're submitting. Values must contain
1681
+ # no more than 64 URI-safe characters as defined by section 2.3 of RFC 3986.
1682
+ # @param [String] fields
1683
+ # Selector specifying which fields to include in a partial response.
1684
+ # @param [String] quota_user
1685
+ # Available to use for quota purposes for server-side applications. Can be any
1686
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1687
+ # Overrides userIp if both are provided.
1688
+ # @param [String] user_ip
1689
+ # IP address of the site where the request originates. Use this if you want to
1690
+ # enforce per-user limits.
1691
+ # @param [Google::Apis::RequestOptions] options
1692
+ # Request-specific options
1693
+ #
1694
+ # @yield [result, err] Result & error if block supplied
1695
+ # @yieldparam result [Google::Apis::GamesV1::PlayerScoreResponse] parsed result object
1696
+ # @yieldparam err [StandardError] error object if request failed
1697
+ #
1698
+ # @return [Google::Apis::GamesV1::PlayerScoreResponse]
1699
+ #
1700
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1701
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1702
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1703
+ def submit_score(leaderboard_id, score, consistency_token: nil, language: nil, score_tag: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1704
+ command = make_simple_command(:post, 'leaderboards/{leaderboardId}/scores', options)
1705
+ command.response_representation = Google::Apis::GamesV1::PlayerScoreResponse::Representation
1706
+ command.response_class = Google::Apis::GamesV1::PlayerScoreResponse
1707
+ command.params['leaderboardId'] = leaderboard_id unless leaderboard_id.nil?
1708
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1709
+ command.query['language'] = language unless language.nil?
1710
+ command.query['score'] = score unless score.nil?
1711
+ command.query['scoreTag'] = score_tag unless score_tag.nil?
1712
+ command.query['fields'] = fields unless fields.nil?
1713
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1714
+ command.query['userIp'] = user_ip unless user_ip.nil?
1715
+ execute_or_queue_command(command, &block)
1716
+ end
1717
+
1718
+ # Submits multiple scores to leaderboards.
1719
+ # @param [Google::Apis::GamesV1::PlayerScoreSubmissionList] player_score_submission_list_object
1720
+ # @param [String] consistency_token
1721
+ # The last-seen mutation timestamp.
1722
+ # @param [String] language
1723
+ # The preferred language to use for strings returned by this method.
1724
+ # @param [String] fields
1725
+ # Selector specifying which fields to include in a partial response.
1726
+ # @param [String] quota_user
1727
+ # Available to use for quota purposes for server-side applications. Can be any
1728
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1729
+ # Overrides userIp if both are provided.
1730
+ # @param [String] user_ip
1731
+ # IP address of the site where the request originates. Use this if you want to
1732
+ # enforce per-user limits.
1733
+ # @param [Google::Apis::RequestOptions] options
1734
+ # Request-specific options
1735
+ #
1736
+ # @yield [result, err] Result & error if block supplied
1737
+ # @yieldparam result [Google::Apis::GamesV1::ListPlayerScoreResponse] parsed result object
1738
+ # @yieldparam err [StandardError] error object if request failed
1739
+ #
1740
+ # @return [Google::Apis::GamesV1::ListPlayerScoreResponse]
1741
+ #
1742
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1743
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1744
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1745
+ def submit_score_multiple(player_score_submission_list_object = nil, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1746
+ command = make_simple_command(:post, 'leaderboards/scores', options)
1747
+ command.request_representation = Google::Apis::GamesV1::PlayerScoreSubmissionList::Representation
1748
+ command.request_object = player_score_submission_list_object
1749
+ command.response_representation = Google::Apis::GamesV1::ListPlayerScoreResponse::Representation
1750
+ command.response_class = Google::Apis::GamesV1::ListPlayerScoreResponse
1751
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1752
+ command.query['language'] = language unless language.nil?
1753
+ command.query['fields'] = fields unless fields.nil?
1754
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1755
+ command.query['userIp'] = user_ip unless user_ip.nil?
1756
+ execute_or_queue_command(command, &block)
1757
+ end
1758
+
1759
+ # Retrieves the metadata for a given snapshot ID.
1760
+ # @param [String] snapshot_id
1761
+ # The ID of the snapshot.
1762
+ # @param [String] consistency_token
1763
+ # The last-seen mutation timestamp.
1764
+ # @param [String] language
1765
+ # The preferred language to use for strings returned by this method.
1766
+ # @param [String] fields
1767
+ # Selector specifying which fields to include in a partial response.
1768
+ # @param [String] quota_user
1769
+ # Available to use for quota purposes for server-side applications. Can be any
1770
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1771
+ # Overrides userIp if both are provided.
1772
+ # @param [String] user_ip
1773
+ # IP address of the site where the request originates. Use this if you want to
1774
+ # enforce per-user limits.
1775
+ # @param [Google::Apis::RequestOptions] options
1776
+ # Request-specific options
1777
+ #
1778
+ # @yield [result, err] Result & error if block supplied
1779
+ # @yieldparam result [Google::Apis::GamesV1::Snapshot] parsed result object
1780
+ # @yieldparam err [StandardError] error object if request failed
1781
+ #
1782
+ # @return [Google::Apis::GamesV1::Snapshot]
1783
+ #
1784
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1785
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1786
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1787
+ def get_snapshot(snapshot_id, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1788
+ command = make_simple_command(:get, 'snapshots/{snapshotId}', options)
1789
+ command.response_representation = Google::Apis::GamesV1::Snapshot::Representation
1790
+ command.response_class = Google::Apis::GamesV1::Snapshot
1791
+ command.params['snapshotId'] = snapshot_id unless snapshot_id.nil?
1792
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1793
+ command.query['language'] = language unless language.nil?
1794
+ command.query['fields'] = fields unless fields.nil?
1795
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1796
+ command.query['userIp'] = user_ip unless user_ip.nil?
1797
+ execute_or_queue_command(command, &block)
1798
+ end
1799
+
1800
+ # Retrieves a list of snapshots created by your application for the player
1801
+ # corresponding to the player ID.
1802
+ # @param [String] player_id
1803
+ # A player ID. A value of me may be used in place of the authenticated player's
1804
+ # ID.
1805
+ # @param [String] consistency_token
1806
+ # The last-seen mutation timestamp.
1807
+ # @param [String] language
1808
+ # The preferred language to use for strings returned by this method.
1809
+ # @param [Fixnum] max_results
1810
+ # The maximum number of snapshot resources to return in the response, used for
1811
+ # paging. For any response, the actual number of snapshot resources returned may
1812
+ # be less than the specified maxResults.
1813
+ # @param [String] page_token
1814
+ # The token returned by the previous request.
1815
+ # @param [String] fields
1816
+ # Selector specifying which fields to include in a partial response.
1817
+ # @param [String] quota_user
1818
+ # Available to use for quota purposes for server-side applications. Can be any
1819
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1820
+ # Overrides userIp if both are provided.
1821
+ # @param [String] user_ip
1822
+ # IP address of the site where the request originates. Use this if you want to
1823
+ # enforce per-user limits.
1824
+ # @param [Google::Apis::RequestOptions] options
1825
+ # Request-specific options
1826
+ #
1827
+ # @yield [result, err] Result & error if block supplied
1828
+ # @yieldparam result [Google::Apis::GamesV1::ListSnapshotResponse] parsed result object
1829
+ # @yieldparam err [StandardError] error object if request failed
1830
+ #
1831
+ # @return [Google::Apis::GamesV1::ListSnapshotResponse]
1832
+ #
1833
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1834
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1835
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1836
+ def list_snapshots(player_id, consistency_token: nil, language: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1837
+ command = make_simple_command(:get, 'players/{playerId}/snapshots', options)
1838
+ command.response_representation = Google::Apis::GamesV1::ListSnapshotResponse::Representation
1839
+ command.response_class = Google::Apis::GamesV1::ListSnapshotResponse
1840
+ command.params['playerId'] = player_id unless player_id.nil?
1841
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1842
+ command.query['language'] = language unless language.nil?
1843
+ command.query['maxResults'] = max_results unless max_results.nil?
1844
+ command.query['pageToken'] = page_token unless page_token.nil?
1845
+ command.query['fields'] = fields unless fields.nil?
1846
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1847
+ command.query['userIp'] = user_ip unless user_ip.nil?
1848
+ execute_or_queue_command(command, &block)
1849
+ end
1850
+
1851
+ # Cancel a turn-based match.
1852
+ # @param [String] match_id
1853
+ # The ID of the match.
1854
+ # @param [String] consistency_token
1855
+ # The last-seen mutation timestamp.
1856
+ # @param [String] fields
1857
+ # Selector specifying which fields to include in a partial response.
1858
+ # @param [String] quota_user
1859
+ # Available to use for quota purposes for server-side applications. Can be any
1860
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1861
+ # Overrides userIp if both are provided.
1862
+ # @param [String] user_ip
1863
+ # IP address of the site where the request originates. Use this if you want to
1864
+ # enforce per-user limits.
1865
+ # @param [Google::Apis::RequestOptions] options
1866
+ # Request-specific options
1867
+ #
1868
+ # @yield [result, err] Result & error if block supplied
1869
+ # @yieldparam result [NilClass] No result returned for this method
1870
+ # @yieldparam err [StandardError] error object if request failed
1871
+ #
1872
+ # @return [void]
1873
+ #
1874
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1875
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1876
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1877
+ def cancel_turn_based_match(match_id, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1878
+ command = make_simple_command(:put, 'turnbasedmatches/{matchId}/cancel', options)
1879
+ command.params['matchId'] = match_id unless match_id.nil?
1880
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1881
+ command.query['fields'] = fields unless fields.nil?
1882
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1883
+ command.query['userIp'] = user_ip unless user_ip.nil?
1884
+ execute_or_queue_command(command, &block)
1885
+ end
1886
+
1887
+ # Create a turn-based match.
1888
+ # @param [Google::Apis::GamesV1::CreateTurnBasedMatchRequest] create_turn_based_match_request_object
1889
+ # @param [String] consistency_token
1890
+ # The last-seen mutation timestamp.
1891
+ # @param [String] language
1892
+ # The preferred language to use for strings returned by this method.
1893
+ # @param [String] fields
1894
+ # Selector specifying which fields to include in a partial response.
1895
+ # @param [String] quota_user
1896
+ # Available to use for quota purposes for server-side applications. Can be any
1897
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1898
+ # Overrides userIp if both are provided.
1899
+ # @param [String] user_ip
1900
+ # IP address of the site where the request originates. Use this if you want to
1901
+ # enforce per-user limits.
1902
+ # @param [Google::Apis::RequestOptions] options
1903
+ # Request-specific options
1904
+ #
1905
+ # @yield [result, err] Result & error if block supplied
1906
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatch] parsed result object
1907
+ # @yieldparam err [StandardError] error object if request failed
1908
+ #
1909
+ # @return [Google::Apis::GamesV1::TurnBasedMatch]
1910
+ #
1911
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1912
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1913
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1914
+ def create_turn_based_match(create_turn_based_match_request_object = nil, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1915
+ command = make_simple_command(:post, 'turnbasedmatches/create', options)
1916
+ command.request_representation = Google::Apis::GamesV1::CreateTurnBasedMatchRequest::Representation
1917
+ command.request_object = create_turn_based_match_request_object
1918
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatch::Representation
1919
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatch
1920
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1921
+ command.query['language'] = language unless language.nil?
1922
+ command.query['fields'] = fields unless fields.nil?
1923
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1924
+ command.query['userIp'] = user_ip unless user_ip.nil?
1925
+ execute_or_queue_command(command, &block)
1926
+ end
1927
+
1928
+ # Decline an invitation to play a turn-based match.
1929
+ # @param [String] match_id
1930
+ # The ID of the match.
1931
+ # @param [String] consistency_token
1932
+ # The last-seen mutation timestamp.
1933
+ # @param [String] language
1934
+ # The preferred language to use for strings returned by this method.
1935
+ # @param [String] fields
1936
+ # Selector specifying which fields to include in a partial response.
1937
+ # @param [String] quota_user
1938
+ # Available to use for quota purposes for server-side applications. Can be any
1939
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1940
+ # Overrides userIp if both are provided.
1941
+ # @param [String] user_ip
1942
+ # IP address of the site where the request originates. Use this if you want to
1943
+ # enforce per-user limits.
1944
+ # @param [Google::Apis::RequestOptions] options
1945
+ # Request-specific options
1946
+ #
1947
+ # @yield [result, err] Result & error if block supplied
1948
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatch] parsed result object
1949
+ # @yieldparam err [StandardError] error object if request failed
1950
+ #
1951
+ # @return [Google::Apis::GamesV1::TurnBasedMatch]
1952
+ #
1953
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1954
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1955
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1956
+ def decline_turn_based_match(match_id, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1957
+ command = make_simple_command(:put, 'turnbasedmatches/{matchId}/decline', options)
1958
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatch::Representation
1959
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatch
1960
+ command.params['matchId'] = match_id unless match_id.nil?
1961
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
1962
+ command.query['language'] = language unless language.nil?
1963
+ command.query['fields'] = fields unless fields.nil?
1964
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1965
+ command.query['userIp'] = user_ip unless user_ip.nil?
1966
+ execute_or_queue_command(command, &block)
1967
+ end
1968
+
1969
+ # Dismiss a turn-based match from the match list. The match will no longer show
1970
+ # up in the list and will not generate notifications.
1971
+ # @param [String] match_id
1972
+ # The ID of the match.
1973
+ # @param [String] consistency_token
1974
+ # The last-seen mutation timestamp.
1975
+ # @param [String] fields
1976
+ # Selector specifying which fields to include in a partial response.
1977
+ # @param [String] quota_user
1978
+ # Available to use for quota purposes for server-side applications. Can be any
1979
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1980
+ # Overrides userIp if both are provided.
1981
+ # @param [String] user_ip
1982
+ # IP address of the site where the request originates. Use this if you want to
1983
+ # enforce per-user limits.
1984
+ # @param [Google::Apis::RequestOptions] options
1985
+ # Request-specific options
1986
+ #
1987
+ # @yield [result, err] Result & error if block supplied
1988
+ # @yieldparam result [NilClass] No result returned for this method
1989
+ # @yieldparam err [StandardError] error object if request failed
1990
+ #
1991
+ # @return [void]
1992
+ #
1993
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1994
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1995
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1996
+ def dismiss_turn_based_match(match_id, consistency_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1997
+ command = make_simple_command(:put, 'turnbasedmatches/{matchId}/dismiss', options)
1998
+ command.params['matchId'] = match_id unless match_id.nil?
1999
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2000
+ command.query['fields'] = fields unless fields.nil?
2001
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2002
+ command.query['userIp'] = user_ip unless user_ip.nil?
2003
+ execute_or_queue_command(command, &block)
2004
+ end
2005
+
2006
+ # Finish a turn-based match. Each player should make this call once, after all
2007
+ # results are in. Only the player whose turn it is may make the first call to
2008
+ # Finish, and can pass in the final match state.
2009
+ # @param [String] match_id
2010
+ # The ID of the match.
2011
+ # @param [Google::Apis::GamesV1::TurnBasedMatchResults] turn_based_match_results_object
2012
+ # @param [String] consistency_token
2013
+ # The last-seen mutation timestamp.
2014
+ # @param [String] language
2015
+ # The preferred language to use for strings returned by this method.
2016
+ # @param [String] fields
2017
+ # Selector specifying which fields to include in a partial response.
2018
+ # @param [String] quota_user
2019
+ # Available to use for quota purposes for server-side applications. Can be any
2020
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2021
+ # Overrides userIp if both are provided.
2022
+ # @param [String] user_ip
2023
+ # IP address of the site where the request originates. Use this if you want to
2024
+ # enforce per-user limits.
2025
+ # @param [Google::Apis::RequestOptions] options
2026
+ # Request-specific options
2027
+ #
2028
+ # @yield [result, err] Result & error if block supplied
2029
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatch] parsed result object
2030
+ # @yieldparam err [StandardError] error object if request failed
2031
+ #
2032
+ # @return [Google::Apis::GamesV1::TurnBasedMatch]
2033
+ #
2034
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2035
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2036
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2037
+ def finish_turn_based_match(match_id, turn_based_match_results_object = nil, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2038
+ command = make_simple_command(:put, 'turnbasedmatches/{matchId}/finish', options)
2039
+ command.request_representation = Google::Apis::GamesV1::TurnBasedMatchResults::Representation
2040
+ command.request_object = turn_based_match_results_object
2041
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatch::Representation
2042
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatch
2043
+ command.params['matchId'] = match_id unless match_id.nil?
2044
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2045
+ command.query['language'] = language unless language.nil?
2046
+ command.query['fields'] = fields unless fields.nil?
2047
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2048
+ command.query['userIp'] = user_ip unless user_ip.nil?
2049
+ execute_or_queue_command(command, &block)
2050
+ end
2051
+
2052
+ # Get the data for a turn-based match.
2053
+ # @param [String] match_id
2054
+ # The ID of the match.
2055
+ # @param [String] consistency_token
2056
+ # The last-seen mutation timestamp.
2057
+ # @param [Boolean] include_match_data
2058
+ # Get match data along with metadata.
2059
+ # @param [String] language
2060
+ # The preferred language to use for strings returned by this method.
2061
+ # @param [String] fields
2062
+ # Selector specifying which fields to include in a partial response.
2063
+ # @param [String] quota_user
2064
+ # Available to use for quota purposes for server-side applications. Can be any
2065
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2066
+ # Overrides userIp if both are provided.
2067
+ # @param [String] user_ip
2068
+ # IP address of the site where the request originates. Use this if you want to
2069
+ # enforce per-user limits.
2070
+ # @param [Google::Apis::RequestOptions] options
2071
+ # Request-specific options
2072
+ #
2073
+ # @yield [result, err] Result & error if block supplied
2074
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatch] parsed result object
2075
+ # @yieldparam err [StandardError] error object if request failed
2076
+ #
2077
+ # @return [Google::Apis::GamesV1::TurnBasedMatch]
2078
+ #
2079
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2080
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2081
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2082
+ def get_turn_based_match(match_id, consistency_token: nil, include_match_data: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2083
+ command = make_simple_command(:get, 'turnbasedmatches/{matchId}', options)
2084
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatch::Representation
2085
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatch
2086
+ command.params['matchId'] = match_id unless match_id.nil?
2087
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2088
+ command.query['includeMatchData'] = include_match_data unless include_match_data.nil?
2089
+ command.query['language'] = language unless language.nil?
2090
+ command.query['fields'] = fields unless fields.nil?
2091
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2092
+ command.query['userIp'] = user_ip unless user_ip.nil?
2093
+ execute_or_queue_command(command, &block)
2094
+ end
2095
+
2096
+ # Join a turn-based match.
2097
+ # @param [String] match_id
2098
+ # The ID of the match.
2099
+ # @param [String] consistency_token
2100
+ # The last-seen mutation timestamp.
2101
+ # @param [String] language
2102
+ # The preferred language to use for strings returned by this method.
2103
+ # @param [String] fields
2104
+ # Selector specifying which fields to include in a partial response.
2105
+ # @param [String] quota_user
2106
+ # Available to use for quota purposes for server-side applications. Can be any
2107
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2108
+ # Overrides userIp if both are provided.
2109
+ # @param [String] user_ip
2110
+ # IP address of the site where the request originates. Use this if you want to
2111
+ # enforce per-user limits.
2112
+ # @param [Google::Apis::RequestOptions] options
2113
+ # Request-specific options
2114
+ #
2115
+ # @yield [result, err] Result & error if block supplied
2116
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatch] parsed result object
2117
+ # @yieldparam err [StandardError] error object if request failed
2118
+ #
2119
+ # @return [Google::Apis::GamesV1::TurnBasedMatch]
2120
+ #
2121
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2122
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2123
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2124
+ def join_turn_based_match(match_id, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2125
+ command = make_simple_command(:put, 'turnbasedmatches/{matchId}/join', options)
2126
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatch::Representation
2127
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatch
2128
+ command.params['matchId'] = match_id unless match_id.nil?
2129
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2130
+ command.query['language'] = language unless language.nil?
2131
+ command.query['fields'] = fields unless fields.nil?
2132
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2133
+ command.query['userIp'] = user_ip unless user_ip.nil?
2134
+ execute_or_queue_command(command, &block)
2135
+ end
2136
+
2137
+ # Leave a turn-based match when it is not the current player's turn, without
2138
+ # canceling the match.
2139
+ # @param [String] match_id
2140
+ # The ID of the match.
2141
+ # @param [String] consistency_token
2142
+ # The last-seen mutation timestamp.
2143
+ # @param [String] language
2144
+ # The preferred language to use for strings returned by this method.
2145
+ # @param [String] fields
2146
+ # Selector specifying which fields to include in a partial response.
2147
+ # @param [String] quota_user
2148
+ # Available to use for quota purposes for server-side applications. Can be any
2149
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2150
+ # Overrides userIp if both are provided.
2151
+ # @param [String] user_ip
2152
+ # IP address of the site where the request originates. Use this if you want to
2153
+ # enforce per-user limits.
2154
+ # @param [Google::Apis::RequestOptions] options
2155
+ # Request-specific options
2156
+ #
2157
+ # @yield [result, err] Result & error if block supplied
2158
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatch] parsed result object
2159
+ # @yieldparam err [StandardError] error object if request failed
2160
+ #
2161
+ # @return [Google::Apis::GamesV1::TurnBasedMatch]
2162
+ #
2163
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2164
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2165
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2166
+ def leave_turn_based_match(match_id, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2167
+ command = make_simple_command(:put, 'turnbasedmatches/{matchId}/leave', options)
2168
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatch::Representation
2169
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatch
2170
+ command.params['matchId'] = match_id unless match_id.nil?
2171
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2172
+ command.query['language'] = language unless language.nil?
2173
+ command.query['fields'] = fields unless fields.nil?
2174
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2175
+ command.query['userIp'] = user_ip unless user_ip.nil?
2176
+ execute_or_queue_command(command, &block)
2177
+ end
2178
+
2179
+ # Leave a turn-based match during the current player's turn, without canceling
2180
+ # the match.
2181
+ # @param [String] match_id
2182
+ # The ID of the match.
2183
+ # @param [Fixnum] match_version
2184
+ # The version of the match being updated.
2185
+ # @param [String] consistency_token
2186
+ # The last-seen mutation timestamp.
2187
+ # @param [String] language
2188
+ # The preferred language to use for strings returned by this method.
2189
+ # @param [String] pending_participant_id
2190
+ # The ID of another participant who should take their turn next. If not set, the
2191
+ # match will wait for other player(s) to join via automatching; this is only
2192
+ # valid if automatch criteria is set on the match with remaining slots for
2193
+ # automatched players.
2194
+ # @param [String] fields
2195
+ # Selector specifying which fields to include in a partial response.
2196
+ # @param [String] quota_user
2197
+ # Available to use for quota purposes for server-side applications. Can be any
2198
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2199
+ # Overrides userIp if both are provided.
2200
+ # @param [String] user_ip
2201
+ # IP address of the site where the request originates. Use this if you want to
2202
+ # enforce per-user limits.
2203
+ # @param [Google::Apis::RequestOptions] options
2204
+ # Request-specific options
2205
+ #
2206
+ # @yield [result, err] Result & error if block supplied
2207
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatch] parsed result object
2208
+ # @yieldparam err [StandardError] error object if request failed
2209
+ #
2210
+ # @return [Google::Apis::GamesV1::TurnBasedMatch]
2211
+ #
2212
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2213
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2214
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2215
+ def leave_turn(match_id, match_version, consistency_token: nil, language: nil, pending_participant_id: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2216
+ command = make_simple_command(:put, 'turnbasedmatches/{matchId}/leaveTurn', options)
2217
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatch::Representation
2218
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatch
2219
+ command.params['matchId'] = match_id unless match_id.nil?
2220
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2221
+ command.query['language'] = language unless language.nil?
2222
+ command.query['matchVersion'] = match_version unless match_version.nil?
2223
+ command.query['pendingParticipantId'] = pending_participant_id unless pending_participant_id.nil?
2224
+ command.query['fields'] = fields unless fields.nil?
2225
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2226
+ command.query['userIp'] = user_ip unless user_ip.nil?
2227
+ execute_or_queue_command(command, &block)
2228
+ end
2229
+
2230
+ # Returns turn-based matches the player is or was involved in.
2231
+ # @param [String] consistency_token
2232
+ # The last-seen mutation timestamp.
2233
+ # @param [Boolean] include_match_data
2234
+ # True if match data should be returned in the response. Note that not all data
2235
+ # will necessarily be returned if include_match_data is true; the server may
2236
+ # decide to only return data for some of the matches to limit download size for
2237
+ # the client. The remainder of the data for these matches will be retrievable on
2238
+ # request.
2239
+ # @param [String] language
2240
+ # The preferred language to use for strings returned by this method.
2241
+ # @param [Fixnum] max_completed_matches
2242
+ # The maximum number of completed or canceled matches to return in the response.
2243
+ # If not set, all matches returned could be completed or canceled.
2244
+ # @param [Fixnum] max_results
2245
+ # The maximum number of matches to return in the response, used for paging. For
2246
+ # any response, the actual number of matches to return may be less than the
2247
+ # specified maxResults.
2248
+ # @param [String] page_token
2249
+ # The token returned by the previous request.
2250
+ # @param [String] fields
2251
+ # Selector specifying which fields to include in a partial response.
2252
+ # @param [String] quota_user
2253
+ # Available to use for quota purposes for server-side applications. Can be any
2254
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2255
+ # Overrides userIp if both are provided.
2256
+ # @param [String] user_ip
2257
+ # IP address of the site where the request originates. Use this if you want to
2258
+ # enforce per-user limits.
2259
+ # @param [Google::Apis::RequestOptions] options
2260
+ # Request-specific options
2261
+ #
2262
+ # @yield [result, err] Result & error if block supplied
2263
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatchList] parsed result object
2264
+ # @yieldparam err [StandardError] error object if request failed
2265
+ #
2266
+ # @return [Google::Apis::GamesV1::TurnBasedMatchList]
2267
+ #
2268
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2269
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2270
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2271
+ def list_turn_based_matches(consistency_token: nil, include_match_data: nil, language: nil, max_completed_matches: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2272
+ command = make_simple_command(:get, 'turnbasedmatches', options)
2273
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatchList::Representation
2274
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatchList
2275
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2276
+ command.query['includeMatchData'] = include_match_data unless include_match_data.nil?
2277
+ command.query['language'] = language unless language.nil?
2278
+ command.query['maxCompletedMatches'] = max_completed_matches unless max_completed_matches.nil?
2279
+ command.query['maxResults'] = max_results unless max_results.nil?
2280
+ command.query['pageToken'] = page_token unless page_token.nil?
2281
+ command.query['fields'] = fields unless fields.nil?
2282
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2283
+ command.query['userIp'] = user_ip unless user_ip.nil?
2284
+ execute_or_queue_command(command, &block)
2285
+ end
2286
+
2287
+ # Create a rematch of a match that was previously completed, with the same
2288
+ # participants. This can be called by only one player on a match still in their
2289
+ # list; the player must have called Finish first. Returns the newly created
2290
+ # match; it will be the caller's turn.
2291
+ # @param [String] match_id
2292
+ # The ID of the match.
2293
+ # @param [String] consistency_token
2294
+ # The last-seen mutation timestamp.
2295
+ # @param [String] language
2296
+ # The preferred language to use for strings returned by this method.
2297
+ # @param [String] request_id
2298
+ # A randomly generated numeric ID for each request specified by the caller. This
2299
+ # number is used at the server to ensure that the request is handled correctly
2300
+ # across retries.
2301
+ # @param [String] fields
2302
+ # Selector specifying which fields to include in a partial response.
2303
+ # @param [String] quota_user
2304
+ # Available to use for quota purposes for server-side applications. Can be any
2305
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2306
+ # Overrides userIp if both are provided.
2307
+ # @param [String] user_ip
2308
+ # IP address of the site where the request originates. Use this if you want to
2309
+ # enforce per-user limits.
2310
+ # @param [Google::Apis::RequestOptions] options
2311
+ # Request-specific options
2312
+ #
2313
+ # @yield [result, err] Result & error if block supplied
2314
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatchRematch] parsed result object
2315
+ # @yieldparam err [StandardError] error object if request failed
2316
+ #
2317
+ # @return [Google::Apis::GamesV1::TurnBasedMatchRematch]
2318
+ #
2319
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2320
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2321
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2322
+ def rematch_turn_based_match(match_id, consistency_token: nil, language: nil, request_id: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2323
+ command = make_simple_command(:post, 'turnbasedmatches/{matchId}/rematch', options)
2324
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatchRematch::Representation
2325
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatchRematch
2326
+ command.params['matchId'] = match_id unless match_id.nil?
2327
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2328
+ command.query['language'] = language unless language.nil?
2329
+ command.query['requestId'] = request_id unless request_id.nil?
2330
+ command.query['fields'] = fields unless fields.nil?
2331
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2332
+ command.query['userIp'] = user_ip unless user_ip.nil?
2333
+ execute_or_queue_command(command, &block)
2334
+ end
2335
+
2336
+ # Returns turn-based matches the player is or was involved in that changed since
2337
+ # the last sync call, with the least recent changes coming first. Matches that
2338
+ # should be removed from the local cache will have a status of MATCH_DELETED.
2339
+ # @param [String] consistency_token
2340
+ # The last-seen mutation timestamp.
2341
+ # @param [Boolean] include_match_data
2342
+ # True if match data should be returned in the response. Note that not all data
2343
+ # will necessarily be returned if include_match_data is true; the server may
2344
+ # decide to only return data for some of the matches to limit download size for
2345
+ # the client. The remainder of the data for these matches will be retrievable on
2346
+ # request.
2347
+ # @param [String] language
2348
+ # The preferred language to use for strings returned by this method.
2349
+ # @param [Fixnum] max_completed_matches
2350
+ # The maximum number of completed or canceled matches to return in the response.
2351
+ # If not set, all matches returned could be completed or canceled.
2352
+ # @param [Fixnum] max_results
2353
+ # The maximum number of matches to return in the response, used for paging. For
2354
+ # any response, the actual number of matches to return may be less than the
2355
+ # specified maxResults.
2356
+ # @param [String] page_token
2357
+ # The token returned by the previous request.
2358
+ # @param [String] fields
2359
+ # Selector specifying which fields to include in a partial response.
2360
+ # @param [String] quota_user
2361
+ # Available to use for quota purposes for server-side applications. Can be any
2362
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2363
+ # Overrides userIp if both are provided.
2364
+ # @param [String] user_ip
2365
+ # IP address of the site where the request originates. Use this if you want to
2366
+ # enforce per-user limits.
2367
+ # @param [Google::Apis::RequestOptions] options
2368
+ # Request-specific options
2369
+ #
2370
+ # @yield [result, err] Result & error if block supplied
2371
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatchSync] parsed result object
2372
+ # @yieldparam err [StandardError] error object if request failed
2373
+ #
2374
+ # @return [Google::Apis::GamesV1::TurnBasedMatchSync]
2375
+ #
2376
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2377
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2378
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2379
+ def sync_turn_based_match(consistency_token: nil, include_match_data: nil, language: nil, max_completed_matches: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2380
+ command = make_simple_command(:get, 'turnbasedmatches/sync', options)
2381
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatchSync::Representation
2382
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatchSync
2383
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2384
+ command.query['includeMatchData'] = include_match_data unless include_match_data.nil?
2385
+ command.query['language'] = language unless language.nil?
2386
+ command.query['maxCompletedMatches'] = max_completed_matches unless max_completed_matches.nil?
2387
+ command.query['maxResults'] = max_results unless max_results.nil?
2388
+ command.query['pageToken'] = page_token unless page_token.nil?
2389
+ command.query['fields'] = fields unless fields.nil?
2390
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2391
+ command.query['userIp'] = user_ip unless user_ip.nil?
2392
+ execute_or_queue_command(command, &block)
2393
+ end
2394
+
2395
+ # Commit the results of a player turn.
2396
+ # @param [String] match_id
2397
+ # The ID of the match.
2398
+ # @param [Google::Apis::GamesV1::TurnBasedMatchTurn] turn_based_match_turn_object
2399
+ # @param [String] consistency_token
2400
+ # The last-seen mutation timestamp.
2401
+ # @param [String] language
2402
+ # The preferred language to use for strings returned by this method.
2403
+ # @param [String] fields
2404
+ # Selector specifying which fields to include in a partial response.
2405
+ # @param [String] quota_user
2406
+ # Available to use for quota purposes for server-side applications. Can be any
2407
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
2408
+ # Overrides userIp if both are provided.
2409
+ # @param [String] user_ip
2410
+ # IP address of the site where the request originates. Use this if you want to
2411
+ # enforce per-user limits.
2412
+ # @param [Google::Apis::RequestOptions] options
2413
+ # Request-specific options
2414
+ #
2415
+ # @yield [result, err] Result & error if block supplied
2416
+ # @yieldparam result [Google::Apis::GamesV1::TurnBasedMatch] parsed result object
2417
+ # @yieldparam err [StandardError] error object if request failed
2418
+ #
2419
+ # @return [Google::Apis::GamesV1::TurnBasedMatch]
2420
+ #
2421
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
2422
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2423
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
2424
+ def take_turn(match_id, turn_based_match_turn_object = nil, consistency_token: nil, language: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2425
+ command = make_simple_command(:put, 'turnbasedmatches/{matchId}/turn', options)
2426
+ command.request_representation = Google::Apis::GamesV1::TurnBasedMatchTurn::Representation
2427
+ command.request_object = turn_based_match_turn_object
2428
+ command.response_representation = Google::Apis::GamesV1::TurnBasedMatch::Representation
2429
+ command.response_class = Google::Apis::GamesV1::TurnBasedMatch
2430
+ command.params['matchId'] = match_id unless match_id.nil?
2431
+ command.query['consistencyToken'] = consistency_token unless consistency_token.nil?
2432
+ command.query['language'] = language unless language.nil?
2433
+ command.query['fields'] = fields unless fields.nil?
2434
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2435
+ command.query['userIp'] = user_ip unless user_ip.nil?
2436
+ execute_or_queue_command(command, &block)
2437
+ end
2438
+
2439
+ protected
2440
+
2441
+ def apply_command_defaults(command)
2442
+ command.query['key'] = key unless key.nil?
2443
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
2444
+ command.query['userIp'] = user_ip unless user_ip.nil?
2445
+ end
2446
+ end
2447
+ end
2448
+ end
2449
+ end