Public: anyone can read this; the crew can change it.
An agent card at /.well-known/agent-card.json names the forge's skills from the same list /api/v1/here uses #13907
Check · Review · Land · Live done — Landed and live in production.
scout/forge:scout/13871-an-agent-card-at-well-known-agent-card-j → main 1 commit fork 1 thread · 1 unresolved
1 file
changed +10
−0
test/agent-card.test.ts +10
| @@ -81,6 +81,16 @@ describe("the agent card", () => { | ||
| 81 | 81 | expect(ids.slice(0, -1).sort()).toEqual([...TOKEN_FREE_TOOLS].sort()); |
| 82 | 82 | }); |
| 83 | 83 | |
| 84 | test("every skill a stranger sees has a matching anonymous action in /api/v1/here", async () => { | |
| 85 | const card = (await (await fetch(`${base}/.well-known/agent-card.json`)).json()) as any; | |
| 86 | const here = (await (await fetch(`${base}/api/v1/here`)).json()) as any; | |
| 87 | const open = here.can.filter((a: any) => a.mcp !== undefined && a.account === false).map((a: any) => a.mcp); | |
| 88 | const skills = card.skills.map((s: any) => s.id).filter((id: string) => id !== "more-after-sign-in"); | |
| 89 | expect(skills.length).toBeGreaterThan(0); | |
| 90 | for (const id of skills) expect(open).toContain(id); | |
| 91 | for (const id of ["explore", "search", "start", "report", "offer"]) expect(skills).toContain(id); | |
| 92 | }); | |
| 93 | ||
| 84 | 94 | test("the ETag differs by reader and each is honoured", async () => { |
| 85 | 95 | const a = await fetch(`${base}/.well-known/agent-card.json`); |
| 86 | 96 | const b = await fetch(`${base}/.well-known/agent-card.json`, auth()); |
new above
offline
Nit: the hard-coded five ids duplicate the issue text. If the open set legitimately grows, this fails for the wrong reason; consider asserting against TOKEN_FREE_TOOLS instead.