RE: Download CSV Report after Letting user chose metrics and date

110 views
Skip to first unread message
Message has been deleted
Message has been deleted

Google Ads API Forum Advisor

unread,
Jul 4, 2021, 9:35:08 PM7/4/21
to routsi...@gmail.com, adwor...@googlegroups.com
Hi Siddharth,

Thank you for posting your concern.

I would like to inform you first that I am going to delete your second comment as it contains your personal information. Please refrain from posting personal information to public channel like this public forum for security purposes.

Moving forward, could you confirm if my understanding is correct that you want to manage the UI using Google Ads API? If yes, then I afraid that this is not possible as you can only mirror the features that can be found in the UI, not to control the UI, using Google Ads API.

Also, I can see that you want to download the cost of each client account, however, I am afraid that reporting at the MCC level is not supported. With this, you will need to iterate all the client accounts first by following this guide, then generate a customer report including the metrics.cost_micros field.

Lastly, downloading a report in a CSV file is not possible. You will need to create a post process on your that will transfer the API response in a CSV file.

Regards,
Google Logo
Ernie John Blanca Tacata
Google Ads API Team
 


ref:_00D1U1174p._5004Q2JYLC7:ref

Siddharth Rout

unread,
Jul 5, 2021, 1:31:39 AM7/5/21
to AdWords API and Google Ads API Forum
Seems like what I posted did nt make it through so posting this again.

First things first. Thanks for taking the time out to answer my question. Much appreciated.

Secondly, What security purpose? My skype address is publically available on many online forums. It is meant to be public. Not that I am sharing my bank account, address or those crucial details. So request you to please refrain from taking decisions on my behalf and deleting my comments. I am also a moderator on few sites so I know how moderation works. If I am breaking a rule then please tell me that and not give me a weird reason "for security purposes...." :)

Now coming back to the main project

