google-dfp-api 0.2.5 → 0.2.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (258) hide show
  1. data/ChangeLog +5 -0
  2. data/README +8 -7
  3. data/Rakefile +2 -2
  4. data/examples/v201111/common/error_handling.rb +76 -0
  5. data/examples/v201111/common/oauth_handling.rb +128 -0
  6. data/examples/v201111/company_service/create_companies.rb +81 -0
  7. data/examples/v201111/company_service/get_all_companies.rb +92 -0
  8. data/examples/v201111/company_service/get_companies_by_statement.rb +88 -0
  9. data/examples/v201111/company_service/get_company.rb +72 -0
  10. data/examples/v201111/company_service/update_companies.rb +95 -0
  11. data/examples/v201111/content_service/get_all_content.rb +94 -0
  12. data/examples/v201111/content_service/get_content_by_category.rb +136 -0
  13. data/examples/v201111/creative_service/copy_image_creatives.rb +115 -0
  14. data/examples/v201111/creative_service/create_creative_from_template.rb +139 -0
  15. data/examples/v201111/creative_service/create_creatives.rb +106 -0
  16. data/examples/v201111/creative_service/create_custom_creative.rb +104 -0
  17. data/examples/v201111/creative_service/get_all_creatives.rb +93 -0
  18. data/examples/v201111/creative_service/get_creative.rb +72 -0
  19. data/examples/v201111/creative_service/get_creatives_by_statement.rb +87 -0
  20. data/examples/v201111/creative_service/update_creatives.rb +96 -0
  21. data/examples/v201111/creative_template_service/get_all_creative_templates.rb +94 -0
  22. data/examples/v201111/creative_template_service/get_creative_template.rb +74 -0
  23. data/examples/v201111/creative_template_service/get_creative_templates_by_statement.rb +80 -0
  24. data/examples/v201111/custom_targeting_service/create_custom_targeting_keys_and_values.rb +140 -0
  25. data/examples/v201111/custom_targeting_service/delete_custom_targeting_keys.rb +121 -0
  26. data/examples/v201111/custom_targeting_service/delete_custom_targeting_values.rb +125 -0
  27. data/examples/v201111/custom_targeting_service/get_all_custom_targeting_keys_and_values.rb +148 -0
  28. data/examples/v201111/custom_targeting_service/get_custom_targeting_keys_by_statement.rb +92 -0
  29. data/examples/v201111/custom_targeting_service/get_custom_targeting_values_by_statement.rb +98 -0
  30. data/examples/v201111/custom_targeting_service/update_custom_targeting_keys.rb +94 -0
  31. data/examples/v201111/custom_targeting_service/update_custom_targeting_values.rb +106 -0
  32. data/examples/v201111/forecast_service/get_forecast.rb +107 -0
  33. data/examples/v201111/forecast_service/get_forecast_by_id.rb +80 -0
  34. data/examples/v201111/inventory_service/create_ad_units.rb +101 -0
  35. data/examples/v201111/inventory_service/create_mobile_ad_unit.rb +100 -0
  36. data/examples/v201111/inventory_service/create_video_ad_unit.rb +108 -0
  37. data/examples/v201111/inventory_service/deactivate_ad_units.rb +119 -0
  38. data/examples/v201111/inventory_service/get_ad_unit.rb +72 -0
  39. data/examples/v201111/inventory_service/get_ad_unit_sizes.rb +73 -0
  40. data/examples/v201111/inventory_service/get_ad_units_by_statement.rb +96 -0
  41. data/examples/v201111/inventory_service/get_all_ad_units.rb +93 -0
  42. data/examples/v201111/inventory_service/update_ad_units.rb +94 -0
  43. data/examples/v201111/label_service/create_labels.rb +83 -0
  44. data/examples/v201111/label_service/deactivate_labels.rb +118 -0
  45. data/examples/v201111/label_service/get_all_labels.rb +94 -0
  46. data/examples/v201111/label_service/get_label.rb +76 -0
  47. data/examples/v201111/label_service/get_labels_by_statement.rb +91 -0
  48. data/examples/v201111/label_service/update_labels.rb +104 -0
  49. data/examples/v201111/line_item_creative_association_service/create_licas.rb +94 -0
  50. data/examples/v201111/line_item_creative_association_service/deactivate_licas.rb +127 -0
  51. data/examples/v201111/line_item_creative_association_service/get_all_licas.rb +95 -0
  52. data/examples/v201111/line_item_creative_association_service/get_lica.rb +77 -0
  53. data/examples/v201111/line_item_creative_association_service/get_licas_by_statement.rb +91 -0
  54. data/examples/v201111/line_item_creative_association_service/update_licas.rb +92 -0
  55. data/examples/v201111/line_item_service/activate_line_items.rb +131 -0
  56. data/examples/v201111/line_item_service/create_line_items.rb +177 -0
  57. data/examples/v201111/line_item_service/create_mobile_line_item.rb +135 -0
  58. data/examples/v201111/line_item_service/create_video_line_item.rb +156 -0
  59. data/examples/v201111/line_item_service/get_all_line_items.rb +94 -0
  60. data/examples/v201111/line_item_service/get_line_item.rb +74 -0
  61. data/examples/v201111/line_item_service/get_line_items_by_statement.rb +89 -0
  62. data/examples/v201111/line_item_service/target_custom_criteria.rb +129 -0
  63. data/examples/v201111/line_item_service/update_line_items.rb +109 -0
  64. data/examples/v201111/network_service/get_all_networks.rb +74 -0
  65. data/examples/v201111/network_service/get_current_network.rb +66 -0
  66. data/examples/v201111/order_service/approve_orders.rb +116 -0
  67. data/examples/v201111/order_service/create_orders.rb +92 -0
  68. data/examples/v201111/order_service/get_all_orders.rb +93 -0
  69. data/examples/v201111/order_service/get_order.rb +74 -0
  70. data/examples/v201111/order_service/get_orders_by_statement.rb +90 -0
  71. data/examples/v201111/order_service/update_orders.rb +95 -0
  72. data/examples/v201111/placement_service/create_placements.rb +129 -0
  73. data/examples/v201111/placement_service/deactivate_placements.rb +118 -0
  74. data/examples/v201111/placement_service/get_all_placements.rb +93 -0
  75. data/examples/v201111/placement_service/get_placement.rb +74 -0
  76. data/examples/v201111/placement_service/get_placements_by_statement.rb +86 -0
  77. data/examples/v201111/placement_service/update_placements.rb +97 -0
  78. data/examples/v201111/publisher_query_language_service/get_all_bandwidth_groups.rb +85 -0
  79. data/examples/v201111/publisher_query_language_service/get_all_browser_languages.rb +85 -0
  80. data/examples/v201111/publisher_query_language_service/get_all_browsers.rb +85 -0
  81. data/examples/v201111/publisher_query_language_service/get_all_cities.rb +85 -0
  82. data/examples/v201111/publisher_query_language_service/get_all_countries.rb +85 -0
  83. data/examples/v201111/publisher_query_language_service/get_all_device_manufacturers.rb +85 -0
  84. data/examples/v201111/publisher_query_language_service/get_all_metros.rb +85 -0
  85. data/examples/v201111/publisher_query_language_service/get_all_mobile_carriers.rb +85 -0
  86. data/examples/v201111/publisher_query_language_service/get_all_mobile_device_submodels.rb +85 -0
  87. data/examples/v201111/publisher_query_language_service/get_all_mobile_devices.rb +85 -0
  88. data/examples/v201111/publisher_query_language_service/get_all_operating_system_versions.rb +85 -0
  89. data/examples/v201111/publisher_query_language_service/get_all_operating_systems.rb +85 -0
  90. data/examples/v201111/publisher_query_language_service/get_all_postal_codes.rb +85 -0
  91. data/examples/v201111/publisher_query_language_service/get_all_regions.rb +85 -0
  92. data/examples/v201111/report_service/download_report.rb +81 -0
  93. data/examples/v201111/report_service/run_delivery_report.rb +91 -0
  94. data/examples/v201111/report_service/run_inventory_report.rb +90 -0
  95. data/examples/v201111/report_service/run_merged_delivery_report.rb +94 -0
  96. data/examples/v201111/report_service/run_sales_report.rb +89 -0
  97. data/examples/v201111/suggested_ad_unit_service/approve_suggested_ad_units.rb +116 -0
  98. data/examples/v201111/suggested_ad_unit_service/get_all_suggested_ad_units.rb +96 -0
  99. data/examples/v201111/suggested_ad_unit_service/get_suggested_ad_unit.rb +75 -0
  100. data/examples/v201111/suggested_ad_unit_service/get_suggested_ad_units_by_statement.rb +91 -0
  101. data/examples/v201111/user_service/create_users.rb +89 -0
  102. data/examples/v201111/user_service/deactivate_users.rb +99 -0
  103. data/examples/v201111/user_service/get_all_roles.rb +73 -0
  104. data/examples/v201111/user_service/get_all_users.rb +92 -0
  105. data/examples/v201111/user_service/get_current_user.rb +66 -0
  106. data/examples/v201111/user_service/get_user.rb +73 -0
  107. data/examples/v201111/user_service/get_users_by_statement.rb +79 -0
  108. data/examples/v201111/user_service/update_users.rb +89 -0
  109. data/lib/dfp_api.rb +1 -1
  110. data/lib/dfp_api/api_config.rb +15 -6
  111. data/lib/dfp_api/v201103/company_service.rb +5 -5
  112. data/lib/dfp_api/v201103/company_service_registry.rb +3 -3
  113. data/lib/dfp_api/v201103/creative_service.rb +9 -9
  114. data/lib/dfp_api/v201103/creative_service_registry.rb +3 -3
  115. data/lib/dfp_api/v201103/custom_targeting_service.rb +17 -17
  116. data/lib/dfp_api/v201103/custom_targeting_service_registry.rb +3 -3
  117. data/lib/dfp_api/v201103/forecast_service.rb +1 -1
  118. data/lib/dfp_api/v201103/forecast_service_registry.rb +3 -3
  119. data/lib/dfp_api/v201103/inventory_service.rb +9 -9
  120. data/lib/dfp_api/v201103/inventory_service_registry.rb +3 -3
  121. data/lib/dfp_api/v201103/line_item_creative_association_service.rb +13 -13
  122. data/lib/dfp_api/v201103/line_item_creative_association_service_registry.rb +3 -3
  123. data/lib/dfp_api/v201103/line_item_service.rb +5 -5
  124. data/lib/dfp_api/v201103/line_item_service_registry.rb +3 -3
  125. data/lib/dfp_api/v201103/network_service.rb +1 -1
  126. data/lib/dfp_api/v201103/network_service_registry.rb +3 -3
  127. data/lib/dfp_api/v201103/order_service.rb +13 -13
  128. data/lib/dfp_api/v201103/order_service_registry.rb +3 -3
  129. data/lib/dfp_api/v201103/placement_service.rb +5 -5
  130. data/lib/dfp_api/v201103/placement_service_registry.rb +3 -3
  131. data/lib/dfp_api/v201103/publisher_query_language_service.rb +1 -1
  132. data/lib/dfp_api/v201103/publisher_query_language_service_registry.rb +3 -3
  133. data/lib/dfp_api/v201103/report_service.rb +5 -5
  134. data/lib/dfp_api/v201103/report_service_registry.rb +3 -3
  135. data/lib/dfp_api/v201103/user_service.rb +13 -13
  136. data/lib/dfp_api/v201103/user_service_registry.rb +3 -3
  137. data/lib/dfp_api/v201104/company_service.rb +5 -5
  138. data/lib/dfp_api/v201104/company_service_registry.rb +3 -3
  139. data/lib/dfp_api/v201104/creative_service.rb +9 -9
  140. data/lib/dfp_api/v201104/creative_service_registry.rb +3 -3
  141. data/lib/dfp_api/v201104/custom_targeting_service.rb +17 -17
  142. data/lib/dfp_api/v201104/custom_targeting_service_registry.rb +3 -3
  143. data/lib/dfp_api/v201104/forecast_service.rb +1 -1
  144. data/lib/dfp_api/v201104/forecast_service_registry.rb +3 -3
  145. data/lib/dfp_api/v201104/inventory_service.rb +9 -9
  146. data/lib/dfp_api/v201104/inventory_service_registry.rb +3 -3
  147. data/lib/dfp_api/v201104/line_item_creative_association_service.rb +13 -13
  148. data/lib/dfp_api/v201104/line_item_creative_association_service_registry.rb +3 -3
  149. data/lib/dfp_api/v201104/line_item_service.rb +5 -5
  150. data/lib/dfp_api/v201104/line_item_service_registry.rb +3 -3
  151. data/lib/dfp_api/v201104/network_service.rb +1 -1
  152. data/lib/dfp_api/v201104/network_service_registry.rb +3 -3
  153. data/lib/dfp_api/v201104/order_service.rb +13 -13
  154. data/lib/dfp_api/v201104/order_service_registry.rb +3 -3
  155. data/lib/dfp_api/v201104/placement_service.rb +5 -5
  156. data/lib/dfp_api/v201104/placement_service_registry.rb +3 -3
  157. data/lib/dfp_api/v201104/publisher_query_language_service.rb +1 -1
  158. data/lib/dfp_api/v201104/publisher_query_language_service_registry.rb +3 -3
  159. data/lib/dfp_api/v201104/report_service.rb +5 -5
  160. data/lib/dfp_api/v201104/report_service_registry.rb +3 -3
  161. data/lib/dfp_api/v201104/user_service.rb +13 -13
  162. data/lib/dfp_api/v201104/user_service_registry.rb +3 -3
  163. data/lib/dfp_api/v201107/company_service.rb +5 -5
  164. data/lib/dfp_api/v201107/company_service_registry.rb +3 -3
  165. data/lib/dfp_api/v201107/creative_service.rb +9 -9
  166. data/lib/dfp_api/v201107/creative_service_registry.rb +3 -3
  167. data/lib/dfp_api/v201107/custom_targeting_service.rb +17 -17
  168. data/lib/dfp_api/v201107/custom_targeting_service_registry.rb +3 -3
  169. data/lib/dfp_api/v201107/forecast_service.rb +1 -1
  170. data/lib/dfp_api/v201107/forecast_service_registry.rb +3 -3
  171. data/lib/dfp_api/v201107/inventory_service.rb +9 -9
  172. data/lib/dfp_api/v201107/inventory_service_registry.rb +3 -3
  173. data/lib/dfp_api/v201107/label_service.rb +5 -5
  174. data/lib/dfp_api/v201107/label_service_registry.rb +3 -3
  175. data/lib/dfp_api/v201107/line_item_creative_association_service.rb +13 -13
  176. data/lib/dfp_api/v201107/line_item_creative_association_service_registry.rb +3 -3
  177. data/lib/dfp_api/v201107/line_item_service.rb +5 -5
  178. data/lib/dfp_api/v201107/line_item_service_registry.rb +3 -3
  179. data/lib/dfp_api/v201107/network_service.rb +1 -1
  180. data/lib/dfp_api/v201107/network_service_registry.rb +3 -3
  181. data/lib/dfp_api/v201107/order_service.rb +13 -13
  182. data/lib/dfp_api/v201107/order_service_registry.rb +3 -3
  183. data/lib/dfp_api/v201107/placement_service.rb +5 -5
  184. data/lib/dfp_api/v201107/placement_service_registry.rb +3 -3
  185. data/lib/dfp_api/v201107/publisher_query_language_service.rb +1 -1
  186. data/lib/dfp_api/v201107/publisher_query_language_service_registry.rb +3 -3
  187. data/lib/dfp_api/v201107/report_service.rb +5 -5
  188. data/lib/dfp_api/v201107/report_service_registry.rb +3 -3
  189. data/lib/dfp_api/v201107/user_service.rb +13 -13
  190. data/lib/dfp_api/v201107/user_service_registry.rb +3 -3
  191. data/lib/dfp_api/v201108/company_service.rb +5 -5
  192. data/lib/dfp_api/v201108/company_service_registry.rb +3 -3
  193. data/lib/dfp_api/v201108/creative_service.rb +9 -9
  194. data/lib/dfp_api/v201108/creative_service_registry.rb +3 -3
  195. data/lib/dfp_api/v201108/custom_targeting_service.rb +17 -17
  196. data/lib/dfp_api/v201108/custom_targeting_service_registry.rb +3 -3
  197. data/lib/dfp_api/v201108/forecast_service.rb +1 -1
  198. data/lib/dfp_api/v201108/forecast_service_registry.rb +3 -3
  199. data/lib/dfp_api/v201108/inventory_service.rb +9 -9
  200. data/lib/dfp_api/v201108/inventory_service_registry.rb +3 -3
  201. data/lib/dfp_api/v201108/label_service.rb +5 -5
  202. data/lib/dfp_api/v201108/label_service_registry.rb +3 -3
  203. data/lib/dfp_api/v201108/line_item_creative_association_service.rb +13 -13
  204. data/lib/dfp_api/v201108/line_item_creative_association_service_registry.rb +3 -3
  205. data/lib/dfp_api/v201108/line_item_service.rb +5 -5
  206. data/lib/dfp_api/v201108/line_item_service_registry.rb +3 -3
  207. data/lib/dfp_api/v201108/network_service.rb +1 -1
  208. data/lib/dfp_api/v201108/network_service_registry.rb +3 -3
  209. data/lib/dfp_api/v201108/order_service.rb +13 -13
  210. data/lib/dfp_api/v201108/order_service_registry.rb +3 -3
  211. data/lib/dfp_api/v201108/placement_service.rb +5 -5
  212. data/lib/dfp_api/v201108/placement_service_registry.rb +3 -3
  213. data/lib/dfp_api/v201108/publisher_query_language_service.rb +1 -1
  214. data/lib/dfp_api/v201108/publisher_query_language_service_registry.rb +3 -3
  215. data/lib/dfp_api/v201108/report_service.rb +5 -5
  216. data/lib/dfp_api/v201108/report_service_registry.rb +3 -3
  217. data/lib/dfp_api/v201108/third_party_slot_service.rb +5 -5
  218. data/lib/dfp_api/v201108/third_party_slot_service_registry.rb +3 -3
  219. data/lib/dfp_api/v201108/user_service.rb +13 -13
  220. data/lib/dfp_api/v201108/user_service_registry.rb +3 -3
  221. data/lib/dfp_api/v201111/company_service.rb +52 -0
  222. data/lib/dfp_api/v201111/company_service_registry.rb +44 -0
  223. data/lib/dfp_api/v201111/content_service.rb +40 -0
  224. data/lib/dfp_api/v201111/content_service_registry.rb +44 -0
  225. data/lib/dfp_api/v201111/creative_service.rb +52 -0
  226. data/lib/dfp_api/v201111/creative_service_registry.rb +44 -0
  227. data/lib/dfp_api/v201111/creative_template_service.rb +36 -0
  228. data/lib/dfp_api/v201111/creative_template_service_registry.rb +44 -0
  229. data/lib/dfp_api/v201111/custom_targeting_service.rb +60 -0
  230. data/lib/dfp_api/v201111/custom_targeting_service_registry.rb +44 -0
  231. data/lib/dfp_api/v201111/forecast_service.rb +36 -0
  232. data/lib/dfp_api/v201111/forecast_service_registry.rb +44 -0
  233. data/lib/dfp_api/v201111/inventory_service.rb +60 -0
  234. data/lib/dfp_api/v201111/inventory_service_registry.rb +44 -0
  235. data/lib/dfp_api/v201111/label_service.rb +56 -0
  236. data/lib/dfp_api/v201111/label_service_registry.rb +44 -0
  237. data/lib/dfp_api/v201111/line_item_creative_association_service.rb +60 -0
  238. data/lib/dfp_api/v201111/line_item_creative_association_service_registry.rb +44 -0
  239. data/lib/dfp_api/v201111/line_item_service.rb +56 -0
  240. data/lib/dfp_api/v201111/line_item_service_registry.rb +44 -0
  241. data/lib/dfp_api/v201111/network_service.rb +40 -0
  242. data/lib/dfp_api/v201111/network_service_registry.rb +44 -0
  243. data/lib/dfp_api/v201111/order_service.rb +56 -0
  244. data/lib/dfp_api/v201111/order_service_registry.rb +44 -0
  245. data/lib/dfp_api/v201111/placement_service.rb +56 -0
  246. data/lib/dfp_api/v201111/placement_service_registry.rb +44 -0
  247. data/lib/dfp_api/v201111/publisher_query_language_service.rb +32 -0
  248. data/lib/dfp_api/v201111/publisher_query_language_service_registry.rb +44 -0
  249. data/lib/dfp_api/v201111/report_service.rb +40 -0
  250. data/lib/dfp_api/v201111/report_service_registry.rb +44 -0
  251. data/lib/dfp_api/v201111/suggested_ad_unit_service.rb +40 -0
  252. data/lib/dfp_api/v201111/suggested_ad_unit_service_registry.rb +44 -0
  253. data/lib/dfp_api/v201111/third_party_slot_service.rb +44 -0
  254. data/lib/dfp_api/v201111/third_party_slot_service_registry.rb +44 -0
  255. data/lib/dfp_api/v201111/user_service.rb +64 -0
  256. data/lib/dfp_api/v201111/user_service_registry.rb +44 -0
  257. data/test/bugs/test_issue_00000016.rb +3 -3
  258. metadata +149 -8
