PassiveDrip PTC bridge: visit campaigns listed on PassiveDrip's paid-to-click page (signed sync every 5 min), delivered visits read back and applied to the pack (read, never derived); admin status + run routes
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
@@ -47,7 +47,8 @@ const badge = require('./badge'); // achievement badge image drawn o
|
||||
const friday = require('./friday');
|
||||
const wednesday = require('./wednesday'); // Wired Wednesday: +25% on $10+ packs, wired into a visits campaign (2026-09-29)
|
||||
const fridaybank = require('./fridaybank'); // Friday Bonus Hunts: days banked Sat-Thu by solo + video (2026-09-26)
|
||||
const refill = require('./refill'); // campaign running-low / ran-out notices, and what came of them // Five Dollar Friday: +20% credits on Friday packs, the wave, the badge (Marty, 2026-09-20)
|
||||
const refill = require('./refill');
|
||||
const pdsync = require('./pdsync'); // PassiveDrip PTC bridge: our visit campaigns on their paid-to-click page (2026-09-30) // campaign running-low / ran-out notices, and what came of them // Five Dollar Friday: +20% credits on Friday packs, the wave, the badge (Marty, 2026-09-20)
|
||||
const snapshot = require('./snapshot'); // daily growth snapshot -> Telegram payments feed (Marty, 2026-09-15)
|
||||
const pipeline = require('./pipeline'); // sponsor follow-up board (coming soon until site setting pipelineMode = on) (Marty, 2026-09-15)
|
||||
const videomaker = require('./videomaker'); // Circuit tool: promo videos with the member's own end card (ffmpeg in the image) // badge-gated promo toolkit + AI Copy Engine (Surge and up) (Marty, 2026-09-14) // referral contest: /leaderboard, Overview card, weekly + monthly winners (Marty, 2026-09-14) // release notes + roadmap: /whats-new, Overview card, Admin > Releases (Marty, 2026-09-14) // blog -> Blotato -> X + Instagram on publish (Marty, 2026-09-13) // admin member card: search, drilldown, edits (Marty, 2026-09-13) // admin-written coaching articles, server-rendered public /blog with SEO metadata (Marty, 2026-09-12)
|
||||
@@ -573,6 +574,8 @@ async function boot() {
|
||||
if (ads.nasEnabled()) {
|
||||
console.log('NAS syndication enabled');
|
||||
setTimeout(() => ads.reconcileNas().catch(e => console.error('nas reconcile', e.message)), 90 * 1000);
|
||||
pdsync.init({ dataDir: DATA_DIR, ads });
|
||||
if (pdsync.enabled()) { const every = Math.max(2, Number(process.env.PD_SYNC_MIN || 5)) * 60 * 1000; setTimeout(() => pdsync.sync().catch(e => console.error('pdsync', e.message)), 90 * 1000); setInterval(() => pdsync.sync().catch(e => console.error('pdsync', e.message)), every); console.log('PassiveDrip PTC bridge: on, every', every / 60000, 'min'); } else console.log('PassiveDrip PTC bridge: off (no PD_BRIDGE_URL/SECRET)');
|
||||
setInterval(() => ads.reconcileNas().catch(e => console.error('nas reconcile', e.message)), 5 * 60 * 1000);
|
||||
}
|
||||
}
|
||||
@@ -1331,6 +1334,8 @@ const server = http.createServer(async (req, res) => {
|
||||
// -- public API
|
||||
if (p === '/api/friday' && req.method === 'GET') return json(res, 200, friday.view(), { 'Cache-Control': 'public, max-age=60' });
|
||||
if (p === '/api/wednesday' && req.method === 'GET') return json(res, 200, wednesday.view(), { 'Cache-Control': 'public, max-age=60' });
|
||||
if (p === '/api/admin/pdsync' && req.method === 'GET') { if (!isAdmin(req)) return json(res, 401, { error: 'auth' }); return json(res, 200, pdsync.status()); }
|
||||
if (p === '/api/admin/pdsync/run' && req.method === 'POST') { if (!isAdmin(req)) return json(res, 401, { error: 'auth' }); return json(res, 200, await pdsync.sync()); }
|
||||
if (p === '/api/admin/wednesday-previews' && req.method === 'GET') { if (!isAdmin(req)) return json(res, 401, { error: 'auth' }); return json(res, 200, wednesday.previews()); }
|
||||
if (p === '/api/admin/wednesday/kick' && req.method === 'POST') { if (!isAdmin(req)) return json(res, 401, { error: 'auth' }); const r = await wednesday.kickNow(); return json(res, r.error ? 400 : 200, r); }
|
||||
// -- the pages a member can turn into a viral link (promo tools > Viral links)
|
||||
|
||||
Reference in New Issue
Block a user