pub struct Gateway { /* private fields */ }Expand description
ZAP MCP Gateway - aggregates multiple MCP servers
Implementations§
Source§impl Gateway
impl Gateway
pub fn new(config: Config) -> Gateway
pub async fn add_server( &self, name: &str, config: ServerConfig, ) -> Result<String, Error>
pub async fn remove_server(&self, id: &str) -> Result<(), Error>
pub async fn list_servers(&self) -> Vec<ServerInfo>
pub async fn server_status(&self, id: &str) -> Option<ServerStatus>
pub async fn list_tools(&self) -> Vec<McpTool>
pub async fn list_resources(&self) -> Vec<McpResource>
pub async fn list_prompts(&self) -> Vec<McpPrompt>
pub async fn call_tool( &self, name: &str, arguments: Value, ) -> Result<Value, Error>
pub async fn read_resource(&self, uri: &str) -> Result<Value, Error>
pub async fn get_prompt( &self, name: &str, arguments: Option<Value>, ) -> Result<Value, Error>
pub async fn run(&mut self) -> Result<(), Error>
pub async fn shutdown(&self) -> Result<(), Error>
Auto Trait Implementations§
impl Freeze for Gateway
impl !RefUnwindSafe for Gateway
impl Send for Gateway
impl Sync for Gateway
impl Unpin for Gateway
impl !UnwindSafe for Gateway
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