From 5ea127114582e3320381d09e880f6a433ccb8710 Mon Sep 17 00:00:00 2001 From: mat Date: Sat, 6 Jan 2024 18:16:11 -0600 Subject: add doc comment about d= --- azalea-auth/src/auth.rs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'azalea-auth/src') diff --git a/azalea-auth/src/auth.rs b/azalea-auth/src/auth.rs index 67a45aa3..7b5846c4 100755 --- a/azalea-auth/src/auth.rs +++ b/azalea-auth/src/auth.rs @@ -140,6 +140,9 @@ pub async fn auth(email: &str, opts: AuthOpts) -> Result /// /// If you don't have a Microsoft auth token, you can get it from /// [`get_ms_link_code`] and then [`get_ms_auth_token`]. +/// +/// If you got the MSA token from your own app (as opposed to the default +/// Nintendo Switch one), you may have to prepend "d=" to the token. pub async fn get_minecraft_token( client: &reqwest::Client, msa: &str, @@ -418,9 +421,9 @@ async fn auth_with_xbox_live( "Properties": { "AuthMethod": "RPS", "SiteName": "user.auth.xboxlive.com", - // i thought this was supposed to be d={} but it doesn't work for - // me when i add it ?????? - "RpsTicket": format!("{access_token}") + // this value should have "d=" prepended if you're using your own app (as opposed to + // the default nintendo switch one) + "RpsTicket": access_token }, "RelyingParty": "http://auth.xboxlive.com", "TokenType": "JWT" -- cgit v1.2.3