pub enum ToolExposure {
Direct,
Search,
}Expand description
How backend tools are exposed to MCP clients.
Controls whether individual backend tools appear in ListTools responses
or are hidden behind discovery meta-tools.
§Examples
use mcp_proxy::config::ToolExposure;
let direct: ToolExposure = serde_json::from_str("\"direct\"").unwrap();
assert_eq!(direct, ToolExposure::Direct);
let search: ToolExposure = serde_json::from_str("\"search\"").unwrap();
assert_eq!(search, ToolExposure::Search);Variants§
Direct
All backend tools appear in ListTools responses.
Search
Only proxy/ namespace meta-tools appear. Backend tools are hidden
from listings but remain invokable via proxy/call_tool.
Trait Implementations§
Source§impl Clone for ToolExposure
impl Clone for ToolExposure
Source§fn clone(&self) -> ToolExposure
fn clone(&self) -> ToolExposure
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ToolExposure
impl Debug for ToolExposure
Source§impl Default for ToolExposure
impl Default for ToolExposure
Source§fn default() -> ToolExposure
fn default() -> ToolExposure
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ToolExposure
impl<'de> Deserialize<'de> for ToolExposure
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ToolExposure
impl PartialEq for ToolExposure
Source§impl Serialize for ToolExposure
impl Serialize for ToolExposure
impl Eq for ToolExposure
impl StructuralPartialEq for ToolExposure
Auto Trait Implementations§
impl Freeze for ToolExposure
impl RefUnwindSafe for ToolExposure
impl Send for ToolExposure
impl Sync for ToolExposure
impl Unpin for ToolExposure
impl UnsafeUnpin for ToolExposure
impl UnwindSafe for ToolExposure
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more