R/qcri_api_key.R

Defines functions qcri_api_key

Documented in qcri_api_key

#' Get the QCRI API key from the environment variable
#'
#' @return The QCRI API key stored in the QCRI_API_KEY environment variable.
qcri_api_key <- function() {
  api_key <- Sys.getenv("QCRI_API_KEY")
  if (api_key == "") {
    stop("QCRI_API_KEY environment variable is not set.")
  }
  return(api_key)
}

Try the polyglotr package in your browser

Any scripts or data that you put into this service are public.

polyglotr documentation built on Sept. 11, 2024, 6:35 p.m.