Function client_auth

Source
pub async fn client_auth(
    access_token: &str,
    uuid: Uuid,
    server_hash: &str,
) -> Result<()>
Expand description

Performs client-side authentication with the given access token and server hash.

The access token can be obtained using client_login; the server hash can be computed with server_hash.

This API endpoint returns no response. If all goes well, then no error will be returned, and the client can proceed with the login process.

ยงExamples

let login = mojang_api::client_login("username", "password").await?;
let server_hash = mojang_api::server_hash("", [0u8; 16], &[1]);

mojang_api::client_auth(&login.access_token, login.profile.uuid, &server_hash);