I have seen those guides. I am not trying to control the UI. I am mirroring the same via a .Net App (VB.Net/C#) as shown in the screenshot below.

Capture.PNG

I suspected that I could not report at the MCC level. Thanks for confirming it. I am ok to loop though the account. I am also ok to create a post process which will transfer the API response in a CSV file. After 2 weeks, now I would like someone to help me out finish this application and I am willing to pay for this and hence I shared my skype address.

Siddharth Rout

unread,
Jul 6, 2021, 1:15:05 AM7/6/21
to AdWords API and Google Ads API Forum
This is urgent. If someone can help me. Feel free to contact me on my skype XPIZON

Google Ads API Forum Advisor

unread,
Jul 8, 2021, 3:03:27 PM7/8/21
to routsi...@gmail.com, adwor...@googlegroups.com
Hi Siddharth,

Regarding the privacy issues -- as a rule, we do not allow personally identifiable information on the forum.

Converting JSON report data to a CSV is an implementation question that is beyond the scope of this support forum, as we only provide support for API-specific issues. However, if you are receiving any errors while using the API, please let us know and we can assist. 

A quick alternative to implementing this conversion would be to use Ads scripts, which has a ready-made spreadsheet based reporting solution (their forum can be found here).

Regards,
Matt
Google Ads API Team

Google Logo
Matt
Google Ads API Team
 

 

 

ref:_00D1U1174p._5004Q2JYLC7:ref

Siddharth Rout

unread,
Jul 10, 2021, 1:04:55 PM7/10/21
to AdWords API and Google Ads API Forum
Thanks Matt for replying. If it is a rule then please say that it is a rule. I definitely do not want to break any rules. But please do not term it as "privacy issue" because it is not. Also can I see the list of rules this forum follows so that I can go through it and ensure that I do not break any rules?

Converting JSON report data to a CSV is something that I can handle. As I mentioned in my previous post "I am also ok to create a post process which will transfer the API response in a CSV file." I am stuck with retrieving the data from the MCC accounts and sub accounts. My questions are

1. How do I loop through them?
2. How do I collate the data?

Thanks again for trying to help out.

Google Ads API Forum Advisor

unread,
Jul 11, 2021, 11:00:35 PM7/11/21
to routsi...@gmail.com, adwor...@googlegroups.com
Hi Siddharth,

You may check out our forum guidelines for more information on the rules when posting.

Moving forward to your other concern on retrieving reports, it is currently not possible to directly generate reports from the MCC / manager account since reports are generated per client account only.

To achieve this, you will first need to get the account hierarchy of the MCC / manager account. Then, for every client account returned, perform a separate request to retrieve/collate the data and other metrics.

Best regards,

Google Logo
Peter Laurence Napa Oliquino
Google Ads API Team
 


ref:_00D1U1174p._5004Q2JYLC7:ref

Siddharth Rout

unread,
Jul 12, 2021, 2:08:16 AM7/12/21
to AdWords API and Google Ads API Forum
Thanks Peter

I checked the rules and no where it says you cannot post personal information (unless I missed it and in that case I apologize in advance for saying what I am going to say now). The closest to what you are saying is

>Avoid posting confidential information on the group, particularly developer tokens, logins, passwords, etc. When attaching logs, make sure to remove this data. You can still provide object IDs such as campaign ID, ad group ID etc. to help us investigate the issue.

My skype ID is not confidential. It is very much public as I mentioned above. Look I do not want to argue with you guys but please ensure that you guys do not break any rules as a moderator by assuming different meanings of your own rules and acting upon it.

Now regarding my query

>To achieve this, you will first need to get the account hierarchy of the MCC / manager account. Then, for every client account returned, perform a separate request to retrieve/collate the data and other metrics.

1. To achieve this, you will first need to get the account hierarchy of the MCC / manager account.

I have managed to achieve this.

2. for every client account returned, perform a separate request to retrieve/collate the data and other metrics

This is exactly where I am stuck.




Google Ads API Forum Advisor

unread,
Jul 13, 2021, 4:28:37 PM7/13/21
to routsi...@gmail.com, adwor...@googlegroups.com
Hi Siddharth,

I work with Peter and will assist you. You can use ParallelReportDownload.cs as an example of looping through customer Id's and getting reports for each. You can modify the report by editing this line and below with a GAQL query of customer. We always recommend using our library as an inspiration and base for your own application.

Regards,

Google Logo
Aryeh Baker
Google Ads API Team
 
 

ref:_00D1U1174p._5004Q2JYLC7:ref

Siddharth Rout

unread,
Jul 14, 2021, 5:56:09 AM7/14/21
to AdWords API and Google Ads API Forum
Thanks Aryeh 

Yes I have seen those links. Like I mentioned in my first post, I have been experimenting with these for the last 1 months.

Oh I just noticed. Someone deleted my original question as well? I knew the 2nd comment would be deleted as Ernie had mentioned but now one of your colleague deleted my original question as well without any explanation? This group is so messed up... Wow... Can you please check who deleted the quesiton and why was it deleted?

Or you know what... forget it... I do not belong in this crazy place where the mods are so screwed up in their head. Like I said, I have been a mod for 16 years now but I have never see something so crazy.

Thanks or no thanks to this group.

I will escalate this on twitter and relevant hastags. I have taken a screenshot of all the messages above.
Capture.PNG

Google Ads API Forum Advisor

unread,
Jul 14, 2021, 10:26:05 PM7/14/21
to routsi...@gmail.com, adwor...@googlegroups.com
Hi Siddharth,

We understand the inconvenience that you are encountering due to your initial post being deleted.

However, our team has managed to secure a copy of your initial post from this thread, before deleting. In the said post, your developer token was unfortunately included, and due to that, the said initial post also had to be deleted. I am posting below the copy of your initial post with the developer token detail redacted, for reference on your initial query :

"Hi All


First time poster. After trying to figure this out for more than a week, I am on the verge of pulling my hair. :(

I am trying to create a desktop application in C# where the user will select the metrics and the date to download the csv report.

I have the App.Config figured out

<GoogleAdsApi>
<!-- API-specific settings --> 
<add key="DeveloperToken" value="XXXXXXXXXXX"/>

<!-- OAuth2 settings -->
<add key="AuthorizationMethod" value="OAuth2" />
<add key = "OAuth2ClientId" value = "XXXXXXX.apps.googleusercontent.com" />
<add key = "OAuth2ClientSecret" value = " XXXXXXX  " />
<add key = "OAuth2Mode" value="APPLICATION"/>
<add key = "OAuth2RefreshToken" value = "1//0gd2 XXXXXXX  " />
</GoogleAdsApi>

I tried reading up on the below link but ended up getting super confused.

https://developers.google.com/google-ads/api/docs/reporting/example


How do I pass the metrics (Account/Cost) and the Date as shown in the attached image to download the file at a click of a button from a C# desktop application?

How do I go about it?"


That being said, our team had to delete the above for security purposes as your developer token may be used without your consent. In the event that you require further clarifications on the details that can or cannot be shared in this forum, please let us know and we'll be happy to clarify for you.

Furthermore, I would like to confirm if you have already resolved the reporting issue for all your accounts, on your end? If not, please write back once more so our team can further assist.

Best regards,

Google Logo
Peter Laurence Napa Oliquino
Google Ads API Team
 


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