R/Users.R

Defines functions user_info

Documented in user_info

#' @title Return information about the user
#'
#' @description Shows information about the user.
#'
#' @references wufoo_api - User's API Key. Default: \code{\link{auth_key}}.
#' @param wufoo_name - User's Name. Default: \code{\link{auth_name}}
#' @param domain - for whatever reason domain's ccTLD may change. With this parameter you can change
#' default \code{wufoo.com} to another one such as \code{wufoo.eu}
#' @param showRequestURL - use only for DEBUG purposes
#' @param debugConnection - samilar as above. Either "0L" (false; default) or "1L"
#'
#' @return \url{https://wufoo.github.io/docs/#users}
#'
#' @examples
#' \dontrun{
#' user_info(debugConnection = 1L, domain = "wufoo.eu")
#' }
#' 
#' @export
user_info <- function(wufoo_name = auth_name(NULL), domain = "wufoo.com",
                      showRequestURL = FALSE, debugConnection = 0L) {
  user_url <- paste0("https://", wufoo_name, ".", domain, "/api/v3/users.json")

  executedUserGetRst <- doRequest(user_url, showURL = showRequestURL, debugConnection = debugConnection)
  df_user <- executedUserGetRst$Users

  return(df_user)
}

Try the WufooR package in your browser

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

WufooR documentation built on April 14, 2020, 5:17 p.m.