Google Ads API: "campaign.label" in SELECT query bugged in campaign?

171 views
Skip to first unread message

Mat

unread,
Jun 10, 2020, 11:04:59 AM6/10/20
to AdWords API and Google Ads API Forum
Hi, 

I keep getting strange errors when I try to fetch a campaign report that includes the "campaign.labels" field in the SELECT query:


[2020-06-10 16:54:10,880 - INFO] Request
-------
Method: /google.ads.googleads.v3.services.GoogleAdsService/SearchStream
Headers: {
  "developer-token": "REDACTED",
  "login-customer-id": "987654321",
  "x-goog-api-client": "gl-python/3.8.2 grpc/1.27.2 gax/1.17.0 gapic/5.1.0",
  "x-goog-request-params": "customer_id=123456789"
}
Request: customer_id: "123456789"
query: "SELECT campaign.id, campaign.name, campaign.labels, campaign.advertising_channel_type, metrics.clicks, metrics.cost_micros, metrics.conversions, metrics.conversions_value FROM campaign WHERE segments.date BETWEEN \"2017-06-01\" AND \"2020-06-09\""


Response
-------
Headers: {
  "google.ads.googleads.v3.errors.googleadsfailure-bin": "\n7\n\u0002\b\u0001\u0012&The error code is not in this version.\u001a\t*\u0007Day.day\nY\n\u0002\b\u0001\u0012&The error code is not in this version.\u001a+*)A_campaign__CampaignAssociation.entity_id\nO\n\u0002\b\u0001\u0012&The error code is not in this version.\u001a!*\u001fCampaignAssociation.campaign_id\nO\n\u0002\b\u0001\u0012&The error code is not in this version.\u001a!*\u001fCampaignAssociation.entity_type\n,\n\u0002\b\u0001\u0012&The error code is not in this version.",
  "grpc-status-details-bin": "\b\u0003\u0012%Request contains an invalid argument.\u001a\u0003\nCtype.googleapis.com/google.ads.googleads.v3.errors.GoogleAdsFailure\u0012\u0002\n7\n\u0002\b\u0001\u0012&The error code is not in this version.\u001a\t*\u0007Day.day\nY\n\u0002\b\u0001\u0012&The error code is not in this version.\u001a+*)A_campaign__CampaignAssociation.entity_id\nO\n\u0002\b\u0001\u0012&The error code is not in this version.\u001a!*\u001fCampaignAssociation.campaign_id\nO\n\u0002\b\u0001\u0012&The error code is not in this version.\u001a!*\u001fCampaignAssociation.entity_type\n,\n\u0002\b\u0001\u0012&The error code is not in this version.",
  "request-id": "-1LZX01Md9L2bk35eQFGug"
}
Fault: errors {
  error_code {
    request_error: UNKNOWN
  }
  message: "The error code is not in this version."
  trigger {
    string_value: "Day.day"
  }
}
errors {
  error_code {
    request_error: UNKNOWN
  }
  message: "The error code is not in this version."
  trigger {
    string_value: "A_campaign__CampaignAssociation.entity_id"
  }
}
errors {
  error_code {
    request_error: UNKNOWN
  }
  message: "The error code is not in this version."
  trigger {
    string_value: "CampaignAssociation.campaign_id"
  }
}
errors {
  error_code {
    request_error: UNKNOWN
  }
  message: "The error code is not in this version."
  trigger {
    string_value: "CampaignAssociation.entity_type"
  }
}
errors {
  error_code {
    request_error: UNKNOWN
  }
  message: "The error code is not in this version."
}


The error remains the same no matter if I there are lables to be fetched or not.

The exact same request without the "campaign.labels" field in the SELECT query works fine. 
Would you please look into it and tell me, what the problem is?

Regards 
Mat

Google Ads API Forum Advisor Prod

unread,
Jun 10, 2020, 2:35:17 PM6/10/20
to m...@keyword-experte.de, adwor...@googlegroups.com
Hi Mat,

Thank you for reaching out. Can you please share your un-masked logs via Reply privately to author so I can further investigate the issue?

Regards,
Mitchell
Google Ads API Team

ref:_00D1U1174p._5004Q20Xmh2:ref

Rob Martin

unread,
Jun 22, 2020, 2:35:29 PM6/22/20
to AdWords API and Google Ads API Forum
I'm encountering the same issue. This part of the Google Ads API documentation makes it sound like you can combine labels with metrics on the Campaign and Ad Group resources, but I get a similar ` request_error: UNKNOWN ` response whenever I include campaign.labels while also querying any metric on the campaign resource. Please include the resolution on this thread, or let me know how I can follow up with more detail.

Thanks,
Rob

Google Ads API Forum Advisor Prod

unread,
Jun 26, 2020, 2:37:02 PM6/26/20
to r...@rankcrankers.com, adwor...@googlegroups.com
Hi Rob,

This is a known bug that's preventing labels and metrics from being selected together. The team is actively working on a fix. I'll follow up here when there's a resolution, or if I have any additional questions for you.

Best,
Ben, Google Ads API Team

ref:_00D1U1174p._5004Q20Xmh2:ref

Rob Martin

unread,
Jun 26, 2020, 3:22:50 PM6/26/20
to Google Ads API Forum Advisor Prod, adwor...@googlegroups.com
Ok, thanks for the update. 

ROB MARTIN - VP of Operations
Rank Crankers
110 5th Ave SE, Suite 300 | Minneapolis, MN 55414

david...@funnel.io

unread,
Aug 24, 2020, 3:36:43 AM8/24/20
to AdWords API and Google Ads API Forum
Hi,

Is there any updates on this? This is very important to us and it would be nice to get a sense of when this will be working.

Thanks!
BR
David @ Funnel

Google Ads API Forum Advisor Prod

unread,
Aug 24, 2020, 10:34:46 AM8/24/20
to david...@funnel.io, adwor...@googlegroups.com
Hi David,

Great news - the bug has finally been fixed! Please try making your request again this week and let me know if you continue to experience any issues.

Regards,
Danica, Google Ads API Team

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