create_token_profile: Create a profile with an API token

View source: R/api_utilities.R

create_token_profileR Documentation

Create a profile with an API token

Description

A wrapper to the new method defined in the Token class.

Usage

create_token_profile(
  token = askpass:::readline_silent("Enter/Paste a token: "),
  auth_type = "Bearer"
)

Arguments

token

a string for token

auth_type

type of HTTP authentication. Should be Bearer or Basic. Default is Bearer

Value

An object of class Token

Examples

## Not run: 
# Create a profile with "Bearer" authentication type
myProfile <- create_token_profile()
myProfile

# Create a profile with a "Basic" authentication type
myProfile2 <- create_token_profile(auth_type = "Basic")
myProfile2

## End(Not run)


CDCgov/Rnssp documentation built on May 12, 2024, 1:32 a.m.