thanks for the reply Danial,
I managed to get it working by searching the github repo of the python
client for 'CustomerService', as I couldn't find it in the documentation.
Here's what worked:
adwords_client = AdWordsClient(environ.get('ADWORDS_DEVELOPER_TOKEN'),
oauth_client, user_agent='your_user_agent_here')
customer = adwords_client.GetService('CustomerService').get()
customer_id = customer['customerId']
regards,
imran
On Monday, February 16, 2015 at 6:47:01 AM UTC-8, Danial Klimkin wrote:
>
> Hello imran,
>
>
> The CustomerService.get method has no parameters:
>
>
> https://developers.google.com/adwords/api/docs/reference/v201409/CustomerService#get
>
> Are you using any of our client libraries?
>
>
> -Danial, AdWords API Team.
>
>
> On Sunday, February 15, 2015 at 1:38:59 AM UTC+3, skunkwerk wrote:
>>
>> Hi,
>>
>> I have an adwords user's oauth credentials, and I'm able to successfully
>> make a call to download a report, but I had to hard-code in the customerId
>> as I couldn't figure out how to get it.
>>
>> The get() method of the CustomerService
>> <https://developers.google.com/adwords/api/docs/reference/v201409/CustomerService>
>>
>> should return the customer ID, but what are the parameters to pass to it?
>>
>> I tried a GET request to this URL:
>> https://adwords.google.com/api/adwords/mcm/v201409
>> without any header params or body params, to which it returns
>> "<html><body>No service was found.</body></html>".
>> I also tried with an Authorization and developerToken defined in the
>> headers, but got the same response.
>>
>> I also tried the python library, and defined an instance of
>> AdWordsClient, but it's client_customer_id ends up as None.
>>
>> thanks for the help,
>> imran
>>
>
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
---
You received this message because you are subscribed to the Google Groups
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
Visit this group at http://groups.google.com/group/adwords-api.
To view this discussion on the web visit
https://groups.google.com/d/msgid/adwords-api/b0bcaccc-3a7a-42e7-850d-63ced950cfda%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.