-
Notifications
You must be signed in to change notification settings - Fork 0
Supabase Voting
This page documents the current Supabase tables used by Proton Pulse.
Pulse-native compatibility reports submitted via the web app. One report per user per game (enforced by unique constraint on client_id + app_id).
Migration:
supabase/migrations/20260410_create_user_configs.sql
| Column | Type | Notes |
|---|---|---|
id |
bigint (identity PK) |
Auto-incrementing report ID |
client_id |
text |
Anonymous browser client ID (hashed) |
app_id |
text |
Steam App ID |
title |
text |
Game title |
cpu |
text |
CPU model string |
gpu |
text |
GPU model string |
gpu_driver |
text |
GPU driver version |
gpu_vendor |
text |
nvidia / amd / intel / other
|
ram |
text |
e.g. 16 GB
|
os |
text |
Constrained enum (see below) |
kernel |
text |
Kernel version string |
proton_version |
text |
e.g. Proton 9.0-4, GE-Proton9-15
|
duration |
text |
Play duration; default unreported
|
rating |
text |
platinum / gold / silver / bronze / borked
|
notes |
text |
Free-text notes |
launch_options |
text |
Steam launch options string |
enabled_vars |
jsonb |
Map of enabled environment variables |
confidence_score |
smallint |
0–200; null if not computed |
source |
text |
proton-pulse (web) or web-linux / web-windows / web-macos / web-steamdeck
|
created_at |
timestamptz |
Insert time |
Check constraints: rating, os, proton_version (regex), ram (regex), gpu_vendor, source, confidence_score range.
Unique constraint: (client_id, app_id) — one report per browser per game.
Proton configs saved and synced by the Decky Plugin. One config per voter_id + app_id, upserted on conflict.
| Column | Type | Notes |
|---|---|---|
id |
bigint (BIGSERIAL) |
Auto-incrementing config ID |
voter_id |
text |
Anonymous plugin voter ID (hashed device ID) |
app_id |
integer |
Steam App ID |
app_name |
text |
Game title at sync time |
config |
jsonb |
Full TrackedConfig blob (see below) |
updated_at |
timestamptz |
Last upsert time |
Primary key: (voter_id, app_id)
Defined in src/lib/trackedConfigs.ts:
| Field | Type | Notes |
|---|---|---|
appId |
number |
Steam App ID |
appName |
string |
Game title |
profileName |
string |
Config profile name (empty = unnamed) |
protonVersion |
string |
Applied Proton version |
launchOptions |
string |
Steam launch options |
enabledVars |
Record<string, string> |
Enabled env vars |
appliedAt |
number |
Unix timestamp of last apply |
source |
string |
protondb / protondb-local / user
|
isEdited |
boolean? |
true if a ProtonDB config was modified |
cpu |
string? |
CPU at apply time |
gpu |
string? |
GPU at apply time |
gpuVendor |
string? |
nvidia / amd / intel / other
|
gpuDriver |
string? |
GPU driver at apply time |
ram |
string? |
RAM at apply time |
os |
string? |
OS at apply time |
kernel |
string? |
Kernel at apply time |
isNonSteam |
boolean? |
true for non-Steam games |
Per-user plugin settings synced by the Decky Plugin (bookmarks, preferences, etc.).
SQL:
docs/dev/user_plugin_settings.sql
| Column | Type | Notes |
|---|---|---|
voter_id |
text |
Anonymous plugin voter ID |
plugin_id |
text |
Default proton-pulse
|
payload |
jsonb |
LocalDataBackupPayload blob |
updated_at |
timestamptz |
Last upsert time |
Primary key: (voter_id, plugin_id)
All tables use the Supabase publishable (anon) key — no server-side secret is ever embedded in the plugin or web app.
-
anon,authenticated:SELECT,INSERT - RLS enabled; policies allow public read and insert
-
anon,authenticated:SELECT,INSERT,UPDATE - Upserted via
Prefer: resolution=merge-duplicatesonvoter_id,app_id
-
anon,authenticated:SELECT,INSERT,UPDATE - DELETE explicitly denied by RLS policy
Both the plugin and anonymous web submissions use a hashed anonymous ID stored in localStorage / Decky settings. No personally-identifying information is stored. Steam-authenticated web users are identified by their Supabase auth.uid() (stored as voter_id / client_id after login).