napkin-0.5.14
Safe HaskellSafe-Inferred
LanguageGHC2021

Napkin.Auth.GoogleEnvironment

Synopsis

Documentation

makeGoogleEnvWithCredentials :: (MonadIO m, MonadCatch m, Katip m) => Maybe Text -> Maybe Seconds -> Credentials BigQueryScopes -> m (Env BigQueryScopes) #

Creates a google env with the scopes required for bigquery ops

makeGoogleEnv #

Arguments

:: (MonadCatch m, Katip m) 
=> FilePath

credentials file

-> Maybe Seconds 
-> m GoogleEnv 

Creates google env from the input file The main purpose for this function is to validate the generated napkin credentials. Note, function only validates if we can create a google env.

googleEnvFromJSONCredentials #

Arguments

:: MonadCatch m 
=> ByteString

oAuth2 token ByteString

-> m (Credentials BigQueryScopes) 

Creates google environment from credentials json