Enum Class XstsError
- All Implemented Interfaces:
Serializable, Comparable<XstsError>, Constable
Why the XSTS step of Microsoft authentication refused, decoded from its
XErr code.
The XSTS endpoint answers a refusal with a numeric XErr that says exactly what is wrong,
and the library used to read only whether a token came back — so every one of these surfaced as a bare
"Xbox auth failed", which tells a user nothing they can act on. Each of these is something the user
fixes in a specific place, so classifying it lets a host say where.
- Since:
- 0.11.0
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionXErr2148916227, which, as commonly observed, means Xbox Live has banned the account; the reading is not guaranteed.XErr2148916229, which, as commonly observed, means the account is restricted from Xbox Live, typically by family or parental settings that whoever manages them can lift; the reading is not guaranteed.The account needs adult verification (South Korea).The account needs adult verification (South Korea) — the second code the service uses for it.The account is a child under an adult's Microsoft Family, and must be added to a family before it can sign into Xbox Live.The Microsoft account has never signed into Xbox, so it has no Xbox profile to authorize.The account is from a country where Xbox Live is not available.XErr2148916234, which, as commonly observed, means the account has not accepted the Xbox Live terms of use, which the user does by signing in once at xbox.com; the reading is not guaranteed.AnXErrthis release does not recognise. -
Method Summary
Modifier and TypeMethodDescriptionlongcode()Returns the rawXErrcode this value maps.static XstsErrorfromCode(long xerr) Maps anXErrcode onto a value.static XstsErrorReturns the enum constant of this class with the specified name.static XstsError[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
NO_XBOX_ACCOUNT
The Microsoft account has never signed into Xbox, so it has no Xbox profile to authorize. The user signs in once at xbox.com to create one.- Since:
- 0.11.0
-
REGION_BLOCKED
The account is from a country where Xbox Live is not available.- Since:
- 0.11.0
-
ADULT_VERIFICATION_REQUIRED
The account needs adult verification (South Korea).- Since:
- 0.11.0
-
ADULT_VERIFICATION_REQUIRED_ALT
The account needs adult verification (South Korea) — the second code the service uses for it.- Since:
- 0.11.0
-
CHILD_ACCOUNT
The account is a child under an adult's Microsoft Family, and must be added to a family before it can sign into Xbox Live.- Since:
- 0.11.0
-
ACCOUNT_BANNED
XErr2148916227, which, as commonly observed, means Xbox Live has banned the account; the reading is not guaranteed. If it holds, nothing the library or the host does changes it, and the user takes it up with Xbox.- Since:
- 1.0.0
-
ACCOUNT_RESTRICTED
XErr2148916229, which, as commonly observed, means the account is restricted from Xbox Live, typically by family or parental settings that whoever manages them can lift; the reading is not guaranteed.- Since:
- 1.0.0
-
TERMS_NOT_ACCEPTED
XErr2148916234, which, as commonly observed, means the account has not accepted the Xbox Live terms of use, which the user does by signing in once at xbox.com; the reading is not guaranteed.- Since:
- 1.0.0
-
UNKNOWN
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
code
public long code()Returns the rawXErrcode this value maps.- Returns:
- the code, or
0forUNKNOWN - Since:
- 0.11.0
-
fromCode
-