A Jellyfin plugin that lets several people share one viewing account, while everyone's watched list stays their own.
--- ## The problem You have one television and one Jellyfin login on it. Two, three, four people use it. Whoever's account is signed in on that TV accumulates everything: *Continue Watching* fills with someone else's half-finished documentaries, *Next Up* suggests episode 4 of a series you never started, and the person whose account it is can no longer tell what they have actually seen. The usual workarounds are all bad: - **Everyone shares one account permanently.** Nobody's watched list means anything any more. - **Everyone logs out and back in.** Nobody does this, especially not on a TV remote. - **Everyone gets their own profile on the TV.** Same problem, switching is friction, so people stop. ## What this plugin does It creates a **shared account**, a real Jellyfin user that several people log into together; and gives it three special behaviours: **1. The account creates itself when you log in.** At the login screen, type `alice+bob` as the username and *your own* password. If no such account exists yet, the plugin checks that `alice` and `bob` are both real users and that the password you typed is one of theirs — then creates the shared account and signs you straight into it. No dashboard visit, no admin, no setup step. Next time, it is just there. **2. Any member's own password unlocks it.** Alice types her password, Bob types his, and both get into the same shared account. Nobody has to remember a new credential, and there is no shared password written on a sticky note. **3. Whatever gets watched there is mirrored back to each member's own account.** Finish an episode on the shared account and it is marked watched for Alice *and* Bob, on their individual accounts. Their personal *Continue Watching* and *Next Up* stay correct, and when they watch alone on their phone, the series picks up where the group left off. The sync is **one-way**: shared account → members. What Alice watches privately is her business and never leaks into the shared account or onto Bob. ``` login as "alice+bob+carol" with any one member's password │ ▼ (creates the account if it does not exist yet) ┌──────────────────┐ alice's password │ │ played ──► alice's account bob's password ──►│ shared account │ played ──► bob's account carol's password │ "alice+bob+carol"│ played ──► carol's account └──────────────────┘ any one unlocks it watched state flows outward only ``` ### This is not SyncPlay Jellyfin already has **SyncPlay**, which keeps playback *synchronized in time* across devices so people in different places press play together. Watched Together solves a different problem: people watching *the same screen* who want their *individual watched lists* to stay accurate. The two are complementary and can be used together. --- ## How it works ### Creating a group by logging in When you submit a username Jellyfin does not recognise, it offers the login to every enabled authentication plugin before giving up. That is the hook this plugin uses. On an unrecognised name, it: 1. Splits the name on the separator (`+` by default) — `alice+bob+carol` → three parts. 2. Requires **every part** to be an existing, enabled user that is not itself a shared account. 3. Requires the submitted password to match **one of those members'** stored hashes. 4. Only then creates the shared account, and returns its name so Jellyfin completes the login. Step 3 is what stops this being an open door: knowing two usernames is not enough to bring an account into being. If any check fails, the plugin declines and the login fails exactly as an ordinary typo would. #### The name collision, and why it is harmless `+` is a legal Jellyfin username character: ``` ^(?!\s)[\w \-'._@+]+(?