Files
instantadpay/public/wall.html
T
martbost 03284aa281 Conversion linkage, InstantAdPay side (Marty 2026-11-07, "Yes ship these"): a LinkSpin click stays with the account, and its sign-up, wallet link and each package purchase are reported to LinkSpin. Reporting only: no sponsor, payout, credit or chain path changes; accounts.js only gains a notification after a wallet is linked.
lsreport.js. A click id (lsclk or lsid) arriving on any page is kept in a first-party cookie iap.lsclk, 30 days, last click wins, like the sponsor cookie. The join page also sends its own copy with the code request and verify (the cookie is refused in traffic-exchange frames and never crosses browsers, the 2026-09-29 lesson) and it is remembered per email. It is stored in its own table ls_account_clicks when the account is created or a waiting LinkSpin shell is claimed, on /api/signup, email sign-in and in-game sign-in (a game may pass lsclk; none does yet).

Reports queue in ls_events, whose primary key is the idempotency key (join:<hash>, wallet:<hash>, purchase:<tx>:<log index>), so two app copies in a deploy cannot double a row, and LinkSpin dedupes on the same key. A background loop sends them signed, retrying up to every 5 minutes; a sign-up or a purchase never waits on LinkSpin. The purchase hook runs after the existing ev: claim and its value is the USD price on the chain event. A first purchase finds its buyer through the contract's wallet for that member id, since member_id may not be stored yet. Linked positions count as the account's purchases. Past 30 days from the sign-up nothing is queued (LinkSpin's window is from the click).

Campaigns > Conversion tracking lists everything the member's clicks led to, and joins, wallets and purchases on each campaign row. Guide, privacy page and chatbot (CANNED + FACTS) updated; common.js, join.js and my.js tags bumped.

QA: bash qa/run.sh netconv (54 checks: local InstantAdPay + local LinkSpin + a mock Polygon RPC, a real Purchase log through the real event fan-out, LinkSpin down, two copies racing).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-07 07:48:36 -06:00

55 lines
4.2 KiB
HTML

<!doctype html>
<html lang="en" data-theme-base="dark">
<head>
<meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1">
<title>Banner wall | InstantAdPay</title>
<!--OG-->
<!--theme-head--><script>(function(){var A=0,h=document.documentElement,b=h.getAttribute("data-theme-base")||"dark",m=window.matchMedia?matchMedia("(prefers-color-scheme: dark)"):{matches:false},v;function g(){try{v=localStorage.getItem("iap.theme")}catch(e){v=null}return v==="light"||v==="dark"||v==="auto"?v:(A?"auto":b)}function ap(){var c=g();h.setAttribute("data-theme",c==="auto"?(m.matches?"dark":"light"):c);h.setAttribute("data-theme-choice",c)}ap();if(m.addEventListener)m.addEventListener("change",ap);else if(m.addListener)m.addListener(ap);window.IAPTheme={base:b,get:g,apply:ap,set:function(c,quiet){try{if(c==="light"||c==="dark"||c==="auto")localStorage.setItem("iap.theme",c);else localStorage.removeItem("iap.theme")}catch(e){}ap();if(!quiet)try{dispatchEvent(new CustomEvent("iap-theme",{detail:g()}))}catch(e){}}}})()</script><!--/theme-head-->
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Sora:wght@600;700;800&display=swap">
<link rel="icon" type="image/png" href="/logo-icon.png">
<link rel="stylesheet" href="/assets/site.css?v=20261101th">
</head>
<body>
<div id="nav"></div>
<section>
<div class="wrap" style="max-width:920px">
<div class="wall-hero" style="text-align:center;padding:26px 0 18px">
<p style="margin:0 0 8px;font-family:var(--disp);font-weight:800;font-size:clamp(22px,3vw,30px);color:var(--ink);letter-spacing:-.01em">Instant<span style="color:var(--mint)">AdPay</span> <span style="font-weight:500;font-size:.62em;color:var(--muted)">member wall</span></p>
<h1 style="font-size:clamp(28px,4.4vw,44px);margin:0 0 10px;line-height:1.1">Advertise and earn. <em style="font-style:normal;color:var(--mint)">Paid on-chain, instantly.</em></h1>
<p class="muted" style="max-width:640px;margin:0 auto;font-size:15.5px">Real ad packages from $5. Every payout arrives as <b style="color:var(--ink)">POL on Polygon</b> in your own wallet, in the same transaction the package sells, on a public ledger. Free to join by email, and <span id="wallHost">this member</span> is your sponsor if you join from here.</p>
</div>
<div class="bio-head" id="bioHead" hidden>
<img id="bioAvatar" class="bio-avatar" alt="" hidden>
<img id="bioBadge" class="bio-badge" alt="achievement badge" hidden>
<div class="bio-meta">
<p class="eyebrow">Your sponsor on InstantAdPay</p>
<h2 id="wallTitle" style="margin:.1em 0">Loading…</h2>
<p id="bioText" class="lead" style="font-size:16px"></p>
<div id="bioSocials" class="bio-socials"></div>
</div>
<div class="bio-qr"><img id="bioQr" alt="Join QR code" width="150" height="150"><div class="small muted" style="text-align:center">scan to join</div></div>
</div>
<div class="bio-video" id="bioVideo" hidden></div>
<div class="sectionhead" style="text-align:left;margin-top:10px">
<h3 style="margin:0">The line, three levels deep</h3>
<p>Three positions, three levels — the exact levels the contract pays. Every banner here belongs
to a real member of this line, and every payment between them settles on-chain, instantly.</p>
</div>
<div class="grid c3" id="wallGrid"></div>
<div class="card" id="adSlotWallText" hidden style="margin-top:16px"></div>
<div class="card" id="adSlotWallBanner" hidden></div>
<div class="card" style="margin-top:22px;text-align:center">
<h3 id="wallCtaHead">Join this line</h3>
<p class="muted small">Free to join with just an email. Your wallet only comes out if you buy —
and payments go straight to member wallets, never through an admin.</p>
<p id="wallGate" class="small" style="color:var(--amber);font-weight:600" hidden></p>
<p><a class="btn" id="wallJoin">Join free through this wall</a></p>
<p class="small muted"><a href="/ledger">Watch the live ledger</a> · <a href="/contract">Read the contract</a></p>
</div>
</div>
</section>
<script src="/assets/common.js?v=20261107nc"></script><script src="/assets/welcome.js?v=20261101th"></script>
<script src="/assets/wall.js?v=20261030pp"></script>
</body>
</html>