oauth

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 15, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetGoogleAccessToken

func GetGoogleAccessToken(cfg Config, refreshToken string) (string, error)

Return an access token from a refresh token

func GetGoogleRefreshToken

func GetGoogleRefreshToken(cfg Config) (string, error)

GetToken starts the OAuth2 flow, opens a temporary web server to handle the callback, and returns the refresh token as a string.

Types

type Config

type Config struct {
	ClientID     string
	ClientSecret string
	Port         string
}

Config holds the configuration for the Google OAuth2 client.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL