use std::future::Future;
use std::pin::Pin;
use serde_json::Value;
use turbomcp_protocol::{InitializeRequest, InitializeResult};
use crate::error::ProxyResult;
pub mod stdio;
pub trait McpBackend: Send + Sync {
fn initialize(
&mut self,
request: InitializeRequest,
) -> Pin<Box<dyn Future<Output = ProxyResult<InitializeResult>> + Send + '_>>;
fn call_method<'a>(
&'a mut self,
method: &'a str,
params: Value,
) -> Pin<Box<dyn Future<Output = ProxyResult<Value>> + Send + 'a>>;
fn send_notification<'a>(
&'a mut self,
method: &'a str,
params: Value,
) -> Pin<Box<dyn Future<Output = ProxyResult<()>> + Send + 'a>>;
fn shutdown(&mut self) -> Pin<Box<dyn Future<Output = ProxyResult<()>> + Send + '_>>;
fn description(&self) -> String;
}