Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func StringCheck ¶
StringCheck function will verify which of either short or long form is defined, and return it. If none are set, an empty string is returned
Types ¶
type GoAuth ¶
type GoAuth struct { Conf *GoAuthConf ClientID *oauth.ClientID ServiceAccount *oauth.ServiceAccount }
GoAuth struct represents an instance (execution) of GoAuth
func NewGoAuth ¶
func NewGoAuth() *GoAuth
NewGoAuth function will create and return a new GoAuth object based on the input configuration
func (*GoAuth) ExecClientID ¶
func (g *GoAuth) ExecClientID()
ExecClientID method will process the actions required for a Client ID account type
func (*GoAuth) ExecServiceAccount ¶
func (g *GoAuth) ExecServiceAccount()
ExecServiceAccount method will process the actions required for a Service Account account type
type GoAuthConf ¶
type GoAuthConf struct { IsClientID bool IsServiceAccount bool IsWebUI bool IsNinjaMode bool AccountName string Secret string Scopes string Subscriber string RefreshToken string }
GoAuthConf struct will represent the configuration for this instance of GoAuth
func GetOpts ¶
func GetOpts() *GoAuthConf
GetOpts function will collect the user's input from the set flags on runtime, and create a GoAuthConf object based on it
func (*GoAuthConf) NewClientID ¶
func (c *GoAuthConf) NewClientID(clientid, secret, scopes, refreshToken string, ninjaMode bool) *GoAuthConf
NewClientID method will create a new Client ID object based on its available input parameters
func (*GoAuthConf) NewServiceAccount ¶
func (c *GoAuthConf) NewServiceAccount(keyfile, scopes, subscriber string, ninjaMode bool) *GoAuthConf
NewServiceAccount method will create a new Service Account object based on its available input parameters