Commit Graph

24 Commits

Author SHA1 Message Date
martbost b70ecf6f75 Pay game POL to any signature-linked wallet, on chain or not (2026-10-27)
InstantAdPay now pushes a member's signature-linked wallet whether or not it is activated (memberId 0 when not on chain).
- POST /api/iap/wallet accepts memberId 0/missing: the wallet fills the email-keyed player (sso.emailId) and its account;
  a player with no account row yet gets one holding the wallet. Signature check, fill-empty-only (different wallet 409),
  same wallet no-op and 404 for an unknown player are unchanged; a real memberId still adopts the email history first.
- /auth: a hand-off wallet fills an EMPTY account wallet so POL earned so far pays on the next sweep (never replaces one).
- game.adopt carries the wallet when the target account has none.
- /api/me: me.hasWallet (own wallet on file, also when it arrived by the push after the session began).
- play.js: no-wallet players see "Link your wallet to receive this POL" (IAP /my#wallet, new tab) on the chapter-clear
  result, the lobby member line and the balance card (which also lost a line that always overwrote the waiting-POL note);
  players with a wallet see the same text as before. play.js?v=20261027lw.
- test/run.js: memberId 0 push -> 200 changed:true -> sweep pays it; /auth memberId 0 wallet; 409; activation later.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 09:18:09 -05:00
martbost eb2cb822ac Signed POST /api/iap/wallet: InstantAdPay pushes a member's activated wallet into the game (fills an empty wallet through the same setWallet path /auth uses; same wallet again is a no-op, a different one is refused), so POL earned before a wallet was linked pays out without a fresh hand-off (2026-10-25, solanaclick 1.5 POL stuck in Gem Kingdom)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 05:09:11 -05:00
martbost cc3db3833f Game Pass bridge (GAMEPASS=on): chapter first clears via InstantAdPay polgrant (wallet-less members by email), shield at run start perk, lobby line + clear note, tests
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-22 06:50:39 -05:00
Marty Bostick fe61842525 Mirror Telegram group posts into the Crypto Team Build Discord
Discord relaunch 2026-10-09: the shared discord-relay.cjs fans every post that goes to the
community group out to the matching Discord channel (achievements topic -> #achievements,
payments topic -> #payment-proofs) through DISCORD_WEBHOOK_* webhooks. Telegram HTML is
converted to Discord markdown, buttons become links, cards post as images. DMs and alert
chats are not mirrored. Fire-and-forget; off when the env is unset.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-09 13:57:38 +00:00
martbost 7c2d6b7467 Signed /api/iap/unpaid feed for InstantAdPay's wallet-link nudges; balance screen and a one-time toast tell a player with POL waiting and no wallet how to get paid
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-10-07 10:35:15 -05:00
martbost 3aa5698c8a Network line: game is part of the InstantAdPay network, the Polygon wing of the Crypto Team Build Network (linked to cryptoteambuild.com, new tab)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 09:42:19 -05:00
martbost 11d6f46950 Invite friends card in the lobby + ?ref attribution on every entry page
Marty: members could not find their referral link. A signed-in player now sees an
"Invite friends" card right under Play: their /r/<username> link (previews with their
own card), Copy (clipboard API, select+copy fallback, prompt last) with a Copied!
confirmation, and Share where the phone has a share sheet. Link stats and the how-it-works
line moved into the card. No username yet: the card says how to get one.

Attribution: ?ref=<name> on /, /play and /signin (and ?r= on the landing, where framed
/r/<name> lands) now sets the same dr.ref sponsor cookie as /r/<name>, last touch wins.
/r/<name> for a name the game does not know keeps it as /?ref=<name> instead of
dropping it. signin.js also reads ?ref straight from the URL. Tests cover each path.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 07:25:22 -05:00
martbost 09692de8c6 Member welcome offer + member perk: after a chapter clear, a signed-in non-member (IAP memberId 0) sees a dismissible "Become an InstantAdPay member" card once per Central day (bonus from IAP /api/starter/public, cached 10 min, skipped when off); a member's first hand-off grants one free hangar upgrade (token on the player, next purchase costs nothing, no POL moved), with a one-time lobby message
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 06:24:20 -05:00
martbost 4fa68b2745 Share links preview as the sharer's own card (badge with their name) for Telegram/Facebook/X; the game page previews as the Drip Runner banner, not the blank badge
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 10:18:49 -05:00
martbost 75ba7ba388 Traffic exchanges: public pages may be framed (admin/sign-in still refuse); a framed game or share link shows the landing, whose buttons open play in a new tab with the referral
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 19:14:15 -05:00
martbost 60f1148efa Paid-traffic source tracking: ?utm_source/src + clickid -> dr.src cookie, per-source visits/guests/runs/sign-ins/new accounts, BeMob postback on a new account (DR_POSTBACK_URL), /api/admin/srcstats
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 11:30:22 -05:00
martbost 305bd435fa Cross-promo: More games strip from InstantAdPay's shared list (2026-10-03)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 10:23:46 -05:00
martbost 9c693fcf63 In-game sign-in: /signin runs the InstantAdPay kit (no trip to InstantAdPay), CSP admits instantadpay.com, dashboard and Level up links open InstantAdPay signed in
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 10:02:47 -05:00
martbost 9a3ba1e497 Badge and milestone cards post to the CTB Game Achievements topic (DR_TG_ACH_TOPIC); payout cards stay in the payments topic. /api/public/today for the shared 6 PM games summary
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-01 20:29:02 -05:00
martbost 7dfed34eaa driprunner.app is home: other hosts forward pages (path + query kept), API/callback/health/badges answer everywhere; preview images on the new domain
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-01 06:02:44 -05:00
martbost bc28136e04 Public landing page (live stats, how it plays and pays, honest fine print), tester briefing moved to /testers, badge art served from /badges/ (cached, cross-origin) for IAP cards and link previews, signed /api/partner/player for the IAP Games card, /api/public/stats
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-01 04:36:56 -05:00
martbost 06daa4ef0a Referral layer: guest play from share links (/r/<username>), guest clears paid on sign-in, sharer's link via their IAP join page, 10% referrer slice of each referral refuel's pool income (IAP sponsor), share buttons + stats in the lobby and on chapter clears, wallet-less progress follows the member once a wallet is linked; 11 new checks
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 17:14:08 -05:00
martbost 83da8c33f2 Facts you learn as you play (SkyCash): tips priced from the live IAP catalog on the lobby, run-over and chapter-cleared cards; Level up on InstantAdPay button in the lobby
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-30 15:35:32 -05:00
martbost 505f5cdae4 Badge cards posted to Telegram: hangar unlocks, chapter milestones (1,3,5,10,15,20), refuel milestones (5,25,100), payouts; neon artwork + ffmpeg-stamped name/earnings; trial wording (coming soon, would have earned) until the admin flips it; admin announce route
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-30 15:04:38 -05:00
martbost fad0767648 Tester list also matches the IAP username
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-30 14:32:45 -05:00
martbost ecfe97b90a Sign-in mode 'key': anyone whose browser holds the curtain pass (opened the key link) may play; tester list still honoured
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-30 14:31:19 -05:00
martbost abc81e8d90 Refused hand-offs (not a tester) are logged and pinged to Marty with the name to add
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-30 14:29:30 -05:00
martbost 5a7dfb0828 Admin: Refresh button + auto-refresh every minute, key kept in the browser so /admin reloads without it
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-30 14:09:35 -05:00
martbost 903b5065b9 Drip Runner trial: IAP hand-off, seeded runs with server replay check, self-funding POL pool (refuel ad share + hangar spends), chapter drips, threshold payouts via faucet (dry run), tester allowlist + briefing page, admin page, e2e test
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-30 13:21:39 -05:00