Campaign StartDate not consistent between AdWords API and Google Ads API

125 views
Skip to first unread message

Dongqi Wang

unread,
May 31, 2019, 11:48:53 AM5/31/19
to AdWords API and Google Ads API Forum
Hi,

When fetching a Campaign from AdWords API, the StartDate I can get is 2019-01-22, while from Google Ads API I will get 2019-01-21. Is there any similar known issue?


Best,
Dongqi

Google Ads API Forum Advisor Prod

unread,
Jun 3, 2019, 1:55:23 AM6/3/19
to adwor...@googlegroups.com
Hi Dongqi,

Thank you for reaching out. I was not able to replicate these results on my test account. Can you provide the clientCustomerId and the SOAP logs / JSON logs / report definition you used that shows these results for further investigation? You may use the reply privately to author option.

Regards,
Dannison
Google Ads API Team

ref:_00D1U1174p._5001UBkhjl:ref

Dongqi Wang

unread,
Jun 11, 2019, 6:34:53 AM6/11/19
to AdWords API and Google Ads API Forum
Hi,

Did you receive the private reply? 
Thanks!

Best,
Dongqi

Google Ads API Forum Advisor Prod

unread,
Jun 12, 2019, 1:19:54 PM6/12/19
to wangdon...@gmail.com, adwor...@googlegroups.com
Hello Dongqi, 

I'm Dannison's colleague addressing your concern as he is out of office. We did not receive the details sent privately. Could you try sharing them again using the Reply privately to author option?

Thanks,
Bharani, Google Ads API Team

ref:_00D1U1174p._5001UBkhjl:ref

Dongqi Wang

unread,
Jul 1, 2019, 2:44:42 AM7/1/19
to AdWords API and Google Ads API Forum
Any update? I've sent the details one more time about 10 days ago.
Thanks!

Best,
Dongqi

Google Ads API Forum Advisor Prod

unread,
Jul 1, 2019, 9:10:46 AM7/1/19
to wangdon...@gmail.com, adwor...@googlegroups.com
Hello Dongqi, 

We did not receive the details sent privately. Could you provide the complete report definition you used in AdWords API, and also the complete logs that were generated when you downloaded the report in Google Ads API side so we can better see the discrepancy? You can share the details privately via Reply privately to author option.


Thanks,
Bharani, Google Ads API Team
 

ref:_00D1U1174p._5001UBkhjl:ref

Dongqi Wang

unread,
Jul 9, 2019, 10:09:39 AM7/9/19
to AdWords API and Google Ads API Forum
Hi,

Here is the details. Thanks~

I just use the example code provided by AdWords API SDK and GoogleAds API SDK to get my campaigns from same account. We can see that the start date of 'Campaign5' is inconsistent between the two responses. 


AdWords API:

Selector selector = new Selector()
                {
                    fields = new string[]
                    {
                        Campaign.Fields.Id,
                        Campaign.Fields.Name,
                        Campaign.Fields.Status,
                        Campaign.Fields.StartDate
                    },
                    paging = Paging.Default
                };

<add key="ClientCustomerId" value="1309083668"/>

.\Google.AdWords.Examples.CSharp.exe v201809.GetCampaigns
This code example lists all campaigns. To add a campaign, run AddCampaign.cs.
1) Campaign with id = '1655121296', name = 'Ad Cus' and status = 'ENABLED' was found. StartDate = 20181213
2) Campaign with id = '1681274351', name = 'Campaign1' and status = 'ENABLED' was found. StartDate = 20190119
3) Campaign with id = '1683957039', name = 'Campaign5' and status = 'ENABLED' was found. StartDate = 20190122
Number of campaigns found: 3


GoogleAds API:
                Query = @"SELECT
                            campaign.id,
                            campaign.name,
                            campaign.network_settings.target_content_network,
                            campaign.start_date
                        FROM campaign
                        WHERE campaign.status != 'REMOVED'
                        ORDER BY campaign.id",
                CustomerId = "1309083668"

.\Google.Ads.GoogleAds.Examples.exe V1.GetCampaigns
This code example gets all campaigns. To add campaigns, run AddCampaigns.cs.
[ "campaign.id", "campaign.name", "campaign.network_settings.target_content_network", "campaign.start_date" ]
Campaign with ID 1655121296 and name 'Ad Cus' was found. StartDate = 2018-12-13
Campaign with ID 1681274351 and name 'Campaign1' was found. StartDate = 2019-01-19
Campaign with ID 1683957039 and name 'Campaign5' was found. StartDate = 2019-01-21


Best,
Dongqi

Google Ads API Forum Advisor Prod

unread,
Jul 9, 2019, 9:21:13 PM7/9/19
to wangdon...@gmail.com, adwor...@googlegroups.com
Hi Dongqi,

I just ran a query against that account, and I see the start date of 2019-01-22 in the Google Ads API response, which matches the UI and the AdWords API.

    {
      "campaign": {
        "resourceName": "customers/1309083668/campaigns/1683957039",
        "id": "1683957039",
        "startDate": "2019-01-22",
        "endDate": "2037-12-30"
      }
    }

Could you run your request again? If it still shows the wrong start date, please share the request ID from the response. You can find this in the logs produced by the library .

Thanks,
Josh, Google Ads API Team

ref:_00D1U1174p._5001UBkhjl:ref

Gavin

unread,
Jul 19, 2019, 1:29:23 PM7/19/19
to AdWords API and Google Ads API Forum
Hello, Josh,

I hit the same issue when I am testing my application using GoogleAds API. I tried to follow the link you shared to get the requestId but the code snippet in the page (logs produced by the library) has grammar error.

Here is the example from the webpage:

GoogleAdsResponseMetadata metadata = new GoogleAdsResponseMetadata(client.Config);

// Add the campaigns.
MutateCampaignsResponse retVal = campaignService.MutateCampaigns(
    customerId.ToString(), operations.ToArray(), metadata.CallSettings);

Console.WriteLine(metadata.RequestId);

However, in GoogleAds v2.2.0, the ctor of GoogleAdsResponseMetadata takes a parameter of type Grpc.Core.Metadata:

public class GoogleAdsResponseMetadata
    {
        //
        // Summary:
        //     Creates a new instance with metadata.
        public GoogleAdsResponseMetadata(Metadata metadata);

        //
        // Summary:
        //     Gets the request ID.
        public string RequestId { get; }
    }


, while client.Config is of type Google.Ads.GoogleAds.Config.GoogleAdsConfig.

Can you please help check what is the good way to get the request ID for a request in GoogleAds? I am currently blocked by this StartDate discrepancy and would like to have a way for you to move the investigation forward.

Thanks,
Gavin
Reply all
Reply to author
Forward
Message has been deleted
0 new messages