Let players log in to your website with their Minecraft account. They prove ownership
by joining a server or signing in with Microsoft, and you get a verified UUID and
username from one HTTP call. No credentials or API keys, and you don't have to register.
A short-lived, single-use 6-digit code links a verified Minecraft account to your website.
1
Player gets a code
They join auth.aristois.net with any Minecraft version and get kicked with a code,
or sign in with the Microsoft account that owns Minecraft.
2
Code reaches your site
The player types the code into your login form, or you use the redirect flow and
the code is sent to your callback URL automatically.
3
You redeem it
Your backend calls GET /token/{code} and receives the player's UUID and
username. The code is invalidated immediately.
5 mincode lifetime
1×single use
0credentials shared
AllMinecraft versions
API
Base URL https://auth.aristois.net. All responses are JSON. Call it from your backend: no CORS headers are sent.
GET/token/{code}Redeem and invalidate a code
Query parameters
Name
Description
originoptional
Your site's origin, e.g. https://example.com. Rejects codes that were issued through the redirect flow for a different site. Recommended for redirect logins.
Response 200 OK
{
"status": "success",
"message": "Token has been invalidated",
"uuid": "069a79f4-44e9-4726-a5be-fca90e38aaf5",
"username": "Notch"
}
Status codes
Status
Meaning
200
Valid code. uuid is lower-case with dashes.
403
Unknown, expired or already used code, or origin mismatch.
Send the player's browser here. After they sign in with Microsoft they are sent back to
{redirect}?code=123456&state={state}. Redeem the code with
/token/{code}?origin=….
redirect must be an absolute https:// URL (http:// is allowed for localhost only).
state is optional, up to 512 characters. Generate a random value per login, store it in the user's session and compare it on return.
Without redirect, the code is shown to the player to type in manually.
GET/token/testCreate a test code
Returns a code that redeems as Notch. Use it while building your integration, and never give the Notch UUID real privileges.
Examples
Copy-paste integrations. Expand one to see the code.
TSRedeem a codeTypeScript · Node 18+, Deno, Bun
interface TokenSuccess {
status: 'success';
message: string;
uuid: string; // lower-case, with dashes
username: string;
}
interface TokenFailure {
status: 'fail';
message: string;
}
export interface MinecraftUser {
uuid: string;
username: string;
}
const BASE_URL = 'https://auth.aristois.net';
/** Redeems a single-use code. Returns null if it is invalid, expired or already used. */
export async function redeem(code: string, origin?: string): Promise<MinecraftUser | null> {
if (!/^\d{6}$/.test(code)) return null;
const url = new URL(`/token/${code}`, BASE_URL);
if (origin) url.searchParams.set('origin', origin);
const response = await fetch(url, { signal: AbortSignal.timeout(10_000) });
if (response.status === 403 || response.status === 404) return null;
if (!response.ok) throw new Error(`authentify returned HTTP ${response.status}`);
const data = (await response.json()) as TokenSuccess | TokenFailure;
return data.status === 'success'
? { uuid: data.uuid, username: data.username }
: null;
}
// Usage: a player typed the code from the Minecraft kick screen into your form
const user = await redeem('123456');
if (user) console.log(`Logged in as ${user.username} (${user.uuid})`);