File Coverage

blib/lib/Microsoft/AdCenter/V6/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::V6::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 58     58   4213556 use strict;
  58         154  
  58         2589  
7 58     58   376 use warnings;
  58         132  
  58         2599  
8              
9             =head1 NAME
10              
11             Microsoft::AdCenter::V6::ReportingService - Service client for Microsoft AdCenter Reporting Service.
12              
13             =head1 SYNOPSIS
14              
15             use Microsoft::AdCenter::V6::ReportingService;
16              
17             my $service_client = Microsoft::AdCenter::V6::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/V6/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 58     58   334 use base qw/Microsoft::AdCenter::Service/;
  58         120  
  58         41188  
70              
71             sub _service_name {
72             return 'ReportingService';
73             }
74              
75             sub _service_version {
76             return 'V6';
77             }
78              
79             sub _class_name {
80             return 'ReportingService';
81             }
82              
83             sub _namespace_uri {
84             return 'https://adcenter.microsoft.com/v6';
85             }
86              
87             sub _default_location {
88             return 'https://adcenterapi.microsoft.com/Api/Advertiser/V6/Reporting/ReportingService.svc';
89             }
90              
91             sub _wsdl {
92             return 'https://adcenterapi.microsoft.com/Api/Advertiser/V6/Reporting/ReportingService.svc?wsdl';
93             }
94              
95             our $_request_headers = [
96             { name => 'ApplicationToken', type => 'string', namespace => 'https://adcenter.microsoft.com/v6' },
97             { name => 'CustomerAccountId', type => 'string', namespace => 'https://adcenter.microsoft.com/v6' },
98             { name => 'CustomerId', type => 'string', namespace => 'https://adcenter.microsoft.com/v6' },
99             { name => 'DeveloperToken', type => 'string', namespace => 'https://adcenter.microsoft.com/v6' },
100             { name => 'Password', type => 'string', namespace => 'https://adcenter.microsoft.com/v6' },
101             { name => 'UserName', type => 'string', namespace => 'https://adcenter.microsoft.com/v6' }
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/v6' }
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/v6' }
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/v6' }
194             ]
195             },
196             response => {
197             name => 'SubmitGenerateReportResponse'
198             },
199             parameters => \%args
200             );
201             }
202              
203             our %_simple_types = (
204             AccountPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
205             AdDistributionReportFilter => 'https://adcenter.microsoft.com/v6',
206             AdDynamicTextPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
207             AdGroupPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
208             AdGroupStatusReportFilter => 'https://adcenter.microsoft.com/v6',
209             AdPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
210             AdStatusReportFilter => 'https://adcenter.microsoft.com/v6',
211             AdTypeReportFilter => 'https://adcenter.microsoft.com/v6',
212             AgeGenderDemographicReportColumn => 'https://adcenter.microsoft.com/v6',
213             AgeGroupReportFilter => 'https://adcenter.microsoft.com/v6',
214             BehavioralPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
215             BehavioralTargetReportColumn => 'https://adcenter.microsoft.com/v6',
216             BiddedMatchTypeReportFilter => 'https://adcenter.microsoft.com/v6',
217             BudgetSummaryReportColumn => 'https://adcenter.microsoft.com/v6',
218             BudgetSummaryReportTimePeriod => 'https://adcenter.microsoft.com/v6',
219             CampaignPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
220             CampaignStatusReportFilter => 'https://adcenter.microsoft.com/v6',
221             CashbackReportFilter => 'https://adcenter.microsoft.com/v6',
222             ConversionPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
223             CountryReportFilter => 'https://adcenter.microsoft.com/v6',
224             DeliveredMatchTypeReportFilter => 'https://adcenter.microsoft.com/v6',
225             DestinationUrlPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
226             DeviceTypeReportFilter => 'https://adcenter.microsoft.com/v6',
227             GenderReportFilter => 'https://adcenter.microsoft.com/v6',
228             GoalsAndFunnelsReportColumn => 'https://adcenter.microsoft.com/v6',
229             KeywordPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
230             LanguageAndRegionReportFilter => 'https://adcenter.microsoft.com/v6',
231             MetroAreaDemographicReportColumn => 'https://adcenter.microsoft.com/v6',
232             NonHourlyReportAggregation => 'https://adcenter.microsoft.com/v6',
233             PublisherUsagePerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
234             ReportAggregation => 'https://adcenter.microsoft.com/v6',
235             ReportFormat => 'https://adcenter.microsoft.com/v6',
236             ReportLanguage => 'https://adcenter.microsoft.com/v6',
237             ReportRequestStatusType => 'https://adcenter.microsoft.com/v6',
238             ReportTimePeriod => 'https://adcenter.microsoft.com/v6',
239             SearchQueryPerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
240             SearchQueryReportAggregation => 'https://adcenter.microsoft.com/v6',
241             SegmentationReportColumn => 'https://adcenter.microsoft.com/v6',
242             SitePerformanceReportColumn => 'https://adcenter.microsoft.com/v6',
243             TacticChannelReportColumn => 'https://adcenter.microsoft.com/v6',
244             TrafficSourcesReportColumn => 'https://adcenter.microsoft.com/v6',
245             char => 'http://schemas.microsoft.com/2003/10/Serialization/',
246             duration => 'http://schemas.microsoft.com/2003/10/Serialization/',
247             guid => 'http://schemas.microsoft.com/2003/10/Serialization/',
248             );
249              
250             sub _simple_types {
251             return %_simple_types;
252             }
253              
254             our @_complex_types = (qw/
255             AccountPerformanceReportFilter
256             AccountPerformanceReportRequest
257             AccountReportScope
258             AccountThroughAdGroupReportScope
259             AccountThroughCampaignReportScope
260             AdApiError
261             AdApiFaultDetail
262             AdDynamicTextPerformanceReportFilter
263             AdDynamicTextPerformanceReportRequest
264             AdGroupPerformanceReportFilter
265             AdGroupPerformanceReportRequest
266             AdGroupReportScope
267             AdPerformanceReportFilter
268             AdPerformanceReportRequest
269             AgeGenderDemographicReportFilter
270             AgeGenderDemographicReportRequest
271             ApiFaultDetail
272             ApplicationFault
273             BatchError
274             BehavioralPerformanceReportFilter
275             BehavioralPerformanceReportRequest
276             BehavioralTargetReportFilter
277             BehavioralTargetReportRequest
278             BudgetSummaryReportRequest
279             BudgetSummaryReportTime
280             CampaignPerformanceReportFilter
281             CampaignPerformanceReportRequest
282             CampaignReportScope
283             ConversionPerformanceReportFilter
284             ConversionPerformanceReportRequest
285             Date
286             DestinationUrlPerformanceReportFilter
287             DestinationUrlPerformanceReportRequest
288             GoalsAndFunnelsReportFilter
289             GoalsAndFunnelsReportRequest
290             KeywordPerformanceReportFilter
291             KeywordPerformanceReportRequest
292             MetroAreaDemographicReportFilter
293             MetroAreaDemographicReportRequest
294             OperationError
295             PollGenerateReportResponse
296             PublisherUsagePerformanceReportFilter
297             PublisherUsagePerformanceReportRequest
298             ReportRequest
299             ReportRequestStatus
300             ReportTime
301             SearchQueryPerformanceReportFilter
302             SearchQueryPerformanceReportRequest
303             SegmentationReportFilter
304             SegmentationReportRequest
305             SitePerformanceReportFilter
306             SitePerformanceReportRequest
307             SubmitGenerateReportResponse
308             TacticChannelReportFilter
309             TacticChannelReportRequest
310             TrafficSourcesReportFilter
311             TrafficSourcesReportRequest
312             /);
313              
314             sub _complex_types {
315             return @_complex_types;
316             }
317              
318             our %_array_types = (
319             ArrayOfAccountPerformanceReportColumn => {
320             namespace_uri => 'https://adcenter.microsoft.com/v6',
321             element_name => 'AccountPerformanceReportColumn',
322             element_type => 'AccountPerformanceReportColumn'
323             },
324             ArrayOfAdApiError => {
325             namespace_uri => 'https://adapi.microsoft.com',
326             element_name => 'AdApiError',
327             element_type => 'AdApiError'
328             },
329             ArrayOfAdDynamicTextPerformanceReportColumn => {
330             namespace_uri => 'https://adcenter.microsoft.com/v6',
331             element_name => 'AdDynamicTextPerformanceReportColumn',
332             element_type => 'AdDynamicTextPerformanceReportColumn'
333             },
334             ArrayOfAdGroupPerformanceReportColumn => {
335             namespace_uri => 'https://adcenter.microsoft.com/v6',
336             element_name => 'AdGroupPerformanceReportColumn',
337             element_type => 'AdGroupPerformanceReportColumn'
338             },
339             ArrayOfAdGroupReportScope => {
340             namespace_uri => 'https://adcenter.microsoft.com/v6',
341             element_name => 'AdGroupReportScope',
342             element_type => 'AdGroupReportScope'
343             },
344             ArrayOfAdPerformanceReportColumn => {
345             namespace_uri => 'https://adcenter.microsoft.com/v6',
346             element_name => 'AdPerformanceReportColumn',
347             element_type => 'AdPerformanceReportColumn'
348             },
349             ArrayOfAgeGenderDemographicReportColumn => {
350             namespace_uri => 'https://adcenter.microsoft.com/v6',
351             element_name => 'AgeGenderDemographicReportColumn',
352             element_type => 'AgeGenderDemographicReportColumn'
353             },
354             ArrayOfBatchError => {
355             namespace_uri => 'https://adcenter.microsoft.com/v6',
356             element_name => 'BatchError',
357             element_type => 'BatchError'
358             },
359             ArrayOfBehavioralPerformanceReportColumn => {
360             namespace_uri => 'https://adcenter.microsoft.com/v6',
361             element_name => 'BehavioralPerformanceReportColumn',
362             element_type => 'BehavioralPerformanceReportColumn'
363             },
364             ArrayOfBehavioralTargetReportColumn => {
365             namespace_uri => 'https://adcenter.microsoft.com/v6',
366             element_name => 'BehavioralTargetReportColumn',
367             element_type => 'BehavioralTargetReportColumn'
368             },
369             ArrayOfBudgetSummaryReportColumn => {
370             namespace_uri => 'https://adcenter.microsoft.com/v6',
371             element_name => 'BudgetSummaryReportColumn',
372             element_type => 'BudgetSummaryReportColumn'
373             },
374             ArrayOfCampaignPerformanceReportColumn => {
375             namespace_uri => 'https://adcenter.microsoft.com/v6',
376             element_name => 'CampaignPerformanceReportColumn',
377             element_type => 'CampaignPerformanceReportColumn'
378             },
379             ArrayOfCampaignReportScope => {
380             namespace_uri => 'https://adcenter.microsoft.com/v6',
381             element_name => 'CampaignReportScope',
382             element_type => 'CampaignReportScope'
383             },
384             ArrayOfConversionPerformanceReportColumn => {
385             namespace_uri => 'https://adcenter.microsoft.com/v6',
386             element_name => 'ConversionPerformanceReportColumn',
387             element_type => 'ConversionPerformanceReportColumn'
388             },
389             ArrayOfDate => {
390             namespace_uri => 'https://adcenter.microsoft.com/v6',
391             element_name => 'Date',
392             element_type => 'Date'
393             },
394             ArrayOfDestinationUrlPerformanceReportColumn => {
395             namespace_uri => 'https://adcenter.microsoft.com/v6',
396             element_name => 'DestinationUrlPerformanceReportColumn',
397             element_type => 'DestinationUrlPerformanceReportColumn'
398             },
399             ArrayOfGoalsAndFunnelsReportColumn => {
400             namespace_uri => 'https://adcenter.microsoft.com/v6',
401             element_name => 'GoalsAndFunnelsReportColumn',
402             element_type => 'GoalsAndFunnelsReportColumn'
403             },
404             ArrayOfKeywordPerformanceReportColumn => {
405             namespace_uri => 'https://adcenter.microsoft.com/v6',
406             element_name => 'KeywordPerformanceReportColumn',
407             element_type => 'KeywordPerformanceReportColumn'
408             },
409             ArrayOfMetroAreaDemographicReportColumn => {
410             namespace_uri => 'https://adcenter.microsoft.com/v6',
411             element_name => 'MetroAreaDemographicReportColumn',
412             element_type => 'MetroAreaDemographicReportColumn'
413             },
414             ArrayOfOperationError => {
415             namespace_uri => 'https://adcenter.microsoft.com/v6',
416             element_name => 'OperationError',
417             element_type => 'OperationError'
418             },
419             ArrayOfPublisherUsagePerformanceReportColumn => {
420             namespace_uri => 'https://adcenter.microsoft.com/v6',
421             element_name => 'PublisherUsagePerformanceReportColumn',
422             element_type => 'PublisherUsagePerformanceReportColumn'
423             },
424             ArrayOfSearchQueryPerformanceReportColumn => {
425             namespace_uri => 'https://adcenter.microsoft.com/v6',
426             element_name => 'SearchQueryPerformanceReportColumn',
427             element_type => 'SearchQueryPerformanceReportColumn'
428             },
429             ArrayOfSegmentationReportColumn => {
430             namespace_uri => 'https://adcenter.microsoft.com/v6',
431             element_name => 'SegmentationReportColumn',
432             element_type => 'SegmentationReportColumn'
433             },
434             ArrayOfSitePerformanceReportColumn => {
435             namespace_uri => 'https://adcenter.microsoft.com/v6',
436             element_name => 'SitePerformanceReportColumn',
437             element_type => 'SitePerformanceReportColumn'
438             },
439             ArrayOfTacticChannelReportColumn => {
440             namespace_uri => 'https://adcenter.microsoft.com/v6',
441             element_name => 'TacticChannelReportColumn',
442             element_type => 'TacticChannelReportColumn'
443             },
444             ArrayOfTrafficSourcesReportColumn => {
445             namespace_uri => 'https://adcenter.microsoft.com/v6',
446             element_name => 'TrafficSourcesReportColumn',
447             element_type => 'TrafficSourcesReportColumn'
448             },
449             ArrayOfint => {
450             namespace_uri => 'http://schemas.microsoft.com/2003/10/Serialization/Arrays',
451             element_name => 'int',
452             element_type => 'int'
453             },
454             ArrayOflong => {
455             namespace_uri => 'http://schemas.microsoft.com/2003/10/Serialization/Arrays',
456             element_name => 'long',
457             element_type => 'long'
458             },
459             ArrayOfstring => {
460             namespace_uri => 'http://schemas.microsoft.com/2003/10/Serialization/Arrays',
461             element_name => 'string',
462             element_type => 'string'
463             },
464             );
465              
466             sub _array_types {
467             return %_array_types;
468             }
469              
470             __PACKAGE__->mk_accessors(qw/
471             ApplicationToken
472             CustomerAccountId
473             CustomerId
474             DeveloperToken
475             Password
476             UserName
477             TrackingId
478             /);
479              
480             1;