View source: R/sf_store_creds.R
This function will add your username, password, and SalesForce
API token to your .Renviron
file so it can be called securely without
being stored in your code. After you have installed your variables, they
the variables can be called any time by typing Sys.getenv("SF_USER")
,
Sys.getenv("SF_PASSWORD")
, or Sys.getenv("SF_TOKEN")
. If you do
not have an .Renviron
file, the function will create on for you.
If you already have an .Renviron
file, the function will append the
variables to your existing file, while making a backup of your original file
for disaster recovery purposes.
You can update all of your variables at once, or update them one at a time.
1 2 3 4 5 6 7 |
username |
The email address you use to login to SalesForce formatted in quotes. |
password |
The password you use to login to SalesForce formatted in quotes. |
token |
The API token provided to you from SalesForce formatted in quotes. A key can be acquired as described here https://help.salesforce.com/s/articleView?id=sf.user_security_token.htm&type=5 |
overwrite |
If this is set to TRUE, it will overwrite the existing variables that you already have in your |
install |
if TRUE, will install your credentials in your |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.