================ @@ -76,17 +76,75 @@ struct ToolCapability { llvm::json::Value toJSON(const ToolCapability &); bool fromJSON(const llvm::json::Value &, ToolCapability &, llvm::json::Path); +struct ResourceCapability { + /// Whether this server supports notifications for changes to the resources + /// list. + bool listChanged = false; + + /// Whether subscriptions are supported. + bool subscribe = false; +}; + +llvm::json::Value toJSON(const ResourceCapability &); +bool fromJSON(const llvm::json::Value &, ResourceCapability &, + llvm::json::Path); + /// Capabilities that a server may support. Known capabilities are defined here, /// in this schema, but this is not a closed set: any server can define its own, /// additional capabilities. struct Capabilities { - /// Present if the server offers any tools to call. + /// Tool capabilities of the server. ToolCapability tools; + + /// Resource capabilities of the server. + ResourceCapability resources; }; llvm::json::Value toJSON(const Capabilities &); bool fromJSON(const llvm::json::Value &, Capabilities &, llvm::json::Path); +/// A known resource that the server is capable of reading. +struct Resource { + /// The URI of this resource. + std::string uri; + + /// A human-readable name for this resource. + std::string name; + + /// A description of what this resource represents. + std::optional<std::string> description; + + /// The MIME type of this resource, if known. + std::optional<std::string> mimeType; ---------------- JDevlieghere wrote:
Let me do this as a followup for all of MCP 👍 https://github.com/llvm/llvm-project/pull/148075 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits