File Coverage

blib/lib/Microsoft/AdCenter/V7/ReportingService.pm
Criterion Covered Total %
statement 9 9 100.0
branch n/a
condition n/a
subroutine 3 3 100.0
pod n/a
total 12 12 100.0


line stmt bran cond sub pod time code
1             package Microsoft::AdCenter::V7::ReportingService;
2             # Copyright (C) 2012 Xerxes Tsang
3             # This program is free software; you can redistribute it and/or modify it
4             # under the terms of Perl Artistic License.
5              
6 63     63   12319765 use strict;
  63         172  
  63         2989  
7 63     63   421 use warnings;
  63         147  
  63         3389  
8              
9             =head1 NAME
10              
11             Microsoft::AdCenter::V7::ReportingService - Service client for Microsoft AdCenter Reporting Service.
12              
13             =head1 SYNOPSIS
14              
15             use Microsoft::AdCenter::V7::ReportingService;
16              
17             my $service_client = Microsoft::AdCenter::V7::ReportingService->new
18             ->ApplicationToken("application token")
19             ->CustomerAccountId("customer account id")
20             ->CustomerId("customer id")
21             ->DeveloperToken("developer token")
22             ->Password("password")
23             ->UserName("user name");
24              
25             my $response = $service_client->PollGenerateReport(
26             ReportRequestId => ...
27             );
28              
29             See L for detailed documentation for this service.
30              
31             =head1 METHODS
32              
33             =head2 EndPoint
34              
35             Changes the end point for this service client.
36              
37             Default value: https://adcenterapi.microsoft.com/Api/Advertiser/V7/Reporting/ReportingService.svc
38              
39             =head2 ApplicationToken
40              
41             Gets/sets ApplicationToken (string) in the request header
42              
43             =head2 CustomerAccountId
44              
45             Gets/sets CustomerAccountId (string) in the request header
46              
47             =head2 CustomerId
48              
49             Gets/sets CustomerId (string) in the request header
50              
51             =head2 DeveloperToken
52              
53             Gets/sets DeveloperToken (string) in the request header
54              
55             =head2 Password
56              
57             Gets/sets Password (string) in the request header
58              
59             =head2 UserName
60              
61             Gets/sets UserName (string) in the request header
62              
63             =head2 TrackingId
64              
65             Gets TrackingId (string) in the response header
66              
67             =cut
68              
69 63     63   412 use base qw/Microsoft::AdCenter::Service/;
  63         128  
  63         58505  
