Faithful Steward — Admin

Platform monitoring & account management
⚠ SAMPLE DATA — this dashboard is a working UI prototype, not connected to a live Supabase project. See the "Connect to Supabase" tab for exactly what to wire up.

Accounts

0
Total Accounts
0
Active
0
Frozen
0
Suspended
0
Revoked
0
New Signups (30d)
0
Daily Active
0
Monthly Active

Signups Over Time

Login Frequency Distribution

How many logins accounts have made in total — most apps see a long tail of light users and a small core of frequent ones.

Retention by Signup Cohort

Of accounts created in a given month, the % still active in the last 30 days.

Inactivity Risk

Accounts with no login in 30+ days, oldest first — a simple churn-risk list.

Filter Accounts

Accounts (0)

Age Range

Sex

Country (Top 10)

Sector / Career

Platform-wide aggregates only — never an individual user's transactions or balances.

Transaction Volume by Type (Monthly)

Average Transaction Size

Average Savings Rate

Budget Envelope Adherence

% of active budget envelopes currently on-track vs. over, platform-wide.

Average Net Worth Trend

Average Debt Payoff Progress

Recent Activity

Connect This Dashboard to Supabase

Every panel above currently reads from generated sample data (see SAMPLE_ACCOUNTS, SAMPLE_ACTIVITY, and the financial series near the top of the script). Replace each loader function below with a real Supabase query against the schema and views from Faithful_Steward_MultiUser_Admin_Scaffold.md, then delete the sample-data generator.

PanelReplace this functionWith a query against
Overview statsloadAccounts()admin_usage_summary view
Signups / login frequency / retentionloadAccounts()profiles + activity_log
Accounts table + actionsloadAccounts(), setAccountStatus()profiles (RLS-scoped by is_staff_or_owner() / is_owner())
DemographicsloadAccounts()admin_demographics view
Financial indicatorsloadFinancialSeries()admin_aggregate_indicators view
Activity logloadActivity()activity_log table

These queries are already written. All you need to do is paste your project URL and anon key only (never the service role key) into SUPABASE_URL and SUPABASE_ANON_KEY near the top of this file's script. The moment both are filled in, the sample-data banner disappears, an admin login appears, and every panel switches to live queries. Access is gated to accounts whose profiles.role is owner or staff.

const { createClient } = supabase; const sb = createClient('https://YOUR-PROJECT.supabase.co', 'YOUR-ANON-KEY'); async function loadAccounts(){ const { data } = await sb.from('profiles').select('*'); return data; } async function setAccountStatus(id, status, reason){ // RLS enforces: staff/owner can set active/frozen/suspended; // only owner can set 'revoked'. See the scaffold doc, Section 1. await sb.from('profiles').update({ status, status_reason: reason, status_changed_at: new Date() }).eq('id', id); }

This dashboard should be deployed and accessed separately from the user-facing app (e.g. its own private URL or kept local on your machine), with its own login — never bundled into index.html.

Change Account Status