package
1.54.4
Repository: https://github.com/artxia/rclone.git
Documentation: pkg.go.dev

# Functions

Config does the initial creation of the token If opt is nil it will use the default Options It may run an internal webserver to receive the results.
Context returns a context with our HTTP Client baked in for oauth2.
GetToken returns the token saved in the config file under section name.
NewClient gets a token from the config file and configures a Client with it.
NewClientWithBaseClient gets a token from the config file and configures a Client with it.
NewRenew creates a new Renew struct and starts a background process which renews the token whenever it expires.
PutToken stores the token in the config file This saves the config file if it changes.

# Constants

AuthResponseTemplate is a template to handle the redirect URL for oauth requests.
RedirectLocalhostURL is redirect to local webserver when active with localhost.
RedirectPublicSecureURL is a public https URL which redirects to the local webserver.
RedirectPublicURL is redirect to local webserver when active with public name.
RedirectURL is redirect to local webserver when active.
TitleBarRedirectURL is the OAuth2 redirect URL to use when the authorization code should be returned in the title bar of the browser, with the page text prompting the user to copy the code and paste it in the application.

# Variables

SharedOptions are shared between backends the utilize an OAuth flow.

# Structs

AuthResult is returned from the web server after authorization success or failure.
Options for the oauth config.
Renew allows tokens to be renewed on expiry if uploads are in progress.
TokenSource stores updated tokens in the config file.

# Type aliases

CheckAuthFn is called when a good Auth has been received.