Documentation ¶
Index ¶
Constants ¶
View Source
const LOCAL_KEYS = ".bootdevbuddy.json"
View Source
const OTP_LOGIN = "https://api.boot.dev/v1/auth/otp/login"
View Source
const REFRESH_URL = "https://api.boot.dev/v1/auth/refresh"
Variables ¶
This section is empty.
Functions ¶
func LogoutUser ¶
func LogoutUser() error
func SaveTokens ¶
Types ¶
type BDToken ¶
type BDToken struct { AccessToken string `json:"access_token"` RefreshToken string `json:"refresh_token"` }
func ExchangeOTPForToken ¶
func ReadTokens ¶
func RefreshToken ¶
RefreshToken gets the refresh_token from the local file and uses it to refresh the user's access_token.
Click to show internal directories.
Click to hide internal directories.