R/login.R

#' verify if object of type try-error
#'
is.error <- function(x) inherits(x, "try-error")

#' authentication function to dhis2 using httr
#'
login <- function() {
    uid <- Sys.getenv("uid")
    pwd <- Sys.getenv("pwd")

    set_config(authenticate(uid, pwd))

}
mayerantoine/Rdhis2PresepiMigration documentation built on May 5, 2019, 12:30 p.m.