ysm4r 0.1

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 (124) hide show
  1. data/Authors.txt +2 -0
  2. data/ChangeLog.txt +1 -0
  3. data/License.txt +13 -0
  4. data/Rakefile +209 -0
  5. data/Readme.txt +4 -0
  6. data/clean.sh +3 -0
  7. data/lib/soapex/driver.rb +13 -0
  8. data/lib/soapex/error.rb +49 -0
  9. data/lib/soapex/mapping.rb +31 -0
  10. data/lib/soapex/wsdl2ruby.rb +166 -0
  11. data/lib/ysm4r.rb +4 -0
  12. data/lib/ysm4r/client.rb +120 -0
  13. data/lib/ysm4r/service.rb +68 -0
  14. data/lib/ysm4r/v1/AccountService.rb +370 -0
  15. data/lib/ysm4r/v1/AccountServiceDriver.rb +162 -0
  16. data/lib/ysm4r/v1/AccountServiceMappingRegistry.rb +509 -0
  17. data/lib/ysm4r/v1/AdGroupService.rb +649 -0
  18. data/lib/ysm4r/v1/AdGroupServiceDriver.rb +226 -0
  19. data/lib/ysm4r/v1/AdGroupServiceMappingRegistry.rb +864 -0
  20. data/lib/ysm4r/v1/AdService.rb +533 -0
  21. data/lib/ysm4r/v1/AdServiceDriver.rb +178 -0
  22. data/lib/ysm4r/v1/AdServiceMappingRegistry.rb +753 -0
  23. data/lib/ysm4r/v1/BasicReportService.rb +259 -0
  24. data/lib/ysm4r/v1/BasicReportServiceDriver.rb +98 -0
  25. data/lib/ysm4r/v1/BasicReportServiceMappingRegistry.rb +389 -0
  26. data/lib/ysm4r/v1/BidInformationService.rb +69 -0
  27. data/lib/ysm4r/v1/BidInformationServiceDriver.rb +50 -0
  28. data/lib/ysm4r/v1/BidInformationServiceMappingRegistry.rb +135 -0
  29. data/lib/ysm4r/v1/BudgetingService.rb +161 -0
  30. data/lib/ysm4r/v1/BudgetingServiceDriver.rb +98 -0
  31. data/lib/ysm4r/v1/BudgetingServiceMappingRegistry.rb +230 -0
  32. data/lib/ysm4r/v1/CampaignService.rb +644 -0
  33. data/lib/ysm4r/v1/CampaignServiceDriver.rb +210 -0
  34. data/lib/ysm4r/v1/CampaignServiceMappingRegistry.rb +909 -0
  35. data/lib/ysm4r/v1/ExcludedWordsService.rb +294 -0
  36. data/lib/ysm4r/v1/ExcludedWordsServiceDriver.rb +122 -0
  37. data/lib/ysm4r/v1/ExcludedWordsServiceMappingRegistry.rb +469 -0
  38. data/lib/ysm4r/v1/ForecastService.rb +200 -0
  39. data/lib/ysm4r/v1/ForecastServiceDriver.rb +66 -0
  40. data/lib/ysm4r/v1/ForecastServiceMappingRegistry.rb +359 -0
  41. data/lib/ysm4r/v1/KeywordResearchService.rb +290 -0
  42. data/lib/ysm4r/v1/KeywordResearchServiceDriver.rb +66 -0
  43. data/lib/ysm4r/v1/KeywordResearchServiceMappingRegistry.rb +548 -0
  44. data/lib/ysm4r/v1/KeywordService.rb +671 -0
  45. data/lib/ysm4r/v1/KeywordServiceDriver.rb +218 -0
  46. data/lib/ysm4r/v1/KeywordServiceMappingRegistry.rb +913 -0
  47. data/lib/ysm4r/v1/LocationService.rb +53 -0
  48. data/lib/ysm4r/v1/LocationServiceDriver.rb +50 -0
  49. data/lib/ysm4r/v1/LocationServiceMappingRegistry.rb +111 -0
  50. data/lib/ysm4r/v1/MasterAccountService.rb +289 -0
  51. data/lib/ysm4r/v1/MasterAccountServiceDriver.rb +74 -0
  52. data/lib/ysm4r/v1/MasterAccountServiceMappingRegistry.rb +414 -0
  53. data/lib/ysm4r/v1/UpgradeService.rb +72 -0
  54. data/lib/ysm4r/v1/UpgradeServiceDriver.rb +58 -0
  55. data/lib/ysm4r/v1/UpgradeServiceMappingRegistry.rb +145 -0
  56. data/lib/ysm4r/v1/UserManagementService.rb +766 -0
  57. data/lib/ysm4r/v1/UserManagementServiceDriver.rb +290 -0
  58. data/lib/ysm4r/v1/UserManagementServiceMappingRegistry.rb +1057 -0
  59. data/lib/ysm4r/v1/sandbox/LocationService.rb +53 -0
  60. data/lib/ysm4r/v1/sandbox/LocationServiceDriver.rb +50 -0
  61. data/lib/ysm4r/v1/sandbox/LocationServiceMappingRegistry.rb +111 -0
  62. data/lib/ysm4r/v1/sandbox/UpgradeService.rb +72 -0
  63. data/lib/ysm4r/v1/sandbox/UpgradeServiceDriver.rb +58 -0
  64. data/lib/ysm4r/v1/sandbox/UpgradeServiceMappingRegistry.rb +145 -0
  65. data/lib/ysm4r/v2/AccountService.rb +372 -0
  66. data/lib/ysm4r/v2/AccountServiceDriver.rb +162 -0
  67. data/lib/ysm4r/v2/AccountServiceMappingRegistry.rb +510 -0
  68. data/lib/ysm4r/v2/AdGroupService.rb +649 -0
  69. data/lib/ysm4r/v2/AdGroupServiceDriver.rb +226 -0
  70. data/lib/ysm4r/v2/AdGroupServiceMappingRegistry.rb +864 -0
  71. data/lib/ysm4r/v2/AdService.rb +553 -0
  72. data/lib/ysm4r/v2/AdServiceDriver.rb +186 -0
  73. data/lib/ysm4r/v2/AdServiceMappingRegistry.rb +774 -0
  74. data/lib/ysm4r/v2/BasicReportService.rb +272 -0
  75. data/lib/ysm4r/v2/BasicReportServiceDriver.rb +98 -0
  76. data/lib/ysm4r/v2/BasicReportServiceMappingRegistry.rb +389 -0
  77. data/lib/ysm4r/v2/BidInformationService.rb +109 -0
  78. data/lib/ysm4r/v2/BidInformationServiceDriver.rb +66 -0
  79. data/lib/ysm4r/v2/BidInformationServiceMappingRegistry.rb +177 -0
  80. data/lib/ysm4r/v2/BudgetingService.rb +161 -0
  81. data/lib/ysm4r/v2/BudgetingServiceDriver.rb +98 -0
  82. data/lib/ysm4r/v2/BudgetingServiceMappingRegistry.rb +230 -0
  83. data/lib/ysm4r/v2/CampaignService.rb +644 -0
  84. data/lib/ysm4r/v2/CampaignServiceDriver.rb +210 -0
  85. data/lib/ysm4r/v2/CampaignServiceMappingRegistry.rb +909 -0
  86. data/lib/ysm4r/v2/CompanyService.rb +68 -0
  87. data/lib/ysm4r/v2/CompanyServiceDriver.rb +50 -0
  88. data/lib/ysm4r/v2/CompanyServiceMappingRegistry.rb +136 -0
  89. data/lib/ysm4r/v2/ExcludedWordsService.rb +294 -0
  90. data/lib/ysm4r/v2/ExcludedWordsServiceDriver.rb +122 -0
  91. data/lib/ysm4r/v2/ExcludedWordsServiceMappingRegistry.rb +469 -0
  92. data/lib/ysm4r/v2/ForecastService.rb +200 -0
  93. data/lib/ysm4r/v2/ForecastServiceDriver.rb +66 -0
  94. data/lib/ysm4r/v2/ForecastServiceMappingRegistry.rb +359 -0
  95. data/lib/ysm4r/v2/KeywordResearchService.rb +369 -0
  96. data/lib/ysm4r/v2/KeywordResearchServiceDriver.rb +82 -0
  97. data/lib/ysm4r/v2/KeywordResearchServiceMappingRegistry.rb +673 -0
  98. data/lib/ysm4r/v2/KeywordService.rb +691 -0
  99. data/lib/ysm4r/v2/KeywordServiceDriver.rb +226 -0
  100. data/lib/ysm4r/v2/KeywordServiceMappingRegistry.rb +934 -0
  101. data/lib/ysm4r/v2/LocationService.rb +53 -0
  102. data/lib/ysm4r/v2/LocationServiceDriver.rb +50 -0
  103. data/lib/ysm4r/v2/LocationServiceMappingRegistry.rb +111 -0
  104. data/lib/ysm4r/v2/MasterAccountService.rb +332 -0
  105. data/lib/ysm4r/v2/MasterAccountServiceDriver.rb +82 -0
  106. data/lib/ysm4r/v2/MasterAccountServiceMappingRegistry.rb +480 -0
  107. data/lib/ysm4r/v2/UpgradeService.rb +72 -0
  108. data/lib/ysm4r/v2/UpgradeServiceDriver.rb +58 -0
  109. data/lib/ysm4r/v2/UpgradeServiceMappingRegistry.rb +145 -0
  110. data/lib/ysm4r/v2/UserManagementService.rb +766 -0
  111. data/lib/ysm4r/v2/UserManagementServiceDriver.rb +290 -0
  112. data/lib/ysm4r/v2/UserManagementServiceMappingRegistry.rb +1057 -0
  113. data/lib/ysm4r/v2/sandbox/LocationService.rb +53 -0
  114. data/lib/ysm4r/v2/sandbox/LocationServiceDriver.rb +50 -0
  115. data/lib/ysm4r/v2/sandbox/LocationServiceMappingRegistry.rb +111 -0
  116. data/lib/ysm4r/v2/sandbox/UpgradeService.rb +72 -0
  117. data/lib/ysm4r/v2/sandbox/UpgradeServiceDriver.rb +58 -0
  118. data/lib/ysm4r/v2/sandbox/UpgradeServiceMappingRegistry.rb +145 -0
  119. data/setup.rb +1585 -0
  120. data/test/test_campaign_service.rb +12 -0
  121. data/test/test_keyword_research_service.rb +15 -0
  122. data/test/test_master_account_service.rb +18 -0
  123. data/ysm.properties +6 -0
  124. metadata +171 -0
