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.
- Scopes:
openid profile, plus any ofemail(their confirmed email),discord(linked Discord),groups(Roblox groups and ranks),discord_servers(servers the person chose to share),twitch,github,steam. People see each one on the “Sign in to …?” screen, and you only get what they have linked. - Code flow with PKCE (S256). Codes last 60 seconds and work once.
- ID tokens are signed HS256 with your client secret. Access tokens work at
/userinfofor an hour. - A Discord bot can send someone to sign in the same way, with a return address on any small web page you run.
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"
GET /api/v1/users/lookup?discord_id=…(orroblox_id,roblox_name,sub): one personGET /api/v1/users?after=&limit=100: everyone who allowed your app, in pages (usenextasafter)GET /api/v1/app: your app’s detailsPOST /api/v1/webhooks/test: send yourself a test webhook
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"}}user.authorizedSomeone allows your app for the first time (or allows more)user.signed_inSomeone signs in to your appuser.updatedSomeone's Roblox name, picture or linked Discord changesuser.revokedSomeone removes your app from their accountuser.deletedSomeone deletes their Foxtail accountuser.bannedA Foxtail admin bans someone who uses your appuser.unbannedA Foxtail admin lifts a ban
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
- Keep secrets on a server. Never put them in a web page or a Roblox game script.
- Only use what people share for the thing they signed in for. Don’t sell it or share it.
- Foxtail admins can switch off any app.