pub struct McpApi { /* private fields */ }Expand description
MCP API client.
Implementations§
Source§impl McpApi
impl McpApi
Sourcepub fn new(http: HttpClient) -> Self
pub fn new(http: HttpClient) -> Self
Create a new MCP API client.
Sourcepub async fn add(&self, req: &McpAddRequest) -> Result<McpActionResponse>
pub async fn add(&self, req: &McpAddRequest) -> Result<McpActionResponse>
Sourcepub async fn auth_start(
&self,
name: &str,
req: &McpAuthStartRequest,
) -> Result<McpAuthStartResponse>
pub async fn auth_start( &self, name: &str, req: &McpAuthStartRequest, ) -> Result<McpAuthStartResponse>
Sourcepub async fn auth_callback(
&self,
name: &str,
req: &McpAuthCallbackRequest,
) -> Result<McpActionResponse>
pub async fn auth_callback( &self, name: &str, req: &McpAuthCallbackRequest, ) -> Result<McpActionResponse>
Sourcepub async fn authenticate(
&self,
name: &str,
req: &McpAuthenticateRequest,
) -> Result<McpActionResponse>
pub async fn authenticate( &self, name: &str, req: &McpAuthenticateRequest, ) -> Result<McpActionResponse>
Sourcepub async fn auth_remove(&self, name: &str) -> Result<()>
pub async fn auth_remove(&self, name: &str) -> Result<()>
Sourcepub async fn connect(&self, name: &str) -> Result<McpActionResponse>
pub async fn connect(&self, name: &str) -> Result<McpActionResponse>
Sourcepub async fn disconnect(&self, name: &str) -> Result<McpActionResponse>
pub async fn disconnect(&self, name: &str) -> Result<McpActionResponse>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for McpApi
impl !RefUnwindSafe for McpApi
impl Send for McpApi
impl Sync for McpApi
impl Unpin for McpApi
impl !UnwindSafe for McpApi
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