google-api-client 0.8.7 → 0.9.pre1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (397) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +20 -0
  3. data/.rspec +2 -0
  4. data/.rubocop.yml +7 -0
  5. data/.rubocop_todo.yml +63 -0
  6. data/.travis.yml +21 -0
  7. data/.yardopts +12 -0
  8. data/CHANGELOG.md +6 -3
  9. data/CONTRIBUTING.md +31 -0
  10. data/Gemfile +28 -2
  11. data/MIGRATING.md +171 -0
  12. data/README.md +158 -150
  13. data/Rakefile +1 -40
  14. data/api_names.yaml +872 -0
  15. data/api_names_out.yaml +20843 -0
  16. data/bin/generate-api +93 -0
  17. data/generated/google/apis/adexchangebuyer_v1_3.rb +35 -0
  18. data/generated/google/apis/adexchangebuyer_v1_3/classes.rb +1124 -0
  19. data/generated/google/apis/adexchangebuyer_v1_3/representations.rb +375 -0
  20. data/generated/google/apis/adexchangebuyer_v1_3/service.rb +893 -0
  21. data/generated/google/apis/adexchangeseller_v2_0.rb +38 -0
  22. data/generated/google/apis/adexchangeseller_v2_0/classes.rb +792 -0
  23. data/generated/google/apis/adexchangeseller_v2_0/representations.rb +309 -0
  24. data/generated/google/apis/adexchangeseller_v2_0/service.rb +682 -0
  25. data/generated/google/apis/admin_directory_v1.rb +89 -0
  26. data/generated/google/apis/admin_directory_v1/classes.rb +2389 -0
  27. data/generated/google/apis/admin_directory_v1/representations.rb +780 -0
  28. data/generated/google/apis/admin_directory_v1/service.rb +2805 -0
  29. data/generated/google/apis/admin_reports_v1.rb +38 -0
  30. data/generated/google/apis/admin_reports_v1/classes.rb +582 -0
  31. data/generated/google/apis/admin_reports_v1/representations.rb +231 -0
  32. data/generated/google/apis/admin_reports_v1/service.rb +341 -0
  33. data/generated/google/apis/adsense_v1_4.rb +38 -0
  34. data/generated/google/apis/adsense_v1_4/classes.rb +1279 -0
  35. data/generated/google/apis/adsense_v1_4/representations.rb +493 -0
  36. data/generated/google/apis/adsense_v1_4/service.rb +1752 -0
  37. data/generated/google/apis/adsensehost_v4_1.rb +35 -0
  38. data/generated/google/apis/adsensehost_v4_1/classes.rb +834 -0
  39. data/generated/google/apis/adsensehost_v4_1/representations.rb +327 -0
  40. data/generated/google/apis/adsensehost_v4_1/service.rb +1190 -0
  41. data/generated/google/apis/analytics_v3.rb +49 -0
  42. data/generated/google/apis/analytics_v3/classes.rb +5113 -0
  43. data/generated/google/apis/analytics_v3/representations.rb +1661 -0
  44. data/generated/google/apis/analytics_v3/service.rb +3600 -0
  45. data/generated/google/apis/androidenterprise_v1.rb +34 -0
  46. data/generated/google/apis/androidenterprise_v1/classes.rb +1162 -0
  47. data/generated/google/apis/androidenterprise_v1/representations.rb +431 -0
  48. data/generated/google/apis/androidenterprise_v1/service.rb +1979 -0
  49. data/generated/google/apis/androidpublisher_v2.rb +34 -0
  50. data/generated/google/apis/androidpublisher_v2/classes.rb +1374 -0
  51. data/generated/google/apis/androidpublisher_v2/representations.rb +630 -0
  52. data/generated/google/apis/androidpublisher_v2/service.rb +2390 -0
  53. data/generated/google/apis/appsactivity_v1.rb +46 -0
  54. data/generated/google/apis/appsactivity_v1/classes.rb +392 -0
  55. data/generated/google/apis/appsactivity_v1/representations.rb +184 -0
  56. data/generated/google/apis/appsactivity_v1/service.rb +129 -0
  57. data/generated/google/apis/appstate_v1.rb +34 -0
  58. data/generated/google/apis/appstate_v1/classes.rb +154 -0
  59. data/generated/google/apis/appstate_v1/representations.rb +79 -0
  60. data/generated/google/apis/appstate_v1/service.rb +265 -0
  61. data/generated/google/apis/autoscaler_v1beta2.rb +38 -0
  62. data/generated/google/apis/autoscaler_v1beta2/classes.rb +747 -0
  63. data/generated/google/apis/autoscaler_v1beta2/representations.rb +281 -0
  64. data/generated/google/apis/autoscaler_v1beta2/service.rb +488 -0
  65. data/generated/google/apis/bigquery_v2.rb +49 -0
  66. data/generated/google/apis/bigquery_v2/classes.rb +2255 -0
  67. data/generated/google/apis/bigquery_v2/representations.rb +754 -0
  68. data/generated/google/apis/bigquery_v2/service.rb +1003 -0
  69. data/generated/google/apis/blogger_v3.rb +37 -0
  70. data/generated/google/apis/blogger_v3/classes.rb +1354 -0
  71. data/generated/google/apis/blogger_v3/representations.rb +562 -0
  72. data/generated/google/apis/blogger_v3/service.rb +1620 -0
  73. data/generated/google/apis/books_v1.rb +34 -0
  74. data/generated/google/apis/books_v1/classes.rb +3515 -0
  75. data/generated/google/apis/books_v1/representations.rb +1361 -0
  76. data/generated/google/apis/books_v1/service.rb +2170 -0
  77. data/generated/google/apis/calendar_v3.rb +37 -0
  78. data/generated/google/apis/calendar_v3/classes.rb +1702 -0
  79. data/generated/google/apis/calendar_v3/representations.rb +566 -0
  80. data/generated/google/apis/calendar_v3/service.rb +1943 -0
  81. data/generated/google/apis/civicinfo_v2.rb +31 -0
  82. data/generated/google/apis/civicinfo_v2/classes.rb +1057 -0
  83. data/generated/google/apis/civicinfo_v2/representations.rb +374 -0
  84. data/generated/google/apis/civicinfo_v2/service.rb +284 -0
  85. data/generated/google/apis/cloudmonitoring_v2beta2.rb +34 -0
  86. data/generated/google/apis/cloudmonitoring_v2beta2/classes.rb +679 -0
  87. data/generated/google/apis/cloudmonitoring_v2beta2/representations.rb +311 -0
  88. data/generated/google/apis/cloudmonitoring_v2beta2/service.rb +458 -0
  89. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +38 -0
  90. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +139 -0
  91. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +65 -0
  92. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +301 -0
  93. data/generated/google/apis/compute_v1.rb +49 -0
  94. data/generated/google/apis/compute_v1/classes.rb +6391 -0
  95. data/generated/google/apis/compute_v1/representations.rb +2209 -0
  96. data/generated/google/apis/compute_v1/service.rb +6352 -0
  97. data/generated/google/apis/container_v1beta1.rb +35 -0
  98. data/generated/google/apis/container_v1beta1/classes.rb +466 -0
  99. data/generated/google/apis/container_v1beta1/representations.rb +177 -0
  100. data/generated/google/apis/container_v1beta1/service.rb +394 -0
  101. data/generated/google/apis/content_v2.rb +35 -0
  102. data/generated/google/apis/content_v2/classes.rb +3780 -0
  103. data/generated/google/apis/content_v2/representations.rb +1456 -0
  104. data/generated/google/apis/content_v2/service.rb +1706 -0
  105. data/generated/google/apis/coordinate_v1.rb +37 -0
  106. data/generated/google/apis/coordinate_v1/classes.rb +669 -0
  107. data/generated/google/apis/coordinate_v1/representations.rb +285 -0
  108. data/generated/google/apis/coordinate_v1/service.rb +687 -0
  109. data/{lib/google/api_client/auth/compute_service_account.rb → generated/google/apis/customsearch_v1.rb} +13 -10
  110. data/generated/google/apis/customsearch_v1/classes.rb +771 -0
  111. data/generated/google/apis/customsearch_v1/representations.rb +276 -0
  112. data/generated/google/apis/customsearch_v1/service.rb +208 -0
  113. data/generated/google/apis/datastore_v1beta2.rb +40 -0
  114. data/generated/google/apis/datastore_v1beta2/classes.rb +1186 -0
  115. data/generated/google/apis/datastore_v1beta2/representations.rb +526 -0
  116. data/generated/google/apis/datastore_v1beta2/service.rb +300 -0
  117. data/generated/google/apis/deploymentmanager_v2beta2.rb +41 -0
  118. data/generated/google/apis/deploymentmanager_v2beta2/classes.rb +820 -0
  119. data/generated/google/apis/deploymentmanager_v2beta2/representations.rb +303 -0
  120. data/generated/google/apis/deploymentmanager_v2beta2/service.rb +647 -0
  121. data/generated/google/apis/dfareporting_v2_1.rb +37 -0
  122. data/generated/google/apis/dfareporting_v2_1/classes.rb +10755 -0
  123. data/generated/google/apis/dfareporting_v2_1/representations.rb +3438 -0
  124. data/generated/google/apis/dfareporting_v2_1/service.rb +8775 -0
  125. data/generated/google/apis/discovery_v1.rb +32 -0
  126. data/generated/google/apis/discovery_v1/classes.rb +947 -0
  127. data/generated/google/apis/discovery_v1/representations.rb +355 -0
  128. data/generated/google/apis/discovery_v1/service.rb +144 -0
  129. data/generated/google/apis/dns_v1.rb +41 -0
  130. data/generated/google/apis/dns_v1/classes.rb +406 -0
  131. data/generated/google/apis/dns_v1/representations.rb +151 -0
  132. data/generated/google/apis/dns_v1/service.rb +460 -0
  133. data/{spec/google/api_client/request_spec.rb → generated/google/apis/doubleclickbidmanager_v1.rb} +15 -13
  134. data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +709 -0
  135. data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +297 -0
  136. data/generated/google/apis/doubleclickbidmanager_v1/service.rb +349 -0
  137. data/generated/google/apis/doubleclicksearch_v2.rb +35 -0
  138. data/generated/google/apis/doubleclicksearch_v2/classes.rb +947 -0
  139. data/generated/google/apis/doubleclicksearch_v2/representations.rb +315 -0
  140. data/generated/google/apis/doubleclicksearch_v2/service.rb +490 -0
  141. data/generated/google/apis/drive_v2.rb +55 -0
  142. data/generated/google/apis/drive_v2/classes.rb +2519 -0
  143. data/generated/google/apis/drive_v2/representations.rb +781 -0
  144. data/generated/google/apis/drive_v2/service.rb +2685 -0
  145. data/generated/google/apis/fitness_v1.rb +49 -0
  146. data/generated/google/apis/fitness_v1/classes.rb +809 -0
  147. data/generated/google/apis/fitness_v1/representations.rb +295 -0
  148. data/generated/google/apis/fitness_v1/service.rb +684 -0
  149. data/generated/google/apis/fusiontables_v2.rb +37 -0
  150. data/generated/google/apis/fusiontables_v2/classes.rb +1048 -0
  151. data/generated/google/apis/fusiontables_v2/representations.rb +409 -0
  152. data/generated/google/apis/fusiontables_v2/service.rb +1496 -0
  153. data/generated/google/apis/games_configuration_v1configuration.rb +34 -0
  154. data/generated/google/apis/games_configuration_v1configuration/classes.rb +506 -0
  155. data/generated/google/apis/games_configuration_v1configuration/representations.rb +206 -0
  156. data/generated/google/apis/games_configuration_v1configuration/service.rb +578 -0
  157. data/generated/google/apis/games_v1.rb +40 -0
  158. data/generated/google/apis/games_v1/classes.rb +4578 -0
  159. data/generated/google/apis/games_v1/representations.rb +1570 -0
  160. data/generated/google/apis/games_v1/service.rb +2306 -0
  161. data/generated/google/apis/gan_v1beta1.rb +31 -0
  162. data/generated/google/apis/gan_v1beta1/classes.rb +1428 -0
  163. data/generated/google/apis/gan_v1beta1/representations.rb +428 -0
  164. data/generated/google/apis/gan_v1beta1/service.rb +692 -0
  165. data/generated/google/apis/genomics_v1beta2.rb +46 -0
  166. data/generated/google/apis/genomics_v1beta2/classes.rb +3288 -0
  167. data/generated/google/apis/genomics_v1beta2/representations.rb +1194 -0
  168. data/generated/google/apis/genomics_v1beta2/service.rb +2356 -0
  169. data/generated/google/apis/gmail_v1.rb +49 -0
  170. data/generated/google/apis/gmail_v1/classes.rb +794 -0
  171. data/generated/google/apis/gmail_v1/representations.rb +339 -0
  172. data/generated/google/apis/gmail_v1/service.rb +1502 -0
  173. data/generated/google/apis/groupsmigration_v1.rb +34 -0
  174. data/generated/google/apis/groupsmigration_v1/classes.rb +51 -0
  175. data/generated/google/apis/groupsmigration_v1/representations.rb +38 -0
  176. data/generated/google/apis/groupsmigration_v1/service.rb +111 -0
  177. data/generated/google/apis/groupssettings_v1.rb +34 -0
  178. data/generated/google/apis/groupssettings_v1/classes.rb +221 -0
  179. data/generated/google/apis/groupssettings_v1/representations.rb +64 -0
  180. data/generated/google/apis/groupssettings_v1/service.rb +179 -0
  181. data/generated/google/apis/identitytoolkit_v3.rb +31 -0
  182. data/generated/google/apis/identitytoolkit_v3/classes.rb +1229 -0
  183. data/generated/google/apis/identitytoolkit_v3/representations.rb +422 -0
  184. data/generated/google/apis/identitytoolkit_v3/service.rb +491 -0
  185. data/generated/google/apis/licensing_v1.rb +34 -0
  186. data/generated/google/apis/licensing_v1/classes.rb +132 -0
  187. data/generated/google/apis/licensing_v1/representations.rb +68 -0
  188. data/generated/google/apis/licensing_v1/service.rb +376 -0
  189. data/generated/google/apis/logging_v1beta3.rb +35 -0
  190. data/generated/google/apis/logging_v1beta3/classes.rb +505 -0
  191. data/generated/google/apis/logging_v1beta3/representations.rb +222 -0
  192. data/generated/google/apis/logging_v1beta3/service.rb +670 -0
  193. data/generated/google/apis/manager_v1beta2.rb +50 -0
  194. data/generated/google/apis/manager_v1beta2/classes.rb +1287 -0
  195. data/generated/google/apis/manager_v1beta2/representations.rb +536 -0
  196. data/generated/google/apis/manager_v1beta2/service.rb +380 -0
  197. data/generated/google/apis/mapsengine_v1.rb +38 -0
  198. data/generated/google/apis/mapsengine_v1/classes.rb +2873 -0
  199. data/generated/google/apis/mapsengine_v1/representations.rb +1235 -0
  200. data/generated/google/apis/mapsengine_v1/service.rb +3465 -0
  201. data/generated/google/apis/mirror_v1.rb +37 -0
  202. data/generated/google/apis/mirror_v1/classes.rb +1072 -0
  203. data/generated/google/apis/mirror_v1/representations.rb +350 -0
  204. data/generated/google/apis/mirror_v1/service.rb +1001 -0
  205. data/generated/google/apis/oauth2_v2.rb +43 -0
  206. data/generated/google/apis/oauth2_v2/classes.rb +245 -0
  207. data/generated/google/apis/oauth2_v2/representations.rb +94 -0
  208. data/generated/google/apis/oauth2_v2/service.rb +203 -0
  209. data/generated/google/apis/pagespeedonline_v2.rb +32 -0
  210. data/generated/google/apis/pagespeedonline_v2/classes.rb +614 -0
  211. data/generated/google/apis/pagespeedonline_v2/representations.rb +244 -0
  212. data/generated/google/apis/pagespeedonline_v2/service.rb +120 -0
  213. data/generated/google/apis/plus_domains_v1.rb +61 -0
  214. data/generated/google/apis/plus_domains_v1/classes.rb +2402 -0
  215. data/generated/google/apis/plus_domains_v1/representations.rb +873 -0
  216. data/generated/google/apis/plus_domains_v1/service.rb +924 -0
  217. data/generated/google/apis/plus_v1.rb +43 -0
  218. data/generated/google/apis/plus_v1/classes.rb +2384 -0
  219. data/generated/google/apis/plus_v1/representations.rb +812 -0
  220. data/generated/google/apis/plus_v1/service.rb +616 -0
  221. data/generated/google/apis/prediction_v1_6.rb +44 -0
  222. data/generated/google/apis/prediction_v1_6/classes.rb +751 -0
  223. data/generated/google/apis/prediction_v1_6/representations.rb +327 -0
  224. data/generated/google/apis/prediction_v1_6/service.rb +388 -0
  225. data/generated/google/apis/pubsub_v1beta2.rb +37 -0
  226. data/generated/google/apis/pubsub_v1beta2/classes.rb +824 -0
  227. data/generated/google/apis/pubsub_v1beta2/representations.rb +366 -0
  228. data/generated/google/apis/pubsub_v1beta2/service.rb +778 -0
  229. data/generated/google/apis/qpx_express_v1.rb +31 -0
  230. data/generated/google/apis/qpx_express_v1/classes.rb +1268 -0
  231. data/generated/google/apis/qpx_express_v1/representations.rb +424 -0
  232. data/generated/google/apis/qpx_express_v1/service.rb +101 -0
  233. data/generated/google/apis/replicapool_v1beta2.rb +41 -0
  234. data/generated/google/apis/replicapool_v1beta2/classes.rb +621 -0
  235. data/generated/google/apis/replicapool_v1beta2/representations.rb +235 -0
  236. data/generated/google/apis/replicapool_v1beta2/service.rb +620 -0
  237. data/generated/google/apis/replicapoolupdater_v1beta1.rb +41 -0
  238. data/generated/google/apis/replicapoolupdater_v1beta1/classes.rb +682 -0
  239. data/generated/google/apis/replicapoolupdater_v1beta1/representations.rb +247 -0
  240. data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +472 -0
  241. data/generated/google/apis/reseller_v1.rb +37 -0
  242. data/generated/google/apis/reseller_v1/classes.rb +502 -0
  243. data/generated/google/apis/reseller_v1/representations.rb +199 -0
  244. data/generated/google/apis/reseller_v1/service.rb +637 -0
  245. data/generated/google/apis/resourceviews_v1beta2.rb +47 -0
  246. data/generated/google/apis/resourceviews_v1beta2/classes.rb +660 -0
  247. data/generated/google/apis/resourceviews_v1beta2/representations.rb +269 -0
  248. data/generated/google/apis/resourceviews_v1beta2/service.rb +574 -0
  249. data/generated/google/apis/site_verification_v1.rb +37 -0
  250. data/generated/google/apis/site_verification_v1/classes.rb +185 -0
  251. data/generated/google/apis/site_verification_v1/representations.rb +101 -0
  252. data/generated/google/apis/site_verification_v1/service.rb +322 -0
  253. data/generated/google/apis/sqladmin_v1beta4.rb +37 -0
  254. data/generated/google/apis/sqladmin_v1beta4/classes.rb +1817 -0
  255. data/generated/google/apis/sqladmin_v1beta4/representations.rb +688 -0
  256. data/generated/google/apis/sqladmin_v1beta4/service.rb +1534 -0
  257. data/generated/google/apis/storage_v1.rb +43 -0
  258. data/generated/google/apis/storage_v1/classes.rb +1177 -0
  259. data/generated/google/apis/storage_v1/representations.rb +427 -0
  260. data/generated/google/apis/storage_v1/service.rb +1920 -0
  261. data/generated/google/apis/tagmanager_v1.rb +52 -0
  262. data/generated/google/apis/tagmanager_v1/classes.rb +1226 -0
  263. data/generated/google/apis/tagmanager_v1/representations.rb +461 -0
  264. data/generated/google/apis/tagmanager_v1/service.rb +1978 -0
  265. data/generated/google/apis/taskqueue_v1beta2.rb +37 -0
  266. data/generated/google/apis/taskqueue_v1beta2/classes.rb +254 -0
  267. data/generated/google/apis/taskqueue_v1beta2/representations.rb +114 -0
  268. data/generated/google/apis/taskqueue_v1beta2/service.rb +416 -0
  269. data/generated/google/apis/tasks_v1.rb +37 -0
  270. data/generated/google/apis/tasks_v1/classes.rb +296 -0
  271. data/generated/google/apis/tasks_v1/representations.rb +115 -0
  272. data/generated/google/apis/tasks_v1/service.rb +657 -0
  273. data/generated/google/apis/translate_v2.rb +31 -0
  274. data/generated/google/apis/translate_v2/classes.rb +168 -0
  275. data/generated/google/apis/translate_v2/representations.rb +109 -0
  276. data/generated/google/apis/translate_v2/service.rb +185 -0
  277. data/generated/google/apis/urlshortener_v1.rb +34 -0
  278. data/generated/google/apis/urlshortener_v1/classes.rb +246 -0
  279. data/generated/google/apis/urlshortener_v1/representations.rb +111 -0
  280. data/generated/google/apis/urlshortener_v1/service.rb +179 -0
  281. data/generated/google/apis/webmasters_v3.rb +37 -0
  282. data/generated/google/apis/webmasters_v3/classes.rb +563 -0
  283. data/generated/google/apis/webmasters_v3/representations.rb +250 -0
  284. data/generated/google/apis/webmasters_v3/service.rb +587 -0
  285. data/generated/google/apis/youtube_analytics_v1.rb +46 -0
  286. data/generated/google/apis/youtube_analytics_v1/classes.rb +540 -0
  287. data/generated/google/apis/youtube_analytics_v1/representations.rb +242 -0
  288. data/generated/google/apis/youtube_analytics_v1/service.rb +567 -0
  289. data/generated/google/apis/youtube_v3.rb +49 -0
  290. data/generated/google/apis/youtube_v3/classes.rb +7225 -0
  291. data/generated/google/apis/youtube_v3/representations.rb +2529 -0
  292. data/generated/google/apis/youtube_v3/service.rb +4051 -0
  293. data/google-api-client.gemspec +27 -39
  294. data/lib/google/api_client/auth/storage.rb +3 -2
  295. data/lib/google/api_client/auth/storages/file_store.rb +1 -3
  296. data/lib/google/api_client/auth/storages/redis_store.rb +6 -2
  297. data/lib/google/apis.rb +48 -0
  298. data/lib/google/apis/core/api_command.rb +128 -0
  299. data/lib/google/apis/core/base_service.rb +314 -0
  300. data/lib/google/apis/core/batch.rb +222 -0
  301. data/lib/google/apis/core/download.rb +94 -0
  302. data/lib/google/apis/core/hashable.rb +44 -0
  303. data/lib/google/apis/core/http_command.rb +275 -0
  304. data/lib/google/apis/core/json_representation.rb +122 -0
  305. data/lib/google/{api_client/version.rb → apis/core/logging.rb} +12 -8
  306. data/lib/google/apis/core/multipart.rb +173 -0
  307. data/lib/google/apis/core/upload.rb +275 -0
  308. data/lib/google/{api_client → apis}/errors.rb +32 -28
  309. data/lib/google/apis/generator.rb +70 -0
  310. data/lib/google/apis/generator/annotator.rb +271 -0
  311. data/lib/google/apis/generator/helpers.rb +74 -0
  312. data/lib/google/apis/generator/model.rb +130 -0
  313. data/lib/google/apis/generator/template.rb +124 -0
  314. data/lib/google/apis/generator/templates/_class.tmpl +40 -0
  315. data/lib/google/apis/generator/templates/_method.tmpl +90 -0
  316. data/lib/google/apis/generator/templates/_representation.tmpl +51 -0
  317. data/lib/google/apis/generator/templates/_representation_stub.tmpl +15 -0
  318. data/lib/google/apis/generator/templates/_representation_type.tmpl +10 -0
  319. data/lib/google/{api_client/reference.rb → apis/generator/templates/classes.rb.tmpl} +11 -9
  320. data/lib/google/apis/generator/templates/module.rb.tmpl +40 -0
  321. data/lib/google/apis/generator/templates/representations.rb.tmpl +32 -0
  322. data/lib/google/apis/generator/templates/service.rb.tmpl +60 -0
  323. data/lib/google/apis/options.rb +79 -0
  324. data/lib/google/apis/version.rb +39 -0
  325. data/rakelib/metrics.rake +22 -0
  326. data/rakelib/rubocop.rake +10 -0
  327. data/rakelib/spec.rake +11 -0
  328. data/rakelib/yard.rake +11 -0
  329. data/samples/calendar/calendar.rb +43 -0
  330. data/samples/drive/drive.rb +40 -0
  331. data/samples/pubsub/pubsub.rb +52 -0
  332. data/{lib/google/api_client/discovery.rb → samples/translate/translate.rb} +14 -5
  333. data/script/generate +79 -0
  334. data/script/package +8 -0
  335. data/script/release +15 -0
  336. data/spec/fixtures/files/api_names.yaml +3 -0
  337. data/spec/fixtures/files/auth_stored_credentials.json +8 -0
  338. data/spec/fixtures/files/client_secrets.json +1 -0
  339. data/spec/fixtures/files/test.blah +1 -0
  340. data/spec/fixtures/files/test.txt +1 -0
  341. data/spec/fixtures/files/test_api.json +440 -0
  342. data/spec/google/api_client/auth/storage_spec.rb +1 -3
  343. data/spec/google/api_client/auth/storages/file_store_spec.rb +1 -2
  344. data/spec/google/api_client/auth/storages/redis_store_spec.rb +1 -3
  345. data/spec/google/apis/core/api_command_spec.rb +170 -0
  346. data/spec/google/apis/core/batch_spec.rb +128 -0
  347. data/spec/google/apis/core/download_spec.rb +90 -0
  348. data/spec/google/apis/core/hashable_spec.rb +60 -0
  349. data/spec/google/apis/core/http_command_spec.rb +238 -0
  350. data/spec/google/apis/core/json_representation_spec.rb +192 -0
  351. data/spec/google/apis/core/service_spec.rb +247 -0
  352. data/spec/google/apis/core/upload_spec.rb +238 -0
  353. data/{lib/google/api_client/service_account.rb → spec/google/apis/generated_spec.rb} +14 -8
  354. data/spec/google/apis/generator/generator_spec.rb +272 -0
  355. data/spec/google/apis/logging_spec.rb +45 -0
  356. data/spec/google/apis/options_spec.rb +40 -0
  357. data/spec/integration_tests/drive_spec.rb +35 -0
  358. data/spec/integration_tests/pubsub_spec.rb +48 -0
  359. data/spec/integration_tests/url_shortener_spec.rb +31 -0
  360. data/spec/spec_helper.rb +102 -46
  361. metadata +433 -178
  362. data/lib/compat/multi_json.rb +0 -19
  363. data/lib/google/api_client.rb +0 -750
  364. data/lib/google/api_client/auth/file_storage.rb +0 -59
  365. data/lib/google/api_client/auth/jwt_asserter.rb +0 -126
  366. data/lib/google/api_client/auth/key_utils.rb +0 -93
  367. data/lib/google/api_client/auth/pkcs12.rb +0 -41
  368. data/lib/google/api_client/batch.rb +0 -326
  369. data/lib/google/api_client/charset.rb +0 -33
  370. data/lib/google/api_client/discovery/api.rb +0 -310
  371. data/lib/google/api_client/discovery/media.rb +0 -77
  372. data/lib/google/api_client/discovery/method.rb +0 -363
  373. data/lib/google/api_client/discovery/resource.rb +0 -156
  374. data/lib/google/api_client/discovery/schema.rb +0 -117
  375. data/lib/google/api_client/environment.rb +0 -42
  376. data/lib/google/api_client/gzip.rb +0 -28
  377. data/lib/google/api_client/logging.rb +0 -32
  378. data/lib/google/api_client/media.rb +0 -259
  379. data/lib/google/api_client/railtie.rb +0 -18
  380. data/lib/google/api_client/request.rb +0 -350
  381. data/lib/google/api_client/result.rb +0 -255
  382. data/lib/google/api_client/service.rb +0 -233
  383. data/lib/google/api_client/service/batch.rb +0 -110
  384. data/lib/google/api_client/service/request.rb +0 -144
  385. data/lib/google/api_client/service/resource.rb +0 -40
  386. data/lib/google/api_client/service/result.rb +0 -162
  387. data/lib/google/api_client/service/simple_file_store.rb +0 -151
  388. data/lib/google/api_client/service/stub_generator.rb +0 -61
  389. data/spec/google/api_client/batch_spec.rb +0 -248
  390. data/spec/google/api_client/discovery_spec.rb +0 -708
  391. data/spec/google/api_client/gzip_spec.rb +0 -98
  392. data/spec/google/api_client/media_spec.rb +0 -178
  393. data/spec/google/api_client/result_spec.rb +0 -207
  394. data/spec/google/api_client/service_account_spec.rb +0 -169
  395. data/spec/google/api_client/service_spec.rb +0 -618
  396. data/spec/google/api_client/simple_file_store_spec.rb +0 -133
  397. data/spec/google/api_client_spec.rb +0 -352