@@ -0,0 +1,44 @@
1
+ #!/usr/bin/ruby
2
+ # This is auto-generated code, changes will be overwritten.
3
+ # Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
4
+ # License:: Licensed under the Apache License,Version 2.0 (the "License").
5
+ #
6
+ # Code generated by AdsCommon library 0.6.0 on 2011-12-02 16:52:50.
7
+
8
+ require 'dfp_api/errors'
9
+
10
+ module DfpApi; module V201111; module ReportService
11
+ class ReportServiceRegistry
12
+ REPORTSERVICE_METHODS = {:get_report_download_url=>{:input=>[{:name=>:report_job_id, :type=>"long", :min_occurs=>0, :max_occurs=>1}, {:name=>:export_format, :type=>"ExportFormat", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"get_report_download_url_response", :fields=>[{:name=>:rval, :type=>"string", :min_occurs=>0, :max_occurs=>1}]}, :original_name=>"getReportDownloadURL"}, :get_report_job=>{:input=>[{:name=>:report_job_id, :type=>"long", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"get_report_job_response", :fields=>[{:name=>:rval, :type=>"ReportJob", :min_occurs=>0, :max_occurs=>1}]}}, :run_report_job=>{:input=>[{:name=>:report_job, :type=>"ReportJob", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"run_report_job_response", :fields=>[{:name=>:rval, :type=>"ReportJob", :min_occurs=>0, :max_occurs=>1}]}}}
13
+ REPORTSERVICE_TYPES = {:Authentication=>{:fields=>[{:name=>:authentication_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}, :ClientLogin=>{:fields=>[{:name=>:token, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Authentication"}, :Date=>{:fields=>[{:name=>:year, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:month, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:day, :type=>"int", :min_occurs=>0, :max_occurs=>1}]}, :OAuth=>{:fields=>[{:name=>:parameters, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Authentication"}, :ReportJob=>{:fields=>[{:name=>:id, :type=>"long", :min_occurs=>0, :max_occurs=>1}, {:name=>:report_query, :type=>"ReportQuery", :min_occurs=>0, :max_occurs=>1}, {:name=>:report_job_status, :type=>"ReportJobStatus", :min_occurs=>0, :max_occurs=>1}]}, :ReportQuery=>{:fields=>[{:name=>:dimensions, :type=>"Dimension", :min_occurs=>0, :max_occurs=>:unbounded}, {:name=>:columns, :type=>"Column", :min_occurs=>0, :max_occurs=>:unbounded}, {:name=>:dimension_attributes, :type=>"DimensionAttribute", :min_occurs=>0, :max_occurs=>:unbounded}, {:name=>:start_date, :type=>"Date", :min_occurs=>0, :max_occurs=>1}, {:name=>:end_date, :type=>"Date", :min_occurs=>0, :max_occurs=>1}, {:name=>:date_range_type, :type=>"DateRangeType", :min_occurs=>0, :max_occurs=>1}, {:name=>:dimension_filters, :type=>"DimensionFilter", :min_occurs=>0, :max_occurs=>:unbounded}]}, :SoapRequestHeader=>{:fields=>[{:name=>:network_code, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:application_name, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:authentication, :type=>"Authentication", :min_occurs=>0, :max_occurs=>1}]}, :SoapResponseHeader=>{:fields=>[{:name=>:request_id, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:response_time, :type=>"long", :min_occurs=>0, :max_occurs=>1}]}, :Column=>{:fields=>[]}, :DateRangeType=>{:fields=>[]}, :Dimension=>{:fields=>[]}, :DimensionAttribute=>{:fields=>[]}, :DimensionFilter=>{:fields=>[]}, :ExportFormat=>{:fields=>[]}, :ReportJobStatus=>{:fields=>[]}}
14
+ REPORTSERVICE_NAMESPACES = []
15
+
16
+ def self.get_method_signature(method_name)
17
+ return REPORTSERVICE_METHODS[method_name.to_sym]
18
+ end
19
+
20
+ def self.get_type_signature(type_name)
21
+ return REPORTSERVICE_TYPES[type_name.to_sym]
22
+ end
23
+
24
+ def self.get_namespace(index)
25
+ return REPORTSERVICE_NAMESPACES[index]
26
+ end
27
+ end
28
+
29
+ # Base class for exceptions.
30
+ class ApplicationException < DfpApi::Errors::ApiException
31
+ attr_reader :message # string
32
+ attr_reader :application_exception_type # string
33
+ end
34
+
35
+ # Exception class for holding a list of service errors.
36
+ class ApiException < ApplicationException
37
+ attr_reader :errors # ApiError
38
+ def initialize(exception_fault)
39
+ @array_fields ||= []
40
+ @array_fields << 'errors'
41
+ super(exception_fault)
42
+ end
43
+ end
44
+ end; end; end
@@ -0,0 +1,40 @@
1
+ #!/usr/bin/ruby
2
+ # This is auto-generated code, changes will be overwritten.
3
+ # Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
4
+ # License:: Licensed under the Apache License,Version 2.0 (the "License").
5
+ #
6
+ # Code generated by AdsCommon library 0.6.0 on 2011-12-02 16:53:02.
7
+
8
+ require 'ads_common/savon_service'
9
+ require 'dfp_api/v201111/suggested_ad_unit_service_registry'
10
+
11
+ module DfpApi; module V201111; module SuggestedAdUnitService
12
+ class SuggestedAdUnitService < AdsCommon::SavonService
13
+ def initialize(api, endpoint)
14
+ namespace = 'https://www.google.com/apis/ads/publisher/v201111'
15
+ super(api, endpoint, namespace, :v201111)
16
+ end
17
+
18
+ def get_suggested_ad_unit(*args, &block)
19
+ return execute_action('get_suggested_ad_unit', args, &block)
20
+ end
21
+
22
+ def get_suggested_ad_units_by_statement(*args, &block)
23
+ return execute_action('get_suggested_ad_units_by_statement', args, &block)
24
+ end
25
+
26
+ def perform_suggested_ad_unit_action(*args, &block)
27
+ return execute_action('perform_suggested_ad_unit_action', args, &block)
28
+ end
29
+
30
+ private
31
+
32
+ def get_service_registry()
33
+ return SuggestedAdUnitServiceRegistry
34
+ end
35
+
36
+ def get_module()
37
+ return DfpApi::V201111::SuggestedAdUnitService
38
+ end
39
+ end
40
+ end; end; end
@@ -0,0 +1,44 @@
1
+ #!/usr/bin/ruby
2
+ # This is auto-generated code, changes will be overwritten.
3
+ # Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
4
+ # License:: Licensed under the Apache License,Version 2.0 (the "License").
5
+ #
6
+ # Code generated by AdsCommon library 0.6.0 on 2011-12-02 16:53:02.
7
+
8
+ require 'dfp_api/errors'
9
+
10
+ module DfpApi; module V201111; module SuggestedAdUnitService
11
+ class SuggestedAdUnitServiceRegistry
12
+ SUGGESTEDADUNITSERVICE_METHODS = {:get_suggested_ad_unit=>{:input=>[{:name=>:suggested_ad_unit_id, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"get_suggested_ad_unit_response", :fields=>[{:name=>:rval, :type=>"SuggestedAdUnit", :min_occurs=>0, :max_occurs=>1}]}}, :get_suggested_ad_units_by_statement=>{:input=>[{:name=>:filter_statement, :type=>"Statement", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"get_suggested_ad_units_by_statement_response", :fields=>[{:name=>:rval, :type=>"SuggestedAdUnitPage", :min_occurs=>0, :max_occurs=>1}]}}, :perform_suggested_ad_unit_action=>{:input=>[{:name=>:suggested_ad_unit_action, :type=>"SuggestedAdUnitAction", :min_occurs=>0, :max_occurs=>1}, {:name=>:filter_statement, :type=>"Statement", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"perform_suggested_ad_unit_action_response", :fields=>[{:name=>:rval, :type=>"SuggestedAdUnitUpdateResult", :min_occurs=>0, :max_occurs=>1}]}}}
13
+ SUGGESTEDADUNITSERVICE_TYPES = {:ApproveSuggestedAdUnit=>{:fields=>[], :base=>"SuggestedAdUnitAction"}, :Authentication=>{:fields=>[{:name=>:authentication_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}, :BooleanValue=>{:fields=>[{:name=>:value, :type=>"boolean", :min_occurs=>0, :max_occurs=>1}], :base=>"Value"}, :ClientLogin=>{:fields=>[{:name=>:token, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Authentication"}, :AdUnitSize=>{:fields=>[{:name=>:size, :type=>"Size", :min_occurs=>0, :max_occurs=>1}, {:name=>:environment_type, :type=>"EnvironmentType", :min_occurs=>0, :max_occurs=>1}, {:name=>:companions, :type=>"AdUnitSize", :min_occurs=>0, :max_occurs=>:unbounded}]}, :NumberValue=>{:fields=>[{:name=>:value, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Value"}, :OAuth=>{:fields=>[{:name=>:parameters, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Authentication"}, :Size=>{:fields=>[{:name=>:width, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:height, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:is_aspect_ratio, :type=>"boolean", :min_occurs=>0, :max_occurs=>1}]}, :SoapRequestHeader=>{:fields=>[{:name=>:network_code, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:application_name, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:authentication, :type=>"Authentication", :min_occurs=>0, :max_occurs=>1}]}, :SoapResponseHeader=>{:fields=>[{:name=>:request_id, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:response_time, :type=>"long", :min_occurs=>0, :max_occurs=>1}]}, :Statement=>{:fields=>[{:name=>:query, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:values, :type=>"String_ValueMapEntry", :min_occurs=>0, :max_occurs=>:unbounded}]}, :String_ValueMapEntry=>{:fields=>[{:name=>:key, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:value, :type=>"Value", :min_occurs=>0, :max_occurs=>1}]}, :SuggestedAdUnitAction=>{:fields=>[{:name=>:suggested_ad_unit_action_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}, :SuggestedAdUnit=>{:fields=>[{:name=>:id, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:num_requests, :type=>"long", :min_occurs=>0, :max_occurs=>1}, {:name=>:path, :type=>"string", :min_occurs=>0, :max_occurs=>:unbounded}, {:name=>:target_window, :type=>"AdUnit.TargetWindow", :min_occurs=>0, :max_occurs=>1}, {:name=>:target_platform, :type=>"TargetPlatform", :min_occurs=>0, :max_occurs=>1}, {:name=>:suggested_ad_unit_sizes, :type=>"AdUnitSize", :min_occurs=>0, :max_occurs=>:unbounded}]}, :SuggestedAdUnitPage=>{:fields=>[{:name=>:total_result_set_size, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:start_index, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:results, :type=>"SuggestedAdUnit", :min_occurs=>0, :max_occurs=>:unbounded}]}, :SuggestedAdUnitUpdateResult=>{:fields=>[{:name=>:new_ad_unit_ids, :type=>"string", :min_occurs=>0, :max_occurs=>:unbounded}], :base=>"UpdateResult"}, :TextValue=>{:fields=>[{:name=>:value, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Value"}, :UpdateResult=>{:fields=>[{:name=>:num_changes, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:update_result_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}]}, :Value=>{:fields=>[{:name=>:value_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}, :"AdUnit.TargetWindow"=>{:fields=>[]}, :EnvironmentType=>{:fields=>[]}, :TargetPlatform=>{:fields=>[]}}
14
+ SUGGESTEDADUNITSERVICE_NAMESPACES = []
15
+
16
+ def self.get_method_signature(method_name)
17
+ return SUGGESTEDADUNITSERVICE_METHODS[method_name.to_sym]
18
+ end
19
+
20
+ def self.get_type_signature(type_name)
21
+ return SUGGESTEDADUNITSERVICE_TYPES[type_name.to_sym]
22
+ end
23
+
24
+ def self.get_namespace(index)
25
+ return SUGGESTEDADUNITSERVICE_NAMESPACES[index]
26
+ end
27
+ end
28
+
29
+ # Base class for exceptions.
30
+ class ApplicationException < DfpApi::Errors::ApiException
31
+ attr_reader :message # string
32
+ attr_reader :application_exception_type # string
33
+ end
34
+
35
+ # Exception class for holding a list of service errors.
36
+ class ApiException < ApplicationException
37
+ attr_reader :errors # ApiError
38
+ def initialize(exception_fault)
39
+ @array_fields ||= []
40
+ @array_fields << 'errors'
41
+ super(exception_fault)
42
+ end
43
+ end
44
+ end; end; end
@@ -0,0 +1,44 @@
1
+ #!/usr/bin/ruby
2
+ # This is auto-generated code, changes will be overwritten.
3
+ # Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
4
+ # License:: Licensed under the Apache License,Version 2.0 (the "License").
5
+ #
6
+ # Code generated by AdsCommon library 0.6.0 on 2011-12-02 16:53:00.
7
+
8
+ require 'ads_common/savon_service'
9
+ require 'dfp_api/v201111/third_party_slot_service_registry'
10
+
11
+ module DfpApi; module V201111; module ThirdPartySlotService
12
+ class ThirdPartySlotService < AdsCommon::SavonService
13
+ def initialize(api, endpoint)
14
+ namespace = 'https://www.google.com/apis/ads/publisher/v201111'
15
+ super(api, endpoint, namespace, :v201111)
16
+ end
17
+
18
+ def create_third_party_slot(*args, &block)
19
+ return execute_action('create_third_party_slot', args, &block)
20
+ end
21
+
22
+ def get_third_party_slots_by_statement(*args, &block)
23
+ return execute_action('get_third_party_slots_by_statement', args, &block)
24
+ end
25
+
26
+ def perform_third_party_slot_action(*args, &block)
27
+ return execute_action('perform_third_party_slot_action', args, &block)
28
+ end
29
+
30
+ def update_third_party_slot(*args, &block)
31
+ return execute_action('update_third_party_slot', args, &block)
32
+ end
33
+
34
+ private
35
+
36
+ def get_service_registry()
37
+ return ThirdPartySlotServiceRegistry
38
+ end
39
+
40
+ def get_module()
41
+ return DfpApi::V201111::ThirdPartySlotService
42
+ end
43
+ end
44
+ end; end; end
@@ -0,0 +1,44 @@
1
+ #!/usr/bin/ruby
2
+ # This is auto-generated code, changes will be overwritten.
3
+ # Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
4
+ # License:: Licensed under the Apache License,Version 2.0 (the "License").
5
+ #
6
+ # Code generated by AdsCommon library 0.6.0 on 2011-12-02 16:53:00.
7
+
8
+ require 'dfp_api/errors'
9
+
10
+ module DfpApi; module V201111; module ThirdPartySlotService
11
+ class ThirdPartySlotServiceRegistry
12
+ THIRDPARTYSLOTSERVICE_METHODS = {:create_third_party_slot=>{:input=>[{:name=>:third_party_slot, :type=>"ThirdPartySlot", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"create_third_party_slot_response", :fields=>[{:name=>:rval, :type=>"ThirdPartySlot", :min_occurs=>0, :max_occurs=>1}]}}, :get_third_party_slots_by_statement=>{:input=>[{:name=>:filter_statement, :type=>"Statement", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"get_third_party_slots_by_statement_response", :fields=>[{:name=>:rval, :type=>"ThirdPartySlotPage", :min_occurs=>0, :max_occurs=>1}]}}, :perform_third_party_slot_action=>{:input=>[{:name=>:third_party_slot_action, :type=>"ThirdPartySlotAction", :min_occurs=>0, :max_occurs=>1}, {:name=>:filter_statement, :type=>"Statement", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"perform_third_party_slot_action_response", :fields=>[{:name=>:rval, :type=>"UpdateResult", :min_occurs=>0, :max_occurs=>1}]}}, :update_third_party_slot=>{:input=>[{:name=>:third_party_slot, :type=>"ThirdPartySlot", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"update_third_party_slot_response", :fields=>[{:name=>:rval, :type=>"ThirdPartySlot", :min_occurs=>0, :max_occurs=>1}]}}}
13
+ THIRDPARTYSLOTSERVICE_TYPES = {:ActivateThirdPartySlots=>{:fields=>[], :base=>"ThirdPartySlotAction"}, :ArchiveThirdPartySlots=>{:fields=>[], :base=>"ThirdPartySlotAction"}, :Authentication=>{:fields=>[{:name=>:authentication_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}, :BooleanValue=>{:fields=>[{:name=>:value, :type=>"boolean", :min_occurs=>0, :max_occurs=>1}], :base=>"Value"}, :ClientLogin=>{:fields=>[{:name=>:token, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Authentication"}, :Entity=>{:fields=>[]}, :NumberValue=>{:fields=>[{:name=>:value, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Value"}, :OAuth=>{:fields=>[{:name=>:parameters, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Authentication"}, :Page=>{:fields=>[{:name=>:total_result_set_size, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:start_index, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:results, :type=>"Entity", :min_occurs=>0, :max_occurs=>:unbounded}, {:name=>:page_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}]}, :SoapRequestHeader=>{:fields=>[{:name=>:network_code, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:application_name, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:authentication, :type=>"Authentication", :min_occurs=>0, :max_occurs=>1}]}, :SoapResponseHeader=>{:fields=>[{:name=>:request_id, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:response_time, :type=>"long", :min_occurs=>0, :max_occurs=>1}]}, :Statement=>{:fields=>[{:name=>:query, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:values, :type=>"String_ValueMapEntry", :min_occurs=>0, :max_occurs=>:unbounded}]}, :String_ValueMapEntry=>{:fields=>[{:name=>:key, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:value, :type=>"Value", :min_occurs=>0, :max_occurs=>1}]}, :TextValue=>{:fields=>[{:name=>:value, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Value"}, :ThirdPartySlotAction=>{:fields=>[{:name=>:third_party_slot_action_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}, :ThirdPartySlot=>{:fields=>[{:name=>:id, :type=>"long", :min_occurs=>0, :max_occurs=>1}, {:name=>:creative_ids, :type=>"long", :min_occurs=>0, :max_occurs=>:unbounded}, {:name=>:company_id, :type=>"long", :min_occurs=>0, :max_occurs=>1}, {:name=>:external_unique_id, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:external_unique_name, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:description, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:status, :type=>"ThirdPartySlot.Status", :min_occurs=>0, :max_occurs=>1}]}, :ThirdPartySlotPage=>{:fields=>[], :base=>"Page"}, :UpdateResult=>{:fields=>[{:name=>:num_changes, :type=>"int", :min_occurs=>0, :max_occurs=>1}]}, :Value=>{:fields=>[{:name=>:value_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}, :"ThirdPartySlot.Status"=>{:fields=>[]}}
14
+ THIRDPARTYSLOTSERVICE_NAMESPACES = []
15
+
16
+ def self.get_method_signature(method_name)
17
+ return THIRDPARTYSLOTSERVICE_METHODS[method_name.to_sym]
18
+ end
19
+
20
+ def self.get_type_signature(type_name)
21
+ return THIRDPARTYSLOTSERVICE_TYPES[type_name.to_sym]
22
+ end
23
+
24
+ def self.get_namespace(index)
25
+ return THIRDPARTYSLOTSERVICE_NAMESPACES[index]
26
+ end
27
+ end
28
+
29
+ # Base class for exceptions.
30
+ class ApplicationException < DfpApi::Errors::ApiException
31
+ attr_reader :message # string
32
+ attr_reader :application_exception_type # string
33
+ end
34
+
35
+ # Exception class for holding a list of service errors.
36
+ class ApiException < ApplicationException
37
+ attr_reader :errors # ApiError
38
+ def initialize(exception_fault)
39
+ @array_fields ||= []
40
+ @array_fields << 'errors'
41
+ super(exception_fault)
42
+ end
43
+ end
44
+ end; end; end
@@ -0,0 +1,64 @@
1
+ #!/usr/bin/ruby
2
+ # This is auto-generated code, changes will be overwritten.
3
+ # Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
4
+ # License:: Licensed under the Apache License,Version 2.0 (the "License").
5
+ #
6
+ # Code generated by AdsCommon library 0.6.0 on 2011-12-02 16:52:52.
7
+
8
+ require 'ads_common/savon_service'
9
+ require 'dfp_api/v201111/user_service_registry'
10
+
11
+ module DfpApi; module V201111; module UserService
12
+ class UserService < AdsCommon::SavonService
13
+ def initialize(api, endpoint)
14
+ namespace = 'https://www.google.com/apis/ads/publisher/v201111'
15
+ super(api, endpoint, namespace, :v201111)
16
+ end
17
+
18
+ def create_user(*args, &block)
19
+ return execute_action('create_user', args, &block)
20
+ end
21
+
22
+ def create_users(*args, &block)
23
+ return execute_action('create_users', args, &block)
24
+ end
25
+
26
+ def get_all_roles(*args, &block)
27
+ return execute_action('get_all_roles', args, &block)
28
+ end
29
+
30
+ def get_current_user(*args, &block)
31
+ return execute_action('get_current_user', args, &block)
32
+ end
33
+
34
+ def get_user(*args, &block)
35
+ return execute_action('get_user', args, &block)
36
+ end
37
+
38
+ def get_users_by_statement(*args, &block)
39
+ return execute_action('get_users_by_statement', args, &block)
40
+ end
41
+
42
+ def perform_user_action(*args, &block)
43
+ return execute_action('perform_user_action', args, &block)
44
+ end
45
+
46
+ def update_user(*args, &block)
47
+ return execute_action('update_user', args, &block)
48
+ end
49
+
50
+ def update_users(*args, &block)
51
+ return execute_action('update_users', args, &block)
52
+ end
53
+
54
+ private
55
+
56
+ def get_service_registry()
57
+ return UserServiceRegistry
58
+ end
59
+
60
+ def get_module()
61
+ return DfpApi::V201111::UserService
62
+ end
63
+ end
64
+ end; end; end
@@ -0,0 +1,44 @@
1
+ #!/usr/bin/ruby
2
+ # This is auto-generated code, changes will be overwritten.
3
+ # Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
4
+ # License:: Licensed under the Apache License,Version 2.0 (the "License").
5
+ #
6
+ # Code generated by AdsCommon library 0.6.0 on 2011-12-02 16:52:52.
7
+
8
+ require 'dfp_api/errors'
9
+
10
+ module DfpApi; module V201111; module UserService
11
+ class UserServiceRegistry
12
+ USERSERVICE_METHODS = {:create_user=>{:input=>[{:name=>:user, :type=>"User", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"create_user_response", :fields=>[{:name=>:rval, :type=>"User", :min_occurs=>0, :max_occurs=>1}]}}, :create_users=>{:input=>[{:name=>:users, :type=>"User", :min_occurs=>0, :max_occurs=>:unbounded}], :output=>{:name=>"create_users_response", :fields=>[{:name=>:rval, :type=>"User", :min_occurs=>0, :max_occurs=>:unbounded}]}}, :get_all_roles=>{:input=>[], :output=>{:name=>"get_all_roles_response", :fields=>[{:name=>:rval, :type=>"Role", :min_occurs=>0, :max_occurs=>:unbounded}]}}, :get_current_user=>{:input=>[], :output=>{:name=>"get_current_user_response", :fields=>[{:name=>:rval, :type=>"User", :min_occurs=>0, :max_occurs=>1}]}}, :get_user=>{:input=>[{:name=>:user_id, :type=>"long", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"get_user_response", :fields=>[{:name=>:rval, :type=>"User", :min_occurs=>0, :max_occurs=>1}]}}, :get_users_by_statement=>{:input=>[{:name=>:filter_statement, :type=>"Statement", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"get_users_by_statement_response", :fields=>[{:name=>:rval, :type=>"UserPage", :min_occurs=>0, :max_occurs=>1}]}}, :perform_user_action=>{:input=>[{:name=>:user_action, :type=>"UserAction", :min_occurs=>0, :max_occurs=>1}, {:name=>:filter_statement, :type=>"Statement", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"perform_user_action_response", :fields=>[{:name=>:rval, :type=>"UpdateResult", :min_occurs=>0, :max_occurs=>1}]}}, :update_user=>{:input=>[{:name=>:user, :type=>"User", :min_occurs=>0, :max_occurs=>1}], :output=>{:name=>"update_user_response", :fields=>[{:name=>:rval, :type=>"User", :min_occurs=>0, :max_occurs=>1}]}}, :update_users=>{:input=>[{:name=>:users, :type=>"User", :min_occurs=>0, :max_occurs=>:unbounded}], :output=>{:name=>"update_users_response", :fields=>[{:name=>:rval, :type=>"User", :min_occurs=>0, :max_occurs=>:unbounded}]}}}
13
+ USERSERVICE_TYPES = {:ActivateUsers=>{:fields=>[], :base=>"UserAction"}, :Authentication=>{:fields=>[{:name=>:authentication_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}, :BooleanValue=>{:fields=>[{:name=>:value, :type=>"boolean", :min_occurs=>0, :max_occurs=>1}], :base=>"Value"}, :ClientLogin=>{:fields=>[{:name=>:token, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Authentication"}, :DeactivateUsers=>{:fields=>[], :base=>"UserAction"}, :NumberValue=>{:fields=>[{:name=>:value, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Value"}, :OAuth=>{:fields=>[{:name=>:parameters, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Authentication"}, :Role=>{:fields=>[{:name=>:id, :type=>"long", :min_occurs=>0, :max_occurs=>1}, {:name=>:name, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:description, :type=>"string", :min_occurs=>0, :max_occurs=>1}]}, :SoapRequestHeader=>{:fields=>[{:name=>:network_code, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:application_name, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:authentication, :type=>"Authentication", :min_occurs=>0, :max_occurs=>1}]}, :SoapResponseHeader=>{:fields=>[{:name=>:request_id, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:response_time, :type=>"long", :min_occurs=>0, :max_occurs=>1}]}, :Statement=>{:fields=>[{:name=>:query, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:values, :type=>"String_ValueMapEntry", :min_occurs=>0, :max_occurs=>:unbounded}]}, :String_ValueMapEntry=>{:fields=>[{:name=>:key, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:value, :type=>"Value", :min_occurs=>0, :max_occurs=>1}]}, :TextValue=>{:fields=>[{:name=>:value, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :base=>"Value"}, :UpdateResult=>{:fields=>[{:name=>:num_changes, :type=>"int", :min_occurs=>0, :max_occurs=>1}]}, :UserAction=>{:fields=>[{:name=>:user_action_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}, :User=>{:fields=>[{:name=>:is_active, :type=>"boolean", :min_occurs=>0, :max_occurs=>1}, {:name=>:is_email_notification_allowed, :type=>"boolean", :min_occurs=>0, :max_occurs=>1}], :base=>"UserRecord"}, :UserPage=>{:fields=>[{:name=>:total_result_set_size, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:start_index, :type=>"int", :min_occurs=>0, :max_occurs=>1}, {:name=>:results, :type=>"User", :min_occurs=>0, :max_occurs=>:unbounded}]}, :UserRecord=>{:fields=>[{:name=>:id, :type=>"long", :min_occurs=>0, :max_occurs=>1}, {:name=>:name, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:email, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:role_id, :type=>"long", :min_occurs=>0, :max_occurs=>1}, {:name=>:role_name, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:preferred_locale, :type=>"string", :min_occurs=>0, :max_occurs=>1}, {:name=>:user_record_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}]}, :Value=>{:fields=>[{:name=>:value_type, :type=>"string", :min_occurs=>0, :max_occurs=>1}], :abstract=>true}}
14
+ USERSERVICE_NAMESPACES = []
15
+
16
+ def self.get_method_signature(method_name)
17
+ return USERSERVICE_METHODS[method_name.to_sym]
18
+ end
19
+
20
+ def self.get_type_signature(type_name)
21
+ return USERSERVICE_TYPES[type_name.to_sym]
22
+ end
23
+
24
+ def self.get_namespace(index)
25
+ return USERSERVICE_NAMESPACES[index]
26
+ end
27
+ end
28
+
29
+ # Base class for exceptions.
30
+ class ApplicationException < DfpApi::Errors::ApiException
31
+ attr_reader :message # string
32
+ attr_reader :application_exception_type # string
33
+ end
34
+
35
+ # Exception class for holding a list of service errors.
36
+ class ApiException < ApplicationException
37
+ attr_reader :errors # ApiError
38
+ def initialize(exception_fault)
39
+ @array_fields ||= []
40
+ @array_fields << 'errors'
41
+ super(exception_fault)
42
+ end
43
+ end
44
+ end; end; end
@@ -22,11 +22,11 @@
22
22
  require 'rubygems'
23
23
  require 'test/unit'
24
24
  require 'dfp_api/errors'
25
- require 'dfp_api/v201108/line_item_service'
25
+ require 'dfp_api/v201111/line_item_service'
26
26
  require 'nori'
27
27
 
28
28
  class TestDfpApi < Test::Unit::TestCase
29
- class StubService < DfpApi::V201108::LineItemService::LineItemService
29
+ class StubService < DfpApi::V201111::LineItemService::LineItemService
30
30
  def stub_get_line_items_by_statement(xml_text)
31
31
  data = Nori.parse(xml_text)[:envelope][:body]
32
32
  return extract_result(data, 'get_line_items_by_statement')
@@ -37,7 +37,7 @@ class TestDfpApi < Test::Unit::TestCase
37
37
  assert_nothing_raised do
38
38
  service = StubService.new(
39
39
  DfpApi::Api.new,
40
- 'https://www.google.com/apis/ads/publisher/v201108/LineItemService')
40
+ 'https://www.google.com/apis/ads/publisher/v201111/LineItemService')
41
41
  result = service.stub_get_line_items_by_statement(get_xml_text)
42
42
  targeting = result[:results][0][:targeting][:inventory_targeting]
43
43
  assert_equal([1234567, 23456], targeting[:targeted_placement_ids])
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 2
8
- - 5
9
- version: 0.2.5
8
+ - 6
9
+ version: 0.2.6
10
10
  platform: ruby
11
11
  authors:
12
12
  - Danial Klimkin
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2011-11-02 00:00:00 +04:00
17
+ date: 2011-12-08 00:00:00 +04:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
@@ -27,9 +27,9 @@ dependencies:
27
27
  - !ruby/object:Gem::Version
28
28
  segments:
29
29
  - 0
30
- - 5
31
- - 4
32
- version: 0.5.4
30
+ - 6
31
+ - 0
32
+ version: 0.6.0
33
33
  type: :runtime
34
34
  version_requirements: *id001
35
35
  - !ruby/object:Gem::Dependency
@@ -43,8 +43,8 @@ dependencies:
43
43
  segments:
44
44
  - 0
45
45
  - 9
46
- - 6
47
- version: 0.9.6
46
+ - 7
47
+ version: 0.9.7
48
48
  type: :runtime
49
49
  version_requirements: *id002
50
50
  description: google-dfp-api is a DFP API client library for Ruby
@@ -172,6 +172,42 @@ files:
172
172
  - lib/dfp_api/v201108/publisher_query_language_service_registry.rb
173
173
  - lib/dfp_api/v201108/inventory_service.rb
174
174
  - lib/dfp_api/v201108/forecast_service_registry.rb
175
+ - lib/dfp_api/v201111/order_service.rb
176
+ - lib/dfp_api/v201111/third_party_slot_service_registry.rb
177
+ - lib/dfp_api/v201111/creative_template_service.rb
178
+ - lib/dfp_api/v201111/report_service_registry.rb
179
+ - lib/dfp_api/v201111/custom_targeting_service.rb
180
+ - lib/dfp_api/v201111/forecast_service.rb
181
+ - lib/dfp_api/v201111/content_service.rb
182
+ - lib/dfp_api/v201111/content_service_registry.rb
183
+ - lib/dfp_api/v201111/placement_service.rb
184
+ - lib/dfp_api/v201111/line_item_creative_association_service_registry.rb
185
+ - lib/dfp_api/v201111/suggested_ad_unit_service.rb
186
+ - lib/dfp_api/v201111/custom_targeting_service_registry.rb
187
+ - lib/dfp_api/v201111/user_service.rb
188
+ - lib/dfp_api/v201111/publisher_query_language_service.rb
189
+ - lib/dfp_api/v201111/inventory_service_registry.rb
190
+ - lib/dfp_api/v201111/creative_service_registry.rb
191
+ - lib/dfp_api/v201111/company_service.rb
192
+ - lib/dfp_api/v201111/user_service_registry.rb
193
+ - lib/dfp_api/v201111/order_service_registry.rb
194
+ - lib/dfp_api/v201111/suggested_ad_unit_service_registry.rb
195
+ - lib/dfp_api/v201111/company_service_registry.rb
196
+ - lib/dfp_api/v201111/creative_service.rb
197
+ - lib/dfp_api/v201111/line_item_service.rb
198
+ - lib/dfp_api/v201111/line_item_creative_association_service.rb
199
+ - lib/dfp_api/v201111/placement_service_registry.rb
200
+ - lib/dfp_api/v201111/creative_template_service_registry.rb
201
+ - lib/dfp_api/v201111/report_service.rb
202
+ - lib/dfp_api/v201111/label_service.rb
203
+ - lib/dfp_api/v201111/third_party_slot_service.rb
204
+ - lib/dfp_api/v201111/label_service_registry.rb
205
+ - lib/dfp_api/v201111/line_item_service_registry.rb
206
+ - lib/dfp_api/v201111/network_service_registry.rb
207
+ - lib/dfp_api/v201111/network_service.rb
208
+ - lib/dfp_api/v201111/publisher_query_language_service_registry.rb
209
+ - lib/dfp_api/v201111/inventory_service.rb
210
+ - lib/dfp_api/v201111/forecast_service_registry.rb
175
211
  - lib/dfp_api/errors.rb
176
212
  - lib/dfp_api.rb
177
213
  - examples/v201103/inventory_service/update_ad_units.rb
@@ -483,6 +519,111 @@ files:
483
519
  - examples/v201108/creative_service/get_creative.rb
484
520
  - examples/v201108/forecast_service/get_forecast.rb
485
521
  - examples/v201108/forecast_service/get_forecast_by_id.rb
522
+ - examples/v201111/suggested_ad_unit_service/get_suggested_ad_unit.rb
523
+ - examples/v201111/suggested_ad_unit_service/approve_suggested_ad_units.rb
524
+ - examples/v201111/suggested_ad_unit_service/get_all_suggested_ad_units.rb
525
+ - examples/v201111/suggested_ad_unit_service/get_suggested_ad_units_by_statement.rb
526
+ - examples/v201111/content_service/get_all_content.rb
527
+ - examples/v201111/content_service/get_content_by_category.rb
528
+ - examples/v201111/inventory_service/get_ad_unit_sizes.rb
529
+ - examples/v201111/inventory_service/update_ad_units.rb
530
+ - examples/v201111/inventory_service/get_ad_unit.rb
531
+ - examples/v201111/inventory_service/create_mobile_ad_unit.rb
532
+ - examples/v201111/inventory_service/create_video_ad_unit.rb
533
+ - examples/v201111/inventory_service/get_ad_units_by_statement.rb
534
+ - examples/v201111/inventory_service/deactivate_ad_units.rb
535
+ - examples/v201111/inventory_service/create_ad_units.rb
536
+ - examples/v201111/inventory_service/get_all_ad_units.rb
537
+ - examples/v201111/company_service/get_all_companies.rb
538
+ - examples/v201111/company_service/get_company.rb
539
+ - examples/v201111/company_service/get_companies_by_statement.rb
540
+ - examples/v201111/company_service/create_companies.rb
541
+ - examples/v201111/company_service/update_companies.rb
542
+ - examples/v201111/line_item_service/get_line_items_by_statement.rb
543
+ - examples/v201111/line_item_service/update_line_items.rb
544
+ - examples/v201111/line_item_service/activate_line_items.rb
545
+ - examples/v201111/line_item_service/get_all_line_items.rb
546
+ - examples/v201111/line_item_service/create_video_line_item.rb
547
+ - examples/v201111/line_item_service/create_line_items.rb
548
+ - examples/v201111/line_item_service/create_mobile_line_item.rb
549
+ - examples/v201111/line_item_service/target_custom_criteria.rb
550
+ - examples/v201111/line_item_service/get_line_item.rb
551
+ - examples/v201111/network_service/get_all_networks.rb
552
+ - examples/v201111/network_service/get_current_network.rb
553
+ - examples/v201111/label_service/get_label.rb
554
+ - examples/v201111/label_service/update_labels.rb
555
+ - examples/v201111/label_service/create_labels.rb
556
+ - examples/v201111/label_service/get_all_labels.rb
557
+ - examples/v201111/label_service/get_labels_by_statement.rb
558
+ - examples/v201111/label_service/deactivate_labels.rb
559
+ - examples/v201111/common/error_handling.rb
560
+ - examples/v201111/common/oauth_handling.rb
561
+ - examples/v201111/custom_targeting_service/delete_custom_targeting_values.rb
562
+ - examples/v201111/custom_targeting_service/create_custom_targeting_keys_and_values.rb
563
+ - examples/v201111/custom_targeting_service/delete_custom_targeting_keys.rb
564
+ - examples/v201111/custom_targeting_service/get_all_custom_targeting_keys_and_values.rb
565
+ - examples/v201111/custom_targeting_service/update_custom_targeting_values.rb
566
+ - examples/v201111/custom_targeting_service/update_custom_targeting_keys.rb
567
+ - examples/v201111/custom_targeting_service/get_custom_targeting_values_by_statement.rb
568
+ - examples/v201111/custom_targeting_service/get_custom_targeting_keys_by_statement.rb
569
+ - examples/v201111/line_item_creative_association_service/update_licas.rb
570
+ - examples/v201111/line_item_creative_association_service/create_licas.rb
571
+ - examples/v201111/line_item_creative_association_service/get_licas_by_statement.rb
572
+ - examples/v201111/line_item_creative_association_service/get_all_licas.rb
573
+ - examples/v201111/line_item_creative_association_service/deactivate_licas.rb
574
+ - examples/v201111/line_item_creative_association_service/get_lica.rb
575
+ - examples/v201111/publisher_query_language_service/get_all_countries.rb
576
+ - examples/v201111/publisher_query_language_service/get_all_cities.rb
577
+ - examples/v201111/publisher_query_language_service/get_all_regions.rb
578
+ - examples/v201111/publisher_query_language_service/get_all_operating_systems.rb
579
+ - examples/v201111/publisher_query_language_service/get_all_browsers.rb
580
+ - examples/v201111/publisher_query_language_service/get_all_mobile_device_submodels.rb
581
+ - examples/v201111/publisher_query_language_service/get_all_browser_languages.rb
582
+ - examples/v201111/publisher_query_language_service/get_all_mobile_carriers.rb
583
+ - examples/v201111/publisher_query_language_service/get_all_metros.rb
584
+ - examples/v201111/publisher_query_language_service/get_all_postal_codes.rb
585
+ - examples/v201111/publisher_query_language_service/get_all_operating_system_versions.rb
586
+ - examples/v201111/publisher_query_language_service/get_all_device_manufacturers.rb
587
+ - examples/v201111/publisher_query_language_service/get_all_bandwidth_groups.rb
588
+ - examples/v201111/publisher_query_language_service/get_all_mobile_devices.rb
589
+ - examples/v201111/report_service/run_sales_report.rb
590
+ - examples/v201111/report_service/download_report.rb
591
+ - examples/v201111/report_service/run_delivery_report.rb
592
+ - examples/v201111/report_service/run_inventory_report.rb
593
+ - examples/v201111/report_service/run_merged_delivery_report.rb
594
+ - examples/v201111/placement_service/get_placements_by_statement.rb
595
+ - examples/v201111/placement_service/update_placements.rb
596
+ - examples/v201111/placement_service/get_all_placements.rb
597
+ - examples/v201111/placement_service/create_placements.rb
598
+ - examples/v201111/placement_service/get_placement.rb
599
+ - examples/v201111/placement_service/deactivate_placements.rb
600
+ - examples/v201111/order_service/update_orders.rb
601
+ - examples/v201111/order_service/create_orders.rb
602
+ - examples/v201111/order_service/get_all_orders.rb
603
+ - examples/v201111/order_service/get_order.rb
604
+ - examples/v201111/order_service/get_orders_by_statement.rb
605
+ - examples/v201111/order_service/approve_orders.rb
606
+ - examples/v201111/user_service/update_users.rb
607
+ - examples/v201111/user_service/create_users.rb
608
+ - examples/v201111/user_service/get_all_roles.rb
609
+ - examples/v201111/user_service/get_user.rb
610
+ - examples/v201111/user_service/get_users_by_statement.rb
611
+ - examples/v201111/user_service/get_all_users.rb
612
+ - examples/v201111/user_service/deactivate_users.rb
613
+ - examples/v201111/user_service/get_current_user.rb
614
+ - examples/v201111/creative_template_service/get_creative_templates_by_statement.rb
615
+ - examples/v201111/creative_template_service/get_creative_template.rb
616
+ - examples/v201111/creative_template_service/get_all_creative_templates.rb
617
+ - examples/v201111/creative_service/create_creatives.rb
618
+ - examples/v201111/creative_service/get_creatives_by_statement.rb
619
+ - examples/v201111/creative_service/update_creatives.rb
620
+ - examples/v201111/creative_service/get_all_creatives.rb
621
+ - examples/v201111/creative_service/copy_image_creatives.rb
622
+ - examples/v201111/creative_service/create_custom_creative.rb
623
+ - examples/v201111/creative_service/get_creative.rb
624
+ - examples/v201111/creative_service/create_creative_from_template.rb
625
+ - examples/v201111/forecast_service/get_forecast.rb
626
+ - examples/v201111/forecast_service/get_forecast_by_id.rb
486
627
  - Rakefile
487
628
  - test/bugs/test_issue_00000016.rb
488
629
  - test/dfp_api/test_dfp_api.rb