I needs to understand in which part of the request does the authorization token implemented? I received error AuthenticationError.LOGIN_COOKIE_REQUIRED and if i add the token it is AuthenticationError.OAUTH_TOKEN_INVALID. Could someone help me with an example or undestand what is missing? I used SoapUi for try the call.
- Requerst to AdwordsUserListService with mutateMembers operation:
- <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v20="https://adwords.google.com/api/adwords/rm/v201710" xmlns:v201="https://adwords.google.com/api/adwords/cm/v201710">
- <soapenv:Header>
- <v20:RequestHeader>
- <v201:clientCustomerId>customerID</v201:clientCustomerId>
- <v201:developerToken>someToken</v201:developerToken>
- <v201:userAgent>aName</v201:userAgent>
- <v201:validateOnly>false</v201:validateOnly>
- <v201:partialFailure>false</v201:partialFailure>
- </v20:RequestHeader>
- </soapenv:Header>
- <soapenv:Body>
- <v20:mutateMembers>
- <v20:operations>
- <v201:operator>ADD</v201:operator>
- <v201:Operation.Type/>
- <v20:operand>
- <v20:userListId>aNumber</v20:userListId>
- <v20:removeAll>false</v20:removeAll>
- <v20:membersList>
- <v20:hashedEmail>value</v20:hashedEmail>
- <v20:mobileId/>
- <v20:hashedPhoneNumber/>
- <v20:addressInfo>
- <v20:hashedFirstName>value</v20:hashedFirstName>
- <v20:hashedLastName>value</v20:hashedLastName>
- <v20:countryCode/>
- <v20:zipCode>value</v20:zipCode>
- </v20:addressInfo>
- <v20:userId/>
- </v20:membersList>
- <v20:membersList>
- <v20:hashedEmail>value</v20:hashedEmail>
- <v20:mobileId/>
- <v20:hashedPhoneNumber/>
- <v20:addressInfo>
- <v20:hashedFirstName>value</v20:hashedFirstName>
- <v20:hashedLastName>value</v20:hashedLastName>
- <v20:countryCode/>
- <v20:zipCode>value</v20:zipCode>
- </v20:addressInfo>
- <v20:userId/>
- </v20:membersList>
- </v20:operand>
- </v20:operations>
- </v20:mutateMembers>
- </soapenv:Body>
- </soapenv:Envelope>
- Response for the call without the authorization token
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<ns2:ResponseHeader xmlns:ns2="https://adwords.google.com/api/adwords/rm/v201710" xmlns="https://adwords.google.com/api/adwords/cm/v201710">
<requestId>000562fdc1c2db300a813252960a78e3</requestId>
<serviceName>AdwordsUserListService</serviceName>
<methodName>mutateMembers</methodName>
<operations>1</operations>
<responseTime>195</responseTime>
</ns2:ResponseHeader>
</soap:Header>
<soap:Body>
<soap:Fault>
<faultcode>soap:Client</faultcode>
<faultstring>[AuthenticationError.LOGIN_COOKIE_REQUIRED @ ; trigger:'<null>']</faultstring>
<detail>
<ns2:ApiExceptionFault xmlns="https://adwords.google.com/api/adwords/cm/v201710" xmlns:ns2="https://adwords.google.com/api/adwords/rm/v201710">
<message>[AuthenticationError.LOGIN_COOKIE_REQUIRED @ ; trigger:'<null>']</message>
<ApplicationException.Type>ApiException</ApplicationException.Type>
<errors xsi:type="AuthenticationError" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<fieldPath/>
<trigger><null></trigger>
<errorString>AuthenticationError.LOGIN_COOKIE_REQUIRED</errorString>
<ApiError.Type>AuthenticationError</ApiError.Type>
<reason>LOGIN_COOKIE_REQUIRED</reason>
</errors>
</ns2:ApiExceptionFault>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>
- Response for the call with the authorization token
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<ns2:ResponseHeader xmlns:ns2="https://adwords.google.com/api/adwords/rm/v201710" xmlns="https://adwords.google.com/api/adwords/cm/v201710">
<requestId>000562fde5c725b80a8105c5b00ce79e</requestId>
<serviceName>AdwordsUserListService</serviceName>
<methodName>mutateMembers</methodName>
<operations>1</operations>
<responseTime>36</responseTime>
</ns2:ResponseHeader>
</soap:Header>
<soap:Body>
<soap:Fault>
<faultcode>soap:Client</faultcode>
<faultstring>[AuthenticationError.OAUTH_TOKEN_INVALID @ ; trigger:'<null>']</faultstring>
<detail>
<ns2:ApiExceptionFault xmlns="https://adwords.google.com/api/adwords/cm/v201710" xmlns:ns2="https://adwords.google.com/api/adwords/rm/v201710">
<message>[AuthenticationError.OAUTH_TOKEN_INVALID @ ; trigger:'<null>']</message>
<ApplicationException.Type>ApiException</ApplicationException.Type>
<errors xsi:type="AuthenticationError" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<fieldPath/>
<trigger><null></trigger>
<errorString>AuthenticationError.OAUTH_TOKEN_INVALID</errorString>
<ApiError.Type>AuthenticationError</ApiError.Type>
<reason>OAUTH_TOKEN_INVALID</reason>
</errors>
</ns2:ApiExceptionFault>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>
Can someone tell me how use this Authorization : Bearer YOUR_ACCESS_TOKEN?
Thanks everyone