Description Usage Arguments Details Examples
View source: R/drugshortagescanada.R
This function logs in to the DSC web API and stores the auth-token in the 'dsc.authtoken' R environment variable so that it is accessible dsc_search()
1 | dsc_login(email, password)
|
email |
Your email address used to log into the DSC |
password |
Your password |
You should not need usually to call this function directly, as it is called by dsc_search() if the auth-token has not be set.
The username and password can be passed into the function, or can be set via and environment variable. See the examples below.
1 2 3 4 5 6 7 8 9 10 | dsc_login("bill.gates@microsoft.com", "passw0rd!")
# You can also set environment variables
Sys.setenv("dsc.email" = "bill.gates@microsoft.com")
Sys.setenv("dsc.password" = "passw0rd!")
dsc_login()
# These credentials can also be stored in the .Renviron file in the current
# directory
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.