google_authenticate: Allow Google Drive authorisation via a server

View source: R/import_data.R

google_authenticateR Documentation

Allow Google Drive authorisation via a server

Description

google_authenticate To access data on a Google drive requires that the user is authenticated, to ensure that you are entitled to view it.

Usage

google_authenticate(
  email = chchpd_user(),
  use_server = chchpd_check_rstudio_server()
)

Arguments

email

Allows you to nominate a particular nzbri.org e-mail address to use for authentication. This can save you having to specify it manually each time the script is run, but shouldn't be used in reproducible workflows (where other users have to be able to run the code). The default value of 'TRUE' means that if authentication has occurred before, and there is just one e-mail address available to select, it will automatically do that.

use_server

If TRUE, use the copy/paste authentication process. If FALSE, use fully browser-contained authentication.

Details

If using RStudio on a server, specifying 'use_server = TRUE' will institute a different authentication process to when you are running locally.

Value

No return value: the function initiates a process which results in the writing of a .httr-oauth token file to disk.


nzbri/chchpd documentation built on July 6, 2023, 11:27 p.m.