accountΒΆ

account contains functions for interacting with your mojang account.

login_user(username: str, password: str) -> Dict[str,Any]

Login to your mojang account. The response contains things like accessToken, clientToken, uuid and something else.

Note: You should never save username and password! Only the client token.

validate_access_token(access_token: str) -> bool

Returns true, if the accessToken is valid. Otherwise it will return false. You should check that before running minecraft.

refresh_access_token(access_token: str, client_token: str) -> Dict[str,Any]

Get a new accessToken.

logout_user(username: str, password: str) -> bool

Log a user out.

invalidate_access_token(access_token: str, client_token: str) -> Any

Make an accessToken invalid.

upload_skin(uuid: str, access_token: str, path: str, slim: bool=False) -> Any

Upload a Skin.

reset_skin(uuid: str, access_token: str) -> Any

Reset a Skin.