diff --git a/app/scripts/mcp-server.ts b/app/scripts/mcp-server.ts index f1459e59..811b75b9 100644 --- a/app/scripts/mcp-server.ts +++ b/app/scripts/mcp-server.ts @@ -135,7 +135,7 @@ const GetPromoDraftsSchema = z.object({ const server = new Server( { - name: "allthingsweb-scripts", + name: "allthings-scripts", version: "1.0.0", }, { diff --git a/app/src/app/mcp/route.ts b/app/src/app/mcp/route.ts index d6f9583e..4d9b678b 100644 --- a/app/src/app/mcp/route.ts +++ b/app/src/app/mcp/route.ts @@ -23,7 +23,7 @@ const handler = createMcpHandler( }), { serverInfo: { - name: "all-things-web", + name: "allthings", version: packageJson.version, }, }, diff --git a/app/src/lib/mcp/tools.ts b/app/src/lib/mcp/tools.ts index 13dd7a3d..a75016fa 100644 --- a/app/src/lib/mcp/tools.ts +++ b/app/src/lib/mcp/tools.ts @@ -53,7 +53,7 @@ async function withDataSource( content: [ { type: "text", - text: `All Things Web ${subject} are temporarily unavailable. Please retry in a minute.`, + text: `all things ${subject} are temporarily unavailable. Please retry in a minute.`, }, ], }; @@ -73,7 +73,7 @@ export function registerAtwTools( { title: "List events", description: - "List All Things Web events in San Francisco. Upcoming (including live) events come soonest first; past events come most recent first. Registration always happens at each event's rsvpUrl.", + "List all things events in San Francisco. Upcoming (including live) events come soonest first; past events come most recent first. Registration always happens at each event's rsvpUrl.", inputSchema: z.object({ when: z .enum(["upcoming", "past", "all"]) @@ -110,7 +110,7 @@ export function registerAtwTools( { title: "Get event", description: - "Get one All Things Web event by slug: schedule, venue, talks with speakers, hosting companies and where to register.", + "Get one all things event by slug: schedule, venue, talks with speakers, hosting companies and where to register.", inputSchema: z.object({ slug: z.string().min(1).describe("Event slug from list_events."), }), @@ -141,7 +141,7 @@ export function registerAtwTools( { title: "List speakers", description: - "List people who have spoken at past All Things Web events, with their talks. Optionally filter by a case-insensitive name, title or talk search.", + "List people who have spoken at past all things events, with their talks. Optionally filter by a case-insensitive name, title or talk search.", inputSchema: z.object({ query: z.string().trim().min(1).optional(), limit: z.number().int().min(1).max(200).default(50), @@ -177,9 +177,9 @@ export function registerAtwTools( server.registerTool( "get_community", { - title: "About All Things Web", + title: "About all things", description: - "What All Things Web is: mission, history, how hosting works, and links to events, Discord and the code of conduct.", + "What all things is: mission, history, how hosting works, and links to events, Discord and the code of conduct.", inputSchema: z.object({}), outputSchema: communitySchema, annotations: readOnly, diff --git a/cli/tests/client.test.ts b/cli/tests/client.test.ts index cbebdb69..33d0da72 100644 --- a/cli/tests/client.test.ts +++ b/cli/tests/client.test.ts @@ -87,7 +87,7 @@ describe("MCP client", () => { content: [ { type: "text", - text: "All Things Web events are temporarily unavailable.", + text: "all things events are temporarily unavailable.", }, ], }, diff --git a/web/src/mcp/server.ts b/web/src/mcp/server.ts index de3383d9..2b4d82e9 100644 --- a/web/src/mcp/server.ts +++ b/web/src/mcp/server.ts @@ -18,7 +18,7 @@ export function mcpHandler( const handler = createMcpHandler( () => { const server = new McpServer({ - name: "all-things-web", + name: "allthings", version: packageJson.version, }); registerTools(server, run); diff --git a/web/src/mcp/tools.ts b/web/src/mcp/tools.ts index 724f9cd7..e2499ce3 100644 --- a/web/src/mcp/tools.ts +++ b/web/src/mcp/tools.ts @@ -99,7 +99,7 @@ const withDataSource = Effect.logError(`MCP tool ${tool} failed`, cause).pipe( Effect.as( fail( - `All Things Web ${subject} are temporarily unavailable. Please retry in a minute.`, + `all things ${subject} are temporarily unavailable. Please retry in a minute.`, ), ), ), @@ -163,7 +163,7 @@ export function registerTools(server: McpServer, run: RunTool): void { { title: "List events", description: - "List All Things Web events in San Francisco. Upcoming (including live) events come soonest first; past events come most recent first. Registration always happens at each event's rsvpUrl.", + "List all things events in San Francisco. Upcoming (including live) events come soonest first; past events come most recent first. Registration always happens at each event's rsvpUrl.", inputSchema: z.object({ when: z .enum(["upcoming", "past", "all"]) @@ -184,7 +184,7 @@ export function registerTools(server: McpServer, run: RunTool): void { { title: "Get event", description: - "Get one All Things Web event by slug: schedule, venue, talks with speakers, hosting companies and where to register.", + "Get one all things event by slug: schedule, venue, talks with speakers, hosting companies and where to register.", inputSchema: z.object({ slug: z.string().min(1).describe("Event slug from list_events."), }), @@ -199,7 +199,7 @@ export function registerTools(server: McpServer, run: RunTool): void { { title: "List speakers", description: - "List people who have spoken at past All Things Web events, with their talks. Optionally filter by a case-insensitive name, title or talk search.", + "List people who have spoken at past all things events, with their talks. Optionally filter by a case-insensitive name, title or talk search.", inputSchema: z.object({ query: z.string().trim().min(1).optional(), limit: z.number().int().min(1).max(200).default(50), @@ -215,9 +215,9 @@ export function registerTools(server: McpServer, run: RunTool): void { server.registerTool( "get_community", { - title: "About All Things Web", + title: "About all things", description: - "What All Things Web is: mission, history, how hosting works, and links to events, Discord and the code of conduct.", + "What all things is: mission, history, how hosting works, and links to events, Discord and the code of conduct.", inputSchema: z.object({}), outputSchema: outputSchema(Schema.Struct(Contract.Community.fields)), annotations: readOnly, diff --git a/web/tests/support/app.ts b/web/tests/support/app.ts index 477fa065..7ba3b0d8 100644 --- a/web/tests/support/app.ts +++ b/web/tests/support/app.ts @@ -86,7 +86,7 @@ export async function loadApp( throw error; }, }), - { serverInfo: { name: "all-things-web", version } }, + { serverInfo: { name: "allthings", version } }, ); const eventPath = /^\/api\/v1\/events\/([^/]+)$/; diff --git a/web/tests/worker.test.ts b/web/tests/worker.test.ts index 7b8e9da9..ab7d0e68 100644 --- a/web/tests/worker.test.ts +++ b/web/tests/worker.test.ts @@ -302,6 +302,11 @@ describe("MCP", () => { }, }); expect(actual).toEqual(expected); + // The server introduces itself by the new name. + expect( + (rpcMessage(actual.body) as { result: { serverInfo: { name: string } } }) + .result.serverInfo.name, + ).toBe("allthings"); }); it("lists the same tools, with the same input and output schemas", async ({ @@ -327,6 +332,10 @@ describe("MCP", () => { // Names, titles, descriptions, annotations and input schemas, exactly. const withoutOutput = ({ outputSchema: _, ...tool }: Tool) => tool; expect(served.map(withoutOutput)).toEqual(today.map(withoutOutput)); + // They name the community as all things, never by its old name. + expect(JSON.stringify(served.map(withoutOutput))).not.toMatch( + /all things web/i, + ); // Output schemas come from core's Effect contract: the same JSON Schema, // as core's contract test defines sameness. expect( @@ -444,7 +453,7 @@ describe("MCP", () => { content: [ { type: "text", - text: `All Things Web ${subject} are temporarily unavailable. Please retry in a minute.`, + text: `all things ${subject} are temporarily unavailable. Please retry in a minute.`, }, ], },