Documentation ¶
Index ¶
Constants ¶
View Source
const AccountType = "xbox"
Variables ¶
View Source
var ErrNilAccount = errors.New("account is nil")
Functions ¶
func RandomKey ¶
RandomKey returns a new byte slice of random bytes to use as a key for Xbox account.
func WriteProperties ¶
func WriteProperties(account *accounts.Account, properties Properties) error
Types ¶
type AuthData ¶
type AuthData struct { MsftAccessToken string `json:"msftAccessToken"` // Microsoft access token used to access Xbox services. MsftRefreshToken string `json:"msftRefreshToken"` // Microsoft refresh token used to refresh access token after it has expired. MsftAccessTokenExpiresAt time.Time `json:"msftAccessTokenExpiresAt"` // Time after which Microsoft token should be considered expired. XBLToken string `json:"xblToken"` // Xbox Live token. UserHash string `json:"userHash"` // Xbox Live user hash. XSTSToken string `json:"xstsToken"` // Xbox Live Token Service token. MinecraftToken string `json:"minecraftToken"` // Minecraft token used to call Minecraft APIs and to log in into the game. MinecraftTokenExpiresAt time.Time `json:"minecraftAccessTokenExpiresAt"` // Time after which Minecraft token should be considered expired. }
AuthData stores the authentication data for Xbox Minecraft account.
type Properties ¶
type Properties struct {
KID string `mapstructure:"xbox:kid"` // Key identifier in the keyring.
}
func ReadProperties ¶
func ReadProperties(account *accounts.Account) (properties Properties, err error)
Click to show internal directories.
Click to hide internal directories.