paul_blankley
08/10/2020, 5:31 PMtap-google-analytics to pass OAuth credentials as environment variables? I don’t see anything with that in the docs.zachary_wynegar
08/10/2020, 7:23 PMmeltano/tap-google-analytics supports loading the OAuth credentials via config.json with oauth_credentials but because the preinstalled tap-google-analytics extractor plugin doesn't list oauth_credentials as a valid setting, you cannot use the preinstalled plugin for passing the OAuth credentials as an environment variable.
However, you can create your own Meltano extractor plugin via the cli using the existing meltano/tap-google-analytics repo with the settings:
meltano add --custom extractor tap-ga-custom
namespace=ga
pip_url=git@gitlab.com:meltano/tap-google-analytics.git
executable=tap-google-analytics
capabilities=catalog,discover,state
settings=view_id,oauth_credentials,reports,start_date,end_date
Then you can add GA_OAUTH_CREDENTIALS to your environment and Meltano will pass it onto the tap via the config.json.
This is untested though so there may be minor errors. We should add an issue to the Meltano repo to get the oauth_credentials setting added to the default plugin, if you'd like to make an issue!yannis_roussos
08/10/2020, 8:50 PMtap-google-analytics something like a year ago, before OAUTH was supported in Meltano UI, so we never exposed it to Meltano.
I am pretty sure that I tested it back in the day with the oauth credentials I was generating by using my google auth script, but it should be definitely be more thoroughly testedpaul_blankley
08/10/2020, 10:50 PMpaul_blankley
08/10/2020, 11:37 PMdouwe_maan
08/11/2020, 3:54 PMoauth_credentials.access_token even if they're not known to Meltano yet: https://meltano.com/docs/command-line-interface.html#custom-settings
And for what it's worth, nested properties are documented here: https://meltano.com/docs/command-line-interface.html#nested-properties 🙂