{
  "generated_at": "2026-08-06T02:48:04.436218+00:00",
  "synthetic": true,
  "run": {
    "run_id": "20260806T024802246Z",
    "status": "ok",
    "started_at": "2026-08-06T02:48:02.246453+00:00",
    "ended_at": "2026-08-06T02:48:04.393685+00:00",
    "business_now": "2026-08-01T17:59:59+00:00",
    "tick": 3,
    "files_seen": 209,
    "rows_loaded": 43,
    "checks_passed": 33,
    "checks_failed": 0
  },
  "uptime": {
    "first_run_at": "2026-08-06T02:10:55.431639+00:00",
    "runs_total": 6,
    "runs_ok": 6
  },
  "checks": [
    {
      "name": "freshness.booking_legacy",
      "severity": "hard",
      "passed": true,
      "observed": "newest row 2026-08-01 (0h old)",
      "expected": "within 26h",
      "subject": "booking_legacy"
    },
    {
      "name": "freshness.booking_acquired",
      "severity": "hard",
      "passed": true,
      "observed": "newest row 2026-08-01 (0h old)",
      "expected": "within 26h",
      "subject": "booking_acquired"
    },
    {
      "name": "freshness.square_settlements",
      "severity": "hard",
      "passed": true,
      "observed": "newest row 2026-08-01 (0h old)",
      "expected": "within 26h",
      "subject": "square_settlements"
    },
    {
      "name": "freshness.stripe_payouts",
      "severity": "hard",
      "passed": true,
      "observed": "newest row 2026-08-01 (0h old)",
      "expected": "within 26h",
      "subject": "stripe_payouts"
    },
    {
      "name": "freshness.expenses",
      "severity": "soft",
      "passed": true,
      "observed": "newest row 2026-07-31 (24h old)",
      "expected": "within 960h",
      "subject": "expenses"
    },
    {
      "name": "freshness.vendor_payments",
      "severity": "soft",
      "passed": true,
      "observed": "newest row 2026-08-01 (0h old)",
      "expected": "within 960h",
      "subject": "vendor_payments"
    },
    {
      "name": "freshness.cancellation_log",
      "severity": "soft",
      "passed": true,
      "observed": "newest row 2026-07-31 (24h old)",
      "expected": "within 960h",
      "subject": "cancellation_log"
    },
    {
      "name": "volume.booking_legacy",
      "severity": "soft",
      "passed": true,
      "observed": "11 rows on 2026-08-01, median 48",
      "expected": "within 6 MAD of the trailing median",
      "subject": "booking_legacy"
    },
    {
      "name": "volume.booking_acquired",
      "severity": "soft",
      "passed": true,
      "observed": "4 rows on 2026-08-01, median 34",
      "expected": "within 6 MAD of the trailing median",
      "subject": "booking_acquired"
    },
    {
      "name": "volume.square_settlements",
      "severity": "soft",
      "passed": true,
      "observed": "7 rows on 2026-08-01, median 46",
      "expected": "within 6 MAD of the trailing median",
      "subject": "square_settlements"
    },
    {
      "name": "control_total.rows_staged",
      "severity": "hard",
      "passed": true,
      "observed": "76,854 rows staged",
      "expected": "76,854 rows recorded by the loader",
      "subject": ""
    },
    {
      "name": "control_total.fee_plausibility",
      "severity": "hard",
      "passed": true,
      "observed": "every processing fee is below the amount that moved",
      "expected": "no fee larger than its payment",
      "subject": ""
    },
    {
      "name": "nulls.stg_appointment",
      "severity": "hard",
      "passed": true,
      "observed": "38,765 rows, no nulls in required columns",
      "expected": "no nulls in 7 required columns",
      "subject": "stg_appointment"
    },
    {
      "name": "nulls.stg_payment",
      "severity": "hard",
      "passed": true,
      "observed": "29,226 rows, no nulls in required columns",
      "expected": "no nulls in 8 required columns",
      "subject": "stg_payment"
    },
    {
      "name": "nulls.stg_expense",
      "severity": "hard",
      "passed": true,
      "observed": "1,342 rows, no nulls in required columns",
      "expected": "no nulls in 5 required columns",
      "subject": "stg_expense"
    },
    {
      "name": "nulls.stg_vendor_payment",
      "severity": "hard",
      "passed": true,
      "observed": "739 rows, no nulls in required columns",
      "expected": "no nulls in 4 required columns",
      "subject": "stg_vendor_payment"
    },
    {
      "name": "nulls.stg_cancellation_entry",
      "severity": "hard",
      "passed": true,
      "observed": "6,687 rows, no nulls in required columns",
      "expected": "no nulls in 3 required columns",
      "subject": "stg_cancellation_entry"
    },
    {
      "name": "duplicate_keys.stg_appointment",
      "severity": "hard",
      "passed": true,
      "observed": "appointment_id unique across 38,765 rows",
      "expected": "appointment_id unique",
      "subject": "stg_appointment"
    },
    {
      "name": "duplicate_keys.stg_payment",
      "severity": "hard",
      "passed": true,
      "observed": "payment_id unique across 29,226 rows",
      "expected": "payment_id unique",
      "subject": "stg_payment"
    },
    {
      "name": "duplicate_keys.stg_expense",
      "severity": "hard",
      "passed": true,
      "observed": "expense_id unique across 1,342 rows",
      "expected": "expense_id unique",
      "subject": "stg_expense"
    },
    {
      "name": "duplicate_keys.stg_vendor_payment",
      "severity": "hard",
      "passed": true,
      "observed": "payment_ref unique across 739 rows",
      "expected": "payment_ref unique",
      "subject": "stg_vendor_payment"
    },
    {
      "name": "rejects.unread_rows",
      "severity": "hard",
      "passed": true,
      "observed": "every row of all 209 live files was read",
      "expected": "no unreadable rows",
      "subject": ""
    },
    {
      "name": "referential.location_id",
      "severity": "hard",
      "passed": true,
      "observed": "all recognised",
      "expected": "every location_id in the location master",
      "subject": ""
    },
    {
      "name": "referential.service_code",
      "severity": "hard",
      "passed": true,
      "observed": "all recognised",
      "expected": "every service_code in the service catalogue",
      "subject": ""
    },
    {
      "name": "referential.gl_code",
      "severity": "hard",
      "passed": true,
      "observed": "all recognised",
      "expected": "every gl_code in the chart of accounts",
      "subject": ""
    },
    {
      "name": "ledger.cash_revenue_identity",
      "severity": "hard",
      "passed": true,
      "observed": "$17,193,587.50 cash - $15,740,450.36 revenue = $1,453,137.14 deferred",
      "expected": "cash - revenue = deferred liability, to the cent",
      "subject": "fct_recognition"
    },
    {
      "name": "ledger.deferred_roll_forward",
      "severity": "hard",
      "passed": true,
      "observed": "94 clinic-months roll forward exactly",
      "expected": "opening + collected - released = closing",
      "subject": "fct_deferred"
    },
    {
      "name": "ledger.recognition_causality",
      "severity": "hard",
      "passed": true,
      "observed": "all 6,538 sessions delivered on or after their sale",
      "expected": "a session is never delivered before its package is sold",
      "subject": "map_redemption"
    },
    {
      "name": "ledger.single_recognition_per_visit",
      "severity": "hard",
      "passed": true,
      "observed": "28,102 visits earn revenue exactly once",
      "expected": "no visit appears in the ledger twice",
      "subject": "fct_recognition"
    },
    {
      "name": "ledger.tips_excluded",
      "severity": "hard",
      "passed": true,
      "observed": "$565,665.00 in tips held out of revenue",
      "expected": "no recognition includes a tip",
      "subject": "fct_recognition"
    },
    {
      "name": "ledger.unexplained_cash",
      "severity": "soft",
      "passed": true,
      "observed": "3 charge(s), $300.00 (0.00% of cash in)",
      "expected": "under 1% of cash unexplained",
      "subject": "fct_payment"
    },
    {
      "name": "recon.contested_share",
      "severity": "soft",
      "passed": true,
      "observed": "$1,458,552.50 contested against $15,740,450.36 (9.27%)",
      "expected": "under 12% of revenue contested",
      "subject": "recon_exception"
    },
    {
      "name": "recon.vendor_resolution",
      "severity": "soft",
      "passed": true,
      "observed": "1 spelling(s), $261,214.55 (3.46% of supplier spend)",
      "expected": "under 5% of supplier spend unattributed",
      "subject": "dim_vendor"
    }
  ],
  "feeds": [
    {
      "feed": "booking_acquired",
      "files": 19,
      "last_ingested": "2026-08-06T02:48:02.357967+00:00",
      "rows": 16166
    },
    {
      "feed": "booking_legacy",
      "files": 19,
      "last_ingested": "2026-08-06T02:48:02.397679+00:00",
      "rows": 22599
    },
    {
      "feed": "cancellation_log",
      "files": 95,
      "last_ingested": "2026-08-06T02:48:02.665928+00:00",
      "rows": 6782
    },
    {
      "feed": "expenses",
      "files": 19,
      "last_ingested": "2026-08-06T02:26:05.725107+00:00",
      "rows": 1342
    },
    {
      "feed": "square_settlements",
      "files": 19,
      "last_ingested": "2026-08-06T02:48:02.719150+00:00",
      "rows": 25153
    },
    {
      "feed": "stripe_payouts",
      "files": 19,
      "last_ingested": "2026-08-06T02:48:02.754649+00:00",
      "rows": 4073
    },
    {
      "feed": "vendor_payments",
      "files": 19,
      "last_ingested": "2026-08-06T02:26:05.967812+00:00",
      "rows": 739
    }
  ],
  "warehouse": {
    "stg_appointment": 38765,
    "stg_payment": 29226,
    "stg_cancellation_entry": 6687,
    "stg_expense": 1342,
    "stg_vendor_payment": 739
  },
  "reconciliation": {
    "totals": {
      "revenue_cents": 1574045036,
      "cash_collected_cents": 1719388750,
      "tips_cents": 56566500,
      "service_cents": 1158361500,
      "package_cents": 339352286,
      "membership_cents": 66446100,
      "cancellation_cents": 22580500,
      "reversal_cents": -12695350,
      "expense_cents": 1144915530,
      "contested_cents": 145855250,
      "quarantined_cents": 30000,
      "deferred_balance_cents": 145313714,
      "deferred_unallocated_cents": 70089500
    },
    "by_month": [
      {
        "period_month": "2025-02",
        "revenue_cents": 68235800,
        "cash_collected_cents": 91784200,
        "expense_cents": 63672463,
        "contested_cents": 3227500
      },
      {
        "period_month": "2025-03",
        "revenue_cents": 85085763,
        "cash_collected_cents": 108787200,
        "expense_cents": 64935863,
        "contested_cents": 5312000
      },
      {
        "period_month": "2025-04",
        "revenue_cents": 88283013,
        "cash_collected_cents": 103557250,
        "expense_cents": 65014500,
        "contested_cents": 5847000
      },
      {
        "period_month": "2025-05",
        "revenue_cents": 96803204,
        "cash_collected_cents": 104675150,
        "expense_cents": 64195769,
        "contested_cents": 7634000
      },
      {
        "period_month": "2025-06",
        "revenue_cents": 84744392,
        "cash_collected_cents": 97703050,
        "expense_cents": 63330496,
        "contested_cents": 6726750
      },
      {
        "period_month": "2025-07",
        "revenue_cents": 80958544,
        "cash_collected_cents": 89620300,
        "expense_cents": 64603090,
        "contested_cents": 9520500
      },
      {
        "period_month": "2025-08",
        "revenue_cents": 80108601,
        "cash_collected_cents": 91704250,
        "expense_cents": 64725489,
        "contested_cents": 8729000
      },
      {
        "period_month": "2025-09",
        "revenue_cents": 85818860,
        "cash_collected_cents": 94854950,
        "expense_cents": 65002299,
        "contested_cents": 7999000
      },
      {
        "period_month": "2025-10",
        "revenue_cents": 97597020,
        "cash_collected_cents": 101268000,
        "expense_cents": 63547059,
        "contested_cents": 9698000
      },
      {
        "period_month": "2025-11",
        "revenue_cents": 97090608,
        "cash_collected_cents": 102001250,
        "expense_cents": 60889311,
        "contested_cents": 7171500
      },
      {
        "period_month": "2025-12",
        "revenue_cents": 102198396,
        "cash_collected_cents": 111392700,
        "expense_cents": 63302701,
        "contested_cents": 9018500
      },
      {
        "period_month": "2026-01",
        "revenue_cents": 73424017,
        "cash_collected_cents": 79087500,
        "expense_cents": 60565563,
        "contested_cents": 7701000
      },
      {
        "period_month": "2026-02",
        "revenue_cents": 71856828,
        "cash_collected_cents": 72048150,
        "expense_cents": 64902081,
        "contested_cents": 7718750
      },
      {
        "period_month": "2026-03",
        "revenue_cents": 87787531,
        "cash_collected_cents": 91582250,
        "expense_cents": 59596786,
        "contested_cents": 8010000
      },
      {
        "period_month": "2026-04",
        "revenue_cents": 92058727,
        "cash_collected_cents": 94993250,
        "expense_cents": 65091272,
        "contested_cents": 6528000
      },
      {
        "period_month": "2026-05",
        "revenue_cents": 99578354,
        "cash_collected_cents": 103810250,
        "expense_cents": 64400374,
        "contested_cents": 7707000
      },
      {
        "period_month": "2026-06",
        "revenue_cents": 94329937,
        "cash_collected_cents": 95052850,
        "expense_cents": 63860020,
        "contested_cents": 9529250
      },
      {
        "period_month": "2026-07",
        "revenue_cents": 87103692,
        "cash_collected_cents": 84742200,
        "expense_cents": 63280394,
        "contested_cents": 17665000
      },
      {
        "period_month": "2026-08",
        "revenue_cents": 981749,
        "cash_collected_cents": 724000,
        "expense_cents": 0,
        "contested_cents": 112500
      }
    ],
    "locations_latest": [
      {
        "location_id": "LUM-IRV",
        "location_name": "Lumen Irvine",
        "period_month": "2026-08",
        "revenue_cents": 119400,
        "cash_collected_cents": 254400,
        "deferred_balance_cents": 26755168,
        "contested_cents": 0,
        "contested_count": 0
      },
      {
        "location_id": "LUM-LAJ",
        "location_name": "Lumen La Jolla",
        "period_month": "2026-08",
        "revenue_cents": 204050,
        "cash_collected_cents": 135800,
        "deferred_balance_cents": 29693506,
        "contested_cents": 0,
        "contested_count": 0
      },
      {
        "location_id": "LUM-SCT",
        "location_name": "Lumen Scottsdale",
        "period_month": "2026-08",
        "revenue_cents": 119100,
        "cash_collected_cents": 119100,
        "deferred_balance_cents": 0,
        "contested_cents": 0,
        "contested_count": 0
      },
      {
        "location_id": "LUM-TMP",
        "location_name": "Lumen Tempe",
        "period_month": "2026-08",
        "revenue_cents": 332883,
        "cash_collected_cents": 82300,
        "deferred_balance_cents": 31928585,
        "contested_cents": 0,
        "contested_count": 0
      },
      {
        "location_id": "LUM-TUC",
        "location_name": "Lumen Tucson",
        "period_month": "2026-08",
        "revenue_cents": 206316,
        "cash_collected_cents": 132400,
        "deferred_balance_cents": 34000218,
        "contested_cents": 112500,
        "contested_count": 2
      }
    ],
    "exceptions": [
      {
        "state": "contested",
        "kind": "visit_unexplained",
        "count": 1359,
        "cents": 71877000
      },
      {
        "state": "contested",
        "kind": "package_unidentified_buyer",
        "count": 110,
        "cents": 31749500
      },
      {
        "state": "contested",
        "kind": "package_allocation_contested",
        "count": 100,
        "cents": 24852500
      },
      {
        "state": "contested",
        "kind": "cancellation_log_vs_processor",
        "count": 72,
        "cents": 1560500
      },
      {
        "state": "contested",
        "kind": "reversal_parent_unknown",
        "count": 47,
        "cents": 2188250
      },
      {
        "state": "contested",
        "kind": "package_awaiting_redemption",
        "count": 46,
        "cents": 13487500
      },
      {
        "state": "contested",
        "kind": "cancellation_total_mismatch",
        "count": 18,
        "cents": 140000
      },
      {
        "state": "contested",
        "kind": "vendor_unresolved",
        "count": 1,
        "cents": 26121455
      },
      {
        "state": "quarantined",
        "kind": "payment_unexplained",
        "count": 3,
        "cents": 30000
      },
      {
        "state": "reconciled",
        "kind": "service_attribution_ambiguous",
        "count": 679,
        "cents": 32947000
      },
      {
        "state": "reconciled",
        "kind": "cancellation_status_recovered",
        "count": 667,
        "cents": 6804500
      }
    ],
    "packages": [
      {
        "resolution": "inferred_corroborated",
        "count": 755,
        "cents": 215046500
      },
      {
        "resolution": "declared",
        "count": 699,
        "cents": 189000500
      },
      {
        "resolution": "unidentified_buyer",
        "count": 110,
        "cents": 31749500
      },
      {
        "resolution": "contested",
        "count": 100,
        "cents": 24852500
      },
      {
        "resolution": "inferred_unique",
        "count": 63,
        "cents": 10529500
      },
      {
        "resolution": "awaiting_redemption",
        "count": 46,
        "cents": 13487500
      }
    ]
  },
  "recent_runs": [
    {
      "run_id": "20260806T024802246Z",
      "started_at": "2026-08-06T02:48:02.246453+00:00",
      "status": "ok",
      "business_now": "2026-08-01T17:59:59+00:00",
      "tick": 3,
      "files_seen": 209,
      "rows_loaded": 43,
      "checks_passed": 33,
      "checks_failed": 0
    },
    {
      "run_id": "20260806T023301598Z",
      "started_at": "2026-08-06T02:33:01.598879+00:00",
      "status": "ok",
      "business_now": "2026-08-01T11:59:59+00:00",
      "tick": 2,
      "files_seen": 209,
      "rows_loaded": 5,
      "checks_passed": 33,
      "checks_failed": 0
    },
    {
      "run_id": "20260806T022604665Z",
      "started_at": "2026-08-06T02:26:04.665137+00:00",
      "status": "ok",
      "business_now": "2026-08-01T05:59:59+00:00",
      "tick": 1,
      "files_seen": 209,
      "rows_loaded": 3650,
      "checks_passed": 33,
      "checks_failed": 0
    },
    {
      "run_id": "20260806T021958212Z",
      "started_at": "2026-08-06T02:19:58.212212+00:00",
      "status": "ok",
      "business_now": "2026-07-31T23:59:59+00:00",
      "tick": 0,
      "files_seen": 198,
      "rows_loaded": 0,
      "checks_passed": 33,
      "checks_failed": 0
    },
    {
      "run_id": "20260806T021832886Z",
      "started_at": "2026-08-06T02:18:32.886567+00:00",
      "status": "ok",
      "business_now": "2026-07-31T23:59:59+00:00",
      "tick": 0,
      "files_seen": 198,
      "rows_loaded": 0,
      "checks_passed": 33,
      "checks_failed": 0
    },
    {
      "run_id": "20260806T021055431Z",
      "started_at": "2026-08-06T02:10:55.431639+00:00",
      "status": "ok",
      "business_now": "2026-07-31T23:59:59+00:00",
      "tick": 0,
      "files_seen": 198,
      "rows_loaded": 0,
      "checks_passed": 33,
      "checks_failed": 0
    }
  ]
}