gl_auth: Authenticate with Google language API services

Description Usage Arguments Details Examples

View source: R/auth.R

Description

Authenticate with Google language API services

Usage

1
2
3
gl_auth(json_file)

gl_auto_auth(...)

Arguments

json_file

Authentication json file you have downloaded from your Google Project

...

additional argument to pass to gar_attach_auto_auth.

Details

The best way to authenticate is to use an environment argument pointing at your authentication file.

Set the file location of your download Google Project JSON file in a GL_AUTH argument

Then, when you load the library you should auto-authenticate

However, you can authenticate directly using this function pointing at your JSON auth file.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
library(googleLanguageR)
gl_auth("location_of_json_file.json")

## End(Not run)

## Not run: 
library(googleLanguageR)
gl_auto_auth()
gl_auto_auth(environment_var = "GAR_AUTH_FILE")

## End(Not run)

googleLanguageR documentation built on April 19, 2020, 3:58 p.m.