Commit Graph

683 Commits

Author SHA1 Message Date
martbost 0865a4967b Short banner links remember a missing file for one minute, not ten (Road Agent's banners were uploaded 2026-11-03 right after Michael asked for them and stayed 404 on the short link)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 08:35:23 -06:00
martbost 7d28ec7b5f Short banner image URLs (Michael Camire via Marty, 2026-11-03): the Spaces CDN links in the Games and BixPay kits ran about 105 characters and exchange / safelist image fields cut them off, so the banners never showed. /b/<slug>/<file> on instantadpay.com and the share hosts (https://ctbgo.com/b/turkeydrop/728x90.png) serves the same game-banners CDN file in place (no redirect, HEAD works, 300-file six-hour cache); promo.js builds every game and BixPay banner URL on the share domain; chatbot banner-image answer; promo.js?v=20261103b, KNOWLEDGE_DATE 2026-11-03
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-03 07:36:55 -06:00
martbost c0a435343a Chatbot: every game is gated now (guests earn nothing, free accounts a quarter of progress rewards under the 2 POL allowance, Game Pass the full table); per-game specifics for ClutterHunt, POL Miner, PolyWarriors paid mints and Turkey Drop prizes
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-02 17:04:54 -06:00
martbost c6b4a84abc Free allowance across the games (Marty 2026-11-02, "cap these so if they want to keep playing they spend a tiny amount"): an account with no Game Pass receives at most capFreeLifetime POL of game rewards ever, across every game (2 POL default, site setting). After that a free account's room for the day is zero: progress rewards defer until a pass is active, repeatable rewards drop, carry waits too. Grant answers and partner caps carry lifetimeHit / freeUsed / lifetime; chatbot facts; QA block for the allowance
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-02 17:01:27 -06:00
martbost 7f3f057db0 Chatbot: the game tiers (2026-11-02): PolHunter free tier (one hunt a day on 0.02 to 0.10 POL; Game Pass holders five at the full draw, the weekly prizes and the Mystery Hunt Box), SpellWheel ladder (guests one place, free account two, Game Pass from the Mountain Lodge on and for daily/streak POL), and a GAME TIERS fact so unlisted games get an honest answer
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-02 13:31:39 -06:00
martbost ae3a08b991 Gem Kingdom Royal Charter: /gk/shop charges a paidOnly order from purchased credits only (never the earned pool); chatbot and promo copy carry the new ladder (guests chapters 1-2, free account for 3, $5 Charter for 4-6, taste rewards then Charter-only rewards capped at what the player paid in)
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-02 11:27:00 -06:00
martbost 4bcc867679 Daily growth snapshot also posts to the InstantAdPay support topic: the 'support' target has been in snapshotTargets since 2026-09-24 but post() only knew feed and echo (Marty, 2026-11-02); POST /api/admin/snapshot/send takes {target} for a one-off post to one destination
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-02 08:23:40 -06:00
martbost 27d7215f0f Merge light and dark themes into main (Marty 2026-11-02 after the Turkey Drop launch): token sets, the Light/Dark/Auto switch saved on the account, the theme head script and its CSP hash, contrast and QA tooling; chatbot answers theme questions; KNOWLEDGE_DATE 2026-11-02 (covers the Turkey Drop note) 2026-11-02 06:32:07 -06:00
martbost 0aaffc308e Turkey Drop integration, gated (2026-10-28): the Thanksgiving season game at turkeydropgame.com, same protocol as POL Miner. TD_SSO_SECRET / TD_URL (default https://turkeydropgame.com) / TD_ALT_URLS (default www + turkeydrop.saasy.top) with tdMint/tdOpen/tdIsGameUrl/tdCallback (code defaults only, no env set); GAME_AUTH turkeydrop (in-game sign-in kit, three origins); /api/my/turkeydrop hand-off + iap.return + my.js redirect; refuel game 'turkeydrop' (label "back on the air", receipt kind td-life, note "Turkey Drop back on the air", gameplay only, never POL; refuel.js done text "WFWL is back on the air"); GAMES() card with season TD_SEASON 2026-11-02..2026-12-01 (Limited time ribbon, gone after Nov 30, CDN art game-banners/turkeydrop/og-turkeydrop-clean.jpg, per-action copy: first score milestones + weekly top 3) and STRIP line, both hidden until 'turkeydrop' is in gamesLive (admin preview kept); /api/public/games/all now shows a seasonal game's "Opens" date only once it is in gamesLive (it used to list any pre-season game); growth snapshot "opened today" counts a season start only when live; walletnudge entry (idle until the secret is set); gamestats name; Game Pass: gamepass GAMES/NAMES += turkeydrop, GP_SECRETS, GP_PERKS row "one free back on the air extra life every day" shown only while the game is in the public games list (Spooky Doors row the same, so it drops after Oct 31), pass copy made count-free ("every game" / "all the games": my.js card, perks table, cap nudge, chatbot pass/Friday/tiers answers + fact, friday.html, Friday pass email); promo tools Games entry (turkeydropgame.com/?ref=, og + 11 CDN banners, 2 posts) shown only while listed and from Nov 2; chatbot CANNED turkeydrop + fact follow gamesLive and the season (coming-soon answer without a date before launch, like POL Miner's; season-over answer from Dec 1; KB answer kept out of the prompt unless live), Game Pass answer names the Turkey Drop perk only while live. my.js?v=20261028td, promo.js?v=20261028td, refuel.js?v=20261028td. qa member 0 bugs (2 old admin warnings), qa public 0 bugs (1 old /shorts warning), refuel-fallback + kb all passed; local e2e (23 checks) and chatbot gating (7 checks) passed.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 04:33:54 -06:00
martbost 4ae7a318da QA for the themes: contrast check in both themes, QA_THEME walks, theme-switch assertions
qa/theme-contrast.mjs (bash qa/run.sh theme) mirrors LinkSpin's: signs in one account per theme (the account value wins at sign-in), walks every member pane, 24 public pages and the admin panes in light and dark with Playwright, samples the main text/background pairs with composited ancestor backgrounds and gradient averages, injects one probe per variant so every pair is measured even when a page has no live example, and reports the ratio per pair with pass/fail at 4.5:1 (3:1 for large text). Result today: 8,169 pairs, 0 fails, worst 4.76:1 (the ok badge in light), worst dark 5.76:1.

qa/walk.mjs honours QA_THEME=light|dark|auto (localStorage iap.theme set before the first navigation; screenshots carry a -<theme> suffix so both sets survive), asserts the header and Profile switch (applies at once, saves to the account, repaints the other control, never touches the username), screenshots the public home, the member's wall and the join page from the local copy, and returns to /my with waitUntil load (a signed-in member area keeps polling, so networkidle never settles). Requests the page cancels by navigating away (net::ERR_ABORTED) no longer count as failures, and the local-only /api/qr 404 (no qrcode module in a checkout) is ignored for images. Both QA_THEME walks: 0 bugs.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-01 12:03:38 -06:00
martbost 1aec9caf6c Theme switch: auto | light | dark, stored in localStorage iap.theme and on the account, applied before first paint on every page
themehead.js is the one source of the tiny inline head script (and of AUTO_DEFAULT, the one constant Marty decides later: 0 = nothing stored keeps the page's current look, dark everywhere on InstantAdPay; 1 = follow the device). It mirrors LinkSpin's themehead.js with only the storage key (iap.theme), the global (window.IAPTheme) and the event name (iap-theme) changed. The script sets data-theme on <html> from iap.theme (auto follows prefers-color-scheme and tracks changes live). tools/stamp-theme-head.cjs writes it into all 28 static site.css pages before the first stylesheet with data-theme-base="dark" on <html>; the blog, the leaderboard, what's-new, the badge page, the unsubscribe page and the wall 404 read the module directly. The site CSP allows inline scripts by hash only, so themehead.CSP_HASH joins script-src (without it the script is silently blocked).

Account side: accounts.theme (JSON store and MySQL, alterSafe theme VARCHAR(8)), in the public account JSON and /api/me; POST /api/my/profile {theme} rides the existing profile save path, never touches the username, and does not tap changed() (appearance is not mirrored to LinkSpin, same as LinkSpin's side). common.js owns the client side for every page: paints every .theme-seg, saves a click to the account, and IAP.themeSync lets the account value win over the local one at sign-in (a local choice is pushed up when the account has none yet); my.js calls it from render(). The Light / Dark / Auto segmented control sits in the member-area header (#boTheme) and in a Profile pane "Appearance" card, and in the admin header for the same session. shorts.html pins the dark ink set on its black video stage; view.html stops reading an undefined --bg. ?v= tags bumped on every changed stylesheet and script (20261101th): site.css on all 28 pages, common.js on 25, welcome.js on 17, support.js, my.js, engine-room.js, admin.js, admin-kits.js, blog-page.js.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-01 11:55:06 -06:00
martbost fdc95b5ed6 Light and dark themes as token sets (Marty 2026-11-01: LinkSpin got light and dark for vision-impaired readers and people who struggle with bright or dark screens, and InstantAdPay gets the same treatment)
site.css keeps its near-black mint look as the dark set and gains :root[data-theme="light"]: light mint-grey ground (#E8F0EC), white panels, dark ink (#0B1A14), muted #50665C, the mint family darkened to a teal that reads as text on white (#0A6B56, hover #075744), white ink on mint buttons, cyan/violet/amber/gold/ok/warn/bad retuned so every text-on-fill pair clears WCAG AA 4.5:1 (qa/theme-contrast.mjs: 8,169 pairs, 0 fails, worst 4.76:1). New tokens, same names as LinkSpin where the role matches: mint-deep/pale/faint/soft-2/line/line-2, ok/ok-ink/ok-soft, warn, bad-soft, gold/gold-2/gold-ink/gold-soft/gold-faint/gold-line, amber-soft/line/ink, cyan-soft/line, violet-soft/line, muted-soft/line, ink-faint, line-soft, ground-soft, field-bg, nav-bg, side-bg, pill-bg, panel-grad, panel-grad-deep, plate-grad, sh-lg, plus color-scheme. A .seg segmented control (pill, mint when on) for the theme switch.

Audit of stray literals: every raw hex/rgba that encoded a surface, text, border or soft fill in site.css now reads a token (nav and sidebar backings, menu hover/on fills, chips, badges, split strip, spend banner, pager, pipeline columns, tank/line chips, toolkit tiers, chat bubbles, the genViz diagram strokes, the Shorts report link that was white at 45 percent on black). Scripts that draw UI read tokens: my.js charts take their colours from getComputedStyle at draw time (CH proxy), the wallet check, tank badges, ledger deltas, Game Pass badges (gold with gold-ink), Friday bank dots and promo errors use var(--ok)/(--warn)/(--gold)/(--bad); admin.js ticket thread fills, welcome.js pop-up card, support.js ticket styles, engine-room.js lamps, admin-kits.js preview border and blog-page.js bar likewise.

Left as literals on purpose: button glows and drop shadows, the modal and ad-viewer backdrops, the ticker mask, iframe/video/QR backings that must stay white or black, the hero arc and isometric art, the welcome pop-up's brand mint button gradient (dark text on a fixed mint fill passes in both themes), the game return bars and ribbons (game-brand colours), canvas-drawn share images, var() fallbacks, print styles, the sticky-note yellow (#fde68a/#7c2d12, 8.5:1 in both themes), and the refuel rail / Spooky Doors / Gem Kingdom shop pages that carry their own palettes.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-01 11:54:47 -06:00
martbost ce33d71427 Nov 1 season turnover: chatbot says Spooky Doors is closed (Candy Crunch top 10 share 27 POL after admin sign-off, unpaid ladder POL pays once a wallet is linked, Turkey Drop opens Nov 2) and ClutterHunt is in its Harvest Farmhouse season (six rooms, Nov 1 to 30); ClutterHunt promo kit carries the Harvest copy and share image; KNOWLEDGE_DATE 2026-11-01
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-11-01 06:07:10 -06:00
martbost b4989ab59f EnjoyBestGames arcade kit in Promo tools > Games (Marty 2026-10-31): member link enjoybestgames.com/?r=<username> (30-day ebg_ref cookie), share image, 4 posts, 11 banner sizes on the game-banners CDN, and a note that the site is an engagement site where only the featured Polygon games pay; generic game panel gains an optional note line; chatbot canned answer + prompt updated, KNOWLEDGE_DATE 2026-10-31
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-31 08:14:49 -05:00
martbost 47ce40b858 Coach nudges never guess from a failed chain read, and the site owner is never coached (Marty 2026-10-31): a chain.member() failure cached null for 60 s, rungFor() then classed the member as "payouts on, no purchase" and mailed the rung-2 "See a payout land: your first package" nudge to the owner (memberId 1, 4 purchases, 7 buyers). describe() now reports unknown and stalled requires a known state; nudgeTick skips adminEmail.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-31 07:44:22 -05:00
martbost f0811ecf70 Policy test follows the new link-farm report wording (new / still watched / left the list)
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-31 07:29:01 -05:00
martbost 53978476bb Link-farm scan reports only changes: new candidates since the last run and accounts that left the list (wallet linked, bought, deleted), with the still-watched count; candidates carry firstSeen (Marty 2026-10-31: watch, do not delete yet)
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-31 07:26:33 -05:00
martbost 2f2cf24946 Legend pass perk: every new hero as it ships (Marty 2026-10-30: Dallas's $100/year tier idea folded into Legend, no new tier, level caps unchanged)
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-30 13:20:34 -05:00
martbost fda27ad43f Merge warpwares-integration: Warp & Wares hand-off, sponsor dock visit kind (dockCapPerDay 10), Games tab card, promo entry, chatbot, walletnudge, qa (gated by gamesLive); conflicts resolved: KNOWLEDGE_DATE 2026-10-30 kept, my.js tag 20261030ww, ads.js dock changes re-applied onto the prohibited-content version (git saw the file as binary)
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-30 11:23:31 -05:00
martbost 012250360e Wall profile rendering: a purchase alone decides (a quarantined account that buys a package gets its bio and links back, as the quarantine notice promises)
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-30 07:33:19 -05:00
martbost 337d4f9e8f Link-farm hardening (2026-10-30 incident: 106 free accounts used casino bios and website links as backlinks; Google indexed the text through /wall pages)
Public walls: profile fields (bio, avatar, socials, intro video) render only for a paying member (memberId > 0 or a registered position), on /api/wall and in the OG image; a free account's wall shows the name, the line's ads and the join call. The meta/og description is a fixed site sentence with the handle, never the bio. Outbound profile links are rel="sponsored ugc noopener" target="_blank". A deleted or unknown name is a real 404 with X-Robots-Tag noindex (was a bare "Banner wall" page at 200, a soft 404 that stayed indexed).

Policy (prohibited.js, byte-for-byte copy on LinkSpin): bios may not carry a URL or a domain token ("Links go in the social fields, not the bio"); gambling, adult, pharma, weapons and link-selling terms (Unicode aware, Vietnamese and Portuguese terms included) are refused in bios, social URLs, line banner targets, wall offers and every campaign field, with the refusal logged. lssync applies it on the way out and lsinbound on ingest.

Quarantine rule: a brand-new free account (no wallet, no sponsor, under 24 h) whose first profile save plants a link is saved with profileQuarantined (JSON + MySQL column), never rendered publicly, and told "Your profile links will appear after your first ad package"; the admin member card shows the flag.

Daily link-farm scan (spamscan.js, same copy on LinkSpin): in-app job at 06:30 Central, claimOnce per day, lists memberId-0 walletless accounts with a link plus a farm signal (prohibited term, sign-in over within 15 min, no sponsor), skips the spamScanAllow setting (seeded), writes DATA_DIR/wall-spam-scan.json and sends one Telegram to the private admin chat only when there are candidates. Admin > Members > Link-farm list: rows with "also on LinkSpin", Delete selected (existing DELETE /api/admin/member, on-chain refused, no cascade) and Allow.

Terms section 8 "Prohibited content", bio hint in the profile editor, chatbot canned answer "What content is not allowed?", KNOWLEDGE_DATE 2026-10-30. Test: qa/profile-policy.test.cjs (unit + local copy; runs in qa/run.sh member and policy).

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-30 07:29:11 -05:00
martbost ec4ada08d7 Five Dollar Friday notice, email and kickoff mention the Game Pass perk correctly: a $5+ Friday pack earns +20% credits (600 from the $5 pack) AND includes the free 7-day Game Pass automatically (fridayPassPerk, since 2026-10-23); Marty 2026-10-30 asked for the tie-in
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-30 05:16:12 -05:00
martbost a058fd515d Warp & Wares integration, gated (2026-10-29): the 30-day Trade Wars-style season game, same protocol as POL Miner and Turkey Drop. WW_SSO_SECRET / WW_URL (default https://warpwares.saasy.top, staging for now) / WW_ALT_URLS / WW_SEASON_START + WW_SEASON_END (default 2026-11-30..2026-12-30, Central, end exclusive) with wwMint/wwOpen/wwIsGameUrl/wwCallback (code defaults only, no env set); GAME_AUTH warpwares (in-game sign-in kit); /api/my/warpwares hand-off + iap.return + my.js redirect; a new visit kind 'dock' in ads.js VISIT_KINDS with its own daily cap (dockCapPerDay, default 10; repeats after the cooldown like refuels; house visits count toward it) and the refuel rail serving game 'warpwares' with that kind (label 'sponsor dock', receipt kind ww-dock, note 'Warp & Wares sponsor dock', refuel.js done text 'Your bonus turns are waiting on the bridge'); GAMES() card with the season window (hidden until 'warpwares' is in gamesLive, its 'Opens' date shown only once live, gone after the season) and STRIP line; growth snapshot counts a season start only when live; walletnudge entry (idle until the secret is set); gamestats + gamepass GAMES/NAMES + GP_SECRETS; Game Pass perks row 'the Season Pass' shown only while the game is in the public games list (gpShown, the Turkey Drop pattern); cap-nudge names; promo tools Games entry (warpwares.saasy.top/?ref=, 3 posts) shown only while live; chatbot CANNED warpwares + fact follow gamesLive and the season window (coming-soon and season-over answers, KB answer kept out of the prompt unless live), KNOWLEDGE_DATE 2026-10-29b; my.js?v=20261029ww, promo.js?v=20261029ww, refuel.js?v=20261029ww. qa/warpwares.mjs (bash qa/run.sh warpwares): 21 checks on a local copy with a mock game (card gating, the hand-off token, a sponsor dock open/challenge/done with receipt + callback, the dock cap separate from refuels, chatbot gating), all passing. Not merged, not deployed.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-29 16:43:49 -05:00
martbost c621fecb54 BixPay sign-up warning (Marty 2026-10-29: bizventures registered through our correct partner link but BIX recorded referrer N/A): the invite token lives only in BIX's URL and their security check often fails inside app webviews, so members who reopen BIX elsewhere lose their sponsor. Guide, Wallet card and Overview card now say: sign up on the page the button opens, no app first, no portal Sign Up menu; in-app browsers (Gmail/Telegram/Facebook webviews, iOS web views) get a notice with the link to copy into Chrome or Safari (no native dialogs); chatbot card answer carries the same; my.js + bixpay-guide.js ?v=20261029bz
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-29 11:46:46 -05:00
martbost 13e0644355 QA: syntax gate in every run.sh mode (node --check on every server and public script) after LinkSpin's /traffic-guide shipped with a parse error
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-29 10:49:06 -05:00
martbost ed6febe0b8 BixPay card integration, phase 1 (Marty approved the copy 2026-10-29; docs/BIXPAY-INTEGRATION.md): gated by site config bixpayLive (off by default). Profile > BixPay card field (partner link validated: bix.ibportal.io/auth/register, e= token, a=1; the appId=3 card-customer link is refused with a message), bixpay.js resolver own > sponsor chain (10 levels) > company link (bixCompanyLink, seeded with Marty's partner link), every surface says whose link it is. Wallet tab card, one-week Overview announcement (24 h snooze), one sentence in TierPaid payout emails and the games' wallet nudges, Promo tools > BixPay tab (3 posts, email swipe, 4 text-only banners on the Spaces CDN, tracked link + per-member clicks), public guide /bixpay with masked app screenshots, chatbot canned answers + facts gated to 'coming soon' while off (KNOWLEDGE_DATE 2026-10-29). Clicks per surface via /go/bixpay in the admin Traffic tab; admin Overview counts members with a link; member card shows it; signed /api/partner/bixpay and the lssync profile row carry it for LinkSpin/CTB. accounts.bix_partner_link column (db.js alterSafe). Tests: qa/bixpay.test.cjs (17) + walk.mjs BixPay block; my.js/promo.js/admin.js ?v=20261029bx.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-29 07:56:49 -05:00
martbost 6e1ab102f1 Holding-tank Telegram notice: a wallet that predates the tank visit says 'already linked (last seen <date>)' instead of 'linked a wallet' (Marty 2026-10-29: @teamearning, dormant since Sep 18, was returned by a sponsor and the notice read as a live member); digest wording to match; readyTick carries lastSeen + linkedNow
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-29 07:16:47 -05:00
martbost 01154c0856 Member update emails: claim the send slot before building the recipient list (the Sendy opt-in checks take minutes). On 2026-10-28 a retried POL Miner launch email raced the first one: both passed the 'already running' check, 475 members got it twice; stopped by a restart, the rest went out once. A second send now gets 'A send is already running' immediately.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 14:34:31 -05:00
martbost 7d134e55a2 Game refuel visits never come up empty (Marty 2026-10-28): after every sponsor has been seen, a member video, then a house sponsor (one of Marty's programs, never the game the player is in; 0 credits, no pool income) and, after the doorRepeatDays cooldown, a sponsor seen before again (a real, paid repeat visit, visit_repeat kind refuel). Repeats and house visits count toward the 20-a-day refuel cap. Applies to every game using /refuel (supply crates, paddles, continues, refuels, hints). Earn stays once-ever. Chatbot fact updated. qa/refuel-fallback.mjs (10 checks); member + earn qa clean; qa/door.mjs prints the callbacks on its pre-existing credits failure (admin-seeded packs are house ads, 0 credits, fails on main too)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 13:23:46 -05:00
martbost 8b28d028a6 All-games promo posts no longer name a game count (said 'Eight games'); list adds the brick breaker and the mining game; promo.js?v=20261028q
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 12:28:33 -05:00
martbost f1482deb12 POL Miner joins the Game Pass (2026-10-28, Marty): gamepass.GAMES/NAMES += polminer (polgrant accepts it with POLMINER_SSO_SECRET); pass copy "nine games" -> "ten games" (my.js card + perks table, chatbot pass/Friday/tiers answers, friday.html, Friday pass email); GP_PERKS + chatbot perk line "POL Miner: daily crystal limit 1.5 POL instead of 0.5, plus one free supply crate every day" (PolyBreak gem precedent + Gem Kingdom free-continue precedent); Games card art -> Spaces CDN og-polminer-clean.jpg; promo tools Games entry (link polminer.com/?ref=, og + 11 CDN banners, 4 posts) shown only once polminer is in the public games list; my.js?v=20261028pp, promo.js?v=20261028p. qa member 0 bugs (2 old warnings), qa public 0 bugs (1 old /shorts warning), qa/gamepass.mjs same 5 date-based failures as without this change.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 12:11:29 -05:00
martbost 6096bf38c6 POL Miner integration, gated (2026-10-28): POLMINER_SSO_SECRET / POLMINER_URL / POLMINER_ALT_URLS with pmMint/pmOpen/pmIsGameUrl/pmCallback; GAME_AUTH polminer (in-game sign-in kit); /api/my/polminer hand-off + iap.return + my.js redirect (my.js?v=20261028pm); refuel game 'polminer' (label "supply crate", receipt kind pm-crate, note "POL Miner supply crate"); GAMES() card (art polminer.com/og-polminer.jpg) and STRIP line, both hidden until 'polminer' is in site config gamesLive; walletnudge entry (idle until the secret is set); gamestats name; chatbot CANNED + systemPrompt fact follow gamesLive (coming-soon answer and fact until launch, its KB answer kept out of the prompt), KNOWLEDGE_DATE 2026-10-28. qa member: 0 bugs (2 old admin warnings), qa public: 0 bugs.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 08:07:26 -05:00
martbost 1089942bca Game POL pays to any LINKED wallet (Marty approved "build all three", 2026-10-27)
- walletnudge.js: the hourly push hands the member's signature-linked wallet (accounts.address, only set by
  auth.verifyChallenge -> accounts.linkWallet) to every game holding an unpaid balance, activated or not; memberId is the
  on-chain id when there is one, else 0 (a failed chain read falls back to the stored id instead of skipping the row).
  Holding-tank members waiting to switch on payouts no longer have their game POL stuck. Game side unchanged contract:
  signed POST, fill-empty-only (different wallet = 409, retried once a day), idempotent.
- Nudge copy (no linked wallet only): "You've earned X POL in <game>. Link your wallet (one free signature) and it's sent
  automatically, including everything you've earned so far." + /my#wallet; never mentions switching on payouts.
- The IAP -> game /auth tokens already carried wallet: a.address regardless of activation (no change).
- chatbot.js: game-pol-wallet canned answer (ahead of the per-game entries) + GAME POL TO ANY LINKED WALLET prompt fact
- qa/walletnudge.test.cjs (mock game: non-activated push with memberId 0, activated push, chain-read failure, nudge copy,
  409 refusal + daily retry), wired into qa/run.sh member + walletnudge; chatbot-parse routing cases for the new answer

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 09:19:10 -05:00
martbost fa5acf0745 Network rate 4:1 (Marty approved 2026-10-27): syndicated delivery costs 1/synRateDivisor of the on-site rate, going forward
rates.synRateDivisor (default 4, Admin > Rates; 1 = the old rule). Network Ad Space impressions charge 1 credit per
impressionsPerCredit x N views (banner 20, text 40 at N=4), through the same chargeCredits path (earned pool first,
then on-chain burn), with their own credit-log line "Network views (1/4 rate)". Fractions are exact: the cumulative
served count carries the remainder. The budget is the limit: NAS bookings, resume, top-up and daily allowances are
sized at the network rate, and a live ad booked at the old rate is topped up once to what its budget now buys.
PassiveDrip: N partner visits use up 1 pack visit (floor on the cumulative count), every partner visit counted in
the new syn_imps column, PD offered visits left x N. Nothing already charged changes. Member Campaigns: network views
and partner visits marked "at 1/4", a note under the table, a Network rate chip. Chatbot canned answer + live AI fact.
Cache tags bumped. QA: qa/run.sh nas (served 8, restart 9, ratio 15), chatbot-sync, run.sh member all passed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 08:05:43 -05:00
martbost 8b03dd2311 Fix NAS phantom delivery on resume/top-up: a stopped NAS ad restarts from its true served count
stopNas zeroes `remaining` after recording the true served count. Resume (setStatus) and topUpCampaign then
used a plain nas.topUp, so assigned - remaining read the zeroed remainder as served and the next reconcileNas
charged it (up to the whole budget). New nas.restart(id, trueServed, add) re-bases assigned on the recorded
count; ads.nasExtend uses it for any stopped ad (remaining 0) and keeps the plain top-up for a running one;
resume tops up only to the budget left. QA: qa/nas-restart.mjs (9 checks; fails on the old code), nas-served 8,
run.sh member all passed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 07:54:08 -05:00
martbost 59607d0c94 One-tap switch on payouts after a holding-tank assignment + reminders (Marty approved 2026-10-27)
- Assignment chat + member email (manual adoption and the 24h auto-assign) carry "Switch on payouts" -> https://instantadpay.com/my?activate=1#wallet
- /my?activate=1: signed in, wallet linked, real sponsor, no hold -> Wallet tab, explainer line, the Activate button's own flow (injected wallet or the WalletConnect picker on a phone). Survives sign-in and the wallet link (sessionStorage); never starts on tankHold, a blocked/routed sponsor or the #1 fallback (/api/me sponsorFallback)
- payTick (in the 15-min readyTick): not activated 24h after the assignment -> ONE member email + ONE in-app notice to the sponsor; 72h -> last member email; stops on memberId / MemberActivated / sponsor change. State tank-ready.json `pay`, each send gated by marks.claim (deploy overlap), record saved before the send; Admin tank view gets payReminders
- Chatbot: tank-activate-link canned answer + system prompt; my.js ?v=20261027pa
- qa/tank-hold.mjs: link texts, reminder schedule on a mocked clock, overlap copy, ?activate=1 browser flows (stubbed wallet)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 07:29:43 -05:00
martbost e5c55c2d8b Never hold a purchase (Marty 2026-10-27): a holding-tank buyer with no sponsor anywhere goes ahead under the catch position #1; the 24h hold only stops a plain switch-on-payouts. Network alignment still runs first. home.js buys with intent=buy; chatbot + QA updated
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 07:05:06 -05:00
martbost 4645d5605a Holding tank activation hold (Marty approved 2026-10-27, "hold them for no longer than 24 hours"): a tank member is never bound under the fallback #1
- Align first: a tank member whose email or wallet already has a sponsor on LinkSpin (the inbound registry rows) is placed under that sponsor when they have a real account here, never a sponsor they were released/rescued from, never a loop (recorded in tank-ready.json, shown in Admin tank)
- Hold: /api/me and /api/sponsor answer tankHold {since, until} instead of the fallback sponsor; Wallet tab hides Activate payouts and shows "You're being matched with a sponsor..." with time left, Getting started has no activate button, buy flows (my + home) refuse on tankHold. The 24-hour clock starts when the member is first seen with a wallet linked (already-linked members start at deploy)
- Surface: Ready to activate badge + hours left, ready members on top (My line tank, Admin tank, Overview notice count); one Telegram line per newly ready member (digest when more than 3, e.g. the first tick after deploy)
- Safety net (readyTick every 15 min + hourly sweep): unadopted 24 h after readyAt -> next eligible adopter in rotation (own $20+ buy, fewer than 2 open, signed in within 7 days, not suspended/flagged, not company, not a no-payout chain, not in their own downline; least recently auto-assigned first, ties by earliest qualification) through adopt() with "auto-assigned after 24 hours in the tank", chat + email to both, Telegram pickup "(auto-assigned)". Nobody eligible: keep holding, one admin alert
- tank.eligibility is now exported (the Overview tank notice was silently failing on it)
- Chatbot: tank-hold canned answer, holding-tank answer + system prompt updated, KNOWLEDGE_DATE 2026-10-27
- qa/tank-hold.mjs (mocked clock unit + local copy e2e), wired into run.sh member and run.sh tankhold; cache tags bumped

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 06:03:41 -05:00
martbost fc81c6a4db Chatbot: free game caps started 2026-10-26 (Marty moved capsStartDate up from 10-29)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-26 17:13:22 -05:00
martbost 06f0a87452 Conversion tracking fixes (Marty approved 2026-10-26): real test pixel, own-click count, own-browser clicks as tests, cost per goal (30 days)
1. Own clicks: auth.onSeen notes the soft key of every InstantAdPay session (lsconv.noteSession, once per 6 h per email + soft key) and the click push carries them as owners [{owner, sk, ts}] (requeued on a failed push), so LinkSpin keeps members' own clicks on their ads, spin links and Banner Spins as tests. /api/ads/click flags a click self for conversions when signed in as the owner OR from a browser the owner signs in from; whether the click is counted and billed is unchanged (still the signed-in check). Linked positions share the owner's email.
2. Send a test conversion now loads the member's real LinkSpin pixel in test mode from the browser (cv.gif?px=..&test=1, reads X-LS-Result: test, the same request LinkSpin's button makes) and falls back to the signed partner call (op test) when the browser cannot load it; CSP connect-src adds https://linkspin.app. The card shows "N from your own clicks, kept as tests and left out" (selfTests from LinkSpin's summary).
4. Cost per goal (30 days): /api/my/conversions returns spend30 = each campaign's spend over the same 30 days from credit_log (ads.spendSince: delivery, login, buy, refund rows by Central day, ref = campaign id). Campaign lines read "Goals and cost per goal (30 days)"; a campaign started inside the window with no log rows uses its spend since start (labelled in the tooltip); an older campaign with no spend on record shows no cost rather than a lifetime figure.
Copy: Conversion tracking card note, /conversion-tracking (test button, own clicks, cost per goal (30 days) row). Chatbot CANNED + FACTS, KNOWLEDGE_DATE 2026-10-26. my.js ?v=20261026cv.
QA: convpixel all passed (new: owners pushed without raw IP, own-browser click self=1 and stranger 0, no re-push within 6 h, spend30 = 200 of the window with the 40-day-old row and another member left out, 50/200 credits each vs lifetime 75, no-log old campaign shows no cost, new campaign uses spend since start, own-click count on the card, test button loads cv.gif?px&test=1 in the browser (routed locally) and falls back to op test); fuel all pass (engine.js / engine-room.js / kit.js untouched, byte-identical with LinkSpin); member walk 0 bugs; public 0 bugs (known /shorts ellipsis warning).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-26 06:31:18 -05:00
martbost 27d663ca29 Conversion tracking walkthrough video live (Marty approved 2026-10-26): on /conversion-tracking and the Training card
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-26 04:55:43 -05:00
martbost b239417cc5 Game Pass tier prices = InstantAdPay one-click packages (Marty 2026-10-25): Explorer $20 (was 19.99), Champion $50 (was 39.99), Sovereign $100 (was 99.99), Legend $250 (was 249.99); weekly $5 unchanged. TIER_DEFS and the siteConfig defaults in cents 2000/5000/10000/25000, so the cheapest qualifying package is exactly the pass price (no silent overpay). A pass is still paid by one fresh package of at least the tier price. Member Games card: each tier says it comes with the $X package and its ad credits (my.js ?v=20261025pr). Admin Game Pass note, docs/GAME-PASS.md, chatbot tier fact (price = package, member keeps the package credits; still 'coming soon' while sovTiers is off). sovTiers untouched (0). QA: sov-passes-store + sov-passes-local ALL PASS with the new prices; qa member 0 bugs, qa public 0 bugs; qa/gamepass.mjs 2 date-based fails identical on the previous commit.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 13:14:29 -05:00
martbost 47638ac1fe Fuel flow IAP -> LinkSpin made obvious (Marty 2026-10-25: "I clicked set up conversion tracking, it took me to LinkSpin and I don't know how to pick up from there"). Engine Room links now follow the site the member is on (engine.js build({site})): Set up conversion tracking on InstantAdPay opens /my#conversions (Campaigns > Conversion tracking card, scrolled to, highlighted, goal box focused; same goals LinkSpin counts) with the /conversion-tracking guide beside the button; buy/refuel/top-up and the Fuel part stay on this site. Only LinkSpin-only tools cross over (Banner Spin -> /links#b, spin link, page, testing), labelled "on LinkSpin" and tagged ?from=iap&task=<job> so LinkSpin shows an arrival strip with Step 1. Streak line and Refuel card get a "Refuel LinkSpin" link to linkspin.app/credits#refuel when the second engine is still open. Part labels wrap cleanly. Chatbot canned + prompt routes, KNOWLEDGE_DATE 2026-10-25. engine.js / engine-room.js stay byte-identical with LinkSpin. QA: fuel 12/12 engine incl. new site-links test, member walk 0 bugs. my.js, fuel.js, engine-room.js ?v=20261025ff.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 09:05:53 -05:00
martbost 7f80d82486 Game Pass tier testing moves to Admin > Game Pass (Marty 2026-10-25): the member Games card shows every account, the admin's included, exactly what a member sees (weekly pass only while sovTiers is off; a holder sees the tier they hold). The /my admin preview note and the admin bypass on GET /api/my/gamepass and POST /api/my/gamepass/buy are gone. New Admin > Game Pass > Tier test and preview card (labelled TEST / PREVIEW): all five tiers as members will see them with on-sale/hidden chips and the admin's own status, Test buy (real waiting order fulfilled by a fresh package), Cancel test order, Give my account (test comp, no sale), End. New admin-only routes GET /api/admin/gamepass/preview, POST /api/admin/gamepass/test-buy | test-cancel | test-comp, always on the signed-in admin's own account. sovTiers untouched. QA: sov-passes-local + store reworked to the new flow (all pass); my.js and admin.js ?v= bumped.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 08:37:17 -05:00
martbost cecba6b313 Wallet-link nudges on for PolyBreak, SpellWheel, PolyWarriors (Marty 2026-10-25; they were push-only); QA walk: signed-out support tickets are members-only (962cdf0), non-member refused 403
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 05:33:43 -05:00
martbost a4642341aa Wallet push: game balances waiting on a wallet the member already linked (on-chain member address, the same one the hand-off token carries) are pushed to the game's signed POST /api/iap/wallet instead of nudged, so the game's own sweep pays them (solanaclick 1.5 POL in Gem Kingdom, 2026-10-25); PolyBreak, SpellWheel, PolyWarriors join the hourly check push-only (no new nudge mail); admin view counts and lists pushes and refusals
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 05:12:15 -05:00
martbost 962cdf08b5 Support tickets are members-only (Marty 2026-10-24, after a throwaway-address 'pentest' ticket IAP-1012): signed-out support form + chatbot handoff need an email that belongs to an account on this site; inbound email opens NEW tickets only for member emails (replies to existing tickets still land)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 11:36:17 -05:00
martbost 13f3ff56f8 Conversion tracking card: goal rows showed 30 (the window length) instead of the goal's conversions
LinkSpin's partnerSummary returns conv = the count and convDays = the window in days; my.js preferred convDays, so every goal read "30" under Conversions (30 days). Now shows g.conv. Also: a goal without a default value (LinkSpin stores 0) no longer adds &value=0 to its snippets or shows 0 as its default. QA mock now matches the real contract (convDays = 30) and asserts the row counts (6, 1). my.js ?v=20261024ct.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 11:08:11 -05:00
martbost bf5cf62caf Conversion tracking member guide at /conversion-tracking (Marty, 2026-10-24: no training existed for the conversion pixel, live since 10-23)
Why track, the click -> landing page -> thank-you page -> counted flow drawn in HTML/CSS (across on desktop, down at 390 px), the 4 steps (goal, landing tag, goal pixel, test incl. the &test=1 page check), copy-paste examples with placeholders for plain HTML, WordPress (footer plugin + Custom HTML block), page builders and Aweber/GetResponse custom thank-you pages, what to do without code on the thank-you page (image pixel = cookie / 24-hour match, hidden lsclk field, LinkSpin.goal for pop-up forms), how to read the report (cost per goal in credits, match methods, tests, 30-day window, own clicks) and a troubleshooting checklist. Copy buttons in conversion-guide.js; frames handled by common.js.
Route + TRAFFIC_PAGES + sitemap + viral-link page list. "How to set it up" link on Campaigns > Conversion tracking. Chatbot CANNED conversion-tracking answer + FACTS line point to the guide (KNOWLEDGE_DATE stays 2026-10-24).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 10:18:51 -05:00
martbost 8ca5ed99e8 NAS 728x90 ad tags load inside a srcdoc iframe: the inline <script> blocked the page below it while networkadspace.com (rhi) was offline for the 2026-10-24 data-center move (PolHunter stalled halfway the same way)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 09:24:09 -05:00