Files
takeyourmeds/tools/schema.sql
T
Frank Schwenk 1cada42370 feat: replace Web Push with ntfy for medication reminders
Single notification path via ntfy HTTP publish for reliable Android delivery;
remove VAPID, push subscriptions, and SW push handlers. PWA settings show
topic subscribe link; humor texts and deep-link actions unchanged.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-06 10:42:58 +02:00

30 lines
688 B
SQL

CREATE TABLE IF NOT EXISTS intake_log (
id TEXT PRIMARY KEY,
slot_id TEXT NOT NULL,
day TEXT NOT NULL,
status TEXT NOT NULL,
logged_at TEXT NOT NULL,
source TEXT DEFAULT 'app'
);
CREATE INDEX IF NOT EXISTS idx_intake_day ON intake_log(day);
CREATE INDEX IF NOT EXISTS idx_intake_slot_day ON intake_log(slot_id, day);
CREATE TABLE IF NOT EXISTS ai_cache (
key TEXT PRIMARY KEY,
content TEXT NOT NULL,
created_at TEXT NOT NULL
);
CREATE TABLE IF NOT EXISTS milestones (
id TEXT PRIMARY KEY,
unlocked_at TEXT NOT NULL
);
CREATE TABLE IF NOT EXISTS snooze (
slot_id TEXT NOT NULL,
day TEXT NOT NULL,
snooze_until TEXT NOT NULL,
PRIMARY KEY (slot_id, day)
);