Google Ads API v12 - INVALID_ARGUMENT Error with Unknown Error Code

2,045 views
Skip to first unread message

Ibrahim Jarrar

unread,
Apr 4, 2023, 5:08:06 AM4/4/23
to Google Ads API and AdWords API Forum
Hello everyone,

I am facing an issue with the Google Ads API (version v12) and could use some help. I encountered a GoogleAdsException with an INVALID_ARGUMENT error. The error message indicates that the request contains an invalid argument, but I am unable to determine the exact cause. The error is related to the resource_name field within the update operation.

Here's the error message:
google.ads.googleads.errors.GoogleAdsException: (<_InactiveRpcError of RPC that terminated with:
status = StatusCode.INVALID_ARGUMENT
details = "Request contains an invalid argument."
debug_error_string = "UNKNOWN:Error received from peer ipv4:142.250.203.202:443 {grpc_message:"Request contains an invalid argument.", grpc_status:3, created_time:"2023-04-04T10:52:10.947727+02:00"}"
>, <_InactiveRpcError of RPC that terminated with:
status = StatusCode.INVALID_ARGUMENT
details = "Request contains an invalid argument."
debug_error_string = "UNKNOWN:Error received from peer ipv4:142.250.203.202:443 {grpc_message:"Request contains an invalid argument.", grpc_status:3, created_time:"2023-04-04T10:52:10.947727+02:00"}"
>, errors {
  error_code {
    request_error: UNKNOWN
  }
  message: "The error code is not in this version."
  location {
    field_path_elements {
      field_name: "operations"
      index: 0
    }
    field_path_elements {
      field_name: "update"
    }
    field_path_elements {
      field_name: "resource_name"
    }
  }
}
request_id: "62eVtPBlDx24CYGRuobjjw"
, '62eVtPBlDx24CYGRuobjjw')

The error occurs in any version I use, but I currently prefer the v12. The error message doesn't provide enough information about which error code is not in this version.

Has anyone encountered a similar issue or can provide guidance on how to resolve it? Any help would be greatly appreciated.

Thank you!

Google Ads API and AdWords API Forum

unread,
Apr 5, 2023, 8:01:34 AM4/5/23
to Google Ads API and AdWords API Forum

