Open-source platform for 3D AI agents. Turn text or a photo into a rigged, animated GLB avatar, give it an LLM brain, memory and a wallet, and embed it anywhere with one web component. Remote MCP server, x402 payments, Three.js, browser-native.
JavaScript 3d-generationai-agentsanimationavatardigital-humangenerative-aiglbgltfimage-to-3dllmmcpmcp-servermodel-context-protocolsolanatext-to-3dthreejsweb-componentswebglwebxrx402
feat: platform-wide activity feed on /feed, live activity on /community
fudjiad627ac2050fb
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex be8786538..80760b563 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -9,6 +9,7 @@ Public history for [three.ws](https://three.ws), newest first. New pages come fr- **Docs · The autonomous economy** (`/docs/autonomous-economy`) — How the three.ws on-chain treasury funds itself and where every dollar flows: the funding-root and engine wallets, the topup/sweepback loop, the allowlist- and destination-locks that keep money inside platform-owned wallets, and the two leak scanners that audit every signer wallet on-chain every minute — plus how to verify there's no leak yourself.- **Robinhood Chain** (`/markets/robinhood`) — The 24/7 tokenized-equity board for Robinhood Chain (4663): live Chainlink NAV vs DEX premium for every Stock Token, a memecoin screener across NOXA and The Odyssey launchpads, recent launches, and chain TVL — plus a real wallet-connect buy flow for its coins.- **Your creator portfolio** (`/profile`) — Your public three.ws portfolio: every avatar, agent, forged 3D model, world, coin, skill, and plugin you've made, in one place. Signed out, this redirects to sign-in; every user's own page also lives at /u/:username.+- **/feed and /community are now real, live pages** — /feed used to only show activity from people you follow — it now defaults to a live, platform-wide feed of every new avatar, agent, forged 3D model, saved world, coin launch, and follow, with a toggle to switch to just the people you follow. Scroll for more and it loads the next page automatically; a "New activity" pill appears when something fresh lands so the list never jumps under you mid-read. /community, previously a static grid of links, now leads with that same live activity feed alongside the existing links to X, GitHub, docs, and tutorials. (`/feed`) `[feature]`- **Agent discovery fixed: six paid endpoints were invisible to x402 scanners** — The machine-readable catalog at /openapi.json — what AI agents and x402 scanners like x402scan and AgentCash read to find and pay for three.ws APIs — had six paid endpoints (agent bouncer, verifiable vanity keys, crypto intel, cosmetic purchase, animation download, club cover) accidentally buried inside another entry, making them undiscoverable. All 61 payable routes now list correctly and the document passes the AgentCash discovery validator. The Permit2 gasless-payment demo is now only advertised when its settlement lane is actually live, so agents are never quoted a payment path that can't settle. (`/openapi.json`) `[fix, improvement]`- **Agent profiles, redesigned** — Agent profile pages got a ground-up redesign. Instead of one endless column of cards, everything is now organized into clear sections — Overview, Capabilities, Economy, Activity, Trust & Identity, Reviews, and Developers — with a sticky navigation bar that follows you as you scroll and hides sections that have nothing to show. The hero is a compact identity band with the live 3D avatar beside the agent's name, description, and actions, and secondary view modes now live in a tidy menu instead of a wall of buttons. Pages are roughly 40% shorter and much easier to scan. Prefer the old look? Every profile keeps a “Classic layout” link that serves the previous design unchanged. The companion panels (live presence, stages, work-for-hire, alpha co-pilot) now sit in a compact strip beside the profile instead of stacking above it — on mobile the agent's name and avatar are the first thing you see — and the live watch view (screen, avatar cam, action log) has a proper home in the Activity section. Signed-out visitors get a clear “sign in to see the action log” state instead of an endless loading spinner, and stats with nothing to report simply don't render. (`/agents`) `[improvement, feature]`- **AI features can no longer go down when one provider does** — Every AI-powered feature on three.ws (fact checks, agent chat, persona extraction, scene composing) routes through one shared brain that tries free providers first and falls back automatically. That chain just got much deeper: Groq now has a second lane with its own separate quota, OpenRouter gets a zero-credit free lane so an empty account no longer kills it, optional Cerebras and Google AI Studio lanes activate the moment a key is added, and — the anchor — Gemini on the platform's own Google Cloud now backs the whole chain with no third-party quota to exhaust. Previously a rare bad hour where every free tier was exhausted at once could surface an error; now the request rides through. The fact-checker was also corrected to stop favoring a paid key ahead of the free lanes. (`/changelog`) `[improvement, fix, infra]`@@ -20,6 +21,7 @@ Public history for [three.ws](https://three.ws), newest first. New pages come fr- **New driving jobs in /play — Cross-Town Delivery and East-West Express** — Two real driving missions landed on the /play jobs board. Grab a car parked at any of the four avenue depots, run the rush order to the depot on the other side of town, and get paid — the delivery only counts if you actually drove it, not walked it. Pairs with the world's existing drivable vehicles and cash economy for a real 'drive around, do jobs, spend the cash' loop. (`/play`) `[feature]`- **News stories now open the full article, with live coin charts** — Open a news story and you now get the whole thing. Many crypto publishers (The Defiant, CoinDesk, The Block and others) block automated fetches, so the reader used to fall back to a single teaser sentence — the page looked empty. It now recovers the full article text through a reader service when a publisher blocks the direct fetch, so the complete story renders instead of a stub. When a story mentions a coin, the reader shows a live price card for it — current price, 24h and 7d moves, a 7-day sparkline chart, and market cap — that links straight to the coin's full profile. Every fully-read story is also saved to a durable crypto knowledge base with its summary, key points, sentiment, tickers, and the companies and projects it's about — the memory our 3D AI agents draw on to answer questions with real, recent, sourced context. (`/markets/news`) `[feature, improvement]`- **News story links no longer go dead** — Every article on the news feed gets a permanent link, but stories published near a month boundary could slip through the hourly archiver and their links would eventually 404. The archiver now files each story under its real publication month (and no longer caps how many articles it sweeps per run), story pages look in neighboring months and redirect to the right address when a link's month is off by one, and a link that truly can't be found now offers a one-click archive search for that story's title instead of a dead end. (`/markets/news`) `[fix, improvement]`+- **Notification bell now covers remixes, royalties, DMs, and launch graduations** — The nav bell already tracked sales and purchases; it now also fires for real events that used to be invisible unless you happened to be watching: someone remixing one of your published 3D models (with the royalty payout amount if one settled on-chain), a friend DMing you while you're away, and a coin you launched hitting its funding target and graduating off the bonding curve. Dashboard → Settings has a new Notification preferences panel wired to the real per-category preference store, so you can mute any category (sales, purchases, social, IRL, market alerts, account) per channel — in-app, push, email, or Telegram — independently; in-app never turns off, so nothing is silently lost. A gear icon in the bell dropdown jumps straight there. (`/dashboard/settings`) `[feature]`- **Oversized x402 payment headers fixed** — Three paid endpoints (vanity, pump launch, agent reputation) mirrored their entire payment challenge — schemas, signed offers and all — into a single HTTP header that grew past 16 KB, the point where proxies and many clients drop or fail to parse the response. The header mirror is now capped at 8 KB: it slims down or steps aside when the challenge is large, while the response body always carries the complete challenge. Payment tooling that reads only headers still gets everything it needs to pay. `[fix]`- **Paid downloads can never ship before the payment settles** — Every paid endpoint on three.ws follows a 'deliver, then settle' order: the handler produces its result, the wrapper charges the buyer on-chain, and only then sends the response. That works for endpoints that hand back a value, but a streaming endpoint — one that writes its own file or feed directly to the connection, the natural shape for a binary download — could deliver the good before the settlement step ran, handing it over for free. No live endpoint did this, but it was a latent trap for the next one built. The payment wrapper now refuses to complete such a response silently: a streaming route must opt in explicitly, and when it does, the wrapper settles the payment first and only then lets the download start. Any endpoint that tried to send its body early is now caught and flagged instead of leaking the good. `[security]`- **Paid endpoints are fully discoverable by payment crawlers again** — Agent-payment directories like AgentCash and x402scan discover a paid API by reading its 402 'payment required' challenge and checking that each endpoint declares what it takes in and what it returns. three.ws sends that challenge two ways — a complete JSON body and a compact copy in a response header — and crawlers read the header. To stay under strict header-size limits, the header copy had been dropping its entire discovery block on richer endpoints, so those endpoints looked schema-less to crawlers even though the full body was correct. The header now keeps the discovery block, shrinking only the parts a crawler doesn't need (and falling back to a compact placeholder schema for the largest endpoints) so every paid route advertises its input and output shape while the header stays small. All 21 paid endpoints now pass AgentCash's discovery validator cleanly. (`/openapi.json`) `[improvement, infra]`@@ -994,7 +996,7 @@ Public history for [three.ws](https://three.ws), newest first. New pages come fr- **Arm your agent — automate Oracle conviction** (`/oracle/arm`) — Configure your 3D agent to trade Oracle conviction automatically: set the minimum score, position size, daily and open-position caps, narrative filters and Telegram alerts, then arm it in simulate or live mode. Every action is graded against the outcome.- **Credits** (`/credits`) — Top up with SOL or $THREE and spend credits on 3D generation, agents, and compute. Hold $THREE for up to 30% off every spend.- **Docs · Walk Avatar** (`/docs/walk`) — Developer and user documentation for the three.ws walking-avatar system: the /walk page, iframe embeds, the JavaScript SDK, the postMessage event contract, companion mode, analytics, and the Chrome extension.-- **Feed** (`/feed`) — Recent activity from the people and agents you follow on three.ws.+- **Feed** (`/feed`) — Live avatars, agents, 3D models, worlds, and launches across three.ws — filter to everyone or just the people you follow.- **Hero Stage** (`/hero-demo`) — A cinematic 3D hero stage for three.ws agents — a lit avatar centered in deep space over concentric glowing rings, a drifting starfield, and soft bloom, with pointer parallax and a live avatar switcher. Motion-safe.- **Make Dad a 3D Avatar** (`/dad`) — Turn one photo of your dad into a recognizable, rigged, animated 3D avatar — it idles, walks, and waves — then share a permalink.- **Studio — Object + Avatar from text** (`/forge-studio`) — One canvas for both text-to-3D pipelines: forge a textured object (GLB) in the Object tab, or describe a character and get a rigged avatar in the Avatar tab.@@ -1793,7 +1795,7 @@ Public history for [three.ws](https://three.ws), newest first. New pages come fr- **Dashboard** (`/dashboard`) — Your account dashboard: agents, avatars, payments, keys, MCP servers, monetization, billing.- **Dashboard · Account** (`/dashboard/account`) — Manage connected wallets, SNS, delegation, and action log.- **Dashboard · Analytics** (`/dashboard/analytics`) — API call volume, x402 spend, and per-agent usage breakdowns.-- **Dashboard · Settings** (`/dashboard/settings`) — Avatar storage modes (R2 vs IPFS), sessions, notifications, and preferences.+- **Dashboard · Settings** (`/dashboard/settings`) — Avatar storage modes (R2 vs IPFS), sessions, your notification inbox, per-category notification channel preferences (in-app/push/email/Telegram), and dashboard preferences.- **Full Animation & Emotion Control — Plus Pump.fun Live Feed** (`/blog/animation-emotion-control`) — three.ws now ships full animation and emotion control for 3D agents, with live Pump.fun feed integration. Your agents react to any API or data feed in real time.- **GMGN Smart Money** (`/gmgn`) — Live smart-money signals narrated by a 3D AI agent. Tracks which wallets are loading on Solana, Ethereum, Base, and BNB Chain in real time.- **Import an avatar URL** (`/import/rpm`) — Import any GLB or glTF avatar into three.ws and give it an agent brain.@@ -1910,7 +1912,7 @@ Public history for [three.ws](https://three.ws), newest first. New pages come fr## 2026-05-04-- **Community** (`/community`) — Featured creators, builds, and conversations from the three.ws community.+- **Community** (`/community`) — Live platform activity plus where to follow, contribute, and connect with three.ws creators.- **How to Embed 3D On-Chain Agents on Your Site** (`/blog/how-to-embed-3d-onchain-agents`) — A complete walkthrough for embedding a three.ws 3D on-chain agent on any website using the <agent-3d> web component — from setup to CORS configuration and page integration.- **Pump Dashboard** (`/pump-dashboard`) — Pump.fun trading desk: watchlists, scanner, quotes, portfolio, and live charts.- **Pump Live** (`/pump-live`) — Real-time feed of every pump.fun launch as it happens, with a 3D agent that reacts live.diff --git a/api/_lib/diorama-store.js b/api/_lib/diorama-store.jsindex 0ecb4389f..e079a5a6e 100644--- a/api/_lib/diorama-store.js+++ b/api/_lib/diorama-store.js@@ -179,8 +179,10 @@ export async function bumpViews(id) {/*** List dioramas for the public gallery — index columns only, no full plans.* scope: 'recent' (default) | 'featured'. Returns lightweight cards.+ * `before` (recent scope only) cursors by created_at for infinite scroll —+ * used by the platform-wide activity feed (api/users/me/feed.js, scope=all).*/-export async function listDioramas({ scope = 'recent', limit = 24 } = {}) {+export async function listDioramas({ scope = 'recent', limit = 24, before } = {}) {if (!(await ensureTable())) return [];const lim = Math.min(60, Math.max(1, Number(limit) || 24));try {@@ -189,18 +191,27 @@ export async function listDioramas({ scope = 'recent', limit = 24 } = {}) {? await sql`select d.id, d.title, d.prompt, d.mood, d.ground, d.views, d.featured, d.created_at,d.doc->'objects' as objects, d.doc->'palette' as palette, d.doc->'author' as author,- u.username as creator_username+ u.username as creator_username, u.display_name as creator_display_name, u.avatar_url as creator_avatar_urlfrom dioramas dleft join users u on u.id = d.user_id and u.deleted_at is nullwhere d.featured = trueorder by d.created_at desc limit ${lim}`- : await sql`- select d.id, d.title, d.prompt, d.mood, d.ground, d.views, d.featured, d.created_at,- d.doc->'objects' as objects, d.doc->'palette' as palette, d.doc->'author' as author,- u.username as creator_username- from dioramas d- left join users u on u.id = d.user_id and u.deleted_at is null- order by d.created_at desc limit ${lim}`;+ : before+ ? await sql`+ select d.id, d.title, d.prompt, d.mood, d.ground, d.views, d.featured, d.created_at,+ d.doc->'objects' as objects, d.doc->'palette' as palette, d.doc->'author' as author,+ u.username as creator_username, u.display_name as creator_display_name, u.avatar_url as creator_avatar_url+ from dioramas d+ left join users u on u.id = d.user_id and u.deleted_at is null+ where d.created_at < ${before}+ order by d.created_at desc limit ${lim}`+ : await sql`+ select d.id, d.title, d.prompt, d.mood, d.ground, d.views, d.featured, d.created_at,+ d.doc->'objects' as objects, d.doc->'palette' as palette, d.doc->'author' as author,+ u.username as creator_username, u.display_name as creator_display_name, u.avatar_url as creator_avatar_url+ from dioramas d+ left join users u on u.id = d.user_id and u.deleted_at is null+ order by d.created_at desc limit ${lim}`;return rows.map(toCard);} catch (err) {console.error('[diorama-store] listDioramas failed:', err?.message);@@ -223,6 +234,8 @@ function toCard(row) {palette: row.palette || null,author: row.author || null,creatorUsername: row.creator_username || null,+ creatorDisplayName: row.creator_display_name || null,+ creatorAvatarUrl: row.creator_avatar_url || null,thumbnailGlb: thumb,objectCount: objects.length,views: Number(row.views) || 0,diff --git a/api/_lib/forge-store.js b/api/_lib/forge-store.jsindex ea664fe6e..f7b926d08 100644--- a/api/_lib/forge-store.js+++ b/api/_lib/forge-store.js@@ -719,6 +719,59 @@ export async function listShowcase({ limit = 12 } = {}) {}}+// Newest durable creations across ALL clients, WITH creator attribution when+// the creator was signed in — powers the platform-wide activity feed+// (api/users/me/feed.js, scope=all) and /community. Same public-artifact bar+// as listShowcase (finished rows with a stored GLB, nothing rejected by its+// own maker), but left-joins users so a signed-in creator's forge shows up+// with a real profile link while an anonymous one (the majority) still+// appears with no identity attached rather than being excluded.+export async function listRecentCreations({ limit = 24, before } = {}) {+ if (!forgeStoreEnabled()) return [];+ const capped = Math.min(Math.max(Number(limit) || 24, 1), 60);+ try {+ const rows = before+ ? await sql`+ select fc.id, fc.prompt, fc.glb_url, fc.preview_image_url, fc.model_category,+ fc.parent_creation_id, fc.created_at,+ u.username, u.display_name, u.avatar_url+ from forge_creations fc+ left join users u on u.id = fc.user_id and u.deleted_at is null and u.username is not null+ where fc.status = 'done' and fc.glb_url is not null+ and (fc.outcome is null or fc.outcome != 'rejected')+ and fc.created_at < ${before}+ order by fc.created_at desc+ limit ${capped}`+ : await sql`+ select fc.id, fc.prompt, fc.glb_url, fc.preview_image_url, fc.model_category,+ fc.parent_creation_id, fc.created_at,+ u.username, u.display_name, u.avatar_url+ from forge_creations fc+ left join users u on u.id = fc.user_id and u.deleted_at is null and u.username is not null+ where fc.status = 'done' and fc.glb_url is not null+ and (fc.outcome is null or fc.outcome != 'rejected')+ order by fc.created_at desc+ limit ${capped}`;+ return rows.map((r) => ({+ id: r.id,+ type: 'model',+ prompt: r.prompt,+ glbUrl: r.glb_url,+ previewImageUrl: r.preview_image_url,+ category: r.model_category ?? 'other',+ isRemix: Boolean(r.parent_creation_id),+ createdAt: r.created_at,+ username: r.username || null,+ displayName: r.display_name || null,+ avatarUrl: r.avatar_url || null,+ }));+ } catch (err) {+ if (isDbUnavailableError(err)) console.warn('[forge-store] listRecentCreations skipped (db unavailable):', err?.message);+ else console.error('[forge-store] listRecentCreations failed:', err?.message);+ return [];+ }+}+// ── Remix economy ────────────────────────────────────────────────────────────//// A creator opts a finished creation into the remix bazaar (setRemixable) with a@@ -910,7 +963,7 @@ export async function getRemixSource({ creationId }) {if (!forgeStoreEnabled() || !creationId) return null;try {const rows = await sql`- select id, client_key, prompt, glb_url, preview_image_url,+ select id, client_key, user_id, prompt, glb_url, preview_image_url,remixable, remix_royalty_bps, creator_wallet_solana,parent_creation_id, lineage_index, aspect, created_atfrom forge_creations@@ -922,6 +975,7 @@ export async function getRemixSource({ creationId }) {return {id: r.id,clientKey: r.client_key,+ userId: r.user_id ?? null,prompt: r.prompt,glbUrl: r.glb_url,previewImageUrl: r.preview_image_url,diff --git a/api/users/me/feed.js b/api/users/me/feed.jsindex d5d6a29aa..f4bb6903c 100644--- a/api/users/me/feed.js+++ b/api/users/me/feed.js@@ -1,56 +1,171 @@-// GET /api/users/me/feed — the signed-in viewer's home feed: recent public-// activity from every account they follow, newest first. This is the social--// graph payoff — following someone means their new avatars, agents, and coin-// launches surface here.+// GET /api/users/me/feed — the platform activity feed: reverse-chronological+// creation events (avatars, agents, coin launches, forged 3D models, saved+// worlds) plus follow activity, merged from the same public records every+// profile page already exposes (no separate event log to keep in sync).//-// Activity is derived from the same public records the profile page already-// exposes (no separate event log to keep in sync): a new public avatar, a new-// public agent identity, and a coin launched through an agent. Items are merged,-// sorted by created_at desc, and capped.+// ?scope=following (default) — only accounts the signed-in viewer follows.+// Requires a session; anonymous callers get 401+// so the client can route to sign-in.+// ?scope=all — platform-wide recent activity. No session+// required — this is what /community and a+// first-time visitor's feed use.+// ?limit=… (1..50, default 30)+// ?before=<iso timestamp> — cursor for the next page (pass the last+// item's created_at back for infinite scroll)//-// ?limit=… (1..50, default 30)-//-// Requires a session — the feed is inherently personal. Anonymous callers get-// 401 so the client can route them to sign-in.+// Every item: { kind, id, created_at, actor{username,display_name,avatar_url},+// title, subtitle?, href, image?, external?, isRemix? } and, for+// kind:'follow' only, a `target` shaped like `actor`. `actor.username` is null+// for an anonymous creation (forge_creations/dioramas made while signed out) —+// the client renders those without a profile link rather than inventing one.import { sql } from '../../_lib/db.js';import { cors, json, method, wrap, error, rateLimited } from '../../_lib/http.js';import { getSessionUser } from '../../_lib/auth.js';import { limits, clientIp } from '../../_lib/rate-limit.js';import { publicUrl, thumbnailUrl } from '../../_lib/r2.js';+import { listRecentCreations } from '../../_lib/forge-store.js';+import { listDioramas } from '../../_lib/diorama-store.js';++const SITE = 'https://three.ws';++function actorFrom(r, { username = 'username', displayName = 'display_name', avatar = 'avatar_url' } = {}) {+ const u = r[username];+ if (!u) return { username: null, display_name: 'A three.ws creator', avatar_url: null };+ const a = r[avatar];+ return {+ username: u,+ display_name: r[displayName] || u,+ avatar_url: a ? (a.startsWith('http') ? a : publicUrl(a)) : null,+ };+}export default wrap(async (req, res) => {if (cors(req, res, { methods: 'GET,OPTIONS', credentials: true })) return;if (!method(req, res, ['GET'])) return;- const viewer = await getSessionUser(req).catch(() => null);- if (!viewer) return error(res, 401, 'unauthorized', 'sign in to view your feed');+ const url = new URL(req.url, 'http://x');+ const scope = url.searchParams.get('scope') === 'all' ? 'all' : 'following';+ const limit = Math.min(50, Math.max(1, parseInt(url.searchParams.get('limit'), 10) || 30));+ const before = (url.searchParams.get('before') || '').trim() || undefined;+ const perKind = limit;+ const followPerKind = Math.max(3, Math.ceil(limit / 4));const rl = await limits.authedReadIp(clientIp(req));if (!rl.success) return rateLimited(res, rl);- const limit = Math.min(50, Math.max(1, parseInt(req.query.limit, 10) || 30));- const perKind = limit; // pull `limit` of each kind, then merge + trim to `limit`+ const viewer = await getSessionUser(req).catch(() => null);+ if (scope === 'following' && !viewer) {+ return error(res, 401, 'unauthorized', 'sign in to view your feed');+ }++ if (scope === 'following') {+ const [{ following_count }] = await sql`+ select count(*)::int as following_count from user_follows where follower_id = ${viewer.id}+ `.catch(() => [{ following_count: 0 }]);++ if (following_count === 0) {+ return json(res, 200, { items: [], following_count: 0, scope, next: null });+ }++ const [avatarRows, agentRows, coinRows, modelRows, worldRows, followRows] = await Promise.all([+ sql`+ select a.id, a.name, a.thumbnail_key, a.created_at,+ u.username, u.display_name, u.avatar_url+ from avatars a+ join user_follows f on f.following_id = a.owner_id and f.follower_id = ${viewer.id}+ join users u on u.id = a.owner_id and u.deleted_at is null and u.username is not null+ where a.visibility = 'public' and a.deleted_at is null+ ${before ? sql`and a.created_at < ${before}` : sql``}+ order by a.created_at desc+ limit ${perKind}+ `,+ sql`+ select a.id, a.name, a.description, a.profile_image_url, a.avatar_url, a.created_at,+ u.username, u.display_name, u.avatar_url as actor_avatar+ from agent_identities a+ join user_follows f on f.following_id = a.user_id and f.follower_id = ${viewer.id}+ join users u on u.id = a.user_id and u.deleted_at is null and u.username is not null+ where a.is_public = true and a.deleted_at is null+ ${before ? sql`and a.created_at < ${before}` : sql``}+ order by a.created_at desc+ limit ${perKind}+ `,+ sql`+ select a.id as agent_id, a.name as agent_name, a.profile_image_url, a.avatar_url,+ a.meta->'token' as token, a.created_at,+ u.username, u.display_name, u.avatar_url as actor_avatar+ from agent_identities a+ join user_follows f on f.following_id = a.user_id and f.follower_id = ${viewer.id}+ join users u on u.id = a.user_id and u.deleted_at is null and u.username is not null+ where a.is_public = true and a.deleted_at is null+ and a.meta->'token'->>'mint' is not null+ ${before ? sql`and a.created_at < ${before}` : sql``}+ order by coalesce(a.meta->'token'->>'launched_at', a.created_at::text) desc+ limit ${perKind}+ `,+ sql`+ select fc.id, fc.prompt, fc.glb_url, fc.preview_image_url, fc.model_category,+ fc.parent_creation_id, fc.created_at,+ u.username, u.display_name, u.avatar_url+ from forge_creations fc+ join user_follows f on f.following_id = fc.user_id and f.follower_id = ${viewer.id}+ join users u on u.id = fc.user_id and u.deleted_at is null and u.username is not null+ where fc.status = 'done' and fc.glb_url is not null+ and (fc.outcome is null or fc.outcome != 'rejected')+ ${before ? sql`and fc.created_at < ${before}` : sql``}+ order by fc.created_at desc+ limit ${perKind}+ `,+ sql`+ select d.id, d.title, d.mood, d.created_at,+ d.doc->'objects' as objects,+ u.username, u.display_name, u.avatar_url+ from dioramas d+ join user_follows f on f.following_id = d.user_id and f.follower_id = ${viewer.id}+ join users u on u.id = d.user_id and u.deleted_at is null and u.username is not null+ where d.user_id is not null+ ${before ? sql`and d.created_at < ${before}` : sql``}+ order by d.created_at desc+ limit ${perKind}+ `,+ sql`+ select f.created_at,+ uf.username as follower_username, uf.display_name as follower_display, uf.avatar_url as follower_avatar,+ ut.username as target_username, ut.display_name as target_display, ut.avatar_url as target_avatar+ from user_follows f+ join user_follows vf on vf.following_id = f.follower_id and vf.follower_id = ${viewer.id}+ join users uf on uf.id = f.follower_id and uf.deleted_at is null and uf.username is not null+ join users ut on ut.id = f.following_id and ut.deleted_at is null and ut.username is not null+ where f.follower_id != ${viewer.id}+ ${before ? sql`and f.created_at < ${before}` : sql``}+ order by f.created_at desc+ limit ${followPerKind}+ `.catch(() => []),+ ]);- // Follow graph lives in user_follows. A deploy that lands before the- // user_follows migration must degrade to an empty feed rather than 500 every- // home feed (migrate-then-deploy; mirrors api/users/[username].js).- const [{ following_count }] = await sql`- select count(*)::int as following_count from user_follows where follower_id = ${viewer.id}- `.catch(() => [{ following_count: 0 }]);+ const items = mergeItems({ avatarRows, agentRows, coinRows, modelRows, worldRows, followRows });+ items.sort((a, b) => new Date(b.created_at) - new Date(a.created_at));+ const page = items.slice(0, limit);- if (following_count === 0) {- return json(res, 200, { items: [], following_count: 0 });+ res.setHeader('Cache-Control', 'private, no-store');+ return json(res, 200, {+ items: page,+ following_count,+ scope,+ next: page.length === limit ? page[page.length - 1].created_at : null,+ });}- const [avatarRows, agentRows, coinRows] = await Promise.all([+ // scope === 'all': platform-wide recent activity, no follow graph, no auth.+ const [avatarRows, agentRows, coinRows, modelRows, worldRows, followRows] = await Promise.all([sql`select a.id, a.name, a.thumbnail_key, a.created_at,u.username, u.display_name, u.avatar_urlfrom avatars a- join user_follows f on f.following_id = a.owner_id and f.follower_id = ${viewer.id}join users u on u.id = a.owner_id and u.deleted_at is null and u.username is not nullwhere a.visibility = 'public' and a.deleted_at is null+ ${before ? sql`and a.created_at < ${before}` : sql``}order by a.created_at desclimit ${perKind}`,@@ -58,9 +173,9 @@ export default wrap(async (req, res) => {select a.id, a.name, a.description, a.profile_image_url, a.avatar_url, a.created_at,u.username, u.display_name, u.avatar_url as actor_avatarfrom agent_identities a- join user_follows f on f.following_id = a.user_id and f.follower_id = ${viewer.id}join users u on u.id = a.user_id and u.deleted_at is null and u.username is not nullwhere a.is_public = true and a.deleted_at is null+ ${before ? sql`and a.created_at < ${before}` : sql``}order by a.created_at desclimit ${perKind}`,@@ -69,23 +184,67 @@ export default wrap(async (req, res) => {a.meta->'token' as token, a.created_at,u.username, u.display_name, u.avatar_url as actor_avatarfrom agent_identities a- join user_follows f on f.following_id = a.user_id and f.follower_id = ${viewer.id}join users u on u.id = a.user_id and u.deleted_at is null and u.username is not nullwhere a.is_public = true and a.deleted_at is nulland a.meta->'token'->>'mint' is not null+ ${before ? sql`and a.created_at < ${before}` : sql``}order by coalesce(a.meta->'token'->>'launched_at', a.created_at::text) desclimit ${perKind}`,+ listRecentCreations({ limit: perKind, before }),+ listDioramas({ scope: 'recent', limit: perKind, before }),+ sql`+ select f.created_at,+ uf.username as follower_username, uf.display_name as follower_display, uf.avatar_url as follower_avatar,+ ut.username as target_username, ut.display_name as target_display, ut.avatar_url as target_avatar+ from user_follows f+ join users uf on uf.id = f.follower_id and uf.deleted_at is null and uf.username is not null+ join users ut on ut.id = f.following_id and ut.deleted_at is null and ut.username is not null+ ${before ? sql`and f.created_at < ${before}` : sql``}+ order by f.created_at desc+ limit ${followPerKind}+ `.catch(() => []),]);- const actor = (r, avatarKey = 'avatar_url') => ({- username: r.username,- display_name: r.display_name || r.username,- avatar_url: r[avatarKey]- ? (r[avatarKey].startsWith('http') ? r[avatarKey] : publicUrl(r[avatarKey]))- : null,+ const items = mergeItems({+ avatarRows,+ agentRows,+ coinRows,+ modelRows: modelRows.map((m) => ({+ id: m.id,+ created_at: m.createdAt,+ glb_url: m.glbUrl,+ preview_image_url: m.previewImageUrl,+ model_category: m.category,+ isRemix: m.isRemix,+ username: m.username,+ display_name: m.displayName,+ avatar_url: m.avatarUrl,+ })),+ worldRows: worldRows.map((w) => ({+ id: w.id,+ created_at: w.createdAt,+ title: w.title,+ mood: w.mood,+ objects: w.thumbnailGlb ? [{ glbUrl: w.thumbnailGlb }] : [],+ username: w.creatorUsername,+ display_name: w.creatorDisplayName || w.creatorUsername,+ avatar_url: w.creatorAvatarUrl,+ })),+ followRows,+ });+ items.sort((a, b) => new Date(b.created_at) - new Date(a.created_at));+ const page = items.slice(0, limit);++ res.setHeader('Cache-Control', 'public, s-maxage=15, stale-while-revalidate=60');+ return json(res, 200, {+ items: page,+ scope,+ next: page.length === limit ? page[page.length - 1].created_at : null,});+});+function mergeItems({ avatarRows, agentRows, coinRows, modelRows, worldRows, followRows }) {const items = [];for (const r of avatarRows) {@@ -93,7 +252,7 @@ export default wrap(async (req, res) => {kind: 'avatar',id: r.id,created_at: r.created_at,- actor: actor(r),+ actor: actorFrom(r),title: r.name,href: `/avatars/${r.id}`,image: thumbnailUrl(r.thumbnail_key),@@ -105,7 +264,7 @@ export default wrap(async (req, res) => {kind: 'agent',id: r.id,created_at: r.created_at,- actor: actor(r, 'actor_avatar'),+ actor: actorFrom(r, { avatar: 'actor_avatar' }),title: r.name,subtitle: r.description || null,href: `/agent/${r.id}`,@@ -120,7 +279,7 @@ export default wrap(async (req, res) => {kind: 'coin',id: t.mint,created_at: t.launched_at || r.created_at,- actor: actor(r, 'actor_avatar'),+ actor: actorFrom(r, { avatar: 'actor_avatar' }),title: t.name || r.agent_name,subtitle: t.symbol ? `$${String(t.symbol).replace(/^\$/, '')}` : null,href: t.pumpfun_url || t.explorer_url || `/agent/${r.agent_id}`,@@ -129,8 +288,46 @@ export default wrap(async (req, res) => {});}- items.sort((a, b) => new Date(b.created_at) - new Date(a.created_at));+ for (const r of modelRows) {+ items.push({+ kind: 'model',+ id: r.id,+ created_at: r.created_at,+ actor: actorFrom(r),+ title: r.prompt,+ subtitle: r.model_category && r.model_category !== 'other' ? r.model_category : null,+ href: `${SITE}/viewer?src=${encodeURIComponent(r.glb_url)}`,+ image: r.preview_image_url || null,+ isRemix: Boolean(r.parent_creation_id ?? r.isRemix),+ });+ }- res.setHeader('Cache-Control', 'private, no-store');- return json(res, 200, { items: items.slice(0, limit), following_count });-});+ for (const r of worldRows) {+ const objects = Array.isArray(r.objects) ? r.objects : [];+ items.push({+ kind: 'world',+ id: r.id,+ created_at: r.created_at,+ actor: actorFrom(r),+ title: r.title,+ subtitle: r.mood || null,+ href: `${SITE}/diorama?id=${r.id}`,+ image: objects.find((o) => o && o.glbUrl)?.glbUrl || null,+ });+ }++ for (const r of followRows) {+ items.push({+ kind: 'follow',+ id: `${r.follower_username}-${r.target_username}-${new Date(r.created_at).getTime()}`,+ created_at: r.created_at,+ actor: actorFrom(r, { username: 'follower_username', displayName: 'follower_display', avatar: 'follower_avatar' }),+ target: actorFrom(r, { username: 'target_username', displayName: 'target_display', avatar: 'target_avatar' }),+ title: r.target_display || r.target_username,+ href: `/u/${r.target_username}`,+ image: r.target_avatar ? (r.target_avatar.startsWith('http') ? r.target_avatar : publicUrl(r.target_avatar)) : null,+ });+ }++ return items;+}diff --git a/data/changelog.json b/data/changelog.jsonindex 2620c3722..184fef702 100644--- a/data/changelog.json+++ b/data/changelog.json@@ -1,6 +1,24 @@{"$comment": "Curated changelog entries for three.ws — the editorial layer of the public changelog. New PAGE launches are tracked automatically via the `added` field in data/pages.json; this file is for everything else holders care about: improvements, fixes, SDK releases, trading/payments capabilities, security work. scripts/build-page-index.mjs merges both sources into CHANGELOG.md, public/changelog.json, and public/changelog.xml. Newest first. Allowed tags: feature, improvement, fix, sdk, infra, docs, security. `link` is optional and must be a live three.ws path.","entries": [+ {+ "date": "2026-07-12",+ "title": "/feed and /community are now real, live pages",+ "summary": "/feed used to only show activity from people you follow — it now defaults to a live, platform-wide feed of every new avatar, agent, forged 3D model, saved world, coin launch, and follow, with a toggle to switch to just the people you follow. Scroll for more and it loads the next page automatically; a \"New activity\" pill appears when something fresh lands so the list never jumps under you mid-read. /community, previously a static grid of links, now leads with that same live activity feed alongside the existing links to X, GitHub, docs, and tutorials.",+ "tags": [+ "feature"+ ],+ "link": "/feed"+ },+ {+ "date": "2026-07-12",+ "title": "Notification bell now covers remixes, royalties, DMs, and launch graduations",+ "summary": "The nav bell already tracked sales and purchases; it now also fires for real events that used to be invisible unless you happened to be watching: someone remixing one of your published 3D models (with the royalty payout amount if one settled on-chain), a friend DMing you while you're away, and a coin you launched hitting its funding target and graduating off the bonding curve. Dashboard → Settings has a new Notification preferences panel wired to the real per-category preference store, so you can mute any category (sales, purchases, social, IRL, market alerts, account) per channel — in-app, push, email, or Telegram — independently; in-app never turns off, so nothing is silently lost. A gear icon in the bell dropdown jumps straight there.",+ "tags": [+ "feature"+ ],+ "link": "/dashboard/settings"+ },{"date": "2026-07-12","title": "Follow creators site-wide and see who's following you",diff --git a/data/pages.json b/data/pages.jsonindex acc710038..e1ab8cfa2 100644--- a/data/pages.json+++ b/data/pages.json@@ -174,9 +174,9 @@{"path": "/community","title": "Community",- "description": "Featured creators, builds, and conversations from the three.ws community.",+ "description": "Live platform activity plus where to follow, contribute, and connect with three.ws creators.","priority": 0.6,- "changefreq": "weekly",+ "changefreq": "daily","added": "2026-05-04"},{@@ -230,7 +230,7 @@{"path": "/feed","title": "Feed",- "description": "Recent activity from the people and agents you follow on three.ws.",+ "description": "Live avatars, agents, 3D models, worlds, and launches across three.ws — filter to everyone or just the people you follow.","priority": 0.6,"changefreq": "daily","added": "2026-06-21"@@ -1772,7 +1772,7 @@{"path": "/dashboard/settings","title": "Dashboard · Settings",- "description": "Avatar storage modes (R2 vs IPFS), sessions, notifications, and preferences.",+ "description": "Avatar storage modes (R2 vs IPFS), sessions, your notification inbox, per-category notification channel preferences (in-app/push/email/Telegram), and dashboard preferences.","auth": "required","indexable": false,"added": "2026-05-25"diff --git a/pages/community.html b/pages/community.htmlindex d1a8fdab9..a2f447679 100644--- a/pages/community.html+++ b/pages/community.html@@ -103,6 +103,81 @@.section li { color: var(--muted); font-size: 14.5px; margin-bottom: 8px; line-height: 1.5; }.section li strong { color: var(--text); }a { color: var(--accent); }++ .activity-head {+ display: flex;+ align-items: baseline;+ justify-content: space-between;+ gap: 12px;+ margin-bottom: 16px;+ }+ .activity-head h2 { margin: 0; }+ .activity-head a {+ font-size: 13.5px;+ font-weight: 600;+ text-decoration: none;+ white-space: nowrap;+ }+ .activity-head a:hover { text-decoration: underline; }++ .activity-list {+ border: 1px solid var(--border);+ border-radius: 16px;+ background: var(--panel);+ overflow: hidden;+ }+ .activity-row {+ display: flex;+ align-items: center;+ gap: 12px;+ padding: 14px 18px;+ border-bottom: 1px solid var(--border);+ text-decoration: none;+ color: inherit;+ transition: background 0.15s;+ animation: activity-in 0.35s ease both;+ }+ @keyframes activity-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }+ .activity-row:last-child { border-bottom: none; }+ .activity-row:hover { background: #1a1a1a; }+ .activity-avatar {+ width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;+ background: #1e1e1e; border: 1px solid var(--border);+ object-fit: cover; display: flex; align-items: center; justify-content: center;+ color: var(--muted); font-size: 0.95rem; overflow: hidden;+ }+ .activity-avatar img { width: 100%; height: 100%; object-fit: cover; }+ .activity-thumb {+ width: 40px; height: 40px; border-radius: 8px; flex-shrink: 0;+ background: #1e1e1e; object-fit: cover; overflow: hidden;+ display: flex; align-items: center; justify-content: center; color: var(--muted);+ }+ .activity-thumb img { width: 100%; height: 100%; object-fit: cover; }+ .activity-text { flex: 1; min-width: 0; }+ .activity-line {+ font-size: 14px;+ color: var(--text);+ white-space: nowrap;+ overflow: hidden;+ text-overflow: ellipsis;+ }+ .activity-line strong { font-weight: 600; }+ .activity-verb { color: var(--muted); font-weight: 400; }+ .activity-time { font-size: 12px; color: var(--muted); margin-top: 2px; }+ .activity-empty, .activity-error {+ padding: 32px 18px;+ text-align: center;+ color: var(--muted);+ font-size: 14px;+ }+ .activity-skeleton {+ height: 62px;+ border-bottom: 1px solid var(--border);+ background: linear-gradient(90deg, #161616 25%, #1c1c1c 37%, #161616 63%);+ background-size: 400% 100%;+ animation: activity-shimmer 1.4s ease infinite;+ }+ @keyframes activity-shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }</style><meta name="twitter:card" content="summary_large_image">@@ -125,6 +200,18 @@<h1>Build with us.</h1><p class="sub">three.ws is built in the open. Follow along, share what you're building, and help shape the 3D agent layer of the internet.</p>+ <div class="section">+ <div class="activity-head">+ <h2>Live activity</h2>+ <a href="/feed">Open the full feed →</a>+ </div>+ <div class="activity-list" id="community-activity">+ <div class="activity-skeleton"></div>+ <div class="activity-skeleton"></div>+ <div class="activity-skeleton"></div>+ </div>+ </div>+<div class="grid"><div class="card"><span class="icon">𝕏</span>@@ -172,5 +259,92 @@<div id="footer-container"></div><script src="/footer.js"></script><script src="/brand.js" defer></script>++ <script type="module">+ const esc = (s) =>+ String(s ?? '').replace(/[&<>"']/g, (c) => ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''' })[c]);+ const attr = (s) => esc(s).replace(/"/g, '"');+ const el = document.getElementById('community-activity');++ const VERB = {+ avatar: 'created a new avatar',+ agent: 'launched an agent',+ coin: 'launched a coin',+ model: 'forged a 3D model',+ world: 'built a world',+ };+ const GLYPH = { avatar: '◎', agent: '🤖', coin: '◉', model: '✦', world: '🌐', follow: '⇢' };++ function relTime(iso) {+ const then = new Date(iso).getTime();+ if (!Number.isFinite(then)) return '';+ const diff = Math.max(0, Date.now() - then);+ const m = Math.floor(diff / 60000);+ if (m < 1) return 'just now';+ if (m < 60) return `${m}m ago`;+ const h = Math.floor(m / 60);+ if (h < 24) return `${h}h ago`;+ const d = Math.floor(h / 24);+ return d < 30 ? `${d}d ago` : new Date(iso).toLocaleDateString(undefined, { month: 'short', day: 'numeric' });+ }++ function rowEl(it) {+ const a = it.actor || {};+ const name = esc(a.display_name || 'A three.ws creator');+ const nameHtml = a.username ? `<a href="/u/${attr(a.username)}" style="color:inherit;text-decoration:none">${name}</a>` : name;+ const avatarHtml = a.avatar_url+ ? `<img src="${attr(a.avatar_url)}" alt="" loading="lazy" referrerpolicy="no-referrer">`+ : GLYPH[it.kind] || '◎';++ if (it.kind === 'follow') {+ const t = it.target || {};+ return `+ <a class="activity-row" href="${attr(it.href)}">+ <span class="activity-avatar">${avatarHtml}</span>+ <div class="activity-text">+ <div class="activity-line"><strong>${nameHtml}</strong> <span class="activity-verb">followed</span> <strong>${esc(t.display_name)}</strong></div>+ <div class="activity-time">${esc(relTime(it.created_at))}</div>+ </div>+ </a>+ `;+ }++ const verb = it.kind === 'model' && it.isRemix ? 'remixed a 3D model' : VERB[it.kind] || 'shared something';+ const thumbHtml = it.image+ ? `<img src="${attr(it.image)}" alt="" loading="lazy" referrerpolicy="no-referrer">`+ : (GLYPH[it.kind] || '◎');+ return `+ <a class="activity-row" href="${attr(it.href)}"${it.external ? ' target="_blank" rel="noopener"' : ''}>+ <span class="activity-avatar">${avatarHtml}</span>+ <div class="activity-text">+ <div class="activity-line"><strong>${nameHtml}</strong> <span class="activity-verb">${esc(verb)}</span> — ${esc(it.title || 'Untitled')}</div>+ <div class="activity-time">${esc(relTime(it.created_at))}</div>+ </div>+ <span class="activity-thumb">${thumbHtml}</span>+ </a>+ `;+ }++ (async function load() {+ let res;+ try {+ res = await fetch('/api/users/me/feed?scope=all&limit=10');+ } catch {+ el.innerHTML = `<div class="activity-error">Could not load live activity right now.</div>`;+ return;+ }+ if (!res.ok) {+ el.innerHTML = `<div class="activity-error">Could not load live activity right now.</div>`;+ return;+ }+ const data = await res.json();+ const items = data.items || [];+ if (!items.length) {+ el.innerHTML = `<div class="activity-empty">Nothing has happened yet — be the first to <a href="/create">create something</a>.</div>`;+ return;+ }+ el.innerHTML = items.map(rowEl).join('');+ })();+ </script></body></html>diff --git a/pages/feed.html b/pages/feed.htmlindex 57cf52d2a..4fc997653 100644--- a/pages/feed.html+++ b/pages/feed.html@@ -3,9 +3,9 @@<head><script>/* three.ws theme boot — no-flash; runtime in /theme-switcher.js */(function(){try{var m=localStorage.getItem('twx_theme');var l=m==='auto'?(window.matchMedia&&window.matchMedia('(prefers-color-scheme: light)').matches):m==='light';document.documentElement.setAttribute('data-theme',l?'light':'dark');}catch(e){document.documentElement.setAttribute('data-theme','dark');}})();</script><meta charset="utf-8" />- <title>Your Feed — three.ws</title>+ <title>Feed — three.ws</title><meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=cover" />- <meta name="description" content="Recent activity from the people and agents you follow on three.ws." />+ <meta name="description" content="Live avatars, agents, 3D models, worlds, and launches across three.ws." /><meta name="theme-color" content="#000000" /><meta name="robots" content="noindex" /><link rel="icon" href="/favicon.ico" sizes="any" />@@ -208,6 +208,81 @@0% { background-position: 100% 0; }100% { background-position: 0 0; }}++ .feed-scope {+ display: flex;+ gap: 0.5rem;+ margin: 1.2rem 0 0.4rem;+ }+ .feed-scope button {+ font: inherit;+ font-size: 0.85rem;+ font-weight: 500;+ background: transparent;+ color: rgba(255, 255, 255, 0.5);+ border: 1px solid rgba(255, 255, 255, 0.12);+ border-radius: 999px;+ padding: 0.4rem 0.95rem;+ cursor: pointer;+ transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;+ }+ .feed-scope button:hover { color: rgba(255, 255, 255, 0.85); border-color: rgba(255, 255, 255, 0.3); }+ .feed-scope button:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }+ .feed-scope button[aria-pressed="true"] {+ background: #fff;+ color: #000;+ border-color: #fff;+ }++ .feed-newpill {+ display: none;+ width: 100%;+ text-align: center;+ background: #fff;+ color: #000;+ font-weight: 500;+ font-size: 0.85rem;+ border: none;+ border-radius: 999px;+ padding: 0.55rem 1rem;+ margin-bottom: 1rem;+ cursor: pointer;+ animation: feed-in 0.25s ease both;+ }+ .feed-newpill.visible { display: block; }+ .feed-newpill:hover { opacity: 0.9; }++ .feed-more {+ display: block;+ width: 100%;+ background: transparent;+ color: rgba(255, 255, 255, 0.6);+ border: 1px solid rgba(255, 255, 255, 0.12);+ border-radius: 10px;+ padding: 0.7rem;+ font: inherit;+ font-size: 0.85rem;+ cursor: pointer;+ margin-top: 0.6rem;+ transition: border-color 0.15s ease, color 0.15s ease;+ }+ .feed-more:hover { color: #fff; border-color: rgba(255, 255, 255, 0.3); }+ .feed-more:disabled { opacity: 0.5; cursor: default; }++ .feed-follow-line { display: flex; align-items: center; gap: 0.5rem; }+ .feed-follow-target {+ display: inline-flex;+ align-items: center;+ gap: 0.4rem;+ color: #fff;+ font-weight: 500;+ text-decoration: none;+ }+ .feed-follow-target:hover { text-decoration: underline; }+ .feed-follow-target img {+ width: 22px; height: 22px; border-radius: 50%; object-fit: cover;+ border: 1px solid rgba(255, 255, 255, 0.15);+ }</style><link rel="canonical" href="https://three.ws/feed">@@ -215,9 +290,9 @@<meta property="og:site_name" content="three.ws"><meta property="og:locale" content="en_US"><meta property="og:title" content="Feed · three.ws">- <meta property="og:description" content="Recent activity from the people and agents you follow on three.ws.">+ <meta property="og:description" content="Live avatars, agents, 3D models, worlds, and launches across three.ws."><meta property="og:url" content="https://three.ws/feed">- <meta property="og:image" content="https://three.ws/api/page-og?s=main&t=Feed&d=Recent+activity+from+the+people+and+agents+you+follow+on+three.ws.&p=%2Ffeed">+ <meta property="og:image" content="https://three.ws/api/page-og?s=main&t=Feed&d=Live+avatars%2C+agents%2C+3D+models%2C+worlds%2C+and+launches+across+three.ws.&p=%2Ffeed"><meta property="og:image:width" content="1200"><meta property="og:image:height" content="630"><meta property="og:image:type" content="image/png">@@ -225,9 +300,9 @@<meta name="twitter:card" content="summary_large_image"><meta name="twitter:site" content="@trythreews"><meta name="twitter:title" content="Feed · three.ws">- <meta name="twitter:description" content="Recent activity from the people and agents you follow on three.ws.">- <meta name="twitter:image" content="https://three.ws/api/page-og?s=main&t=Feed&d=Recent+activity+from+the+people+and+agents+you+follow+on+three.ws.&p=%2Ffeed">- <script type="application/ld+json">{"@context":"https://schema.org","@graph":[{"@type":"WebPage","name":"Feed","description":"Recent activity from the people and agents you follow on three.ws.","url":"https://three.ws/feed","isPartOf":{"@type":"WebSite","name":"three.ws","url":"https://three.ws"},"primaryImageOfPage":"https://three.ws/api/page-og?s=main&t=Feed&d=Recent+activity+from+the+people+and+agents+you+follow+on+three.ws.&p=%2Ffeed"}]}</script>+ <meta name="twitter:description" content="Live avatars, agents, 3D models, worlds, and launches across three.ws.">+ <meta name="twitter:image" content="https://three.ws/api/page-og?s=main&t=Feed&d=Live+avatars%2C+agents%2C+3D+models%2C+worlds%2C+and+launches+across+three.ws.&p=%2Ffeed">+ <script type="application/ld+json">{"@context":"https://schema.org","@graph":[{"@type":"WebPage","name":"Feed","description":"Live avatars, agents, 3D models, worlds, and launches across three.ws.","url":"https://three.ws/feed","isPartOf":{"@type":"WebSite","name":"three.ws","url":"https://three.ws"},"primaryImageOfPage":"https://three.ws/api/page-og?s=main&t=Feed&d=Live+avatars%2C+agents%2C+3D+models%2C+worlds%2C+and+launches+across+three.ws.&p=%2Ffeed"}]}</script></head><body><header><div id="nav-container"></div></header>@@ -236,18 +311,25 @@<main><div class="feed-root"><div class="feed-head">- <h1>Your Feed</h1>- <p>New avatars, agents, and launches from everyone you follow.</p>+ <h1>Feed</h1>+ <p>New avatars, agents, models, worlds, and launches across three.ws.</p><a class="feed-tip" href="/discover"><svg width="13" height="13" viewBox="0 0 16 16" aria-hidden="true"><path fill="currentColor" d="M8 1a7 7 0 1 0 0 14A7 7 0 0 0 8 1m.75 10.5h-1.5V7h1.5zm0-6h-1.5V4h1.5z"/></svg>Discover more people to follow</a></div>+ <div class="feed-scope" role="tablist" aria-label="Feed scope">+ <button type="button" id="scope-all" role="tab" aria-pressed="true">All activity</button>+ <button type="button" id="scope-following" role="tab" aria-pressed="false">Following</button>+ </div>+ <button type="button" class="feed-newpill" id="feed-newpill">New activity — click to view</button><div id="feed-list"><div class="feed-skeleton"></div><div class="feed-skeleton"></div><div class="feed-skeleton"></div></div>+ <button type="button" class="feed-more" id="feed-more" hidden>Load more</button>+ <div id="feed-sentinel" aria-hidden="true"></div></div></main>@@ -260,13 +342,28 @@String(s ?? '').replace(/[&<>"']/g, (c) => ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''' })[c]);const attr = (s) => esc(s).replace(/"/g, '"');const list = document.getElementById('feed-list');+ const moreBtn = document.getElementById('feed-more');+ const newPill = document.getElementById('feed-newpill');+ const sentinel = document.getElementById('feed-sentinel');+ const scopeAllBtn = document.getElementById('scope-all');+ const scopeFollowingBtn = document.getElementById('scope-following');const VERB = {avatar: 'created a new avatar',agent: 'launched an agent',coin: 'launched a coin',+ model: 'forged a 3D model',+ world: 'built a world',};- const GLYPH = { avatar: '◎', agent: '🤖', coin: '◉' };+ const GLYPH = { avatar: '◎', agent: '🤖', coin: '◉', model: '✦', world: '🌐', follow: '⇢' };+ const SCOPE_KEY = 'twx_feed_scope';++ let scope = localStorage.getItem(SCOPE_KEY) === 'following' ? 'following' : 'all';+ let cursor = null;+ let loading = false;+ let done = false;+ let renderedOnce = false;+ let pollTimer = null;function relTime(iso) {if (!iso) return '';@@ -283,26 +380,56 @@return new Date(iso).toLocaleDateString(undefined, { month: 'short', day: 'numeric' });}+ function actorLink(actor, extra = '') {+ if (!actor || !actor.username) return `<span class="actor" style="color:#fff;font-weight:500">${esc(actor?.display_name || 'A three.ws creator')}</span>`;+ return `<a class="actor" href="/u/${attr(actor.username)}"${extra}>${esc(actor.display_name)}</a>`;+ }+function avatarEl(actor) {const inner = actor.avatar_url? `<img src="${attr(actor.avatar_url)}" alt="${attr(actor.display_name)}" loading="lazy" referrerpolicy="no-referrer">`: '◎';- return `<a class="feed-avatar" href="/u/${attr(actor.username)}" aria-label="${attr(actor.display_name)}">${inner}</a>`;+ return actor.username+ ? `<a class="feed-avatar" href="/u/${attr(actor.username)}" aria-label="${attr(actor.display_name)}">${inner}</a>`+ : `<span class="feed-avatar" aria-hidden="true">${inner}</span>`;}function itemEl(it) {const a = it.actor || {};++ if (it.kind === 'follow') {+ const t = it.target || {};+ return `+ <article class="feed-item">+ ${avatarEl(a)}+ <div class="feed-body">+ <div class="feed-line feed-follow-line">+ ${actorLink(a)}+ <span class="feed-verb">followed</span>+ <a class="feed-follow-target" href="${attr(it.href)}">+ ${t.avatar_url ? `<img src="${attr(t.avatar_url)}" alt="" loading="lazy" referrerpolicy="no-referrer">` : ''}+ ${esc(t.display_name)}+ </a>+ <span class="feed-pill">follow</span>+ </div>+ <div class="feed-time">${esc(relTime(it.created_at))}</div>+ </div>+ </article>+ `;+ }+const cardThumb = it.image? `<img src="${attr(it.image)}" alt="" loading="lazy" referrerpolicy="no-referrer">`: GLYPH[it.kind] || '◎';const external = it.external ? ' target="_blank" rel="noopener"' : '';+ const verb = it.kind === 'model' && it.isRemix ? 'remixed a 3D model' : VERB[it.kind] || 'shared something';return `<article class="feed-item">${avatarEl(a)}<div class="feed-body"><div class="feed-line">- <a class="actor" href="/u/${attr(a.username)}">${esc(a.display_name)}</a>- <span class="feed-verb"> ${esc(VERB[it.kind] || 'shared something')}</span>+ ${actorLink(a)}+ <span class="feed-verb"> ${esc(verb)}</span><span class="feed-pill">${esc(it.kind)}</span></div><a class="feed-card" href="${attr(it.href)}"${external}>@@ -327,39 +454,61 @@${cta ? `<a class="feed-btn" href="${attr(cta.href)}">${esc(cta.label)}</a>` : ''}</div>`;+ moreBtn.hidden = true;+ }++ function updateScopeButtons() {+ scopeAllBtn.setAttribute('aria-pressed', String(scope === 'all'));+ scopeFollowingBtn.setAttribute('aria-pressed', String(scope === 'following'));}- (async function load() {+ async function fetchPage(before) {+ const params = new URLSearchParams({ scope, limit: '24' });+ if (before) params.set('before', before);+ return fetch(`/api/users/me/feed?${params}`, { credentials: 'include' });+ }++ async function loadInitial() {+ stopPoll();+ newPill.classList.remove('visible');+ cursor = null;+ done = false;+ renderedOnce = false;+ list.innerHTML = `<div class="feed-skeleton"></div><div class="feed-skeleton"></div><div class="feed-skeleton"></div>`;+ moreBtn.hidden = true;+let res;try {- res = await fetch('/api/users/me/feed?limit=40', { credentials: 'include' });+ res = await fetchPage();} catch {- renderState({ glyph: '⚠', title: 'Could not load your feed', body: 'Check your connection and try again.', cta: { href: '/feed', label: 'Retry' } });+ renderState({ glyph: '⚠', title: 'Could not load the feed', body: 'Check your connection and try again.', cta: { href: '/feed', label: 'Retry' } });return;}if (res.status === 401) {renderState({glyph: '◎',- title: 'Sign in to see your feed',- body: 'Follow creators and agents on three.ws to build a feed of their latest work.',+ title: 'Sign in to see who you follow',+ body: 'Follow creators and agents on three.ws to build a feed of their latest work — or switch to All activity above.',cta: { href: `/login?return=${encodeURIComponent('/feed')}`, label: 'Sign in' },});return;}if (!res.ok) {- renderState({ glyph: '⚠', title: 'Something went wrong', body: 'We could not load your feed right now.', cta: { href: '/feed', label: 'Retry' } });+ renderState({ glyph: '⚠', title: 'Something went wrong', body: 'We could not load the feed right now.', cta: { href: '/feed', label: 'Retry' } });return;}const data = await res.json();const items = data.items || [];+ cursor = data.next || null;+ done = !cursor;- if (data.following_count === 0) {+ if (scope === 'following' && data.following_count === 0) {renderState({glyph: '✦',title: "You're not following anyone yet",- body: 'Find creators and agents to follow — their new avatars, agents, and launches will show up here.',+ body: 'Find creators and agents to follow — their new avatars, agents, models, and launches will show up here.',cta: { href: '/discover', label: 'Discover creators' },});return;@@ -367,15 +516,107 @@if (!items.length) {renderState({glyph: '☾',- title: 'No recent activity',- body: 'The people you follow have not posted anything public lately. Check back soon.',- cta: { href: '/discover', label: 'Follow more people' },+ title: scope === 'following' ? 'No recent activity' : 'Nothing has happened yet',+ body: scope === 'following'+ ? 'The people you follow have not posted anything public lately. Check back soon.'+ : 'Be the first — forge a model, build a world, or launch an agent.',+ cta: { href: scope === 'following' ? '/discover' : '/create', label: scope === 'following' ? 'Follow more people' : 'Start creating' },});return;}list.innerHTML = items.map(itemEl).join('');- })();+ renderedOnce = true;+ topCreatedAt = items[0].created_at;+ moreBtn.hidden = done;+ startPoll();+ }++ async function loadMore() {+ if (loading || done || !renderedOnce) return;+ loading = true;+ moreBtn.disabled = true;+ moreBtn.textContent = 'Loading…';+ try {+ const res = await fetchPage(cursor);+ if (!res.ok) throw new Error('load more failed');+ const data = await res.json();+ const items = data.items || [];+ list.insertAdjacentHTML('beforeend', items.map(itemEl).join(''));+ cursor = data.next || null;+ done = !cursor || !items.length;+ } catch {+ done = true;+ } finally {+ loading = false;+ moreBtn.disabled = false;+ moreBtn.textContent = 'Load more';+ moreBtn.hidden = done;+ }+ }++ moreBtn.addEventListener('click', loadMore);+ const observer = new IntersectionObserver((entries) => {+ if (entries.some((e) => e.isIntersecting)) loadMore();+ }, { rootMargin: '400px' });+ observer.observe(sentinel);++ // Poll for newer items than the currently rendered top; on real activity+ // surface a "New activity" pill instead of silently reflowing the list+ // under the reader (same delight-without-jank pattern as the site-wide+ // ticker in api/feed.js / public/feed.js).+ function startPoll() {+ stopPoll();+ pollTimer = setInterval(checkForNew, 25000);+ }+ function stopPoll() {+ if (pollTimer) clearInterval(pollTimer);+ pollTimer = null;+ }+ let topCreatedAt = null;+ async function checkForNew() {+ if (document.hidden) return;+ try {+ const res = await fetchPage();+ if (!res.ok) return;+ const data = await res.json();+ const items = data.items || [];+ if (!items.length) return;+ if (!topCreatedAt) { topCreatedAt = items[0].created_at; return; }+ if (new Date(items[0].created_at) > new Date(topCreatedAt)) {+ newPill.classList.add('visible');+ }+ } catch {+ /* a missed poll is invisible — next tick tries again */+ }+ }++ newPill.addEventListener('click', () => {+ newPill.classList.remove('visible');+ topCreatedAt = null;+ window.scrollTo({ top: 0, behavior: 'smooth' });+ loadInitial();+ });++ scopeAllBtn.addEventListener('click', () => {+ if (scope === 'all') return;+ scope = 'all';+ localStorage.setItem(SCOPE_KEY, scope);+ updateScopeButtons();+ topCreatedAt = null;+ loadInitial();+ });+ scopeFollowingBtn.addEventListener('click', () => {+ if (scope === 'following') return;+ scope = 'following';+ localStorage.setItem(SCOPE_KEY, scope);+ updateScopeButtons();+ topCreatedAt = null;+ loadInitial();+ });++ updateScopeButtons();+ loadInitial();</script></body></html>diff --git a/public/changelog.json b/public/changelog.jsonindex 6bed65884..77b0f6306 100644--- a/public/changelog.json+++ b/public/changelog.json@@ -1,5 +1,5 @@{- "generated_at": "2026-07-12T16:06:40.049Z",+ "generated_at": "2026-07-12T16:11:52.299Z","generated_by": "scripts/build-page-index.mjs from data/pages.json + data/changelog.json","site": {"name": "three.ws",@@ -36,6 +36,16 @@"launch"]},+ {+ "date": "2026-07-12",+ "type": "update",+ "title": "/feed and /community are now real, live pages",+ "summary": "/feed used to only show activity from people you follow — it now defaults to a live, platform-wide feed of every new avatar, agent, forged 3D model, saved world, coin launch, and follow, with a toggle to switch to just the people you follow. Scroll for more and it loads the next page automatically; a \"New activity\" pill appears when something fresh lands so the list never jumps under you mid-read. /community, previously a static grid of links, now leads with that same live activity feed alongside the existing links to X, GitHub, docs, and tutorials.",+ "link": "/feed",+ "tags": [+ "feature"+ ]+ },{"date": "2026-07-12","type": "update",@@ -152,6 +162,16 @@"improvement"]},+ {+ "date": "2026-07-12",+ "type": "update",+ "title": "Notification bell now covers remixes, royalties, DMs, and launch graduations",+ "summary": "The nav bell already tracked sales and purchases; it now also fires for real events that used to be invisible unless you happened to be watching: someone remixing one of your published 3D models (with the royalty payout amount if one settled on-chain), a friend DMing you while you're away, and a coin you launched hitting its funding target and graduating off the bonding curve. Dashboard → Settings has a new Notification preferences panel wired to the real per-category preference store, so you can mute any category (sales, purchases, social, IRL, market alerts, account) per channel — in-app, push, email, or Telegram — independently; in-app never turns off, so nothing is silently lost. A gear icon in the bell dropdown jumps straight there.",+ "link": "/dashboard/settings",+ "tags": [+ "feature"+ ]+ },{"date": "2026-07-12","type": "update",@@ -9666,7 +9686,7 @@"date": "2026-06-21","type": "launch","title": "Feed",- "summary": "Recent activity from the people and agents you follow on three.ws.",+ "summary": "Live avatars, agents, 3D models, worlds, and launches across three.ws — filter to everyone or just the people you follow.","link": "/feed","tags": ["launch"@@ -17087,7 +17107,7 @@"date": "2026-05-25","type": "launch","title": "Dashboard · Settings",- "summary": "Avatar storage modes (R2 vs IPFS), sessions, notifications, and preferences.",+ "summary": "Avatar storage modes (R2 vs IPFS), sessions, your notification inbox, per-category notification channel preferences (in-app/push/email/Telegram), and dashboard preferences.","link": "/dashboard/settings","tags": ["launch"@@ -17845,7 +17865,7 @@"date": "2026-05-04","type": "launch","title": "Community",- "summary": "Featured creators, builds, and conversations from the three.ws community.",+ "summary": "Live platform activity plus where to follow, contribute, and connect with three.ws creators.","link": "/community","tags": ["launch"diff --git a/public/changelog.xml b/public/changelog.xmlindex 4ecb369ae..c54db4715 100644--- a/public/changelog.xml+++ b/public/changelog.xml@@ -30,6 +30,14 @@<category>launch</category><description>Your public three.ws portfolio: every avatar, agent, forged 3D model, world, coin, skill, and plugin you've made, in one place. Signed out, this redirects to sign-in; every user's own page also lives at /u/:username.</description></item>+ <item>+ <title>/feed and /community are now real, live pages</title>+ <link>https://three.ws/feed</link>+ <guid isPermaLink="false">2026-07-12:/feed and /community are now real, live pages</guid>+ <pubDate>Sun, 12 Jul 2026 12:00:00 GMT</pubDate>+ <category>feature</category>+ <description>/feed used to only show activity from people you follow — it now defaults to a live, platform-wide feed of every new avatar, agent, forged 3D model, saved world, coin launch, and follow, with a toggle to switch to just the people you follow. Scroll for more and it loads the next page automatically; a "New activity" pill appears when something fresh lands so the list never jumps under you mid-read. /community, previously a static grid of links, now leads with that same live activity feed alongside the existing links to X, GitHub, docs, and tutorials.</description>+ </item><item><title>Agent discovery fixed: six paid endpoints were invisible to x402 scanners</title><link>https://three.ws/openapi.json</link>@@ -118,6 +126,14 @@<category>fix</category><description>Every article on the news feed gets a permanent link, but stories published near a month boundary could slip through the hourly archiver and their links would eventually 404. The archiver now files each story under its real publication month (and no longer caps how many articles it sweeps per run), story pages look in neighboring months and redirect to the right address when a link's month is off by one, and a link that truly can't be found now offers a one-click archive search for that story's title instead of a dead end.</description></item>+ <item>+ <title>Notification bell now covers remixes, royalties, DMs, and launch graduations</title>+ <link>https://three.ws/dashboard/settings</link>+ <guid isPermaLink="false">2026-07-12:Notification bell now covers remixes, royalties, DMs, and launch graduations</guid>+ <pubDate>Sun, 12 Jul 2026 12:00:00 GMT</pubDate>+ <category>feature</category>+ <description>The nav bell already tracked sales and purchases; it now also fires for real events that used to be invisible unless you happened to be watching: someone remixing one of your published 3D models (with the royalty payout amount if one settled on-chain), a friend DMing you while you're away, and a coin you launched hitting its funding target and graduating off the bonding curve. Dashboard → Settings has a new Notification preferences panel wired to the real per-category preference store, so you can mute any category (sales, purchases, social, IRL, market alerts, account) per channel — in-app, push, email, or Telegram — independently; in-app never turns off, so nothing is silently lost. A gear icon in the bell dropdown jumps straight there.</description>+ </item><item><title>Oversized x402 payment headers fixed</title><link>https://three.ws/changelog</link>@@ -7412,7 +7428,7 @@<guid isPermaLink="false">2026-06-21:Feed</guid><pubDate>Sun, 21 Jun 2026 12:00:00 GMT</pubDate><category>launch</category>- <description>Recent activity from the people and agents you follow on three.ws.</description>+ <description>Live avatars, agents, 3D models, worlds, and launches across three.ws — filter to everyone or just the people you follow.</description></item><item><title>Hero Stage</title>@@ -13156,7 +13172,7 @@<guid isPermaLink="false">2026-05-25:Dashboard · Settings</guid><pubDate>Mon, 25 May 2026 12:00:00 GMT</pubDate><category>launch</category>- <description>Avatar storage modes (R2 vs IPFS), sessions, notifications, and preferences.</description>+ <description>Avatar storage modes (R2 vs IPFS), sessions, your notification inbox, per-category notification channel preferences (in-app/push/email/Telegram), and dashboard preferences.</description></item><item><title>Full Animation & Emotion Control — Plus Pump.fun Live Feed</title>@@ -13756,7 +13772,7 @@<guid isPermaLink="false">2026-05-04:Community</guid><pubDate>Mon, 04 May 2026 12:00:00 GMT</pubDate><category>launch</category>- <description>Featured creators, builds, and conversations from the three.ws community.</description>+ <description>Live platform activity plus where to follow, contribute, and connect with three.ws creators.</description></item><item><title>How to Embed 3D On-Chain Agents on Your Site</title>diff --git a/public/features.json b/public/features.jsonindex 3ec8f9166..66d016f82 100644--- a/public/features.json+++ b/public/features.json@@ -1,5 +1,5 @@{- "generated_at": "2026-07-12T16:06:40.034Z",+ "generated_at": "2026-07-12T16:11:52.286Z","generated_by": "scripts/build-page-index.mjs from data/pages.json","site": {"name": "three.ws",@@ -208,7 +208,7 @@{"path": "/community","title": "Community",- "description": "Featured creators, builds, and conversations from the three.ws community.",+ "description": "Live platform activity plus where to follow, contribute, and connect with three.ws creators.","added": "2026-05-04","auth": null,"indexable": true,@@ -278,7 +278,7 @@{"path": "/feed","title": "Feed",- "description": "Recent activity from the people and agents you follow on three.ws.",+ "description": "Live avatars, agents, 3D models, worlds, and launches across three.ws — filter to everyone or just the people you follow.","added": "2026-06-21","auth": null,"indexable": true,@@ -2163,7 +2163,7 @@{"path": "/dashboard/settings","title": "Dashboard · Settings",- "description": "Avatar storage modes (R2 vs IPFS), sessions, notifications, and preferences.",+ "description": "Avatar storage modes (R2 vs IPFS), sessions, your notification inbox, per-category notification channel preferences (in-app/push/email/Telegram), and dashboard preferences.","added": "2026-05-25","auth": "required","indexable": false,diff --git a/public/llms-full.txt b/public/llms-full.txtindex 786ccb2bd..7f6c40f13 100644--- a/public/llms-full.txt+++ b/public/llms-full.txt@@ -131,7 +131,7 @@ Browse, search, and install agent skills — tool packs, knowledge bases, and caURL: https://three.ws/community-Featured creators, builds, and conversations from the three.ws community.+Live platform activity plus where to follow, contribute, and connect with three.ws creators.### Sitemap@@ -173,7 +173,7 @@ Your 3D avatar walks anywhere on the web. Live demos across six environments, aURL: https://three.ws/feed-Recent activity from the people and agents you follow on three.ws.+Live avatars, agents, 3D models, worlds, and launches across three.ws — filter to everyone or just the people you follow.### Partner Ecosystem@@ -1326,7 +1326,7 @@ URL: https://three.ws/dashboard/settingsAuth: required (sign-in)Indexable: no (excluded from sitemap)-Avatar storage modes (R2 vs IPFS), sessions, notifications, and preferences.+Avatar storage modes (R2 vs IPFS), sessions, your notification inbox, per-category notification channel preferences (in-app/push/email/Telegram), and dashboard preferences.### Settingsdiff --git a/public/llms.txt b/public/llms.txtindex 6ba85ca5f..b5e539bcc 100644--- a/public/llms.txt+++ b/public/llms.txt@@ -30,14 +30,14 @@ Entry points into the product.- [Marketplace Analytics](https://three.ws/marketplace/analytics): Real-time stats on the three.ws skill marketplace: top skills, top agents, and sales volume.- [My Collection](https://three.ws/collection): View all the skills and subscriptions you've unlocked on three.ws.- [Skills Marketplace](https://three.ws/skills): Browse, search, and install agent skills — tool packs, knowledge bases, and capabilities that make AI agents smarter.-- [Community](https://three.ws/community): Featured creators, builds, and conversations from the three.ws community.+- [Community](https://three.ws/community): Live platform activity plus where to follow, contribute, and connect with three.ws creators.- [Sitemap](https://three.ws/sitemap): Human-readable index of every page on three.ws.- [Characters](https://three.ws/characters): Discover AI characters on three.ws. Chat, trade, and create.- [What is three.ws?](https://three.ws/what-is): Plain-English introduction to three.ws — what a 3D AI agent is, real use-cases, and where to begin.- [Pitch Deck](https://three.ws/pitch): The three.ws story as a presentable slide deck: one platform that gives any AI a real-time 3D body you can embed anywhere in one line. Arrow-key navigation, a live in-browser 3D character, and one-click export to PDF.- [Guided Tour](https://three.ws/tour): A 3D guide walks across the live site, points at every feature, and narrates what each one does and how to use it — voice plus an on-screen chat bubble, paced by you.- [Walk Anywhere on the Web](https://three.ws/walk): Your 3D avatar walks anywhere on the web. Live demos across six environments, a Chrome extension, one-tag embeds, and a global distance leaderboard.-- [Feed](https://three.ws/feed): Recent activity from the people and agents you follow on three.ws.+- [Feed](https://three.ws/feed): Live avatars, agents, 3D models, worlds, and launches across three.ws — filter to everyone or just the people you follow.- [Partner Ecosystem](https://three.ws/partners): three.ws partner ecosystem — AWS, IBM, Google Cloud, Alibaba Cloud, Intel, NVIDIA, Microsoft, Oracle. The cloud and AI platforms powering 3D AI agents at enterprise scale.## Builddiff --git a/public/sitemap/index.html b/public/sitemap/index.htmlindex 3d8026604..7ac2469cb 100644--- a/public/sitemap/index.html+++ b/public/sitemap/index.html@@ -237,7 +237,7 @@<a href="/community"><span class="sm-title">Community</span><span class="sm-path">/community</span>- <span class="sm-desc">Featured creators, builds, and conversations from the three.ws community.</span>+ <span class="sm-desc">Live platform activity plus where to follow, contribute, and connect with three.ws creators.</span></a></li><li>@@ -286,7 +286,7 @@<a href="/feed"><span class="sm-title">Feed</span><span class="sm-path">/feed</span>- <span class="sm-desc">Recent activity from the people and agents you follow on three.ws.</span>+ <span class="sm-desc">Live avatars, agents, 3D models, worlds, and launches across three.ws — filter to everyone or just the people you follow.</span></a></li><li>@@ -1626,7 +1626,7 @@<a href="/dashboard/settings"><span class="sm-title">Dashboard · Settings<span class="sm-badge sm-badge-auth">sign-in</span><span class="sm-badge sm-badge-internal">internal</span></span><span class="sm-path">/dashboard/settings</span>- <span class="sm-desc">Avatar storage modes (R2 vs IPFS), sessions, notifications, and preferences.</span>+ <span class="sm-desc">Avatar storage modes (R2 vs IPFS), sessions, your notification inbox, per-category notification channel preferences (in-app/push/email/Telegram), and dashboard preferences.</span></a></li><li>diff --git a/tests/api/activity-feed.test.js b/tests/api/activity-feed.test.jsnew file mode 100644index 000000000..f01b4f010--- /dev/null+++ b/tests/api/activity-feed.test.js@@ -0,0 +1,165 @@+// Unit tests for the merge/render logic of GET /api/users/me/feed —+// specifically the scope=all (platform-wide, no-auth) path added by+// prompts/user-value/02-activity-feed.md, and the model/world/follow event+// kinds layered onto the pre-existing avatar/agent/coin feed+// (see tests/api/users-follow.test.js for the follow-graph-specific contract+// this file deliberately leaves alone).+//+// Mocks: sql (raw avatar/agent/coin/follow queries), forge-store's+// listRecentCreations, diorama-store's listDioramas. All offline — no+// DATABASE_URL or Redis needed.++import { describe, it, expect, vi, beforeEach } from 'vitest';++const authState = { session: null };+vi.mock('../../api/_lib/auth.js', () => ({+ getSessionUser: vi.fn(async () => authState.session),+}));++// api/_lib/db.js's real `sql` composes nested `sql\`\`` fragments (used here for+// conditional `${before ? sql\`and x < ${before}\` : sql\`\`}` WHERE clauses)+// into the parent query rather than executing them standalone. This mock must+// do the same — an empty fragment call (`sql\`\`` with no interpolations) is a+// building block, not a query, and must NOT consume a slot off sqlQueue.+const sqlQueue = [];+vi.mock('../../api/_lib/db.js', () => ({+ sql: Object.assign(+ vi.fn((strings, ...values) => {+ const isEmptyFragment = Array.isArray(strings) && strings.length === 1 && strings[0] === '' && values.length === 0;+ if (isEmptyFragment) return { __fragment: true };+ return (async () => (sqlQueue.length ? sqlQueue.shift() : []))();+ }),+ { transaction: vi.fn(async (fns) => { for (const f of fns) await f; }) },+ ),+ isDbUnavailableError: () => false,+ isDbCapacityError: () => false,+}));++const rlState = { success: true };+vi.mock('../../api/_lib/rate-limit.js', () => ({+ limits: { authedReadIp: vi.fn(async () => rlState) },+ clientIp: vi.fn(() => '127.0.0.1'),+}));++vi.mock('../../api/_lib/r2.js', () => ({+ publicUrl: (k) => (k ? `https://r2.example/${k}` : null),+ thumbnailUrl: (k) => (k ? `https://r2.example/thumb/${k}` : null),+}));++const listRecentCreations = vi.fn(async () => []);+vi.mock('../../api/_lib/forge-store.js', () => ({ listRecentCreations: (...a) => listRecentCreations(...a) }));++const listDioramas = vi.fn(async () => []);+vi.mock('../../api/_lib/diorama-store.js', () => ({ listDioramas: (...a) => listDioramas(...a) }));++const { default: meFeedHandler } = await import('../../api/users/me/feed.js');++function makeReq(query = {}) {+ return { method: 'GET', query, headers: {}, url: `/api/users/me/feed?${new URLSearchParams(query)}` };+}+function makeRes() {+ return {+ statusCode: 200,+ _h: {},+ setHeader(k, v) { this._h[k.toLowerCase()] = v; },+ getHeader(k) { return this._h[k.toLowerCase()]; },+ end(body) { this._body = body; },+ };+}+async function call(query) {+ const req = makeReq(query);+ const res = makeRes();+ await meFeedHandler(req, res);+ let body = null;+ try { body = JSON.parse(res._body); } catch {}+ return { res, body };+}++beforeEach(() => {+ sqlQueue.length = 0;+ authState.session = null;+ rlState.success = true;+ listRecentCreations.mockReset().mockResolvedValue([]);+ listDioramas.mockReset().mockResolvedValue([]);+});++describe('GET /api/users/me/feed?scope=all', () => {+ it('requires no session', async () => {+ sqlQueue.push([]); // avatars+ sqlQueue.push([]); // agents+ sqlQueue.push([]); // coins+ sqlQueue.push([]); // follows+ const { res } = await call({ scope: 'all' });+ expect(res.statusCode).toBe(200);+ });++ it('merges avatar/agent/coin/model/world/follow rows into one reverse-chronological feed', async () => {+ sqlQueue.push([+ { id: 'av1', name: 'Cool Avatar', thumbnail_key: 'thumb1', created_at: '2026-07-12T10:00:00Z', username: 'alice', display_name: 'Alice', avatar_url: null },+ ]);+ sqlQueue.push([+ { id: 'ag1', name: 'Helper Bot', description: 'helps', profile_image_url: null, avatar_url: null, created_at: '2026-07-12T08:00:00Z', username: 'bob', display_name: 'Bob', actor_avatar: null },+ ]);+ sqlQueue.push([+ { agent_id: 'ag2', agent_name: 'Coin Bot', profile_image_url: null, avatar_url: null, token: { mint: 'MintAddr123', name: 'CoinName', symbol: 'CN', launched_at: '2026-07-12T12:00:00Z' }, created_at: '2026-07-12T09:00:00Z', username: 'carol', display_name: 'Carol', actor_avatar: null },+ ]);+ sqlQueue.push([+ { created_at: '2026-07-12T11:00:00Z', follower_username: 'dave', follower_display: 'Dave', follower_avatar: null, target_username: 'erin', target_display: 'Erin', target_avatar: null },+ ]);+ listRecentCreations.mockResolvedValue([+ { id: 'm1', type: 'model', prompt: 'a red robot', glbUrl: 'https://cdn/x.glb', previewImageUrl: null, category: 'other', isRemix: false, createdAt: '2026-07-12T13:00:00Z', username: null, displayName: null, avatarUrl: null },+ { id: 'm2', type: 'model', prompt: 'remixed sword', glbUrl: 'https://cdn/y.glb', previewImageUrl: null, category: 'item', isRemix: true, createdAt: '2026-07-12T07:00:00Z', username: 'frank', displayName: 'Frank', avatarUrl: null },+ ]);+ listDioramas.mockResolvedValue([+ { id: 'w1', title: 'A cozy world', prompt: 'p', mood: 'cozy', ground: 'grass', palette: null, author: null, creatorUsername: 'gwen', creatorDisplayName: 'Gwen', creatorAvatarUrl: null, thumbnailGlb: 'https://cdn/w.glb', objectCount: 3, views: 0, featured: false, createdAt: '2026-07-12T06:00:00Z' },+ ]);++ const { res, body } = await call({ scope: 'all', limit: '10' });+ expect(res.statusCode).toBe(200);+ expect(body.scope).toBe('all');++ // m1 13:00 > coin (launched_at 12:00) > follow 11:00 > avatar 10:00 >+ // agent 08:00 > m2 07:00 > world 06:00.+ const kinds = body.items.map((it) => it.kind);+ expect(kinds).toEqual(['model', 'coin', 'follow', 'avatar', 'agent', 'model', 'world']);++ // Newest-first ordering across all merged kinds.+ const times = body.items.map((it) => new Date(it.created_at).getTime());+ expect(times).toEqual([...times].sort((a, b) => b - a));++ // A model made while signed out carries no attributable actor.+ const anon = body.items.find((it) => it.id === 'm1');+ expect(anon.actor.username).toBeNull();++ // A remixed model is flagged so the client can render "remixed" not "forged".+ const remix = body.items.find((it) => it.id === 'm2');+ expect(remix.isRemix).toBe(true);++ // A world links to the diorama viewer and carries real creator attribution.+ const world = body.items.find((it) => it.kind === 'world');+ expect(world.href).toBe('https://three.ws/diorama?id=w1');+ expect(world.actor.username).toBe('gwen');++ // A follow event carries both actor (follower) and target (followee).+ const follow = body.items.find((it) => it.kind === 'follow');+ expect(follow.actor.username).toBe('dave');+ expect(follow.target.username).toBe('erin');+ expect(follow.href).toBe('/u/erin');++ // A coin launch resolves mint/name/symbol from the agent's token metadata.+ const coin = body.items.find((it) => it.kind === 'coin');+ expect(coin.id).toBe('MintAddr123');+ expect(coin.subtitle).toBe('$CN');+ });++ it('returns a well-formed empty feed when nothing has happened, never 500s', async () => {+ sqlQueue.push([]); // avatars+ sqlQueue.push([]); // agents+ sqlQueue.push([]); // coins+ sqlQueue.push([]); // follows+ const { res, body } = await call({ scope: 'all' });+ expect(res.statusCode).toBe(200);+ expect(body.items).toEqual([]);+ expect(body.next).toBeNull();+ });+});