Sunday, October 1, 2017

How to Keep AdWords Scripts Running When the AdWords API Changes



The AdWords API is regularly updated by Google with their latest capabilities. While it's great not to have to wait too long to get access to new capabilities, it comes with a downside too: AdWords Scripts may stop working on the day Scripts switch to using a newer version of the API.

The reason is that new API version may rename or remove metrics and attributes. An AdWords Script that is not updated with these latest names will stop working. 

You can find the release dates of new API versions here and the table looks like this:


The release date is not always the date that AdWords Scripts start to use the newer version. As a result, it is very tricky to ensure that scripts you write continue to work. 

Luckily there is a solution and it's as simple as telling your script which API version it should use by including the optional apiVersion argument. 

A reporting call without the API version: 
var report2 = AdWordsApp.report(
     'SELECT AdGroupId, Id, KeywordText, Impressions, Clicks ' +
     'FROM   KEYWORDS_PERFORMANCE_REPORT ' +
     'DURING 20130101,20130301');
And that same call with the API version:
var report2 = AdWordsApp.report(
     'SELECT AdGroupId, Id, KeywordText, Impressions, Clicks ' +
     'FROM   KEYWORDS_PERFORMANCE_REPORT ' +
     'DURING 20130101,20130301', {
       apiVersion: 'v201605'
     });

By telling the script which API version to use, you guarantee that it will continue to work on the day that Google switches the default the a new version because you now control the switch that tells the script when your code has been updated and should start using a new API version.

You'll still need to do the migration at some point, but you'll have several months to do so. The sunset date in the table above indicates the final day that a script can use a particular API version. After that date, the old version will cease to work.

Note that you do NOT have to go through every API version. It's completely acceptable to skip a version if you don't need any of its capabilities. For example, say you were using v201609. Since it doesn't sunset until October 2, 2017, you could have waited for the release of v201708 on August 9, 2017, and skipped the 2 API versions in between.

The scripts in the Optmyzr Enhanced Scripts library handle all of these API transitions automatically for our users so if you'd rather not deal with API versions, it's a great solution to try. (Optmyzr is my employer)

23 comments:

  1. I really appreciate this post,your article is valuable for me and for others. Thanks for sharing your information!
    Best website designing company in Laxmi Nagar

    ReplyDelete
  2. Invest in an heirloom to cherish forever with a timepiece from the fake cartier watches collection. A fusion of cutting-edge technology and heritage craftsmanship, replica calibre de cartier carbon diver watchesCartier’s fine watches carry the replica calibre de cartier carbon diver watches prestige of the brand’s illustrious history and exceptional quality.

    ReplyDelete
  3. Gelbooru is the website of Japanese made hentai, this website has millions of pictures of Japanese children. This website has millions of visitors coming and watching these pictures. In addition, it has its own website to address various category forms with different outcomes. Anyone can create an account here, and access free photos to create a free user account to sign up.

    ReplyDelete
  4. Great info. Thank you for sharing this fascinating information together.here are a lot of people looking for posts like this. Peaky Blinder Costumes

    ReplyDelete
  5. Putlocker may be a seamless portal for television, series, movies, songs, etc. for free. it's not mainly for any film or language, from Hollywood to Bollywood, one can have access to each possible movie. In fact, unlike other portals who operate completely illegally, Putlocker has an official site named Putlocker.com that a broad base of individuals is mad.

    For the official content recorded, over 1.6 million people worldwide made access to it portal on a per-day basis. because of the piracy issues, it faced a report by motion picture Association of America, which led to its pack up by the united kingdom court Order. it had been considered together of the highest 250 sites visited by the people worldwide. Although, thanks to its massive fan base, Putlockers remains operated under different proxy websites.


    In October 2018, the MPAA's report on Online Notorious Markets to the United States Trade Representative, said that the conclusion of 123movies, 123movieshub, gostream, and gomovies, by walking of a criminal examination in Vietnam in 2018, was "a significant turn of events" in combatting illicit film theft administrations. In any case, the MPAA report additionally noticed that various copycat locales had risen in any event eight different nations. In November 2018 TorrentFreak revealed locales associated or like 123Movies, for example, WatchAsap had additionally been closed somewhere around the FBI, yet were re-coordinating to other document sharing destinations.

    ReplyDelete
  6. Protect your website with automated risk assessment technology

    ReplyDelete
  7. HP Scanner Not Working Error, scanner not working is the basic mistake and it very well may be fathomed by following these basic advances. For Further Guidance to this printer arrangement

    ReplyDelete
  8. Thanks for the great content Mr Unknown! I loved your post about Free AdWords Scripts and Google Ads. I hope this would be very helpful for many people in regard to a PPC task. By: Buy Assignment Online

    ReplyDelete
  9. Great info. Thank you for sharing this fascinating information together. Retaliation Cobra Commander Costume

    ReplyDelete
  10. Websites like Yes Porn Please are pretty hard to work out. For starters, the planning of those websites is pretty fucking simple, so you cannot really tell what the hell goes on up in there. Then, the name of this website in specific doesn't really tell us tons about the contents of the page, which is pretty weird, but not uncommon. For the foremost part, websites that are hard to work out will have some kind of gimmick in their name which will either make it much easier for you to recollect just what they're all about, or rather, just to form the name of the page stay in your head for as long as possible in order that you retain returning thereto over and once again .

    All in all, this website right here is pretty mysterious, but i feel that you simply could call YesPornPlease.com an "all-brown" websites, as there are all kinds of dark-skinned couples on this page just going at it. Furthermore, it should even be mentioned that these couples right here don't like fucking for professional porn studios and every one that, but rather, they create their own sex tapes reception , and that is a reasonably big thing at YesPornPlease.com!

    ReplyDelete
  11. Quickbooks is a popular accounting tool, used to record data's, pay bills, send payroll and complete payroll and many other useful features. If you need any assistance regarding to any problems you face on Quickbooks head for Quickbooks error

    ReplyDelete
  12. As a final semester digital marketing student, I think these tips will definitely help me in the Adwords class. I am actually more interested in the social media side of things and have been searching for Digital Marketing Dissertation Topics related to social media. However, having an advanced understanding of Adwords will do no harm. I am saving this post and bookmarking this page – I will definitely be coming back to it in the future and also sharing it with my friends.

    ReplyDelete
  13. On 25 March 2001, Arlo Logue had been born in the U.S. Yet her name was changed into Jade Logue after a certain time. She is born Finn Logue, an older brother who has grown up in his parents ‘ lovely house. Jade Logue

    ReplyDelete
  14. Many factors need to be considered when you have to go through the anxiety of picking the right daycare and the right people. We are here to help you with that.

    Your perfect daycare should have an engaging, happy, and comfortable aura for your child. children's learning adventure

    ReplyDelete
  15. Hello Guys,
    I am Sahil or You can call me a Digital Marketer who loves to find Digital Marketing Loops on the Internet. So, let talk about some of the Best Digital Marketing Categories.

    Digital Marketing Expert in Dwarka Mor

    ReplyDelete
  16. Your blogs are great. Are you also searching for Help with my Math assignment? we are the best solution for you. We are best known for delivering quality essay writing services to students without having to break the bank

    ReplyDelete
  17. Your blogs are great. Are you also searching for nursing capstone writing project? we are the best solution for you. We are best known for delivering quality nursing capstone writing services to students without having to break the bank

    ReplyDelete
  18. Yep, this... Really, this is the only thing I'm missing... really like it otherwise. cookie clicker slope unblocked

    ReplyDelete