CREATE TABLE IF NOT EXISTS signups (
  id            INTEGER PRIMARY KEY,

  -- from user
  created       TEXT DEFAULT (strftime('%Y-%m-%dT%H:%M', 'now', 'localtime')),
  email         TEXT,
  how           TEXT,
  why           TEXT,
  links         TEXT,

  -- admin provided
  decision_time TEXT,
  decision      TEXT,
  decided_by    TEXT,
  clean_email   TEXT
);

CREATE TABLE IF NOT EXISTS notes (
  id       INTEGER PRIMARY KEY,
  signupid INTEGER,
  author   TEXT,
  content  TEXT,
  created  TEXT DEFAULT (strftime('%Y-%m-%dT%H:%M', 'now', 'localtime')),

  FOREIGN KEY (signupid) REFERENCES signups(signupid)
);

-- 2025-11-22: bad hosts
CREATE TABLE IF NOT EXISTS suspicious_hosts (
  id          INTEGER PRIMARY KEY,
  domain      TEXT
)
