diff --git a/Sources/MCPConformance/Server/main.swift b/Sources/MCPConformance/Server/main.swift index 6a7ccead..16916148 100644 --- a/Sources/MCPConformance/Server/main.swift +++ b/Sources/MCPConformance/Server/main.swift @@ -376,7 +376,12 @@ func createConformanceServer(state: ServerState, transport: StatefulHTTPServerTr Resource(name: "Static Text Resource", uri: "test://static-text", description: "A simple static text resource", mimeType: "text/plain"), Resource(name: "Static Binary Resource", uri: "test://static-binary", description: "A simple static binary resource", mimeType: "application/octet-stream"), Resource(name: "Watched Resource", uri: "test://watched", description: "A resource that can be subscribed to for updates", mimeType: "text/plain"), - Resource(name: "Template Resource", uri: "test://template/{id}", description: "A resource template with URI parameters", mimeType: "text/plain"), + ]) + } + + await server.withMethodHandler(ListResourceTemplates.self) { _ in + .init(templates: [ + Resource.Template(uriTemplate: "test://template/{id}", name: "Template Resource", description: "A resource template with URI parameters", mimeType: "text/plain") ]) }