@@ -0,0 +1,35 @@
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/doubleclicksearch_v2/service.rb'
16
+ require 'google/apis/doubleclicksearch_v2/classes.rb'
17
+ require 'google/apis/doubleclicksearch_v2/representations.rb'
18
+
19
+ module Google
20
+ module Apis
21
+ # DoubleClick Search API
22
+ #
23
+ # Report and modify your advertising data in DoubleClick Search (for example,
24
+ # campaigns, ad groups, keywords, and conversions).
25
+ #
26
+ # @see https://developers.google.com/doubleclick-search/
27
+ module DoubleclicksearchV2
28
+ VERSION = 'V2'
29
+ REVISION = '20150526'
30
+
31
+ # View and manage your advertising data in DoubleClick Search
32
+ AUTH_DOUBLECLICKSEARCH = 'https://www.googleapis.com/auth/doubleclicksearch'
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,947 @@
1
+ # Copyright 2015 Google Inc.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'date'
16
+ require 'google/apis/core/base_service'
17
+ require 'google/apis/core/json_representation'
18
+ require 'google/apis/core/hashable'
19
+ require 'google/apis/errors'
20
+
21
+ module Google
22
+ module Apis
23
+ module DoubleclicksearchV2
24
+
25
+ # A message containing availability data relevant to DoubleClick Search.
26
+ class Availability
27
+ include Google::Apis::Core::Hashable
28
+
29
+ # DS advertiser ID.
30
+ # Corresponds to the JSON property `advertiserId`
31
+ # @return [String]
32
+ attr_accessor :advertiser_id
33
+
34
+ # DS agency ID.
35
+ # Corresponds to the JSON property `agencyId`
36
+ # @return [String]
37
+ attr_accessor :agency_id
38
+
39
+ # The time by which all conversions have been uploaded, in epoch millis UTC.
40
+ # Corresponds to the JSON property `availabilityTimestamp`
41
+ # @return [String]
42
+ attr_accessor :availability_timestamp
43
+
44
+ # The numeric segmentation identifier (for example, DoubleClick Search
45
+ # Floodlight activity ID).
46
+ # Corresponds to the JSON property `segmentationId`
47
+ # @return [String]
48
+ attr_accessor :segmentation_id
49
+
50
+ # The friendly segmentation identifier (for example, DoubleClick Search
51
+ # Floodlight activity name).
52
+ # Corresponds to the JSON property `segmentationName`
53
+ # @return [String]
54
+ attr_accessor :segmentation_name
55
+
56
+ # The segmentation type that this availability is for (its default value is
57
+ # FLOODLIGHT).
58
+ # Corresponds to the JSON property `segmentationType`
59
+ # @return [String]
60
+ attr_accessor :segmentation_type
61
+
62
+ def initialize(**args)
63
+ update!(**args)
64
+ end
65
+
66
+ # Update properties of this object
67
+ def update!(**args)
68
+ @advertiser_id = args[:advertiser_id] unless args[:advertiser_id].nil?
69
+ @agency_id = args[:agency_id] unless args[:agency_id].nil?
70
+ @availability_timestamp = args[:availability_timestamp] unless args[:availability_timestamp].nil?
71
+ @segmentation_id = args[:segmentation_id] unless args[:segmentation_id].nil?
72
+ @segmentation_name = args[:segmentation_name] unless args[:segmentation_name].nil?
73
+ @segmentation_type = args[:segmentation_type] unless args[:segmentation_type].nil?
74
+ end
75
+ end
76
+
77
+ # A conversion containing data relevant to DoubleClick Search.
78
+ class Conversion
79
+ include Google::Apis::Core::Hashable
80
+
81
+ # DS ad group ID.
82
+ # Corresponds to the JSON property `adGroupId`
83
+ # @return [String]
84
+ attr_accessor :ad_group_id
85
+
86
+ # DS ad ID.
87
+ # Corresponds to the JSON property `adId`
88
+ # @return [String]
89
+ attr_accessor :ad_id
90
+
91
+ # DS advertiser ID.
92
+ # Corresponds to the JSON property `advertiserId`
93
+ # @return [String]
94
+ attr_accessor :advertiser_id
95
+
96
+ # DS agency ID.
97
+ # Corresponds to the JSON property `agencyId`
98
+ # @return [String]
99
+ attr_accessor :agency_id
100
+
101
+ # This field is ignored.
102
+ # Corresponds to the JSON property `attributionModel`
103
+ # @return [String]
104
+ attr_accessor :attribution_model
105
+
106
+ # DS campaign ID.
107
+ # Corresponds to the JSON property `campaignId`
108
+ # @return [String]
109
+ attr_accessor :campaign_id
110
+
111
+ # Sales channel for the product. Acceptable values are:
112
+ # - "local": a physical store
113
+ # - "online": an online store
114
+ # Corresponds to the JSON property `channel`
115
+ # @return [String]
116
+ attr_accessor :channel
117
+
118
+ # DS click ID for the conversion.
119
+ # Corresponds to the JSON property `clickId`
120
+ # @return [String]
121
+ attr_accessor :click_id
122
+
123
+ # For offline conversions, this is an ID provided by advertisers. Advertisers
124
+ # can use this property to specify an ID that is meaningful to them. If an
125
+ # advertiser doesn't specify a conversionId, DoubleClick Search generates one.
126
+ # For online conversions, DS copies the dsConversionId or floodlightOrderId into
127
+ # this property depending on the advertiser's Floodlight instructions.
128
+ # Corresponds to the JSON property `conversionId`
129
+ # @return [String]
130
+ attr_accessor :conversion_id
131
+
132
+ # The time at which the conversion was last modified, in epoch millis UTC.
133
+ # Corresponds to the JSON property `conversionModifiedTimestamp`
134
+ # @return [String]
135
+ attr_accessor :conversion_modified_timestamp
136
+
137
+ # The time at which the conversion took place, in epoch millis UTC.
138
+ # Corresponds to the JSON property `conversionTimestamp`
139
+ # @return [String]
140
+ attr_accessor :conversion_timestamp
141
+
142
+ # This field is ignored.
143
+ # Corresponds to the JSON property `countMillis`
144
+ # @return [String]
145
+ attr_accessor :count_millis
146
+
147
+ # DS criterion (keyword) ID.
148
+ # Corresponds to the JSON property `criterionId`
149
+ # @return [String]
150
+ attr_accessor :criterion_id
151
+
152
+ # The currency code for the conversion's revenue. Should be in ISO 4217
153
+ # alphabetic (3-char) format.
154
+ # Corresponds to the JSON property `currencyCode`
155
+ # @return [String]
156
+ attr_accessor :currency_code
157
+
158
+ # Custom dimensions for the conversion, which can be used to filter data in a
159
+ # report.
160
+ # Corresponds to the JSON property `customDimension`
161
+ # @return [Array<Google::Apis::DoubleclicksearchV2::CustomDimension>]
162
+ attr_accessor :custom_dimension
163
+
164
+ # Custom metrics for the conversion.
165
+ # Corresponds to the JSON property `customMetric`
166
+ # @return [Array<Google::Apis::DoubleclicksearchV2::CustomMetric>]
167
+ attr_accessor :custom_metric
168
+
169
+ # The type of device on which the conversion occurred.
170
+ # Corresponds to the JSON property `deviceType`
171
+ # @return [String]
172
+ attr_accessor :device_type
173
+
174
+ # ID that DoubleClick Search generates for each conversion.
175
+ # Corresponds to the JSON property `dsConversionId`
176
+ # @return [String]
177
+ attr_accessor :ds_conversion_id
178
+
179
+ # DS engine account ID.
180
+ # Corresponds to the JSON property `engineAccountId`
181
+ # @return [String]
182
+ attr_accessor :engine_account_id
183
+
184
+ # The Floodlight order ID provided by the advertiser for the conversion.
185
+ # Corresponds to the JSON property `floodlightOrderId`
186
+ # @return [String]
187
+ attr_accessor :floodlight_order_id
188
+
189
+ # ID that DS generates and uses to uniquely identify the inventory account that
190
+ # contains the product.
191
+ # Corresponds to the JSON property `inventoryAccountId`
192
+ # @return [String]
193
+ attr_accessor :inventory_account_id
194
+
195
+ # The country registered for the Merchant Center feed that contains the product.
196
+ # Use an ISO 3166 code to specify a country.
197
+ # Corresponds to the JSON property `productCountry`
198
+ # @return [String]
199
+ attr_accessor :product_country
200
+
201
+ # DS product group ID.
202
+ # Corresponds to the JSON property `productGroupId`
203
+ # @return [String]
204
+ attr_accessor :product_group_id
205
+
206
+ # The product ID (SKU).
207
+ # Corresponds to the JSON property `productId`
208
+ # @return [String]
209
+ attr_accessor :product_id
210
+
211
+ # The language registered for the Merchant Center feed that contains the product.
212
+ # Use an ISO 639 code to specify a language.
213
+ # Corresponds to the JSON property `productLanguage`
214
+ # @return [String]
215
+ attr_accessor :product_language
216
+
217
+ # The quantity of this conversion, in millis.
218
+ # Corresponds to the JSON property `quantityMillis`
219
+ # @return [String]
220
+ attr_accessor :quantity_millis
221
+
222
+ # The revenue amount of this TRANSACTION conversion, in micros.
223
+ # Corresponds to the JSON property `revenueMicros`
224
+ # @return [String]
225
+ attr_accessor :revenue_micros
226
+
227
+ # The numeric segmentation identifier (for example, DoubleClick Search
228
+ # Floodlight activity ID).
229
+ # Corresponds to the JSON property `segmentationId`
230
+ # @return [String]
231
+ attr_accessor :segmentation_id
232
+
233
+ # The friendly segmentation identifier (for example, DoubleClick Search
234
+ # Floodlight activity name).
235
+ # Corresponds to the JSON property `segmentationName`
236
+ # @return [String]
237
+ attr_accessor :segmentation_name
238
+
239
+ # The segmentation type of this conversion (for example, FLOODLIGHT).
240
+ # Corresponds to the JSON property `segmentationType`
241
+ # @return [String]
242
+ attr_accessor :segmentation_type
243
+
244
+ # The state of the conversion, that is, either ACTIVE or REMOVED. Note: state
245
+ # DELETED is deprecated.
246
+ # Corresponds to the JSON property `state`
247
+ # @return [String]
248
+ attr_accessor :state
249
+
250
+ # The ID of the local store for which the product was advertised. Applicable
251
+ # only when the channel is "local".
252
+ # Corresponds to the JSON property `storeId`
253
+ # @return [String]
254
+ attr_accessor :store_id
255
+
256
+ # The type of the conversion, that is, either ACTION or TRANSACTION. An ACTION
257
+ # conversion is an action by the user that has no monetarily quantifiable value,
258
+ # while a TRANSACTION conversion is an action that does have a monetarily
259
+ # quantifiable value. Examples are email list signups (ACTION) versus ecommerce
260
+ # purchases (TRANSACTION).
261
+ # Corresponds to the JSON property `type`
262
+ # @return [String]
263
+ attr_accessor :type
264
+
265
+ def initialize(**args)
266
+ update!(**args)
267
+ end
268
+
269
+ # Update properties of this object
270
+ def update!(**args)
271
+ @ad_group_id = args[:ad_group_id] unless args[:ad_group_id].nil?
272
+ @ad_id = args[:ad_id] unless args[:ad_id].nil?
273
+ @advertiser_id = args[:advertiser_id] unless args[:advertiser_id].nil?
274
+ @agency_id = args[:agency_id] unless args[:agency_id].nil?
275
+ @attribution_model = args[:attribution_model] unless args[:attribution_model].nil?
276
+ @campaign_id = args[:campaign_id] unless args[:campaign_id].nil?
277
+ @channel = args[:channel] unless args[:channel].nil?
278
+ @click_id = args[:click_id] unless args[:click_id].nil?
279
+ @conversion_id = args[:conversion_id] unless args[:conversion_id].nil?
280
+ @conversion_modified_timestamp = args[:conversion_modified_timestamp] unless args[:conversion_modified_timestamp].nil?
281
+ @conversion_timestamp = args[:conversion_timestamp] unless args[:conversion_timestamp].nil?
282
+ @count_millis = args[:count_millis] unless args[:count_millis].nil?
283
+ @criterion_id = args[:criterion_id] unless args[:criterion_id].nil?
284
+ @currency_code = args[:currency_code] unless args[:currency_code].nil?
285
+ @custom_dimension = args[:custom_dimension] unless args[:custom_dimension].nil?
286
+ @custom_metric = args[:custom_metric] unless args[:custom_metric].nil?
287
+ @device_type = args[:device_type] unless args[:device_type].nil?
288
+ @ds_conversion_id = args[:ds_conversion_id] unless args[:ds_conversion_id].nil?
289
+ @engine_account_id = args[:engine_account_id] unless args[:engine_account_id].nil?
290
+ @floodlight_order_id = args[:floodlight_order_id] unless args[:floodlight_order_id].nil?
291
+ @inventory_account_id = args[:inventory_account_id] unless args[:inventory_account_id].nil?
292
+ @product_country = args[:product_country] unless args[:product_country].nil?
293
+ @product_group_id = args[:product_group_id] unless args[:product_group_id].nil?
294
+ @product_id = args[:product_id] unless args[:product_id].nil?
295
+ @product_language = args[:product_language] unless args[:product_language].nil?
296
+ @quantity_millis = args[:quantity_millis] unless args[:quantity_millis].nil?
297
+ @revenue_micros = args[:revenue_micros] unless args[:revenue_micros].nil?
298
+ @segmentation_id = args[:segmentation_id] unless args[:segmentation_id].nil?
299
+ @segmentation_name = args[:segmentation_name] unless args[:segmentation_name].nil?
300
+ @segmentation_type = args[:segmentation_type] unless args[:segmentation_type].nil?
301
+ @state = args[:state] unless args[:state].nil?
302
+ @store_id = args[:store_id] unless args[:store_id].nil?
303
+ @type = args[:type] unless args[:type].nil?
304
+ end
305
+ end
306
+
307
+ # A list of conversions.
308
+ class ConversionList
309
+ include Google::Apis::Core::Hashable
310
+
311
+ # The conversions being requested.
312
+ # Corresponds to the JSON property `conversion`
313
+ # @return [Array<Google::Apis::DoubleclicksearchV2::Conversion>]
314
+ attr_accessor :conversion
315
+
316
+ # Identifies this as a ConversionList resource. Value: the fixed string
317
+ # doubleclicksearch#conversionList.
318
+ # Corresponds to the JSON property `kind`
319
+ # @return [String]
320
+ attr_accessor :kind
321
+
322
+ def initialize(**args)
323
+ update!(**args)
324
+ end
325
+
326
+ # Update properties of this object
327
+ def update!(**args)
328
+ @conversion = args[:conversion] unless args[:conversion].nil?
329
+ @kind = args[:kind] unless args[:kind].nil?
330
+ end
331
+ end
332
+
333
+ # A message containing the custome dimension.
334
+ class CustomDimension
335
+ include Google::Apis::Core::Hashable
336
+
337
+ # Custom dimension name.
338
+ # Corresponds to the JSON property `name`
339
+ # @return [String]
340
+ attr_accessor :name
341
+
342
+ # Custom dimension value.
343
+ # Corresponds to the JSON property `value`
344
+ # @return [String]
345
+ attr_accessor :value
346
+
347
+ def initialize(**args)
348
+ update!(**args)
349
+ end
350
+
351
+ # Update properties of this object
352
+ def update!(**args)
353
+ @name = args[:name] unless args[:name].nil?
354
+ @value = args[:value] unless args[:value].nil?
355
+ end
356
+ end
357
+
358
+ # A message containing the custome metric.
359
+ class CustomMetric
360
+ include Google::Apis::Core::Hashable
361
+
362
+ # Custom metric name.
363
+ # Corresponds to the JSON property `name`
364
+ # @return [String]
365
+ attr_accessor :name
366
+
367
+ # Custom metric numeric value.
368
+ # Corresponds to the JSON property `value`
369
+ # @return [Float]
370
+ attr_accessor :value
371
+
372
+ def initialize(**args)
373
+ update!(**args)
374
+ end
375
+
376
+ # Update properties of this object
377
+ def update!(**args)
378
+ @name = args[:name] unless args[:name].nil?
379
+ @value = args[:value] unless args[:value].nil?
380
+ end
381
+ end
382
+
383
+ # A DoubleClick Search report. This object contains the report request, some
384
+ # report metadata such as currency code, and the generated report rows or report
385
+ # files.
386
+ class Report
387
+ include Google::Apis::Core::Hashable
388
+
389
+ # Asynchronous report only. Contains a list of generated report files once the
390
+ # report has succesfully completed.
391
+ # Corresponds to the JSON property `files`
392
+ # @return [Array<Google::Apis::DoubleclicksearchV2::Report::File>]
393
+ attr_accessor :files
394
+
395
+ # Asynchronous report only. Id of the report.
396
+ # Corresponds to the JSON property `id`
397
+ # @return [String]
398
+ attr_accessor :id
399
+
400
+ # Asynchronous report only. True if and only if the report has completed
401
+ # successfully and the report files are ready to be downloaded.
402
+ # Corresponds to the JSON property `isReportReady`
403
+ # @return [Boolean]
404
+ attr_accessor :is_report_ready
405
+ alias_method :is_report_ready?, :is_report_ready
406
+
407
+ # Identifies this as a Report resource. Value: the fixed string
408
+ # doubleclicksearch#report.
409
+ # Corresponds to the JSON property `kind`
410
+ # @return [String]
411
+ attr_accessor :kind
412
+
413
+ # A request object used to create a DoubleClick Search report.
414
+ # Corresponds to the JSON property `request`
415
+ # @return [Google::Apis::DoubleclicksearchV2::ReportRequest]
416
+ attr_accessor :request
417
+
418
+ # The number of report rows generated by the report, not including headers.
419
+ # Corresponds to the JSON property `rowCount`
420
+ # @return [Fixnum]
421
+ attr_accessor :row_count
422
+
423
+ # Synchronous report only. Generated report rows.
424
+ # Corresponds to the JSON property `rows`
425
+ # @return [Array<Hash<String,Object>>]
426
+ attr_accessor :rows
427
+
428
+ # The currency code of all monetary values produced in the report, including
429
+ # values that are set by users (e.g., keyword bid settings) and metrics (e.g.,
430
+ # cost and revenue). The currency code of a report is determined by the
431
+ # statisticsCurrency field of the report request.
432
+ # Corresponds to the JSON property `statisticsCurrencyCode`
433
+ # @return [String]
434
+ attr_accessor :statistics_currency_code
435
+
436
+ # If all statistics of the report are sourced from the same time zone, this
437
+ # would be it. Otherwise the field is unset.
438
+ # Corresponds to the JSON property `statisticsTimeZone`
439
+ # @return [String]
440
+ attr_accessor :statistics_time_zone
441
+
442
+ def initialize(**args)
443
+ update!(**args)
444
+ end
445
+
446
+ # Update properties of this object
447
+ def update!(**args)
448
+ @files = args[:files] unless args[:files].nil?
449
+ @id = args[:id] unless args[:id].nil?
450
+ @is_report_ready = args[:is_report_ready] unless args[:is_report_ready].nil?
451
+ @kind = args[:kind] unless args[:kind].nil?
452
+ @request = args[:request] unless args[:request].nil?
453
+ @row_count = args[:row_count] unless args[:row_count].nil?
454
+ @rows = args[:rows] unless args[:rows].nil?
455
+ @statistics_currency_code = args[:statistics_currency_code] unless args[:statistics_currency_code].nil?
456
+ @statistics_time_zone = args[:statistics_time_zone] unless args[:statistics_time_zone].nil?
457
+ end
458
+
459
+ #
460
+ class File
461
+ include Google::Apis::Core::Hashable
462
+
463
+ # The size of this report file in bytes.
464
+ # Corresponds to the JSON property `byteCount`
465
+ # @return [String]
466
+ attr_accessor :byte_count
467
+
468
+ # Use this url to download the report file.
469
+ # Corresponds to the JSON property `url`
470
+ # @return [String]
471
+ attr_accessor :url
472
+
473
+ def initialize(**args)
474
+ update!(**args)
475
+ end
476
+
477
+ # Update properties of this object
478
+ def update!(**args)
479
+ @byte_count = args[:byte_count] unless args[:byte_count].nil?
480
+ @url = args[:url] unless args[:url].nil?
481
+ end
482
+ end
483
+ end
484
+
485
+ # A request object used to create a DoubleClick Search report.
486
+ class ReportApiColumnSpec
487
+ include Google::Apis::Core::Hashable
488
+
489
+ # Name of a DoubleClick Search column to include in the report.
490
+ # Corresponds to the JSON property `columnName`
491
+ # @return [String]
492
+ attr_accessor :column_name
493
+
494
+ # Segments a report by a custom dimension. The report must be scoped to an
495
+ # advertiser or lower, and the custom dimension must already be set up in
496
+ # DoubleClick Search. The custom dimension name, which appears in DoubleClick
497
+ # Search, is case sensitive.
498
+ # If used in a conversion report, returns the value of the specified custom
499
+ # dimension for the given conversion, if set. This column does not segment the
500
+ # conversion report.
501
+ # Corresponds to the JSON property `customDimensionName`
502
+ # @return [String]
503
+ attr_accessor :custom_dimension_name
504
+
505
+ # Name of a custom metric to include in the report. The report must be scoped to
506
+ # an advertiser or lower, and the custom metric must already be set up in
507
+ # DoubleClick Search. The custom metric name, which appears in DoubleClick
508
+ # Search, is case sensitive.
509
+ # Corresponds to the JSON property `customMetricName`
510
+ # @return [String]
511
+ attr_accessor :custom_metric_name
512
+
513
+ # Inclusive day in YYYY-MM-DD format. When provided, this overrides the overall
514
+ # time range of the report for this column only. Must be provided together with
515
+ # startDate.
516
+ # Corresponds to the JSON property `endDate`
517
+ # @return [String]
518
+ attr_accessor :end_date
519
+
520
+ # Synchronous report only. Set to true to group by this column. Defaults to
521
+ # false.
522
+ # Corresponds to the JSON property `groupByColumn`
523
+ # @return [Boolean]
524
+ attr_accessor :group_by_column
525
+ alias_method :group_by_column?, :group_by_column
526
+
527
+ # Text used to identify this column in the report output; defaults to columnName
528
+ # or savedColumnName when not specified. This can be used to prevent collisions
529
+ # between DoubleClick Search columns and saved columns with the same name.
530
+ # Corresponds to the JSON property `headerText`
531
+ # @return [String]
532
+ attr_accessor :header_text
533
+
534
+ # The platform that is used to provide data for the custom dimension. Acceptable
535
+ # values are "Floodlight".
536
+ # Corresponds to the JSON property `platformSource`
537
+ # @return [String]
538
+ attr_accessor :platform_source
539
+
540
+ # Name of a saved column to include in the report. The report must be scoped at
541
+ # advertiser or lower, and this saved column must already be created in the
542
+ # DoubleClick Search UI.
543
+ # Corresponds to the JSON property `savedColumnName`
544
+ # @return [String]
545
+ attr_accessor :saved_column_name
546
+
547
+ # Inclusive date in YYYY-MM-DD format. When provided, this overrides the overall
548
+ # time range of the report for this column only. Must be provided together with
549
+ # endDate.
550
+ # Corresponds to the JSON property `startDate`
551
+ # @return [String]
552
+ attr_accessor :start_date
553
+
554
+ def initialize(**args)
555
+ update!(**args)
556
+ end
557
+
558
+ # Update properties of this object
559
+ def update!(**args)
560
+ @column_name = args[:column_name] unless args[:column_name].nil?
561
+ @custom_dimension_name = args[:custom_dimension_name] unless args[:custom_dimension_name].nil?
562
+ @custom_metric_name = args[:custom_metric_name] unless args[:custom_metric_name].nil?
563
+ @end_date = args[:end_date] unless args[:end_date].nil?
564
+ @group_by_column = args[:group_by_column] unless args[:group_by_column].nil?
565
+ @header_text = args[:header_text] unless args[:header_text].nil?
566
+ @platform_source = args[:platform_source] unless args[:platform_source].nil?
567
+ @saved_column_name = args[:saved_column_name] unless args[:saved_column_name].nil?
568
+ @start_date = args[:start_date] unless args[:start_date].nil?
569
+ end
570
+ end
571
+
572
+ # A request object used to create a DoubleClick Search report.
573
+ class ReportRequest
574
+ include Google::Apis::Core::Hashable
575
+
576
+ # The columns to include in the report. This includes both DoubleClick Search
577
+ # columns and saved columns. For DoubleClick Search columns, only the columnName
578
+ # parameter is required. For saved columns only the savedColumnName parameter is
579
+ # required. Both columnName and savedColumnName cannot be set in the same stanza.
580
+ # Corresponds to the JSON property `columns`
581
+ # @return [Array<Google::Apis::DoubleclicksearchV2::ReportApiColumnSpec>]
582
+ attr_accessor :columns
583
+
584
+ # Format that the report should be returned in. Currently csv or tsv is
585
+ # supported.
586
+ # Corresponds to the JSON property `downloadFormat`
587
+ # @return [String]
588
+ attr_accessor :download_format
589
+
590
+ # A list of filters to be applied to the report.
591
+ # Corresponds to the JSON property `filters`
592
+ # @return [Array<Google::Apis::DoubleclicksearchV2::ReportRequest::Filter>]
593
+ attr_accessor :filters
594
+
595
+ # Determines if removed entities should be included in the report. Defaults to
596
+ # false. Deprecated, please use includeRemovedEntities instead.
597
+ # Corresponds to the JSON property `includeDeletedEntities`
598
+ # @return [Boolean]
599
+ attr_accessor :include_deleted_entities
600
+ alias_method :include_deleted_entities?, :include_deleted_entities
601
+
602
+ # Determines if removed entities should be included in the report. Defaults to
603
+ # false.
604
+ # Corresponds to the JSON property `includeRemovedEntities`
605
+ # @return [Boolean]
606
+ attr_accessor :include_removed_entities
607
+ alias_method :include_removed_entities?, :include_removed_entities
608
+
609
+ # Asynchronous report only. The maximum number of rows per report file. A large
610
+ # report is split into many files based on this field. Acceptable values are
611
+ # 1000000 to 100000000, inclusive.
612
+ # Corresponds to the JSON property `maxRowsPerFile`
613
+ # @return [Fixnum]
614
+ attr_accessor :max_rows_per_file
615
+
616
+ # Synchronous report only. A list of columns and directions defining sorting to
617
+ # be performed on the report rows.
618
+ # Corresponds to the JSON property `orderBy`
619
+ # @return [Array<Google::Apis::DoubleclicksearchV2::ReportRequest::OrderBy>]
620
+ attr_accessor :order_by
621
+
622
+ # The reportScope is a set of IDs that are used to determine which subset of
623
+ # entities will be returned in the report. The full lineage of IDs from the
624
+ # lowest scoped level desired up through agency is required.
625
+ # Corresponds to the JSON property `reportScope`
626
+ # @return [Google::Apis::DoubleclicksearchV2::ReportRequest::ReportScope]
627
+ attr_accessor :report_scope
628
+
629
+ # Determines the type of rows that are returned in the report. For example, if
630
+ # you specify reportType: keyword, each row in the report will contain data
631
+ # about a keyword. See the Types of Reports reference for the columns that are
632
+ # available for each type.
633
+ # Corresponds to the JSON property `reportType`
634
+ # @return [String]
635
+ attr_accessor :report_type
636
+
637
+ # Synchronous report only. The maxinum number of rows to return; additional rows
638
+ # are dropped. Acceptable values are 0 to 10000, inclusive. Defaults to 10000.
639
+ # Corresponds to the JSON property `rowCount`
640
+ # @return [Fixnum]
641
+ attr_accessor :row_count
642
+
643
+ # Synchronous report only. Zero-based index of the first row to return.
644
+ # Acceptable values are 0 to 50000, inclusive. Defaults to 0.
645
+ # Corresponds to the JSON property `startRow`
646
+ # @return [Fixnum]
647
+ attr_accessor :start_row
648
+
649
+ # Specifies the currency in which monetary will be returned. Possible values are:
650
+ # usd, agency (valid if the report is scoped to agency or lower), advertiser (
651
+ # valid if the report is scoped to * advertiser or lower), or account (valid if
652
+ # the report is scoped to engine account or lower).
653
+ # Corresponds to the JSON property `statisticsCurrency`
654
+ # @return [String]
655
+ attr_accessor :statistics_currency
656
+
657
+ # If metrics are requested in a report, this argument will be used to restrict
658
+ # the metrics to a specific time range.
659
+ # Corresponds to the JSON property `timeRange`
660
+ # @return [Google::Apis::DoubleclicksearchV2::ReportRequest::TimeRange]
661
+ attr_accessor :time_range
662
+
663
+ # If true, the report would only be created if all the requested stat data are
664
+ # sourced from a single timezone. Defaults to false.
665
+ # Corresponds to the JSON property `verifySingleTimeZone`
666
+ # @return [Boolean]
667
+ attr_accessor :verify_single_time_zone
668
+ alias_method :verify_single_time_zone?, :verify_single_time_zone
669
+
670
+ def initialize(**args)
671
+ update!(**args)
672
+ end
673
+
674
+ # Update properties of this object
675
+ def update!(**args)
676
+ @columns = args[:columns] unless args[:columns].nil?
677
+ @download_format = args[:download_format] unless args[:download_format].nil?
678
+ @filters = args[:filters] unless args[:filters].nil?
679
+ @include_deleted_entities = args[:include_deleted_entities] unless args[:include_deleted_entities].nil?
680
+ @include_removed_entities = args[:include_removed_entities] unless args[:include_removed_entities].nil?
681
+ @max_rows_per_file = args[:max_rows_per_file] unless args[:max_rows_per_file].nil?
682
+ @order_by = args[:order_by] unless args[:order_by].nil?
683
+ @report_scope = args[:report_scope] unless args[:report_scope].nil?
684
+ @report_type = args[:report_type] unless args[:report_type].nil?
685
+ @row_count = args[:row_count] unless args[:row_count].nil?
686
+ @start_row = args[:start_row] unless args[:start_row].nil?
687
+ @statistics_currency = args[:statistics_currency] unless args[:statistics_currency].nil?
688
+ @time_range = args[:time_range] unless args[:time_range].nil?
689
+ @verify_single_time_zone = args[:verify_single_time_zone] unless args[:verify_single_time_zone].nil?
690
+ end
691
+
692
+ #
693
+ class Filter
694
+ include Google::Apis::Core::Hashable
695
+
696
+ # A request object used to create a DoubleClick Search report.
697
+ # Corresponds to the JSON property `column`
698
+ # @return [Google::Apis::DoubleclicksearchV2::ReportApiColumnSpec]
699
+ attr_accessor :column
700
+
701
+ # Operator to use in the filter. See the filter reference for a list of
702
+ # available operators.
703
+ # Corresponds to the JSON property `operator`
704
+ # @return [String]
705
+ attr_accessor :operator
706
+
707
+ # A list of values to filter the column value against.
708
+ # Corresponds to the JSON property `values`
709
+ # @return [Array<Object>]
710
+ attr_accessor :values
711
+
712
+ def initialize(**args)
713
+ update!(**args)
714
+ end
715
+
716
+ # Update properties of this object
717
+ def update!(**args)
718
+ @column = args[:column] unless args[:column].nil?
719
+ @operator = args[:operator] unless args[:operator].nil?
720
+ @values = args[:values] unless args[:values].nil?
721
+ end
722
+ end
723
+
724
+ #
725
+ class OrderBy
726
+ include Google::Apis::Core::Hashable
727
+
728
+ # A request object used to create a DoubleClick Search report.
729
+ # Corresponds to the JSON property `column`
730
+ # @return [Google::Apis::DoubleclicksearchV2::ReportApiColumnSpec]
731
+ attr_accessor :column
732
+
733
+ # The sort direction, which is either ascending or descending.
734
+ # Corresponds to the JSON property `sortOrder`
735
+ # @return [String]
736
+ attr_accessor :sort_order
737
+
738
+ def initialize(**args)
739
+ update!(**args)
740
+ end
741
+
742
+ # Update properties of this object
743
+ def update!(**args)
744
+ @column = args[:column] unless args[:column].nil?
745
+ @sort_order = args[:sort_order] unless args[:sort_order].nil?
746
+ end
747
+ end
748
+
749
+ # The reportScope is a set of IDs that are used to determine which subset of
750
+ # entities will be returned in the report. The full lineage of IDs from the
751
+ # lowest scoped level desired up through agency is required.
752
+ class ReportScope
753
+ include Google::Apis::Core::Hashable
754
+
755
+ # DS ad group ID.
756
+ # Corresponds to the JSON property `adGroupId`
757
+ # @return [String]
758
+ attr_accessor :ad_group_id
759
+
760
+ # DS ad ID.
761
+ # Corresponds to the JSON property `adId`
762
+ # @return [String]
763
+ attr_accessor :ad_id
764
+
765
+ # DS advertiser ID.
766
+ # Corresponds to the JSON property `advertiserId`
767
+ # @return [String]
768
+ attr_accessor :advertiser_id
769
+
770
+ # DS agency ID.
771
+ # Corresponds to the JSON property `agencyId`
772
+ # @return [String]
773
+ attr_accessor :agency_id
774
+
775
+ # DS campaign ID.
776
+ # Corresponds to the JSON property `campaignId`
777
+ # @return [String]
778
+ attr_accessor :campaign_id
779
+
780
+ # DS engine account ID.
781
+ # Corresponds to the JSON property `engineAccountId`
782
+ # @return [String]
783
+ attr_accessor :engine_account_id
784
+
785
+ # DS keyword ID.
786
+ # Corresponds to the JSON property `keywordId`
787
+ # @return [String]
788
+ attr_accessor :keyword_id
789
+
790
+ def initialize(**args)
791
+ update!(**args)
792
+ end
793
+
794
+ # Update properties of this object
795
+ def update!(**args)
796
+ @ad_group_id = args[:ad_group_id] unless args[:ad_group_id].nil?
797
+ @ad_id = args[:ad_id] unless args[:ad_id].nil?
798
+ @advertiser_id = args[:advertiser_id] unless args[:advertiser_id].nil?
799
+ @agency_id = args[:agency_id] unless args[:agency_id].nil?
800
+ @campaign_id = args[:campaign_id] unless args[:campaign_id].nil?
801
+ @engine_account_id = args[:engine_account_id] unless args[:engine_account_id].nil?
802
+ @keyword_id = args[:keyword_id] unless args[:keyword_id].nil?
803
+ end
804
+ end
805
+
806
+ # If metrics are requested in a report, this argument will be used to restrict
807
+ # the metrics to a specific time range.
808
+ class TimeRange
809
+ include Google::Apis::Core::Hashable
810
+
811
+ # Inclusive UTC timestamp in RFC format, e.g., 2013-07-16T10:16:23.555Z. See
812
+ # additional references on how changed attribute reports work.
813
+ # Corresponds to the JSON property `changedAttributesSinceTimestamp`
814
+ # @return [DateTime]
815
+ attr_accessor :changed_attributes_since_timestamp
816
+
817
+ # Inclusive UTC timestamp in RFC format, e.g., 2013-07-16T10:16:23.555Z. See
818
+ # additional references on how changed metrics reports work.
819
+ # Corresponds to the JSON property `changedMetricsSinceTimestamp`
820
+ # @return [DateTime]
821
+ attr_accessor :changed_metrics_since_timestamp
822
+
823
+ # Inclusive date in YYYY-MM-DD format.
824
+ # Corresponds to the JSON property `endDate`
825
+ # @return [String]
826
+ attr_accessor :end_date
827
+
828
+ # Inclusive date in YYYY-MM-DD format.
829
+ # Corresponds to the JSON property `startDate`
830
+ # @return [String]
831
+ attr_accessor :start_date
832
+
833
+ def initialize(**args)
834
+ update!(**args)
835
+ end
836
+
837
+ # Update properties of this object
838
+ def update!(**args)
839
+ @changed_attributes_since_timestamp = args[:changed_attributes_since_timestamp] unless args[:changed_attributes_since_timestamp].nil?
840
+ @changed_metrics_since_timestamp = args[:changed_metrics_since_timestamp] unless args[:changed_metrics_since_timestamp].nil?
841
+ @end_date = args[:end_date] unless args[:end_date].nil?
842
+ @start_date = args[:start_date] unless args[:start_date].nil?
843
+ end
844
+ end
845
+ end
846
+
847
+ # A saved column
848
+ class SavedColumn
849
+ include Google::Apis::Core::Hashable
850
+
851
+ # Identifies this as a SavedColumn resource. Value: the fixed string
852
+ # doubleclicksearch#savedColumn.
853
+ # Corresponds to the JSON property `kind`
854
+ # @return [String]
855
+ attr_accessor :kind
856
+
857
+ # The name of the saved column.
858
+ # Corresponds to the JSON property `savedColumnName`
859
+ # @return [String]
860
+ attr_accessor :saved_column_name
861
+
862
+ # The type of data this saved column will produce.
863
+ # Corresponds to the JSON property `type`
864
+ # @return [String]
865
+ attr_accessor :type
866
+
867
+ def initialize(**args)
868
+ update!(**args)
869
+ end
870
+
871
+ # Update properties of this object
872
+ def update!(**args)
873
+ @kind = args[:kind] unless args[:kind].nil?
874
+ @saved_column_name = args[:saved_column_name] unless args[:saved_column_name].nil?
875
+ @type = args[:type] unless args[:type].nil?
876
+ end
877
+ end
878
+
879
+ # A list of saved columns. Advertisers create saved columns to report on
880
+ # Floodlight activities, Google Analytics goals, or custom KPIs. To request
881
+ # reports with saved columns, you'll need the saved column names that are
882
+ # available from this list.
883
+ class SavedColumnList
884
+ include Google::Apis::Core::Hashable
885
+
886
+ # The saved columns being requested.
887
+ # Corresponds to the JSON property `items`
888
+ # @return [Array<Google::Apis::DoubleclicksearchV2::SavedColumn>]
889
+ attr_accessor :items
890
+
891
+ # Identifies this as a SavedColumnList resource. Value: the fixed string
892
+ # doubleclicksearch#savedColumnList.
893
+ # Corresponds to the JSON property `kind`
894
+ # @return [String]
895
+ attr_accessor :kind
896
+
897
+ def initialize(**args)
898
+ update!(**args)
899
+ end
900
+
901
+ # Update properties of this object
902
+ def update!(**args)
903
+ @items = args[:items] unless args[:items].nil?
904
+ @kind = args[:kind] unless args[:kind].nil?
905
+ end
906
+ end
907
+
908
+ # The request to update availability.
909
+ class UpdateAvailabilityRequest
910
+ include Google::Apis::Core::Hashable
911
+
912
+ # The availabilities being requested.
913
+ # Corresponds to the JSON property `availabilities`
914
+ # @return [Array<Google::Apis::DoubleclicksearchV2::Availability>]
915
+ attr_accessor :availabilities
916
+
917
+ def initialize(**args)
918
+ update!(**args)
919
+ end
920
+
921
+ # Update properties of this object
922
+ def update!(**args)
923
+ @availabilities = args[:availabilities] unless args[:availabilities].nil?
924
+ end
925
+ end
926
+
927
+ # The response to a update availability request.
928
+ class UpdateAvailabilityResponse
929
+ include Google::Apis::Core::Hashable
930
+
931
+ # The availabilities being returned.
932
+ # Corresponds to the JSON property `availabilities`
933
+ # @return [Array<Google::Apis::DoubleclicksearchV2::Availability>]
934
+ attr_accessor :availabilities
935
+
936
+ def initialize(**args)
937
+ update!(**args)
938
+ end
939
+
940
+ # Update properties of this object
941
+ def update!(**args)
942
+ @availabilities = args[:availabilities] unless args[:availabilities].nil?
943
+ end
944
+ end
945
+ end
946
+ end
947
+ end