Skip to content

Commit

Permalink
Merge pull request #46 from trocco-io/feature/update_v14
Browse files Browse the repository at this point in the history
bump Google Ads SDK to 0.26.1 (support for Google Ads API v14.1)
  • Loading branch information
d-hrs authored Jan 9, 2024
2 parents f172dc8 + 7d54847 commit 1e37a05
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion shadow-google-ads-helper/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ configurations {
}

dependencies {
compile("com.google.api-ads:google-ads:25.0.0") {
compile("com.google.api-ads:google-ads:26.1.0") {
exclude group: "commons-logging", module: "commons-logging"
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package org.embulk.input.google_ads;

import com.google.ads.googleads.v13.services.GoogleAdsRow;
import com.google.ads.googleads.v13.services.GoogleAdsServiceClient;
import com.google.ads.googleads.v14.services.GoogleAdsRow;
import com.google.ads.googleads.v14.services.GoogleAdsServiceClient;
import com.google.common.collect.ImmutableList;

import org.embulk.config.ConfigDiff;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
import com.fasterxml.jackson.databind.node.JsonNodeType;
import com.fasterxml.jackson.databind.node.ObjectNode;
import com.google.ads.googleads.lib.GoogleAdsClient;
import com.google.ads.googleads.v13.services.GoogleAdsRow;
import com.google.ads.googleads.v13.services.GoogleAdsServiceClient;
import com.google.ads.googleads.v13.services.SearchGoogleAdsRequest;
import com.google.ads.googleads.v14.services.GoogleAdsRow;
import com.google.ads.googleads.v14.services.GoogleAdsServiceClient;
import com.google.ads.googleads.v14.services.SearchGoogleAdsRequest;
import com.google.auth.oauth2.UserCredentials;
import com.google.common.base.CaseFormat;
import com.google.protobuf.Descriptors;
Expand Down Expand Up @@ -62,7 +62,7 @@ public Iterable<GoogleAdsServiceClient.SearchPage> getReportPage()
String query = buildQuery(task, startDateTime);
logger.info(query);
SearchGoogleAdsRequest request = buildRequest(task, query);
GoogleAdsServiceClient googleAdsService = client.getVersion13().createGoogleAdsServiceClient();
GoogleAdsServiceClient googleAdsService = client.getVersion14().createGoogleAdsServiceClient();
GoogleAdsServiceClient.SearchPagedResponse response = googleAdsService.search(request);

if (response.getPage().getResponse().getResultsCount() == 0) {
Expand Down

0 comments on commit 1e37a05

Please sign in to comment.