AI ad writer on the text-ad form (Marty 2026-11-17: "do it on the other sites too"): "Write my ad from my link" asks the network hub (hubadwriter.js, POST /v1/adwriter, 60/90 limits) for 3 ads from the member's own page; shown only when the hub says on; chatbot fact; my.js?v=9
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
+2
-1
@@ -49,6 +49,7 @@ listen(HUB_PORT, async (q, r, b) => {
|
||||
else if (j.email) p = all.find(x => x.email === j.email);
|
||||
return r.end(JSON.stringify({ person: hubView(p) }));
|
||||
}
|
||||
if (String(q.url).startsWith('/v1/adwriter')) return r.end(JSON.stringify({ on: true, daily: 5, left: 5 })); // the ad writer (hubadwriter.js; its own test covers the calls)
|
||||
HUB.got.push({ route: q.url, body: j }); r.end('{"ok":true}');
|
||||
});
|
||||
// ---- stand-in InstantAdPay member lookup (only used while the hub is down) ----
|
||||
@@ -476,7 +477,7 @@ const mtop = await anon.json('/api/wire?page=member&u=topdog');
|
||||
pa = await M1.json('/api/my/ad', adBody(1, { link: 'https://member-1.example-shop.com/third', track: true }));
|
||||
my = await M1.json('/api/my'); ok(pa.ok && pa.linkspin === 'tracked' && my.ad.spin === false && my.linkspin.state === 'tracked', 'back to an ordinary link: tracked with LinkSpin again', [pa, my.linkspin]);
|
||||
const h = await (await anon.req('/my')).text(); const js = await (await anon.req('/assets/my.js?v=7')).text();
|
||||
ok(/id="spinBtn"[^>]*>Use one of my spin links</.test(h) && /id="trackNote"/.test(h) && /my\.js\?v=8/.test(h) && /\/api\/my\/spins/.test(js), 'the ad form has "Use one of my spin links" and the tracking note'); }
|
||||
ok(/id="spinBtn"[^>]*>Use one of my spin links</.test(h) && /id="trackNote"/.test(h) && /my\.js\?v=9/.test(h) && /id="aiWrite"/.test(h) && /\/api\/my\/spins/.test(js), 'the ad form has "Use one of my spin links" and the tracking note'); }
|
||||
|
||||
console.log('14c. PolHunter mission (front page, How it works)');
|
||||
{ const hr = await anon.req('/'); const hh = await hr.text(); const csp = hr.headers.get('content-security-policy') || '';
|
||||
|
||||
Reference in New Issue
Block a user