payslip-ingest/alembic
Viktor Barzin 3a62a38069 rsu_vest_events: schema + ORM for Schwab vest ground truth (Phase D)
Migration 0008 + ORM model for payslip_ingest.rsu_vest_events.

Purpose: broker-sync (separate repo) will parse Schwab "Release
Confirmation" emails and populate this table, enabling Panel 15 of
the UK payslip dashboard to reconcile:
  payslip.rsu_vest   ↔ SUM(rsu_vest_events.gross_value_gbp)
  RSU-attributed PAYE ↔ SUM(rsu_vest_events.tax_withheld_gbp)

Schema carries both the raw USD figures (fmv_at_vest_usd,
tax_withheld_usd, shares_*) and the GBP-translated values
(gross_value_gbp, tax_withheld_gbp) plus the FX rate used — the
dashboard joins on GBP, audits keep USD.

Idempotent on `external_id` — broker-sync emits a stable
`schwab:{date}:{ticker}:VEST:{shares_vested}` for each vest event.

The broker-sync postgres sink that writes here is pending a real email
fixture (current parser is heuristic-only) and a cross-service DB grant
for broker-sync's K8s ServiceAccount. Follow-up under code-860.

Part of: code-860
2026-04-19 18:27:41 +00:00
..
versions rsu_vest_events: schema + ORM for Schwab vest ground truth (Phase D) 2026-04-19 18:27:41 +00:00
env.py alembic: create schema before initializing version table 2026-04-18 22:23:30 +00:00
script.py.mako Initial commit: event-driven UK payslip ingest service 2026-04-18 22:10:23 +00:00