{
  "schemaVersion": 1,
  "generatedAt": "2026-07-28T00:51:17.341Z",
  "enhancements": {
    "generatedAt": "2026-07-28T00:51:17.320Z",
    "consoleDepth": 4,
    "rows": [
      {
        "feature": "health.states",
        "expectedState": {
          "ok": true,
          "states": [
            "MA",
            "NJ"
          ]
        },
        "actualState": {
          "ok": true,
          "states": [
            "MA",
            "NJ"
          ]
        },
        "match": true,
        "notes": "GET /health lists regulated states"
      },
      {
        "feature": "check.ma_licensed_nba_totals",
        "expectedState": {
          "allowed": true,
          "status": 200
        },
        "actualState": {
          "allowed": true,
          "status": 200
        },
        "match": true,
        "notes": "demo-ma-licensed straight NBA/totals"
      },
      {
        "feature": "check.nj_unlicensed_block",
        "expectedState": {
          "allowed": false,
          "status": 403
        },
        "actualState": {
          "allowed": false,
          "status": 403
        },
        "match": true,
        "notes": "demo-unlicensed soccer blocked in NJ"
      },
      {
        "feature": "status.ma_licensed_shape",
        "expectedState": {
          "ok": true,
          "state": "MA",
          "licenseStatus": "active",
          "hasLimits": true
        },
        "actualState": {
          "ok": true,
          "state": "MA",
          "licenseStatus": "active",
          "hasLimits": true
        },
        "match": true,
        "notes": "GET /api/compliance/status panel"
      },
      {
        "feature": "identity.agent_key_prefix",
        "expectedState": {
          "method": "prefix_lookup",
          "timing": "constant",
          "prefixLen": 5
        },
        "actualState": {
          "method": "prefix_lookup",
          "timing": "constant",
          "prefixLen": 5
        },
        "match": true,
        "notes": "agent API keys use fixed prefix for O(1) lookup shape"
      },
      {
        "feature": "runtime.deepEquals.strict_vs_loose",
        "expectedState": {
          "loose": true,
          "strict": false,
          "diverges": true
        },
        "actualState": {
          "loose": true,
          "strict": false,
          "diverges": true
        },
        "match": true,
        "notes": "Bun.deepEquals(a,b) true; Bun.deepEquals(a,b,true) false — same as toStrictEqual"
      },
      {
        "feature": "runtime.deepEquals.docs_matrix",
        "expectedState": {
          "ok": true,
          "cases": 6
        },
        "actualState": {
          "ok": true,
          "cases": 6
        },
        "match": true,
        "notes": "docs strict-inequality matrix (undefined, sparse, class vs plain)"
      },
      {
        "feature": "runtime.escapeHTML",
        "expectedState": {
          "hasLt": true,
          "hasAmp": true,
          "hasQuot": true,
          "rawUnsafe": false
        },
        "actualState": {
          "hasLt": true,
          "hasAmp": true,
          "hasQuot": true,
          "rawUnsafe": false
        },
        "match": true,
        "notes": "Bun.escapeHTML for safe HTML report cells"
      }
    ],
    "passed": 8,
    "total": 8,
    "signature": "f3aa87d1eb017f4dfc27c2e4bb6325a8ab39bdc464852057f3fd83c84259554e"
  },
  "shadow": {
    "generatedAt": "2026-07-28T00:51:17.341Z",
    "base": "http://127.0.0.1:62225/",
    "rows": [
      {
        "state": "MA",
        "partner": "demo-ma-licensed",
        "licenseStatus": "active",
        "realAllowed": true,
        "shadowAllowed": true,
        "match": true
      },
      {
        "state": "NJ",
        "partner": "demo-ma-licensed",
        "licenseStatus": null,
        "realAllowed": false,
        "shadowAllowed": false,
        "match": true,
        "reason": "Partner not licensed in NJ"
      },
      {
        "state": "MA",
        "partner": "demo-nj-licensed",
        "licenseStatus": null,
        "realAllowed": false,
        "shadowAllowed": false,
        "match": true,
        "reason": "Partner not licensed in MA"
      },
      {
        "state": "NJ",
        "partner": "demo-nj-licensed",
        "licenseStatus": "active",
        "realAllowed": true,
        "shadowAllowed": true,
        "match": true
      },
      {
        "state": "MA",
        "partner": "demo-dual-licensed",
        "licenseStatus": "active",
        "realAllowed": true,
        "shadowAllowed": true,
        "match": true
      },
      {
        "state": "NJ",
        "partner": "demo-dual-licensed",
        "licenseStatus": "active",
        "realAllowed": true,
        "shadowAllowed": true,
        "match": true
      },
      {
        "state": "MA",
        "partner": "demo-unlicensed",
        "licenseStatus": null,
        "realAllowed": false,
        "shadowAllowed": false,
        "match": true,
        "reason": "Partner not licensed in MA"
      },
      {
        "state": "NJ",
        "partner": "demo-unlicensed",
        "licenseStatus": null,
        "realAllowed": false,
        "shadowAllowed": false,
        "match": true,
        "reason": "Partner not licensed in NJ"
      }
    ],
    "summary": {
      "allow": 4,
      "block": 4,
      "mismatches": 0
    },
    "signature": "0e81169ff971a71fc009ba747e673cf1de5e1472fd8fc11d30b8bda1912ee48e",
    "proof": {
      "algorithm": "sha3-256",
      "digest": "0e81169ff971a71fc009ba747e673cf1de5e1472fd8fc11d30b8bda1912ee48e",
      "bunVersion": "1.4.0",
      "generatedAt": "2026-07-28T00:51:17.341Z",
      "hmac": "cab811d1cd812a7d6f820a206ed84e672273d873f1281843a84ee248e9aabb2c"
    }
  },
  "geo": {
    "partners": [
      {
        "nodeId": "demo-ma-licensed",
        "stateCode": "MA",
        "age": 28,
        "location": "Boston",
        "zipCode": "02108"
      },
      {
        "nodeId": "demo-nj-licensed",
        "stateCode": "NJ",
        "age": 32,
        "location": "Atlantic City",
        "zipCode": "08401"
      },
      {
        "nodeId": "demo-dual-licensed",
        "stateCode": "MA",
        "age": 40,
        "location": "Cambridge",
        "zipCode": "02139"
      },
      {
        "nodeId": "demo-unlicensed",
        "stateCode": "MA",
        "age": 22,
        "location": "Worcester",
        "zipCode": "01608"
      }
    ]
  },
  "integrity": {
    "scoreHint": "integrity+hmac",
    "proof": {
      "algorithm": "sha3-256",
      "digest": "c6a3e96437897d2634b45e4f0cdc39c734f558ee7e0c30dc55cec00a81ca584c",
      "bunVersion": "1.4.0",
      "generatedAt": "2026-07-28T00:51:17.346Z",
      "hmac": "b4ce58a81cfd13016d0223f6312bf08c789aa53298b2130baa9fa5523c683b95"
    },
    "checks": [
      {
        "id": "enhancements",
        "ok": true,
        "label": "Enhancements 8/8"
      },
      {
        "id": "shadow",
        "ok": true,
        "label": "Shadow mismatches 0"
      },
      {
        "id": "sha3",
        "ok": true,
        "label": "Board integrity sha3-256"
      },
      {
        "id": "hmac",
        "ok": true,
        "label": "HMAC (REPORT_SIGNING_SECRET from vault/mint)"
      },
      {
        "id": "geo",
        "ok": true,
        "label": "Geo profiles discrete (state/age/location/zip)"
      }
    ]
  },
  "links": {
    "portal": "/portal/compliance/",
    "registryEnhancements": "/registry/compliance-enhancements.json",
    "registryShadow": "/registry/compliance-shadow.json",
    "api": "/api/compliance",
    "deepAudit": "bun run ops:audit:deep"
  },
  "proton": {
    "note": "Bake is offline-safe. Deploy uses vault-injected CLOUDFLARE_API_TOKEN. Report HMAC uses REPORT_SIGNING_SECRET (mintable or pass://factorywager/Report Signing Secret/password when vaulted).",
    "inject": "bun run proton:inject:factorywager:reasonix",
    "bakeVault": "bun run compliance:bake:vault",
    "reportSigning": "bun run vault:gap:mint-local  # REPORT_SIGNING_SECRET · or pass://factorywager/Report Signing Secret/password",
    "vaultMap": "docs/harness/tenants/proton-integration.md"
  }
}