70              
71             sub _service_name {
72             return 'ReportingService';
73             }
74              
75             sub _service_version {
76             return 'V7';
77             }
78              
79             sub _class_name {
80             return 'ReportingService';
81             }
82              
83             sub _namespace_uri {
84             return 'https://adcenter.microsoft.com/v7';
85             }
86              
87             sub _default_location {
88             return 'https://adcenterapi.microsoft.com/Api/Advertiser/V7/Reporting/ReportingService.svc';
89             }
90              
91             sub _wsdl {
92             return 'https://adcenterapi.microsoft.com/Api/Advertiser/V7/Reporting/ReportingService.svc?wsdl';
93             }
94              
95             our $_request_headers = [
96             { name => 'ApplicationToken', type => 'string', namespace => 'https://adcenter.microsoft.com/v7' },
97             { name => 'CustomerAccountId', type => 'string', namespace => 'https://adcenter.microsoft.com/v7' },
98             { name => 'CustomerId', type => 'string', namespace => 'https://adcenter.microsoft.com/v7' },
99             { name => 'DeveloperToken', type => 'string', namespace => 'https://adcenter.microsoft.com/v7' },
100             { name => 'Password', type => 'string', namespace => 'https://adcenter.microsoft.com/v7' },
101             { name => 'UserName', type => 'string', namespace => 'https://adcenter.microsoft.com/v7' }
102             ];
103              
104             our $_request_headers_expanded = {
105             ApplicationToken => 'string',
106             CustomerAccountId => 'string',
107             CustomerId => 'string',
108             DeveloperToken => 'string',
109             Password => 'string',
110             UserName => 'string'
111             };
112              
113             sub _request_headers {
114             return $_request_headers;
115             }
116              
117             sub _request_headers_expanded {
118             return $_request_headers_expanded;
119             }
120              
121             our $_response_headers = [
122             { name => 'TrackingId', type => 'string', namespace => 'https://adcenter.microsoft.com/v7' }
123             ];
124              
125             our $_response_headers_expanded = {
126             TrackingId => 'string'
127             };
128              
129             sub _response_headers {
130             return $_response_headers;
131             }
132              
133             sub _response_headers_expanded {
134             return $_response_headers_expanded;
135             }
136              
137             =head2 PollGenerateReport
138              
139             =over
140              
141             =item Parameters:
142              
143             ReportRequestId (string)
144              
145             =item Returns:
146              
147             PollGenerateReportResponse
148              
149             =back
150              
151             =cut
152              
153             sub PollGenerateReport {
154             my ($self, %args) = @_;
155             return $self->_invoke(
156             soap_action => 'PollGenerateReport',
157             request => {
158             name => 'PollGenerateReportRequest',
159             parameters => [
160             { name => 'ReportRequestId', type => 'string', namespace => 'https://adcenter.microsoft.com/v7' }
161             ]
162             },
163             response => {
164             name => 'PollGenerateReportResponse'
165             },
166             parameters => \%args
167             );
168             }
169              
170             =head2 SubmitGenerateReport
171              
172             =over
173              
174             =item Parameters:
175              
176             ReportRequest (ReportRequest)
177              
178             =item Returns:
179              
180             SubmitGenerateReportResponse
181              
182             =back
183              
184             =cut
185              
186             sub SubmitGenerateReport {
187             my ($self, %args) = @_;
188             return $self->_invoke(
189             soap_action => 'SubmitGenerateReport',
190             request => {
191             name => 'SubmitGenerateReportRequest',
192             parameters => [
193             { name => 'ReportRequest', type => 'ReportRequest', namespace => 'https://adcenter.microsoft.com/v7' }
194             ]
195             },
196             response => {
197             name => 'SubmitGenerateReportResponse'
198             },
199             parameters => \%args
200             );
201             }
202              
203             our %_simple_types = (
204             AccountPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
205             AdDistributionReportFilter => 'https://adcenter.microsoft.com/v7',
206             AdDynamicTextPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
207             AdGroupPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
208             AdGroupStatusReportFilter => 'https://adcenter.microsoft.com/v7',
209             AdPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
210             AdStatusReportFilter => 'https://adcenter.microsoft.com/v7',
211             AdTypeReportFilter => 'https://adcenter.microsoft.com/v7',
212             AgeGenderDemographicReportColumn => 'https://adcenter.microsoft.com/v7',
213             AgeGroupReportFilter => 'https://adcenter.microsoft.com/v7',
214             BehavioralPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
215             BehavioralTargetReportColumn => 'https://adcenter.microsoft.com/v7',
216             BidMatchTypeReportFilter => 'https://adcenter.microsoft.com/v7',
217             BudgetSummaryReportColumn => 'https://adcenter.microsoft.com/v7',
218             BudgetSummaryReportTimePeriod => 'https://adcenter.microsoft.com/v7',
219             CampaignPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
220             CampaignStatusReportFilter => 'https://adcenter.microsoft.com/v7',
221             CashbackReportFilter => 'https://adcenter.microsoft.com/v7',
222             ComponentTypeFilter => 'https://adcenter.microsoft.com/v7',
223             ConversionPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
224             CountryReportFilter => 'https://adcenter.microsoft.com/v7',
225             DeliveredMatchTypeReportFilter => 'https://adcenter.microsoft.com/v7',
226             DestinationUrlPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
227             DeviceTypeReportFilter => 'https://adcenter.microsoft.com/v7',
228             GenderReportFilter => 'https://adcenter.microsoft.com/v7',
229             GoalsAndFunnelsReportColumn => 'https://adcenter.microsoft.com/v7',
230             KeywordPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
231             LanguageAndRegionReportFilter => 'https://adcenter.microsoft.com/v7',
232             MetroAreaDemographicReportColumn => 'https://adcenter.microsoft.com/v7',
233             NegativeKeywordConflictReportColumn => 'https://adcenter.microsoft.com/v7',
234             NonHourlyReportAggregation => 'https://adcenter.microsoft.com/v7',
235             PublisherUsagePerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
236             ReportAggregation => 'https://adcenter.microsoft.com/v7',
237             ReportFormat => 'https://adcenter.microsoft.com/v7',
238             ReportLanguage => 'https://adcenter.microsoft.com/v7',
239             ReportRequestStatusType => 'https://adcenter.microsoft.com/v7',
240             ReportTimePeriod => 'https://adcenter.microsoft.com/v7',
241             RichAdComponentPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
242             RichAdSubTypeFilter => 'https://adcenter.microsoft.com/v7',
243             SearchQueryPerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
244             SearchQueryReportAggregation => 'https://adcenter.microsoft.com/v7',
245             SegmentationReportColumn => 'https://adcenter.microsoft.com/v7',
246             ShareOfVoiceReportColumn => 'https://adcenter.microsoft.com/v7',
247             SitePerformanceReportColumn => 'https://adcenter.microsoft.com/v7',
248             TacticChannelReportColumn => 'https://adcenter.microsoft.com/v7',
249             TrafficSourcesReportColumn => 'https://adcenter.microsoft.com/v7',
250             char => 'http://schemas.microsoft.com/2003/10/Serialization/',
251             duration => 'http://schemas.microsoft.com/2003/10/Serialization/',
252             guid => 'http://schemas.microsoft.com/2003/10/Serialization/',
253             );
254              
255             sub _simple_types {
256             return %_simple_types;
257             }
258              
259             our @_complex_types = (qw/
260             AccountPerformanceReportFilter
261             AccountPerformanceReportRequest
262             AccountReportScope
263             AccountThroughAdGroupReportScope
264             AccountThroughCampaignReportScope
265             AdApiError
266             AdApiFaultDetail
267             AdDynamicTextPerformanceReportFilter
268             AdDynamicTextPerformanceReportRequest
269             AdGroupPerformanceReportFilter
270             AdGroupPerformanceReportRequest
271             AdGroupReportScope
272             AdPerformanceReportFilter
273             AdPerformanceReportRequest
274             AgeGenderDemographicReportFilter
275             AgeGenderDemographicReportRequest
276             ApiFaultDetail
277             ApplicationFault
278             BatchError
279             BehavioralPerformanceReportFilter
280             BehavioralPerformanceReportRequest
281             BehavioralTargetReportFilter
282             BehavioralTargetReportRequest
283             BudgetSummaryReportRequest
284             BudgetSummaryReportTime
285             CampaignPerformanceReportFilter
286             CampaignPerformanceReportRequest
287             CampaignReportScope
288             ConversionPerformanceReportFilter
289             ConversionPerformanceReportRequest
290             Date
291             DestinationUrlPerformanceReportFilter
292             DestinationUrlPerformanceReportRequest
293             GoalsAndFunnelsReportFilter
294             GoalsAndFunnelsReportRequest
295             KeywordPerformanceReportFilter
296             KeywordPerformanceReportRequest
297             MetroAreaDemographicReportFilter
298             MetroAreaDemographicReportRequest
299             NegativeKeywordConflictReportRequest
300             OperationError
301             PollGenerateReportResponse
302             PublisherUsagePerformanceReportFilter
303             PublisherUsagePerformanceReportRequest
304             ReportRequest
305             ReportRequestStatus
306             ReportTime
307             RichAdComponentPerformanceReportFilter
308             RichAdComponentPerformanceReportRequest
309             SearchQueryPerformanceReportFilter
310             SearchQueryPerformanceReportRequest
311             SegmentationReportFilter
312             SegmentationReportRequest
313             ShareOfVoiceReportFilter
314             ShareOfVoiceReportRequest
315             SitePerformanceReportFilter
316             SitePerformanceReportRequest
317             SubmitGenerateReportResponse
318             TacticChannelReportFilter
319             TacticChannelReportRequest
320             TrafficSourcesReportFilter
321             TrafficSourcesReportRequest
322             /);
323              
324             sub _complex_types {
325             return @_complex_types;
326             }
327              
328             our %_array_types = (
329             ArrayOfAccountPerformanceReportColumn => {
330             namespace_uri => 'https://adcenter.microsoft.com/v7',
331             element_name => 'AccountPerformanceReportColumn',
332             element_type => 'AccountPerformanceReportColumn'
333             },
334             ArrayOfAdApiError => {
335             namespace_uri => 'https://adapi.microsoft.com',
336             element_name => 'AdApiError',
337             element_type => 'AdApiError'
338             },
339             ArrayOfAdDynamicTextPerformanceReportColumn => {
340             namespace_uri => 'https://adcenter.microsoft.com/v7',
341             element_name => 'AdDynamicTextPerformanceReportColumn',
342             element_type => 'AdDynamicTextPerformanceReportColumn'
343             },
344             ArrayOfAdGroupPerformanceReportColumn => {
345             namespace_uri => 'https://adcenter.microsoft.com/v7',
346             element_name => 'AdGroupPerformanceReportColumn',
347             element_type => 'AdGroupPerformanceReportColumn'
348             },
349             ArrayOfAdGroupReportScope => {
350             namespace_uri => 'https://adcenter.microsoft.com/v7',
351             element_name => 'AdGroupReportScope',
352             element_type => 'AdGroupReportScope'
353             },
354             ArrayOfAdPerformanceReportColumn => {
355             namespace_uri => 'https://adcenter.microsoft.com/v7',
356             element_name => 'AdPerformanceReportColumn',
357             element_type => 'AdPerformanceReportColumn'
358             },
359             ArrayOfAgeGenderDemographicReportColumn => {
360             namespace_uri => 'https://adcenter.microsoft.com/v7',
361             element_name => 'AgeGenderDemographicReportColumn',
362             element_type => 'AgeGenderDemographicReportColumn'
363             },
364             ArrayOfBatchError => {
365             namespace_uri => 'https://adcenter.microsoft.com/v7',
366             element_name => 'BatchError',
367             element_type => 'BatchError'
368             },
369             ArrayOfBehavioralPerformanceReportColumn => {
370             namespace_uri => 'https://adcenter.microsoft.com/v7',
371             element_name => 'BehavioralPerformanceReportColumn',
372             element_type => 'BehavioralPerformanceReportColumn'
373             },
374             ArrayOfBehavioralTargetReportColumn => {
375             namespace_uri => 'https://adcenter.microsoft.com/v7',
376             element_name => 'BehavioralTargetReportColumn',
377             element_type => 'BehavioralTargetReportColumn'
378             },
379             ArrayOfBudgetSummaryReportColumn => {
380             namespace_uri => 'https://adcenter.microsoft.com/v7',
381             element_name => 'BudgetSummaryReportColumn',
382             element_type => 'BudgetSummaryReportColumn'
383             },
384             ArrayOfCampaignPerformanceReportColumn => {
385             namespace_uri => 'https://adcenter.microsoft.com/v7',
386             element_name => 'CampaignPerformanceReportColumn',
387             element_type => 'CampaignPerformanceReportColumn'
388             },
389             ArrayOfCampaignReportScope => {
390             namespace_uri => 'https://adcenter.microsoft.com/v7',
391             element_name => 'CampaignReportScope',
392             element_type => 'CampaignReportScope'
393             },
394             ArrayOfConversionPerformanceReportColumn => {
395             namespace_uri => 'https://adcenter.microsoft.com/v7',
396             element_name => 'ConversionPerformanceReportColumn',
397             element_type => 'ConversionPerformanceReportColumn'
398             },
399             ArrayOfDestinationUrlPerformanceReportColumn => {
400             namespace_uri => 'https://adcenter.microsoft.com/v7',
401             element_name => 'DestinationUrlPerformanceReportColumn',
402             element_type => 'DestinationUrlPerformanceReportColumn'
403             },
404             ArrayOfGoalsAndFunnelsReportColumn => {
405             namespace_uri => 'https://adcenter.microsoft.com/v7',
406             element_name => 'GoalsAndFunnelsReportColumn',
407             element_type => 'GoalsAndFunnelsReportColumn'
408             },
409             ArrayOfKeywordPerformanceReportColumn => {
410             namespace_uri => 'https://adcenter.microsoft.com/v7',
411             element_name => 'KeywordPerformanceReportColumn',
412             element_type => 'KeywordPerformanceReportColumn'
413             },
414             ArrayOfMetroAreaDemographicReportColumn => {
415             namespace_uri => 'https://adcenter.microsoft.com/v7',
416             element_name => 'MetroAreaDemographicReportColumn',
417             element_type => 'MetroAreaDemographicReportColumn'
418             },
419             ArrayOfNegativeKeywordConflictReportColumn => {
420             namespace_uri => 'https://adcenter.microsoft.com/v7',
421             element_name => 'NegativeKeywordConflictReportColumn',
422             element_type => 'NegativeKeywordConflictReportColumn'
423             },
424             ArrayOfOperationError => {
425             namespace_uri => 'https://adcenter.microsoft.com/v7',
426             element_name => 'OperationError',
427             element_type => 'OperationError'
428             },
429             ArrayOfPublisherUsagePerformanceReportColumn => {
430             namespace_uri => 'https://adcenter.microsoft.com/v7',
431             element_name => 'PublisherUsagePerformanceReportColumn',
432             element_type => 'PublisherUsagePerformanceReportColumn'
433             },
434             ArrayOfRichAdComponentPerformanceReportColumn => {
435             namespace_uri => 'https://adcenter.microsoft.com/v7',
436             element_name => 'RichAdComponentPerformanceReportColumn',
437             element_type => 'RichAdComponentPerformanceReportColumn'
438             },
439             ArrayOfSearchQueryPerformanceReportColumn => {
440             namespace_uri => 'https://adcenter.microsoft.com/v7',
441             element_name => 'SearchQueryPerformanceReportColumn',
442             element_type => 'SearchQueryPerformanceReportColumn'
443             },
444             ArrayOfSegmentationReportColumn => {
445             namespace_uri => 'https://adcenter.microsoft.com/v7',
446             element_name => 'SegmentationReportColumn',
447             element_type => 'SegmentationReportColumn'
448             },
449             ArrayOfShareOfVoiceReportColumn => {
450             namespace_uri => 'https://adcenter.microsoft.com/v7',
451             element_name => 'ShareOfVoiceReportColumn',
452             element_type => 'ShareOfVoiceReportColumn'
453             },
454             ArrayOfSitePerformanceReportColumn => {
455             namespace_uri => 'https://adcenter.microsoft.com/v7',
456             element_name => 'SitePerformanceReportColumn',
457             element_type => 'SitePerformanceReportColumn'
458             },
459             ArrayOfTacticChannelReportColumn => {
460             namespace_uri => 'https://adcenter.microsoft.com/v7',
461             element_name => 'TacticChannelReportColumn',
462             element_type => 'TacticChannelReportColumn'
463             },
464             ArrayOfTrafficSourcesReportColumn => {
465             namespace_uri => 'https://adcenter.microsoft.com/v7',
466             element_name => 'TrafficSourcesReportColumn',
467             element_type => 'TrafficSourcesReportColumn'
468             },
469             ArrayOfint => {
470             namespace_uri => 'http://schemas.microsoft.com/2003/10/Serialization/Arrays',
471             element_name => 'int',
472             element_type => 'int'
473             },
474             ArrayOflong => {
475             namespace_uri => 'http://schemas.microsoft.com/2003/10/Serialization/Arrays',
476             element_name => 'long',
477             element_type => 'long'
478             },
479             ArrayOfstring => {
480             namespace_uri => 'http://schemas.microsoft.com/2003/10/Serialization/Arrays',
481             element_name => 'string',
482             element_type => 'string'
483             },
484             );
485              
486             sub _array_types {
487             return %_array_types;
488             }
489              
490             __PACKAGE__->mk_accessors(qw/
491             ApplicationToken
492             CustomerAccountId
493             CustomerId
494             DeveloperToken
495             Password
496             UserName
497             TrackingId
498             /);
499              
500             1;