Re: Getting Errors from a Campaign Mutate - Google Ads API (V2) - PHP

44 views
Skip to first unread message

Dan Slay

unread,
Nov 29, 2019, 9:22:08 AM11/29/19
to Google Ads API Direct Support, adwor...@googlegroups.com
Hi Pierrick,

Am I doing this correctly? If I do a bulk campaign mutate and there are errors it throws an ApiException (see below). Each one of these is obviously relating to each campaign that failed but how do I get those details e.g. accountLimitType and enclosingId I need to know what campaign ids have failed.

Do I have to enable partial failures on mutateCampaignCriteria? If I do that I get another error:

Error occurred during parsing: Class google.ads.googleads.v2.errors.GoogleAdsFailure hasn't been added to descriptor pool

Am I doing this in the wrong way?

ApiException: {
    "message": "Request contains an invalid argument.",
    "code": 3,
    "status": "INVALID_ARGUMENT",
    "details": [
        {
            "@type": 0,
            "data": "type.googleapis.com\/google.ads.googleads.v2.errors.GoogleAdsFailure"
        },
        {
            "@type": 0,
            "data": [
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "0"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "1"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "2"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "3"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "4"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "5"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "6"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "7"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "8"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "9"
                            }
                        ]
                    }
                },
                {
                    "errorCode": {
                        "resourceCountLimitExceededError": "CAMPAIGN_LIMIT"
                    },
                    "message": "Indicates that this request would exceed the number of allowed resources in a Campaign. The exact resource type and limit being checked can be inferred from accountLimitType, and the numeric id of the Campaign involved is given by enclosingId.",
                    "trigger": {
                        "stringValue": ""
                    },
                    "location": {
                        "fieldPathElements": [
                            {
                                "fieldName": "operations",
                                "index": "10"
                            }
                        ]
                    }
                },





On Tue, Nov 12, 2019 at 18:02, Google Ads API Direct Support <googleadsa...@google.com> wrote:
Hi Dan,

My name is Pierrick and I work as a Developer Advocate for Ads API.

Regarding the PHP failure, feel free to open a bug with as much detail as possible (environment, etc.) on the associated GitHub project and we will be looking into it.

Concerning the missing information in the Google Ads error, I would like to check if this is something specific to the PHP client library or if it is generic to the Google Ads API. Do you happen to have the request ID for the example you provided?

Thanks,
Pierrick - Ads API Team

ref:_00D1U1174p._5001UMWauF:ref

Dan Slay

unread,
Dec 2, 2019, 5:58:44 AM12/2/19
to Google Ads API Direct Support, adwor...@googlegroups.com
Hi Pierrick,

Is there any update to this at all?

Would really appreciate an update as its currently holding up development.

Thanks

Dan.
Reply all
Reply to author
Forward
0 new messages