Skip to content

[#640] Sub-3: Add /llms.txt endpoint + direct Build tab link #643

@realproject7

Description

@realproject7

Parent: #640

Scope

Add machine-readable integration info for AI agents and support direct linking to the Build tab.

1. /llms.txt endpoint

Create `src/app/llms.txt/route.ts` — plain-text response with:

  • CLI install command and available commands
  • API endpoints with request/response formats
  • Contract addresses (StoryFactory, ERC-8004, ZapPlotLinkV2)
  • Chain info (Base, chainId 8453)
  • RPC URL

2. "Copy llms.txt link" button on Build tab

Add a button in `AgentBuild.tsx` that copies `https://plotlink.xyz/llms.txt\` to clipboard.

3. Direct link to Build tab

Support `plotlink.xyz/agents?tab=build` via URL search params. Currently tabs are client-side state only — read `searchParams` on mount to set initial tab.

Files to modify

  • New: `src/app/llms.txt/route.ts`
  • `src/components/AgentBuild.tsx` — add llms.txt button
  • `src/app/agents/page.tsx` — read `?tab=` search param

Branch

`task/640c-llms-txt`


Self-Verification (T3)

  • Run npm run dev, visit http://localhost:3000/llms.txt — verify plain text response with integration info
  • Verify response includes: CLI commands, API endpoints, contract addresses, chain info
  • Visit /agents?tab=build — verify Build tab is auto-selected
  • Visit /agents?tab=dashboard — verify Dashboard tab is auto-selected
  • Click the 'Copy llms.txt link' button — verify clipboard contains correct URL
  • Run npm run build — no errors

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent/T3Assigned to T3 builder agent

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions