Helper Function to Parse a String to be Used as a Username/Password Combination

Converts a string of length 1 or of length 2 into a list that can then be passed on to the authenticate function from the "httr" package.

pwd_parse(...)

Arguments

...

A single string, character vetor, or list containing the username and password that should be used. If it is a single string, it should be in the form of "username:password".

Note

This function is not intended to be called directly. It is used in other functions.

Author

Ananda Mahto

Examples

if (FALSE) { pwd_parse("username", "password") pwd_parse("username:password") pwd_parse(c("username", "password")) }