« blib/lib/Google/Ads/AdWords/v201809/CustomerNegativeCriterionService/CustomerNegativeCriterionServiceInterfacePort.pm
↑ Summary
blib/lib/Google/Ads/AdWords/v201809/FeedItemService/FeedItemServiceInterfacePort.pm »
| 1 | package Google::Ads::AdWords::v201809::DraftService::DraftServiceInterfacePort; | ||
| 2 | use strict; | ||
| 3 | use warnings; | ||
| 4 | use Class::Std::Fast::Storable; | ||
| 5 | use Scalar::Util qw(blessed); | ||
| 6 | use base qw(SOAP::WSDL::Client::Base); | ||
| 7 | |||
| 8 | # only load if it hasn't been loaded before | ||
| 9 | require Google::Ads::AdWords::v201809::TypeMaps::DraftService | ||
| 10 | if not Google::Ads::AdWords::v201809::TypeMaps::DraftService->can('get_class'); | ||
| 11 | |||
| 12 | sub START { | ||
| 13 | $_[0]->set_proxy('https://adwords.google.com/api/adwords/cm/v201809/DraftService') if not $_[2]->{proxy}; | ||
| 14 | $_[0]->set_class_resolver('Google::Ads::AdWords::v201809::TypeMaps::DraftService') | ||
| 15 | if not $_[2]->{class_resolver}; | ||
| 16 | |||
| 17 | $_[0]->set_prefix($_[2]->{use_prefix}) if exists $_[2]->{use_prefix}; | ||
| 18 | } | ||
| 19 | |||
| 20 | sub get { | ||
| 21 | my ($self, $body, $header) = @_; | ||
| 22 | die "get must be called as object method (\$self is <$self>)" if not blessed($self); | ||
| 23 | return $self->SUPER::call({ | ||
| 24 | operation => 'get', | ||
| 25 | soap_action => '', | ||
| 26 | style => 'document', | ||
| 27 | body => { | ||
| 28 | |||
| 29 | |||
| 30 | 'use' => 'literal', | ||
| 31 | namespace => 'http://schemas.xmlsoap.org/wsdl/soap/', | ||
| 32 | encodingStyle => '', | ||
| 33 | parts => [qw( Google::Ads::AdWords::v201809::DraftService::get )], | ||
| 34 | }, | ||
| 35 | header => { | ||
| 36 | |||
| 37 | |||
| 38 | |||
| 39 | 'use' => 'literal', | ||
| 40 | namespace => 'http://schemas.xmlsoap.org/wsdl/soap/', | ||
| 41 | encodingStyle => '', | ||
| 42 | parts => [qw( Google::Ads::AdWords::v201809::DraftService::RequestHeader )], | ||
| 43 | }, | ||
| 44 | headerfault => { | ||
| 45 | |||
| 46 | } | ||
| 47 | }, $body, $header); | ||
| 48 | } | ||
| 49 | |||
| 50 | |||
| 51 | sub mutate { | ||
| 52 | my ($self, $body, $header) = @_; | ||
| 53 | die "mutate must be called as object method (\$self is <$self>)" if not blessed($self); | ||
| 54 | return $self->SUPER::call({ | ||
| 55 | operation => 'mutate', | ||
| 56 | soap_action => '', | ||
| 57 | style => 'document', | ||
| 58 | body => { | ||
| 59 | |||
| 60 | |||
| 61 | 'use' => 'literal', | ||
| 62 | namespace => 'http://schemas.xmlsoap.org/wsdl/soap/', | ||
| 63 | encodingStyle => '', | ||
| 64 | parts => [qw( Google::Ads::AdWords::v201809::DraftService::mutate )], | ||
| 65 | }, | ||
| 66 | header => { | ||
| 67 | |||
| 68 | |||
| 69 | |||
| 70 | 'use' => 'literal', | ||
| 71 | namespace => 'http://schemas.xmlsoap.org/wsdl/soap/', | ||
| 72 | encodingStyle => '', | ||
| 73 | parts => [qw( Google::Ads::AdWords::v201809::DraftService::RequestHeader )], | ||
| 74 | }, | ||
| 75 | headerfault => { | ||
| 76 | |||
| 77 | } | ||
| 78 | }, $body, $header); | ||
| 79 | } | ||
| 80 | |||
| 81 | |||
| 82 | sub query { | ||
| 83 | my ($self, $body, $header) = @_; | ||
| 84 | die "query must be called as object method (\$self is <$self>)" if not blessed($self); | ||
| 85 | return $self->SUPER::call({ | ||
| 86 | operation => 'query', | ||
| 87 | soap_action => '', | ||
| 88 | style => 'document', | ||
| 89 | body => { | ||
| 90 | |||
| 91 | |||
| 92 | 'use' => 'literal', | ||
| 93 | namespace => 'http://schemas.xmlsoap.org/wsdl/soap/', | ||
| 94 | encodingStyle => '', | ||
| 95 | parts => [qw( Google::Ads::AdWords::v201809::DraftService::query )], | ||
| 96 | }, | ||
| 97 | header => { | ||
| 98 | |||
| 99 | |||
| 100 | |||
| 101 | 'use' => 'literal', | ||
| 102 | namespace => 'http://schemas.xmlsoap.org/wsdl/soap/', | ||
| 103 | encodingStyle => '', | ||
| 104 | parts => [qw( Google::Ads::AdWords::v201809::DraftService::RequestHeader )], | ||
| 105 | }, | ||
| 106 | headerfault => { | ||
| 107 | |||
| 108 | } | ||
| 109 | }, $body, $header); | ||
| 110 | } | ||
| 111 | |||
| 112 | |||
| 113 | |||
| 114 | |||
| 115 | 1; | ||
| 116 | |||
| 117 | |||
| 118 | |||
| 119 | __END__ | ||
| 120 | |||
| 121 | =pod | ||
| 122 | |||
| 123 | =head1 NAME | ||
| 124 | |||
| 125 | Google::Ads::AdWords::v201809::DraftService::DraftServiceInterfacePort - SOAP Interface for the DraftService Web Service | ||
| 126 | |||
| 127 | =head1 SYNOPSIS | ||
| 128 | |||
| 129 | use Google::Ads::AdWords::v201809::DraftService::DraftServiceInterfacePort; | ||
| 130 | my $interface = Google::Ads::AdWords::v201809::DraftService::DraftServiceInterfacePort->new(); | ||
| 131 | |||
| 132 | my $response; | ||
| 133 | $response = $interface->get(); | ||
| 134 | $response = $interface->mutate(); | ||
| 135 | $response = $interface->query(); | ||
| 136 | |||
| 137 | |||
| 138 | |||
| 139 | =head1 DESCRIPTION | ||
| 140 | |||
| 141 | SOAP Interface for the DraftService web service | ||
| 142 | located at https://adwords.google.com/api/adwords/cm/v201809/DraftService. | ||
| 143 | |||
| 144 | =head1 SERVICE DraftService | ||
| 145 | |||
| 146 | |||
| 147 | |||
| 148 | =head2 Port DraftServiceInterfacePort | ||
| 149 | |||
| 150 | |||
| 151 | |||
| 152 | =head1 METHODS | ||
| 153 | |||
| 154 | =head2 General methods | ||
| 155 | |||
| 156 | =head3 new | ||
| 157 | |||
| 158 | Constructor. | ||
| 159 | |||
| 160 | All arguments are forwarded to L<SOAP::WSDL::Client|SOAP::WSDL::Client>. | ||
| 161 | |||
| 162 | =head2 SOAP Service methods | ||
| 163 | |||
| 164 | Method synopsis is displayed with hash refs as parameters. | ||
| 165 | |||
| 166 | The commented class names in the method's parameters denote that objects | ||
| 167 | of the corresponding class can be passed instead of the marked hash ref. | ||
| 168 | |||
| 169 | You may pass any combination of objects, hash and list refs to these | ||
| 170 | methods, as long as you meet the structure. | ||
| 171 | |||
| 172 | List items (i.e. multiple occurences) are not displayed in the synopsis. | ||
| 173 | You may generally pass a list ref of hash refs (or objects) instead of a hash | ||
| 174 | ref - this may result in invalid XML if used improperly, though. Note that | ||
| 175 | SOAP::WSDL always expects list references at maximum depth position. | ||
| 176 | |||
| 177 | XML attributes are not displayed in this synopsis and cannot be set using | ||
| 178 | hash refs. See the respective class' documentation for additional information. | ||
| 179 | |||
| 180 | |||
| 181 | |||
| 182 | =head3 get | ||
| 183 | |||
| 184 | Returns a DraftPage that contains a list of Draft objects matching the selector. @throws {#link com.google.ads.api.services.common.error.ApiException} if problems occurred while retrieving the results. | ||
| 185 | |||
| 186 | Returns a L<Google::Ads::AdWords::v201809::DraftService::getResponse|Google::Ads::AdWords::v201809::DraftService::getResponse> object. | ||
| 187 | |||
| 188 | $response = $interface->get( { | ||
| 189 | selector => $a_reference_to, # see Google::Ads::AdWords::v201809::Selector | ||
| 190 | },, | ||
| 191 | ); | ||
| 192 | |||
| 193 | =head3 mutate | ||
| 194 | |||
| 195 | The mutate action is used for creating new Drafts and controlling the life cycle of Drafts, such as abandoning or promoting Drafts. @return The list of updated Drafts, in the same order as the {@code operations} list. @throws {#link com.google.ads.api.services.common.error.ApiException} if problems occurred while processing the request. | ||
| 196 | |||
| 197 | Returns a L<Google::Ads::AdWords::v201809::DraftService::mutateResponse|Google::Ads::AdWords::v201809::DraftService::mutateResponse> object. | ||
| 198 | |||
| 199 | $response = $interface->mutate( { | ||
| 200 | operations => $a_reference_to, # see Google::Ads::AdWords::v201809::DraftOperation | ||
| 201 | },, | ||
| 202 | ); | ||
| 203 | |||
| 204 | =head3 query | ||
| 205 | |||
| 206 | Returns a DraftPage that contains a list of Draft objects matching the query. @throws {#link com.google.ads.api.services.common.error.ApiException} if problems occurred while retrieving the results. | ||
| 207 | |||
| 208 | Returns a L<Google::Ads::AdWords::v201809::DraftService::queryResponse|Google::Ads::AdWords::v201809::DraftService::queryResponse> object. | ||
| 209 | |||
| 210 | $response = $interface->query( { | ||
| 211 | query => $some_value, # string | ||
| 212 | },, | ||
| 213 | ); | ||
| 214 | |||
| 215 | |||
| 216 | |||
| 217 | =head1 AUTHOR | ||
| 218 | |||
| 219 | Generated by SOAP::WSDL on Thu Sep 20 11:09:28 2018 | ||
| 220 | |||
| 221 | =cut |