airbytehq / airbyte

The leading data integration platform for ETL / ELT data pipelines from APIs, databases & files to data warehouses, data lakes & data lakehouses. Both self-hosted and Cloud-hosted.
https://airbyte.com
Other
15.73k stars 4.03k forks source link

Apple Search Ads connector - timezones #26649

Open MrdjanPoletanovic opened 1 year ago

MrdjanPoletanovic commented 1 year ago

Connector Name

source-apple-search-ads

Connector Version

0.1.0

What step the error happened?

Configuring a new connector

Revelant information

Currently, it is not possible to add a timezone option during the configuring process. Search Ads Connector returns data using UTC timezone by default, and it will be useful to have the option to select which timezone you need. I need America/Los Angeles timezone, and there is no way to ensure it with the current connector implementation. Also, with only daily aggregated data, it is not possible to do any type of transformation to change the timezone.

Relevant log output

No response

Contribute

MrdjanPoletanovic commented 1 year ago

Just to add, through setting the Apple Search Ads platform it is possible to set up a default timezone, so every API call for stats will result in data from the selected timezone. I go through your code and find out that you specify UTC as the default timezone for API requests, so, the possible fix could be changing it to the default platform value. I think It is enough to not specify it during send request.

Link: https://github.com/airbytehq/airbyte/blob/7ea742c2fe757f2ed223001c2488b2119c0ba1d5/airbyte-integrations/connectors/source-apple-search-ads/source_apple_search_ads/manifest.yaml#LL117C23-L117C23

Search Ads API Docs: https://developer.apple.com/documentation/apple_search_ads/reportingrequest

image