@@ -0,0 +1,259 @@
1
+ require 'xsd/qname'
2
+
3
+ module YSM::BasicReportService
4
+
5
+
6
+ # {http://marketing.ews.yahooapis.com/V1}FileOutputFormat
7
+ class FileOutputFormat
8
+ attr_accessor :fileOutputType
9
+ attr_accessor :zipped
10
+
11
+ def initialize(fileOutputType = nil, zipped = nil)
12
+ @fileOutputType = fileOutputType
13
+ @zipped = zipped
14
+ end
15
+ end
16
+
17
+ # {http://marketing.ews.yahooapis.com/V1}ApiFault
18
+ class ApiFault < ::StandardError
19
+ attr_accessor :code
20
+ attr_accessor :message
21
+
22
+ def initialize(code = nil, message = nil)
23
+ @code = code
24
+ @message = message
25
+ end
26
+ end
27
+
28
+ # {http://marketing.ews.yahooapis.com/V1}BasicReportRequest
29
+ class BasicReportRequest
30
+ attr_accessor :dateRange
31
+ attr_accessor :endDate
32
+ attr_accessor :reportName
33
+ attr_accessor :reportType
34
+ attr_accessor :startDate
35
+
36
+ def initialize(dateRange = nil, endDate = nil, reportName = nil, reportType = nil, startDate = nil)
37
+ @dateRange = dateRange
38
+ @endDate = endDate
39
+ @reportName = reportName
40
+ @reportType = reportType
41
+ @startDate = startDate
42
+ end
43
+ end
44
+
45
+ # {http://marketing.ews.yahooapis.com/V1}ArrayOfInt
46
+ class ArrayOfInt < ::Array
47
+ end
48
+
49
+ # {http://marketing.ews.yahooapis.com/V1}ArrayOfReportInfo
50
+ class ArrayOfReportInfo < ::Array
51
+ end
52
+
53
+ # {http://marketing.ews.yahooapis.com/V1}ReportInfo
54
+ class ReportInfo
55
+ attr_accessor :createDate
56
+ attr_accessor :reportID
57
+ attr_accessor :reportName
58
+ attr_accessor :status
59
+
60
+ def initialize(createDate = nil, reportID = nil, reportName = nil, status = nil)
61
+ @createDate = createDate
62
+ @reportID = reportID
63
+ @reportName = reportName
64
+ @status = status
65
+ end
66
+ end
67
+
68
+ # {http://marketing.ews.yahooapis.com/V1}ArrayOfString
69
+ class ArrayOfString < ::Array
70
+ end
71
+
72
+ # {http://schemas.xmlsoap.org/ws/2002/07/secext}Security
73
+ class Security
74
+ attr_accessor :usernameToken
75
+
76
+ def initialize(usernameToken = nil)
77
+ @usernameToken = usernameToken
78
+ end
79
+ end
80
+
81
+ # {http://schemas.xmlsoap.org/ws/2002/07/secext}UsernameToken
82
+ class UsernameToken
83
+ attr_accessor :username
84
+ attr_accessor :password
85
+
86
+ def initialize(username = nil, password = nil)
87
+ @username = username
88
+ @password = password
89
+ end
90
+ end
91
+
92
+ # {http://marketing.ews.yahooapis.com/V1}FileOutputType
93
+ class FileOutputType < ::String
94
+ CSV = FileOutputType.new("CSV")
95
+ CSV_EXCEL = FileOutputType.new("CSV_EXCEL")
96
+ TSV = FileOutputType.new("TSV")
97
+ XML = FileOutputType.new("XML")
98
+ end
99
+
100
+ # {http://marketing.ews.yahooapis.com/V1}DateRange
101
+ class DateRange < ::String
102
+ Last30Days = DateRange.new("Last30Days")
103
+ Last7Days = DateRange.new("Last7Days")
104
+ LastBusinessWeek = DateRange.new("LastBusinessWeek")
105
+ LastCalendarMonth = DateRange.new("LastCalendarMonth")
106
+ LastCalendarQuarter = DateRange.new("LastCalendarQuarter")
107
+ LastCalendarWeek = DateRange.new("LastCalendarWeek")
108
+ MonthToDate = DateRange.new("MonthToDate")
109
+ WeekToDate = DateRange.new("WeekToDate")
110
+ YearToDate = DateRange.new("YearToDate")
111
+ Yesterday = DateRange.new("Yesterday")
112
+ end
113
+
114
+ # {http://marketing.ews.yahooapis.com/V1}BasicReportType
115
+ class BasicReportType < ::String
116
+ AccountSummary = BasicReportType.new("AccountSummary")
117
+ AdGroupSummary = BasicReportType.new("AdGroupSummary")
118
+ AdKeywordSummary = BasicReportType.new("AdKeywordSummary")
119
+ AdSummary = BasicReportType.new("AdSummary")
120
+ AdvancedAdKeywordPerformance = BasicReportType.new("AdvancedAdKeywordPerformance")
121
+ AdvancedAdPerformance = BasicReportType.new("AdvancedAdPerformance")
122
+ CampaignSummary = BasicReportType.new("CampaignSummary")
123
+ DailySummary = BasicReportType.new("DailySummary")
124
+ KeywordSummary = BasicReportType.new("KeywordSummary")
125
+ MultiChannelAccount = BasicReportType.new("MultiChannelAccount")
126
+ MultiChannelAdGroup = BasicReportType.new("MultiChannelAdGroup")
127
+ MultiChannelCampaign = BasicReportType.new("MultiChannelCampaign")
128
+ MultiChannelDaily = BasicReportType.new("MultiChannelDaily")
129
+ MultiChannelMarketingActivity = BasicReportType.new("MultiChannelMarketingActivity")
130
+ end
131
+
132
+ # {http://marketing.ews.yahooapis.com/V1}getReportOutputUrl
133
+ class GetReportOutputUrl
134
+ attr_accessor :reportID
135
+ attr_accessor :fileFormat
136
+
137
+ def initialize(reportID = nil, fileFormat = nil)
138
+ @reportID = reportID
139
+ @fileFormat = fileFormat
140
+ end
141
+ end
142
+
143
+ # {http://marketing.ews.yahooapis.com/V1}getReportOutputUrlResponse
144
+ class GetReportOutputUrlResponse
145
+ attr_accessor :out
146
+
147
+ def initialize(out = nil)
148
+ @out = out
149
+ end
150
+ end
151
+
152
+ # {http://marketing.ews.yahooapis.com/V1}addReportRequestWithAccountAggregation
153
+ class AddReportRequestWithAccountAggregation
154
+ attr_accessor :reportRequest
155
+
156
+ def initialize(reportRequest = nil)
157
+ @reportRequest = reportRequest
158
+ end
159
+ end
160
+
161
+ # {http://marketing.ews.yahooapis.com/V1}addReportRequestWithAccountAggregationResponse
162
+ class AddReportRequestWithAccountAggregationResponse
163
+ attr_accessor :out
164
+
165
+ def initialize(out = nil)
166
+ @out = out
167
+ end
168
+ end
169
+
170
+ # {http://marketing.ews.yahooapis.com/V1}addReportRequestForAccountID
171
+ class AddReportRequestForAccountID
172
+ attr_accessor :accountID
173
+ attr_accessor :reportRequest
174
+
175
+ def initialize(accountID = nil, reportRequest = nil)
176
+ @accountID = accountID
177
+ @reportRequest = reportRequest
178
+ end
179
+ end
180
+
181
+ # {http://marketing.ews.yahooapis.com/V1}addReportRequestForAccountIDResponse
182
+ class AddReportRequestForAccountIDResponse
183
+ attr_accessor :out
184
+
185
+ def initialize(out = nil)
186
+ @out = out
187
+ end
188
+ end
189
+
190
+ # {http://marketing.ews.yahooapis.com/V1}deleteReports
191
+ class DeleteReports
192
+ attr_accessor :reportIDs
193
+
194
+ def initialize(reportIDs = nil)
195
+ @reportIDs = reportIDs
196
+ end
197
+ end
198
+
199
+ # {http://marketing.ews.yahooapis.com/V1}deleteReportsResponse
200
+ class DeleteReportsResponse
201
+ def initialize
202
+ end
203
+ end
204
+
205
+ # {http://marketing.ews.yahooapis.com/V1}deleteReport
206
+ class DeleteReport
207
+ attr_accessor :reportID
208
+
209
+ def initialize(reportID = nil)
210
+ @reportID = reportID
211
+ end
212
+ end
213
+
214
+ # {http://marketing.ews.yahooapis.com/V1}deleteReportResponse
215
+ class DeleteReportResponse
216
+ def initialize
217
+ end
218
+ end
219
+
220
+ # {http://marketing.ews.yahooapis.com/V1}getReportList
221
+ class GetReportList
222
+ attr_accessor :onlyCompleted
223
+
224
+ def initialize(onlyCompleted = nil)
225
+ @onlyCompleted = onlyCompleted
226
+ end
227
+ end
228
+
229
+ # {http://marketing.ews.yahooapis.com/V1}getReportListResponse
230
+ class GetReportListResponse
231
+ attr_accessor :out
232
+
233
+ def initialize(out = nil)
234
+ @out = out
235
+ end
236
+ end
237
+
238
+ # {http://marketing.ews.yahooapis.com/V1}getReportOutputUrls
239
+ class GetReportOutputUrls
240
+ attr_accessor :reportIDs
241
+ attr_accessor :fileFormat
242
+
243
+ def initialize(reportIDs = nil, fileFormat = nil)
244
+ @reportIDs = reportIDs
245
+ @fileFormat = fileFormat
246
+ end
247
+ end
248
+
249
+ # {http://marketing.ews.yahooapis.com/V1}getReportOutputUrlsResponse
250
+ class GetReportOutputUrlsResponse
251
+ attr_accessor :out
252
+
253
+ def initialize(out = nil)
254
+ @out = out
255
+ end
256
+ end
257
+
258
+
259
+ end
@@ -0,0 +1,98 @@
1
+ require 'ysm4r/v1/BasicReportServiceMappingRegistry'
2
+
3
+
4
+ module YSM::BasicReportService
5
+ require 'soap/rpc/driver'
6
+
7
+ class BasicReportService < ::SOAP::RPC::Driver
8
+ DefaultEndpointUrl = "https://USE_ADDRESS_RETURNED_BY_LOCATION_SERVICE/services/V1/BasicReportService"
9
+
10
+ Methods = [
11
+ [ "",
12
+ "getReportOutputUrl",
13
+ [ ["in", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "getReportOutputUrl"]],
14
+ ["out", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "getReportOutputUrlResponse"]] ],
15
+ { :request_style => :document, :request_use => :literal,
16
+ :response_style => :document, :response_use => :literal,
17
+ :faults => {"YSM::BasicReportService::ApiFault"=>{:name=>"ApiFault", :encodingstyle=>"document", :namespace=>nil, :ns=>"http://marketing.ews.yahooapis.com/V1", :use=>"literal"}} }
18
+ ],
19
+ [ "",
20
+ "addReportRequestWithAccountAggregation",
21
+ [ ["in", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "addReportRequestWithAccountAggregation"]],
22
+ ["out", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "addReportRequestWithAccountAggregationResponse"]] ],
23
+ { :request_style => :document, :request_use => :literal,
24
+ :response_style => :document, :response_use => :literal,
25
+ :faults => {"YSM::BasicReportService::ApiFault"=>{:name=>"ApiFault", :encodingstyle=>"document", :namespace=>nil, :ns=>"http://marketing.ews.yahooapis.com/V1", :use=>"literal"}} }
26
+ ],
27
+ [ "",
28
+ "addReportRequestForAccountID",
29
+ [ ["in", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "addReportRequestForAccountID"]],
30
+ ["out", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "addReportRequestForAccountIDResponse"]] ],
31
+ { :request_style => :document, :request_use => :literal,
32
+ :response_style => :document, :response_use => :literal,
33
+ :faults => {"YSM::BasicReportService::ApiFault"=>{:name=>"ApiFault", :encodingstyle=>"document", :namespace=>nil, :ns=>"http://marketing.ews.yahooapis.com/V1", :use=>"literal"}} }
34
+ ],
35
+ [ "",
36
+ "deleteReports",
37
+ [ ["in", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "deleteReports"]],
38
+ ["out", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "deleteReportsResponse"]] ],
39
+ { :request_style => :document, :request_use => :literal,
40
+ :response_style => :document, :response_use => :literal,
41
+ :faults => {"YSM::BasicReportService::ApiFault"=>{:name=>"ApiFault", :encodingstyle=>"document", :namespace=>nil, :ns=>"http://marketing.ews.yahooapis.com/V1", :use=>"literal"}} }
42
+ ],
43
+ [ "",
44
+ "deleteReport",
45
+ [ ["in", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "deleteReport"]],
46
+ ["out", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "deleteReportResponse"]] ],
47
+ { :request_style => :document, :request_use => :literal,
48
+ :response_style => :document, :response_use => :literal,
49
+ :faults => {"YSM::BasicReportService::ApiFault"=>{:name=>"ApiFault", :encodingstyle=>"document", :namespace=>nil, :ns=>"http://marketing.ews.yahooapis.com/V1", :use=>"literal"}} }
50
+ ],
51
+ [ "",
52
+ "getReportList",
53
+ [ ["in", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "getReportList"]],
54
+ ["out", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "getReportListResponse"]] ],
55
+ { :request_style => :document, :request_use => :literal,
56
+ :response_style => :document, :response_use => :literal,
57
+ :faults => {"YSM::BasicReportService::ApiFault"=>{:name=>"ApiFault", :encodingstyle=>"document", :namespace=>nil, :ns=>"http://marketing.ews.yahooapis.com/V1", :use=>"literal"}} }
58
+ ],
59
+ [ "",
60
+ "getReportOutputUrls",
61
+ [ ["in", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "getReportOutputUrls"]],
62
+ ["out", "parameters", ["::SOAP::SOAPElement", "http://marketing.ews.yahooapis.com/V1", "getReportOutputUrlsResponse"]] ],
63
+ { :request_style => :document, :request_use => :literal,
64
+ :response_style => :document, :response_use => :literal,
65
+ :faults => {"YSM::BasicReportService::ApiFault"=>{:name=>"ApiFault", :encodingstyle=>"document", :namespace=>nil, :ns=>"http://marketing.ews.yahooapis.com/V1", :use=>"literal"}} }
66
+ ]
67
+ ]
68
+
69
+ def initialize(endpoint_url = nil)
70
+ endpoint_url ||= DefaultEndpointUrl
71
+ super(endpoint_url, nil)
72
+ self.mapping_registry = DefaultMappingRegistry::EncodedRegistry
73
+ self.literal_mapping_registry = DefaultMappingRegistry::LiteralRegistry
74
+ init_methods
75
+ end
76
+
77
+ private
78
+
79
+ def init_methods
80
+ Methods.each do |definitions|
81
+ opt = definitions.last
82
+ if opt[:request_style] == :document
83
+ add_document_operation(*definitions)
84
+ else
85
+ add_rpc_operation(*definitions)
86
+ qname = definitions[0]
87
+ name = definitions[2]
88
+ if qname.name != name and qname.name.capitalize == name.capitalize
89
+ ::SOAP::Mapping.define_singleton_method(self, qname.name) do |*arg|
90
+ __send__(name, *arg)
91
+ end
92
+ end
93
+ end
94
+ end
95
+ end
96
+ end
97
+
98
+ end
@@ -0,0 +1,389 @@
1
+ require 'ysm4r/v1/BasicReportService'
2
+ require 'soap/mapping'
3
+
4
+ module YSM; module BasicReportService
5
+
6
+ module DefaultMappingRegistry
7
+ EncodedRegistry = ::SOAP::Mapping::EncodedRegistry.new
8
+ LiteralRegistry = ::SOAP::Mapping::LiteralRegistry.new
9
+
10
+ EncodedRegistry.register(
11
+ :class => YSM::BasicReportService::FileOutputFormat,
12
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
13
+ :schema_type => "FileOutputFormat",
14
+ :schema_element => [
15
+ ["fileOutputType", "SOAP::SOAPString", [0, 1]],
16
+ ["zipped", "SOAP::SOAPBoolean", [0, 1]]
17
+ ]
18
+ )
19
+
20
+ EncodedRegistry.register(
21
+ :class => YSM::BasicReportService::ApiFault,
22
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
23
+ :schema_type => "ApiFault",
24
+ :schema_element => [
25
+ ["code", "SOAP::SOAPString", [0, 1]],
26
+ ["message", "SOAP::SOAPString", [0, 1]]
27
+ ]
28
+ )
29
+
30
+ EncodedRegistry.register(
31
+ :class => YSM::BasicReportService::BasicReportRequest,
32
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
33
+ :schema_type => "BasicReportRequest",
34
+ :schema_element => [
35
+ ["dateRange", "SOAP::SOAPString", [0, 1]],
36
+ ["endDate", "SOAP::SOAPDateTime", [0, 1]],
37
+ ["reportName", "SOAP::SOAPString", [0, 1]],
38
+ ["reportType", "SOAP::SOAPString", [0, 1]],
39
+ ["startDate", "SOAP::SOAPDateTime", [0, 1]]
40
+ ]
41
+ )
42
+
43
+ EncodedRegistry.set(
44
+ YSM::BasicReportService::ArrayOfInt,
45
+ ::SOAP::SOAPArray,
46
+ ::SOAP::Mapping::EncodedRegistry::TypedArrayFactory,
47
+ { :type => XSD::QName.new("http://www.w3.org/2001/XMLSchema", "int") }
48
+ )
49
+
50
+ EncodedRegistry.set(
51
+ YSM::BasicReportService::ArrayOfReportInfo,
52
+ ::SOAP::SOAPArray,
53
+ ::SOAP::Mapping::EncodedRegistry::TypedArrayFactory,
54
+ { :type => XSD::QName.new("http://marketing.ews.yahooapis.com/V1", "ReportInfo") }
55
+ )
56
+
57
+ EncodedRegistry.register(
58
+ :class => YSM::BasicReportService::ReportInfo,
59
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
60
+ :schema_type => "ReportInfo",
61
+ :schema_element => [
62
+ ["createDate", "SOAP::SOAPDateTime", [0, 1]],
63
+ ["reportID", "SOAP::SOAPInt", [0, 1]],
64
+ ["reportName", "SOAP::SOAPString", [0, 1]],
65
+ ["status", "SOAP::SOAPString", [0, 1]]
66
+ ]
67
+ )
68
+
69
+ EncodedRegistry.set(
70
+ YSM::BasicReportService::ArrayOfString,
71
+ ::SOAP::SOAPArray,
72
+ ::SOAP::Mapping::EncodedRegistry::TypedArrayFactory,
73
+ { :type => XSD::QName.new("http://www.w3.org/2001/XMLSchema", "string") }
74
+ )
75
+
76
+ EncodedRegistry.register(
77
+ :class => YSM::BasicReportService::Security,
78
+ :schema_ns => "http://schemas.xmlsoap.org/ws/2002/07/secext",
79
+ :schema_type => "Security",
80
+ :schema_element => [
81
+ ["usernameToken", ["YSM::BasicReportService::UsernameToken", XSD::QName.new(nil, "UsernameToken")]]
82
+ ]
83
+ )
84
+
85
+ EncodedRegistry.register(
86
+ :class => YSM::BasicReportService::UsernameToken,
87
+ :schema_ns => "http://schemas.xmlsoap.org/ws/2002/07/secext",
88
+ :schema_type => "UsernameToken",
89
+ :schema_element => [
90
+ ["username", ["SOAP::SOAPString", XSD::QName.new(nil, "Username")]],
91
+ ["password", ["SOAP::SOAPString", XSD::QName.new(nil, "Password")]]
92
+ ]
93
+ )
94
+
95
+ EncodedRegistry.register(
96
+ :class => YSM::BasicReportService::FileOutputType,
97
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
98
+ :schema_type => "FileOutputType"
99
+ )
100
+
101
+ EncodedRegistry.register(
102
+ :class => YSM::BasicReportService::DateRange,
103
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
104
+ :schema_type => "DateRange"
105
+ )
106
+
107
+ EncodedRegistry.register(
108
+ :class => YSM::BasicReportService::BasicReportType,
109
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
110
+ :schema_type => "BasicReportType"
111
+ )
112
+
113
+ LiteralRegistry.register(
114
+ :class => YSM::BasicReportService::FileOutputFormat,
115
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
116
+ :schema_type => "FileOutputFormat",
117
+ :schema_qualified => false,
118
+ :schema_element => [
119
+ ["fileOutputType", "SOAP::SOAPString", [0, 1]],
120
+ ["zipped", "SOAP::SOAPBoolean", [0, 1]]
121
+ ]
122
+ )
123
+
124
+ LiteralRegistry.register(
125
+ :class => YSM::BasicReportService::ApiFault,
126
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
127
+ :schema_type => "ApiFault",
128
+ :schema_qualified => false,
129
+ :schema_element => [
130
+ ["code", "SOAP::SOAPString", [0, 1]],
131
+ ["message", "SOAP::SOAPString", [0, 1]]
132
+ ]
133
+ )
134
+
135
+ LiteralRegistry.register(
136
+ :class => YSM::BasicReportService::BasicReportRequest,
137
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
138
+ :schema_type => "BasicReportRequest",
139
+ :schema_qualified => false,
140
+ :schema_element => [
141
+ ["dateRange", "SOAP::SOAPString", [0, 1]],
142
+ ["endDate", "SOAP::SOAPDateTime", [0, 1]],
143
+ ["reportName", "SOAP::SOAPString", [0, 1]],
144
+ ["reportType", "SOAP::SOAPString", [0, 1]],
145
+ ["startDate", "SOAP::SOAPDateTime", [0, 1]]
146
+ ]
147
+ )
148
+
149
+ LiteralRegistry.register(
150
+ :class => YSM::BasicReportService::ArrayOfInt,
151
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
152
+ :schema_type => "ArrayOfInt",
153
+ :schema_element => [
154
+ ["int", ["SOAP::SOAPInt[]", XSD::QName.new("http://marketing.ews.yahooapis.com/V1", "int")], [0, nil]]
155
+ ]
156
+ )
157
+
158
+ LiteralRegistry.register(
159
+ :class => YSM::BasicReportService::ArrayOfReportInfo,
160
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
161
+ :schema_type => "ArrayOfReportInfo",
162
+ :schema_element => [
163
+ ["ReportInfo", ["YSM::BasicReportService::ReportInfo[]", XSD::QName.new("http://marketing.ews.yahooapis.com/V1", "ReportInfo")], [0, nil]]
164
+ ]
165
+ )
166
+
167
+ LiteralRegistry.register(
168
+ :class => YSM::BasicReportService::ReportInfo,
169
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
170
+ :schema_type => "ReportInfo",
171
+ :schema_qualified => false,
172
+ :schema_element => [
173
+ ["createDate", "SOAP::SOAPDateTime", [0, 1]],
174
+ ["reportID", "SOAP::SOAPInt", [0, 1]],
175
+ ["reportName", "SOAP::SOAPString", [0, 1]],
176
+ ["status", "SOAP::SOAPString", [0, 1]]
177
+ ]
178
+ )
179
+
180
+ LiteralRegistry.register(
181
+ :class => YSM::BasicReportService::ArrayOfString,
182
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
183
+ :schema_type => "ArrayOfString",
184
+ :schema_element => [
185
+ ["string", ["SOAP::SOAPString[]", XSD::QName.new("http://marketing.ews.yahooapis.com/V1", "string")], [0, nil]]
186
+ ]
187
+ )
188
+
189
+ LiteralRegistry.register(
190
+ :class => YSM::BasicReportService::Security,
191
+ :schema_ns => "http://schemas.xmlsoap.org/ws/2002/07/secext",
192
+ :schema_type => "Security",
193
+ :schema_qualified => false,
194
+ :schema_element => [
195
+ ["usernameToken", ["YSM::BasicReportService::UsernameToken", XSD::QName.new(nil, "UsernameToken")]]
196
+ ]
197
+ )
198
+
199
+ LiteralRegistry.register(
200
+ :class => YSM::BasicReportService::UsernameToken,
201
+ :schema_ns => "http://schemas.xmlsoap.org/ws/2002/07/secext",
202
+ :schema_type => "UsernameToken",
203
+ :schema_qualified => false,
204
+ :schema_element => [
205
+ ["username", ["SOAP::SOAPString", XSD::QName.new(nil, "Username")]],
206
+ ["password", ["SOAP::SOAPString", XSD::QName.new(nil, "Password")]]
207
+ ]
208
+ )
209
+
210
+ LiteralRegistry.register(
211
+ :class => YSM::BasicReportService::FileOutputType,
212
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
213
+ :schema_type => "FileOutputType"
214
+ )
215
+
216
+ LiteralRegistry.register(
217
+ :class => YSM::BasicReportService::DateRange,
218
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
219
+ :schema_type => "DateRange"
220
+ )
221
+
222
+ LiteralRegistry.register(
223
+ :class => YSM::BasicReportService::BasicReportType,
224
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
225
+ :schema_type => "BasicReportType"
226
+ )
227
+
228
+ LiteralRegistry.register(
229
+ :class => YSM::BasicReportService::GetReportOutputUrl,
230
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
231
+ :schema_name => "getReportOutputUrl",
232
+ :schema_qualified => true,
233
+ :schema_element => [
234
+ ["reportID", "SOAP::SOAPInt"],
235
+ ["fileFormat", "YSM::BasicReportService::FileOutputFormat"]
236
+ ]
237
+ )
238
+
239
+ LiteralRegistry.register(
240
+ :class => YSM::BasicReportService::GetReportOutputUrlResponse,
241
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
242
+ :schema_name => "getReportOutputUrlResponse",
243
+ :schema_qualified => true,
244
+ :schema_element => [
245
+ ["out", "SOAP::SOAPString"]
246
+ ]
247
+ )
248
+
249
+ LiteralRegistry.register(
250
+ :class => YSM::BasicReportService::ApiFault,
251
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
252
+ :schema_name => "ApiFault",
253
+ :schema_qualified => true,
254
+ :schema_element => [
255
+ ["code", "SOAP::SOAPString", [0, 1]],
256
+ ["message", "SOAP::SOAPString", [0, 1]]
257
+ ]
258
+ )
259
+
260
+ LiteralRegistry.register(
261
+ :class => YSM::BasicReportService::AddReportRequestWithAccountAggregation,
262
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
263
+ :schema_name => "addReportRequestWithAccountAggregation",
264
+ :schema_qualified => true,
265
+ :schema_element => [
266
+ ["reportRequest", "YSM::BasicReportService::BasicReportRequest"]
267
+ ]
268
+ )
269
+
270
+ LiteralRegistry.register(
271
+ :class => YSM::BasicReportService::AddReportRequestWithAccountAggregationResponse,
272
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
273
+ :schema_name => "addReportRequestWithAccountAggregationResponse",
274
+ :schema_qualified => true,
275
+ :schema_element => [
276
+ ["out", "SOAP::SOAPInt"]
277
+ ]
278
+ )
279
+
280
+ LiteralRegistry.register(
281
+ :class => YSM::BasicReportService::AddReportRequestForAccountID,
282
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
283
+ :schema_name => "addReportRequestForAccountID",
284
+ :schema_qualified => true,
285
+ :schema_element => [
286
+ ["accountID", "SOAP::SOAPString"],
287
+ ["reportRequest", "YSM::BasicReportService::BasicReportRequest"]
288
+ ]
289
+ )
290
+
291
+ LiteralRegistry.register(
292
+ :class => YSM::BasicReportService::AddReportRequestForAccountIDResponse,
293
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
294
+ :schema_name => "addReportRequestForAccountIDResponse",
295
+ :schema_qualified => true,
296
+ :schema_element => [
297
+ ["out", "SOAP::SOAPInt"]
298
+ ]
299
+ )
300
+
301
+ LiteralRegistry.register(
302
+ :class => YSM::BasicReportService::DeleteReports,
303
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
304
+ :schema_name => "deleteReports",
305
+ :schema_qualified => true,
306
+ :schema_element => [
307
+ ["reportIDs", "YSM::BasicReportService::ArrayOfInt"]
308
+ ]
309
+ )
310
+
311
+ LiteralRegistry.register(
312
+ :class => YSM::BasicReportService::DeleteReportsResponse,
313
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
314
+ :schema_name => "deleteReportsResponse",
315
+ :schema_qualified => true,
316
+ :schema_element => []
317
+ )
318
+
319
+ LiteralRegistry.register(
320
+ :class => YSM::BasicReportService::DeleteReport,
321
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
322
+ :schema_name => "deleteReport",
323
+ :schema_qualified => true,
324
+ :schema_element => [
325
+ ["reportID", "SOAP::SOAPInt"]
326
+ ]
327
+ )
328
+
329
+ LiteralRegistry.register(
330
+ :class => YSM::BasicReportService::DeleteReportResponse,
331
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
332
+ :schema_name => "deleteReportResponse",
333
+ :schema_qualified => true,
334
+ :schema_element => []
335
+ )
336
+
337
+ LiteralRegistry.register(
338
+ :class => YSM::BasicReportService::GetReportList,
339
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
340
+ :schema_name => "getReportList",
341
+ :schema_qualified => true,
342
+ :schema_element => [
343
+ ["onlyCompleted", "SOAP::SOAPBoolean"]
344
+ ]
345
+ )
346
+
347
+ LiteralRegistry.register(
348
+ :class => YSM::BasicReportService::GetReportListResponse,
349
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
350
+ :schema_name => "getReportListResponse",
351
+ :schema_qualified => true,
352
+ :schema_element => [
353
+ ["out", "YSM::BasicReportService::ArrayOfReportInfo"]
354
+ ]
355
+ )
356
+
357
+ LiteralRegistry.register(
358
+ :class => YSM::BasicReportService::GetReportOutputUrls,
359
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
360
+ :schema_name => "getReportOutputUrls",
361
+ :schema_qualified => true,
362
+ :schema_element => [
363
+ ["reportIDs", "YSM::BasicReportService::ArrayOfInt"],
364
+ ["fileFormat", "YSM::BasicReportService::FileOutputFormat"]
365
+ ]
366
+ )
367
+
368
+ LiteralRegistry.register(
369
+ :class => YSM::BasicReportService::GetReportOutputUrlsResponse,
370
+ :schema_ns => "http://marketing.ews.yahooapis.com/V1",
371
+ :schema_name => "getReportOutputUrlsResponse",
372
+ :schema_qualified => true,
373
+ :schema_element => [
374
+ ["out", "YSM::BasicReportService::ArrayOfString"]
375
+ ]
376
+ )
377
+
378
+ LiteralRegistry.register(
379
+ :class => YSM::BasicReportService::Security,
380
+ :schema_ns => "http://schemas.xmlsoap.org/ws/2002/07/secext",
381
+ :schema_name => "Security",
382
+ :schema_qualified => true,
383
+ :schema_element => [
384
+ ["usernameToken", ["YSM::BasicReportService::UsernameToken", XSD::QName.new(nil, "UsernameToken")]]
385
+ ]
386
+ )
387
+ end
388
+
389
+ end; end