Re-posting the last inquiry (https://groups.google.com/g/adwords-api/c/c0kGHdPsz9A) from the forum as it wasn't routed to our support queue.


Regards,
Google Ads API Team

Google Ads API and AdWords API Forum

unread,
Apr 5, 2023, 6:47:52 PM4/5/23
to Google Ads API and AdWords API Forum
Hi,

Thank you for raising this concern to our team.

Regarding your concern, can you provide the complete request and response logs with request ID and request header generated on your end so our team can provide guidance accordingly? If you haven't yet, logging can be enabled by navigating to the Client libraries > Your client library (ex. Java) > Logging documentation, which you can access from this link.

You may then send the requested logs via the Reply privately to author option. If this option is not available, you may send the details directly to our googleadsa...@google.com alias instead.

Regards,
Google Ads API Team
On Tuesday, April 4, 2023 at 5:08:06 PM UTC+8 ibrahim...@vinted.com wrote:
Message has been deleted

Google Ads API and AdWords API Forum

unread,
Apr 13, 2023, 9:31:50 AM4/13/23
to Google Ads API and AdWords API Forum

Re-posting the last inquiry (https://groups.google.com/g/adwords-api/c/c0kGHdPsz9A) from the forum as it wasn't routed to our support queue.


Regards,
Google Ads API Team
On Tuesday, April 11, 2023 at 8:47:55 PM UTC+8 ibrahim...@vinted.com wrote:
Request
-------
Method: /google.ads.googleads.v12.services.AdService/GetAd
Headers: {
"developer-token": "REDACTED",
"login-customer-id": "2189850922",
"x-goog-api-client": "gl-python/3.8.11 grpc/1.48.0 gax/2.10.1 gccl/19.0.0 pb/4.22.0",
"x-goog-request-params": "resource_name=customers/3815500097/ads/640893474384"
}
Request: resource_name: "customers/3815500097/ads/640893474384"
Response
-------
Headers: {
"alt-svc": "h3=\":443\"; ma=2592000,h3-29=\":443\"; ma=2592000",
"content-disposition": "attachment",
"date": "Tue, 11 Apr 2023 12:01:22 GMT",
"request-id": "-gcxsR1SihGjbZbxDxZjLw"
}
Response: resource_name: "customers/3815500097/ads/640893474384"
id: 640893474384
final_app_urls {
os_type: ANDROID
}
type_: APP_ENGAGEMENT_AD
added_by_google_ads: false
app_engagement_ad {
headlines {
text: "Carica il tuo primo articolo."
}
headlines {
text: "Carica gli articoli. Guadagna."
}
headlines {
text: "Carica i tuoi abiti e guadagna"
}
headlines {
text: "Sai che non le metti."
}
descriptions {
text: "Abbiamo tutti dei vestiti che non usiamo. Vendi i più belli. Caricali subito su Vinted!"
}
descriptions {
text: "Non lasciare le tue sneaker chiuse in un armadio. Vendile su Vinted e guadagna!"
}
descriptions {
text: "Cosa aspetti? Con Vinted puoi caricare i tuoi articoli in pochi minuti. Provaci!"
}
descriptions {
text: "Libera l\'armadio e guadagna in un colpo solo. Carica i tuoi vestiti su Vinted!"
}
descriptions {
text: "Passo n.1: carica ora il tuo primo articolo su Vinted e inizia a guadagnare."
}
images {
asset: "customers/3815500097/assets/14247976785"
}
images {
asset: "customers/3815500097/assets/14247976788"
}
images {
asset: "customers/3815500097/assets/14765851554"
}
images {
asset: "customers/3815500097/assets/14765851557"
}
images {
asset: "customers/3815500097/assets/18381104240"
}
images {
asset: "customers/3815500097/assets/18122264643"
}
videos {
asset: "customers/3815500097/assets/37114989499"
}
videos {
asset: "customers/3815500097/assets/37114972789"
}
videos {
asset: "customers/3815500097/assets/37117286417"
}
videos {
asset: "customers/3815500097/assets/37117241057"
}
videos {
asset: "customers/3815500097/assets/64412122544"
}
videos {
asset: "customers/3815500097/assets/64412122547"
}
videos {
asset: "customers/3815500097/assets/58344744360"
}
videos {
asset: "customers/3815500097/assets/58296876706"
}
videos {
asset: "customers/3815500097/assets/44779618341"
}
videos {
asset: "customers/3815500097/assets/44729455489"
}
videos {
asset: "customers/3815500097/assets/20174780105"
}
videos {
asset: "customers/3815500097/assets/37117286027"
}
videos {
asset: "customers/3815500097/assets/70272953772"
}
videos {
asset: "customers/3815500097/assets/70272953769"
}
videos {
asset: "customers/3815500097/assets/68432772605"
}
videos {
asset: "customers/3815500097/assets/68416876483"
}
videos {
asset: "customers/3815500097/assets/68416826746"
}
videos {
asset: "customers/3815500097/assets/61268645205"
}
videos {
asset: "customers/3815500097/assets/54866595462"
}
videos {
asset: "customers/3815500097/assets/71836596256"
}
}
Request made: ClientCustomerId: 3815500097, Host: googleads.googleapis.com, Method: /google.ads.googleads.v12.services.AdService/GetAd, RequestId: -gcxsR1SihGjbZbxDxZjLw, IsFault: False, FaultMessage: None
Request
-------
Method: /google.ads.googleads.v12.services.AdService/MutateAds
Headers: {
"developer-token": "REDACTED",
"login-customer-id": "2189850922",
"x-goog-api-client": "gl-python/3.8.11 grpc/1.48.0 gax/2.10.1 gccl/19.0.0 pb/4.22.0",
"x-goog-request-params": "customer_id=3815500097"
}
Request: customer_id: "3815500097"
operations {
update_mask {
paths: "resource_name"
paths: "app_ad.youtube_videos"
}
update {
resource_name: "customers/3815500097/ads/640893474384"
app_ad {
youtube_videos {
asset: "customers/3815500097/assets/68480151654"
}
}
}
}
Response
-------
Headers: {
"google.ads.googleads.v12.errors.googleadsfailure-bin": "\nY\n\u0002\b\u0001\u0012&The error code is not in this version.\"+\u0012\u000e\n\noperations\u0018\u0000\u0012\b\n\u0006update\u0012\u000f\n\rresource_name\u0012\u0016f8PaShOlegQvFoGQWdrGTw",
"grpc-status-details-bin": "\b\u0003\u0012%Request contains an invalid argument.\u001a\u0001\nDtype.googleapis.com/google.ads.googleads.v12.errors.GoogleAdsFailure\u0012s\nY\n\u0002\b\u0001\u0012&The error code is not in this version.\"+\u0012\u000e\n\noperations\u0018\u0000\u0012\b\n\u0006update\u0012\u000f\n\rresource_name\u0012\u0016f8PaShOlegQvFoGQWdrGTw",
"request-id": "f8PaShOlegQvFoGQWdrGTw"
}
Fault: errors {
error_code {
request_error: UNKNOWN
}
message: "The error code is not in this version."
location {
field_path_elements {
field_name: "operations"
index: 0
}
field_path_elements {
field_name: "update"
}
field_path_elements {
field_name: "resource_name"
}
}
}
request_id: "f8PaShOlegQvFoGQWdrGTw"
Request made: ClientCustomerId: 3815500097, Host: googleads.googleapis.com, Method: /google.ads.googleads.v12.services.AdService/MutateAds, RequestId: f8PaShOlegQvFoGQWdrGTw, IsFault: True, FaultMessage: The error code is not in this version.

Google Ads API Forum Advisor

unread,
Apr 13, 2023, 4:21:30 PM4/13/23
to adwor...@googlegroups.com

Hi, 

Thanks for reaching out to the Google Ads API Forum and for providing information. I hope you are doing well today.

With regards to your concern, for us to for our team to further compare, investigate, and validate why you are encountering issues, could you please try to use Google Ads v13? If issues still persist, kindly provide again the complete (request and response with request-id) logs with request ID generated as shown in the respective links.

In line with this as the errors are still unknown as shown from the logs, as part of the investigation, could you also please confirm to us what you are trying to mutate/ update? If this happens related to VideoAd or VideoResponsiveAd, not that this is immutable. For more information regarding this, please refer to the Google Ads API: Ad type compatibility.

You can provide these via the Reply privately to author option. If this option is not available, then send it instead on this email address googleadsa...@google.com.

Furthermore, I would like you to know that we are going to delete your posts here on this forum as it contains confidential information such as the logs that you've provided.

Reference links:


Have a great day.

Regards,

Google Logo Google Ads API Team


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