Foxtail account

How apps connect

1. Make an app

On Developers, make an app. You get a client ID and a secret. Websites add their return address. Bots that only use the API can leave it empty.

2. Let people sign in

Foxtail account speaks standard OpenID Connect, so most login libraries work by pointing them at https://auth.foxtailentertainment.com. They read everything else from https://auth.foxtailentertainment.com/.well-known/openid-configuration.

What you get: sub (their Foxtail ID, never changes), roblox_id, roblox_username, name, picture, mfa_enabled; with email: email and email_verified (always true: addresses are confirmed with a code); with discord: discord_id, discord_username; with groups: roblox_groups (a list of {id, name, rank, role}); with discord_servers: discord_servers ({id, name, owner}); with twitch/github/steam: twitch_id, twitch_username and so on. The ID token’s amr is ["fed", "otp", "mfa"] when that sign-in passed two-step sign-in.

3. Look people up from your server or bot

Use HTTP Basic auth with your client ID and secret. Up to 300 calls a minute.

curl -u CLIENT_ID:CLIENT_SECRET "https://auth.foxtailentertainment.com/api/v1/users/lookup?discord_id=123456789012345678"

You only ever see people who have allowed your app, and only what they allowed. Anyone else gives 404, the same as nobody.

4. Get told when things change (webhooks)

Add a webhook address to your app and pick events. We POST JSON like this:

{"id": "wh_…", "event": "user.updated", "created": 1764400000, "app": "fx_…",
 "user": {"sub": "fx…", "roblox_id": "1001", "discord_id": "…", "status": "active"}}

Check every call: X-Foxtail-Signature is sha256= plus the hex HMAC-SHA256 of X-Foxtail-Timestamp + "." + body with your webhook secret. Refuse ones older than 5 minutes. Answer with any 2xx; failures are retried after 1 minute, 5 minutes, 30 minutes, 2 hours and 6 hours. X-Foxtail-Delivery stays the same across retries.

# Python
import hmac, hashlib, time
def genuine(secret, headers, body):
    ts = headers["X-Foxtail-Timestamp"]
    want = "sha256=" + hmac.new(secret.encode(), (ts + "." + body).encode(), hashlib.sha256).hexdigest()
    return hmac.compare_digest(want, headers["X-Foxtail-Signature"]) and abs(time.time() - int(ts)) < 300
// Node
const crypto = require("crypto");
function genuine(secret, headers, body) {
  const ts = headers["x-foxtail-timestamp"];
  const want = "sha256=" + crypto.createHmac("sha256", secret).update(ts + "." + body).digest("hex");
  return want.length === headers["x-foxtail-signature"].length && crypto.timingSafeEqual(Buffer.from(want), Buffer.from(headers["x-foxtail-signature"]))
    && Math.abs(Date.now() / 1000 - ts) < 300;
}

Rules for apps