Error creating test accounts: Request contains an invalid argument

124 views
Skip to first unread message

Javier Val

unread,
Apr 4, 2022, 9:17:21 AM4/4/22
to Google Ads API and AdWords API Forum
Hello!

In one of my integration tests, I am creating test accounts with the following format: string.Format("{0}_{1}", "Create_Account_Name", DateTime.Now.ToString("ddMMyyyy_hhmmss")). For example, Create_Account_Name_04042022_125948. 

Until today, it has worked fine for me. But now the test fails me, getting the following error message: "Request contains an invalid argument". 

I paste an example error trace, hoping you can help me, because I can't find the reason for the failure:


[13: 00: 14 WRN]Google Account not created for client Create_Account_Name_04042022_125948
[13: 01: 49 INF]Google response: Result {
    "ResourceName": "",
    "InvitationLink": "",
    "ResourceNameAsCustomerName": null
}

    "StatusCode": 3,
    "Details": "Request contains an invalid argument.",
    "RequestId": "LJ93dGQhwlCKsc3eIsIoBw",
    "Failure": {
        "errors": [{
                "errorCode": {
                    "stringLengthError": "TOO_SHORT"
                },
                "message": "Too short.",
                "trigger": {
                    "stringValue": ""
                },
                "location": {
                    "fieldPathElements": [{
                            "fieldName": "operations",
                            "index": 0
                        }, {
                            "fieldName": "create"
                        }, {
                            "fieldName": "name"
                        }
                    ]
                }
            }
        ],
        "requestId": "LJ93dGQhwlCKsc3eIsIoBw"
    }


Thank you very much for your help.
All the best!

Google Ads API Forum Advisor

unread,
Apr 4, 2022, 3:34:47 PM4/4/22
to javie...@tiendeo.com, adwor...@googlegroups.com
Hi Javier,

Thanks for reaching out. Based on the error message (TOO_SHORT), it appears you did not actually provide a name for the campaign. Can you please check your request, as interpreted by the API? If you don't believe this is the source of the error, please respond privately with your complete request and response.

Regards,
Matt
Google Ads API Team

Google Logo
Matt
Google Ads API Team
 


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