Posts tagged with parsing

I'm trying to modularize a type of report from the API. This is my query for the request:

content = ['CampaignId', 'AdvertisingChannelType', ...] report_query = (adwords.ReportQueryBuilder()                        .Select(content)                        .From('CAMPAIGN_PERFORMANCE_REPORT')                        .During(start_date=since,end_date=until)                        .Build()) 

However, I'm having a problem with the .Select() statement since its common usage is .Select('CampaignId', 'AdvertisingChannelType', ...) (as the list but without the brackets []) and in my query I'm parsing the arguments as a list, which of course returns an error.

My question is, how can I parse the elements of content as required? I've tried turning the list into a string but it doesn't work as all the list becomes a single element. I can't assign by hand the elements since it's number may vary (will be used for more than one client).

Any help will be appreciated. Thanks!