pub struct McpToolInfo {
pub name: String,
pub title: String,
pub description: String,
pub scope: McpToolScope,
pub annotations: McpToolAnnotations,
pub output_schema: Option<Value>,
}Expand description
Everything about a tool except its input schema.
Fields§
§name: String§title: String§description: String§scope: McpToolScope§annotations: McpToolAnnotations§output_schema: Option<Value>Implementations§
Source§impl McpToolInfo
impl McpToolInfo
Sourcepub fn new(name: impl Into<String>, description: impl Into<String>) -> Self
pub fn new(name: impl Into<String>, description: impl Into<String>) -> Self
A BinaryView-scoped tool with no title, annotations or output schema.
pub fn with_title(self, title: impl Into<String>) -> Self
pub fn with_scope(self, scope: McpToolScope) -> Self
pub fn with_annotations(self, annotations: McpToolAnnotations) -> Self
pub fn with_output_schema(self, schema: Value) -> Self
Sourcepub fn with_input_schema(self, input_schema: Value) -> McpToolDefinition
pub fn with_input_schema(self, input_schema: Value) -> McpToolDefinition
Completes the definition with a JSON Schema object for the tool’s input.
Trait Implementations§
Source§impl Clone for McpToolInfo
impl Clone for McpToolInfo
Source§fn clone(&self) -> McpToolInfo
fn clone(&self) -> McpToolInfo
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for McpToolInfo
impl RefUnwindSafe for McpToolInfo
impl Send for McpToolInfo
impl Sync for McpToolInfo
impl Unpin for McpToolInfo
impl UnsafeUnpin for McpToolInfo
impl UnwindSafe for McpToolInfo
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more