Learn R Programming

daiR (version 1.0.0)

dai_token: Produce access token

Description

Produces an access token for Google Cloud Services (GCS)

Usage

dai_token(
  path = Sys.getenv("GCS_AUTH_FILE"),
  scopes = "https://www.googleapis.com/auth/cloud-platform"
)

Value

a GCS access token object (if credentials are valid) or a message (if not).

Arguments

path

path to a JSON file with a service account key

scopes

GCS auth scopes for the token

Examples

Run this code
if (FALSE) {
token <- dai_token()
}

Run the code above in your browser using DataLab