Google Ads API: MutateJobService Code Examples

128 views
Skip to first unread message

goingdev

unread,
May 9, 2019, 12:34:49 PM5/9/19
to AdWords API and Google Ads API Forum

I'm in the process of converting from the Adwords API to the Ads API.

To process bulk operations and get their results, I've used the BatchJob and BatchJobService to upload jobs with the following code:

    BatchJobService batchJobService = (BatchJobService)user.GetService(AdWordsService.v201809.BatchJobService);
   
BatchJobOperation addOp = new BatchJobOperation()
   
{
       
@operator = Operator.ADD,
        operand
= new BatchJob()
   
};
   
BatchJob batchJob = batchJobService.mutate(new BatchJobOperation[] { addOp }).value[0];

   
BatchJobUtilities batchJobUploadHelper = new BatchJobUtilities(user, true, 4 * 1024 * 1024);
   
string resumableUploadUrl = batchJobUploadHelper.GetResumableUploadUrl(batchJob.uploadUrl.url);
    batchJobUploadHelper
.Upload(resumableUploadUrl, batch.ToArray());


I haven't found examples in the Google Ads API documentation using the MutateJobService, AddMutateJobOperationsRequest etc.

Questions:
  1. How would I upload a batch job and get its response with the new Google Ads API? I'm using the .NET / C# client library. Can you post some sample code?
  2. The documentation states that this feature is white-listed. Is this still the case, and if yes, how can we get white-listed? As most of our requests are done through the batch service, we will not be able to start using or testing the Google Ads API until this feature is accessible to us.

googleadsapi...@google.com

unread,
May 9, 2019, 5:00:30 PM5/9/19
to AdWords API and Google Ads API Forum
Hello,

Yes, as per the document, for now Batch job service is a whitelisted feature. The code samples to create the batch jobs is not yet available for Google Ads API. Our team is aware of this concern, meanwhile you could keep an eye on our blog for information related to the future releases.

Regards,
Sai Teja, Google Ads API Team


=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
    https://ads-developers.googleblog.com/search/label/google_ads_api
    https://developers.google.com/adwords/api/community/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

Was your question answered? Please rate your experience with us by taking a short survey.
If not -- reply to this email and tell us what else we can do to help.

Take Survey

Also find us on our blog and discussion group:
http://googleadsdeveloper.blogspot.com/search/label/adwords_api
https://developers.google.com/adwords/api/community/

RY

unread,
May 10, 2019, 12:13:22 PM5/10/19
to AdWords API and Google Ads API Forum
How can I get whitelisted?

As stated in my OP, the majority of the requests to the API are done through the BatchService, as they are long running jobs with potentially thousands of operations uploading with each one.

I cannot migrate to the new API without being able to test this. It is integral to my app.
Message has been deleted

Wesley Bowman

unread,
May 13, 2019, 5:30:31 AM5/13/19
to AdWords API and Google Ads API Forum
Is there any sort of estimation on when this feature will be released?

When I went to the workshop, we asked about this feature then (March 26), and we were told it would potentially be released in 2-3 weeks. It's now been a quite a bit longer than that, and this is the feature we need to continue with our migration from the old API to the new.

This is holding up our entire process :/


On Friday, May 10, 2019 at 11:16:14 PM UTC+2, googleadsapi-forumadvisor wrote:
Hello,

As of now we are not accepting the whitelisting for the batch-job services, It's still in testing phase.

Regards,
Sai Teja, Google Ads API Team

=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
    https://ads-developers.googleblog.com/search/label/google_ads_api
    https://developers.google.com/adwords/api/community/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

googleadsapi...@google.com

unread,
May 14, 2019, 3:26:42 AM5/14/19
to wes...@channable.com, AdWords API and Google Ads API Forum
Hello Wesley,

I apologize for keeping you waiting. 
The engineering team is working their best to make this feature complete and robust before releasing it widely.
We're expecting to have it very soon, probably in the next release.

Best,
Thanet, Google Ads API Team


=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
    https://ads-developers.googleblog.com/search/label/google_ads_api
    https://developers.google.com/adwords/api/community/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
 
You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwor...@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscribe@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api+unsubscribe@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/5b91742a-4c4f-4d60-ac3c-4b97e09baf21%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

RY

unread,
Jun 25, 2019, 5:28:41 PM6/25/19
to AdWords API and Google Ads API Forum
Any update on this? When will this be released?

Google Ads API Forum Advisor Prod

unread,
Jun 26, 2019, 3:12:31 AM6/26/19
to adwor...@googlegroups.com
Hi,

As of now, we still do not have information as to when this will be fully available. Please continue to follow our blog for updates.

Thanks and regards,
Peter
Google Ads API Team

ref:_00D1U1174p._5001UCZUjm:ref
Reply all
Reply to author
Forward
0 new messages