Documentation
¶
Index ¶
- Constants
- Variables
- func IsEmptyConfig(cfg *Config) bool
- func SecretsSetupPrompt()
- func VerifyConfigExists(cfg *Config) bool
- func WriteTokenToHomeDirectory(configData *CombinedTokenStructure, initiateChannel bool)
- type CombinedTokenStructure
- type Config
- type ConfigService
- type EnvVarConfig
- type FetchType
- type TokenType
- type UserLibraryReadTokenStructure
- type UserModifyTokenStructure
- type UserReadTokenStructure
Constants ¶
View Source
const ( UserModifyPlaybackStateRoute = "/user-modify-playback-state-auth" UserModifyPlaybackStateRouteCallback = "/user-modify-playback-state-auth-callback" UserModifyPlaybackStateScope = "user-modify-playback-state" )
View Source
const ( UserReadPlaybackStateRoute = "/user-read-playback-state-auth" UserReadPlaybackStateRouteCallback = "/user-read-playback-state-auth-callback" UserReadPlaybackState = "user-read-playback-state" )
View Source
const ( UserLibraryReadRoute = "/user-library-read-auth" UserLibraryReadRouteCallback = "/user-library-read-auth-callback" UserLibraryRead = "user-library-read" )
View Source
const (
ServerUrl = "http://localhost:4949"
)
Variables ¶
View Source
var AuthTokenData = make(chan CombinedTokenStructure)
Functions ¶
func IsEmptyConfig ¶ added in v1.0.65
func SecretsSetupPrompt ¶ added in v1.0.64
func SecretsSetupPrompt()
func VerifyConfigExists ¶
func WriteTokenToHomeDirectory ¶
func WriteTokenToHomeDirectory(configData *CombinedTokenStructure, initiateChannel bool)
Types ¶
type CombinedTokenStructure ¶ added in v1.0.61
type CombinedTokenStructure struct { ModifyToken UserModifyTokenStructure `yaml:"ModifyToken"` ReadToken UserReadTokenStructure `yaml:"ReadToken"` LibraryReadToken UserLibraryReadTokenStructure `yaml:"LibraryReadToken"` }
func ReadTokenFromHome ¶
func ReadTokenFromHome(tokenType TokenType) *CombinedTokenStructure
type Config ¶ added in v1.0.61
func LoadConfiguration ¶
func SecretsPrompt ¶ added in v1.0.64
type ConfigService ¶ added in v1.0.65
type ConfigService struct {
// contains filtered or unexported fields
}
func NewConfigService ¶ added in v1.0.65
func NewConfigService() *ConfigService
func (*ConfigService) GetConfig ¶ added in v1.0.65
func (c *ConfigService) GetConfig() *Config
func (*ConfigService) GetFetchType ¶ added in v1.0.65
func (c *ConfigService) GetFetchType() *FetchType
type EnvVarConfig ¶ added in v1.0.61
type UserLibraryReadTokenStructure ¶ added in v1.0.61
type UserModifyTokenStructure ¶ added in v1.0.61
type UserReadTokenStructure ¶ added in v1.0.61
Click to show internal directories.
Click to hide internal directories.