Hi,
When used in this way, the InfoService will only return accounts for
which you have API usage. You can use the GetAccountHierarchy code example
to get a list of all accounts managed by your MCC.
- Kevin Winter
AdWords API Team
On Wednesday, June 20, 2012 2:27:44 PM UTC-4, Claudio Pomo wrote:
>
> I want to retrieve all clientID from my MCC account. I'm using this code
>
>
> AdWordsUser user = new
> AdWordsUser(adwordsPropertyService.getEmail(),
> adwordsPropertyService.getPassword(),
> null, adwordsPropertyService.getUseragent(),
> adwordsPropertyService.getDeveloperToken(),
> adwordsPropertyService.getUseSandbox());
>
> InfoServiceInterface infoService =
> user.getService(AdWordsService.V201109.INFO_SERVICE);
>
>
> InfoSelector selector = new InfoSelector();
> selector.setApiUsageType(ApiUsageType.UNIT_COUNT_FOR_CLIENTS);
> String today = new SimpleDateFormat("yyyyMMdd").format(new
> Date());
> selector.setDateRange(new DateRange(today, today));
> selector.setIncludeSubAccounts(true);
>
> ApiUsageInfo apiUsageInfo = infoService.get(selector);
> for (ApiUsageRecord record : apiUsageInfo.getApiUsageRecords())
> {
> ......
>
> But apiUsageInfo.getApiUsageRecords return my only some clientId.
> Have you any suggests?
>
> On Friday, June 8, 2012 6:01:29 PM UTC+2, David Torres wrote:
>>
>> Hi Claudio,
>>
>> The problem is that you are specifying your MCC id as clientCustomerId,
>> instead what you want to specify the id of the account owner of those
>> campaigns.
>>
>> Best,
>>
>> -David Torres - AdWords API Team
>>
>> On Friday, June 8, 2012 3:30:16 AM UTC-4, Claudio Pomo wrote:
>>>
>>> *requestId=0004c1bcd7694f100a3414e3000050c1*
>>>
>>> On Thursday, June 7, 2012 10:41:39 PM UTC+2, Claudio Pomo wrote:
>>>>
>>>> Hi David,
>>>>
>>>> where I can found a request id?
>>>>
>>>> On Thursday, June 7, 2012 9:22:59 PM UTC+2, David Torres wrote:
>>>>>
>>>>> Hi Claudio,
>>>>>
>>>>> Can you post a request id? I'll be glad to check.
>>>>>
>>>>> Best,
>>>>>
>>>>> -David Torres - AdWords API Team
>>>>>
>>>>> On Tuesday, June 5, 2012 1:46:16 PM UTC-4, Claudio Pomo wrote:
>>>>>>
>>>>>> I'm using adwords API for java but when I try to "mutate" my
>>>>>> campaign I get this error:
>>>>>>>
>>>>>>> AxisFault
>>>>>>>
>>>>>>> faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server
>>>>>>>
>>>>>>> faultSubcode:
>>>>>>>
>>>>>>> faultString: [EntityNotFound.INVALID_ID @ operations[0].operand;
>>>>>>>> trigger:'CampaignId: 93996448', EntityNotFound.INVALID_ID @
>>>>>>>> operations[1].operand; trigger:'CampaignId: *******',
>>>>>>>> EntityNotFound.INVALID_ID @ operations[2].operand;
>>>>>>>> trigger:'CampaignId: *******', EntityNotFound.INVALID_ID @
>>>>>>>> operations[3].operand; trigger:'CampaignId: *******',
>>>>>>>> EntityNotFound.INVALID_ID @ operations[4].operand;
>>>>>>>> trigger:'CampaignId: *******', EntityNotFound.INVALID_ID @
>>>>>>>> operations[5].operand; trigger:'CampaignId: *******',
>>>>>>>> EntityNotFound.INVALID_ID @ operations[6].operand;
>>>>>>>> trigger:'CampaignId: *******', EntityNotFound.INVALID_ID @
>>>>>>>> operations[7].operand; trigger:'CampaignId: *******'
>>>>>>>
>>>>>>>
>>>>>> I don't understand where is the problem because I've used adwords API
>>>>>> with PHP and there never still have been problem.
>>>>>>
>>>>>> I create a linkedList of "CampaignCriterionOperation"
>>>>>>
>>>>>>> operations2.add(new CampaignCriterionOperation(Operator.ADD,
>>>>>>> campaignCriterionType, new CampaignCriterion(campaign.getId(),
>>>>>>> location,
>>>>>>> campaignCriterionType)));
>>>>>>
>>>>>>
>>>>>> then I mutate the campaing
>>>>>>
>>>>>>> CampaignCriterionOperation[] operations = new
>>>>>>> CampaignCriterionOperation[operations2.size()];
>>>>>>
>>>>>> CampaignCriterionReturnValue result =
>>>>>>> campaignServiceOperation.mutate(operations2.toArray(operations));
>>>>>>
>>>>>>
>>>>>>
>>>>>
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
http://adwordsapi.blogspot.com
http://groups.google.com/group/adwords-api
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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