From ab02a2e982d145333d843fe84087b5fdd0e05b38 Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Mon, 16 Nov 2026 17:19:14 +0100 Subject: docs: the Xbox tab Co-Authored-By: Claude Opus 5.5 --- AGENTS.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'AGENTS.md') diff --git a/AGENTS.md b/AGENTS.md index 7f40147..9733b87 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -93,6 +93,19 @@ Keep the server dependency-free apart from that one package. - `tablet` reads the tablet's battery (`dumpsys battery`) and Wi-Fi (`cmd wifi status`, Android 11+) over adb, from the device whose reverse carries the dashboard socket; reads are cached 10s. +- `xbox` reads Xbox Live with the user's own Azure app (`[xbox] client_id`, a + public client for personal accounts): device code sign-in started from the + tab, the refresh token in `~/.config/deck-it/xbox-token.json` (0600), the + MS → user token → XSTS chain in memory. A thread reads presence and the + consoles (`xccs`) every 30s, profile, recent titles (titlehub, minutes from + userstats), the last achievements and friends every 10 min and on a title + change; an endpoint that refuses keeps its last data. A foreground title + that titlehub calls a Game is `playing`: `$XDG_RUNTIME_DIR/status.xbox` + gets 1 (keystone ORs it into presentation) and `xbox.js`'s `peek` returns + `Infinity` once per `session`, which `app.js` reads as "show and stay". + Console actions are `xccs` commands (power: tap wakes, hold turns off; + media and volume), for a console id the last state listed. Endpoints and + bodies follow xbox-webapi-python; Microsoft documents none of them. - `assistant` is a client of desktop-assistant's socket (`$XDG_RUNTIME_DIR/desktop-assistant.sock`, JSON lines; every client sees every event); a reader thread folds events into the state the tab polls -- cgit v1.2.3