login: Authenticate with the Crunch API

Description Usage Arguments Details

View source: R/auth.R

Description

Note that you can store your Crunch account info in encrypted format via the keyring package, with key_set(service = "crunch", "<USERNAME>", ...) If you do so, you can simply login() to authenticate. For running batch jobs, this could be particularly useful.

Usage

1
login(email = NULL, password = NULL, ...)

Arguments

email

the email address associated with the user's Crunch account

password

the password associated with the user's Crunch account

...

additional parameters passed in the authentication. Not currently supported by the Crunch API.

Details

Your email and password can also be stored in and read from the environmental variables R_CRUNCH_EMAIL and R_CRUNCH_PW, or from your .Rprofile under crunch.email and crunch.pw. However, environmental variables and .RProfile files are not encrypted, so this practice is no longer recommended. If an email or password is found in multiple locations, priority is given to 1) environmental variables, 2) .RProfile, and 3) keyring. This order of priority is for backwards compatibility, and methods 1) and 2) are no longer recommended.

If a password is not stored in any of these locations, and you are in an interactive session, you will be prompted to enter your password.


crunch documentation built on April 6, 2021, 1:05 a.m.