4343//! # ServiceExt, serve_server,
4444//! # };
4545//! #[cfg(feature = "client")]
46- //! #[cfg_attr(docsrs, doc(cfg(feature = "client")))]
4746//! # use rmcp::serve_client;
4847//!
4948//! // create transport from tcp stream
5049//! #[cfg(feature = "client")]
51- //! #[cfg_attr(docsrs, doc(cfg(feature = "client")))]
5250//! async fn client() -> Result<(), Box<dyn std::error::Error>> {
5351//! let stream = tokio::net::TcpSocket::new_v4()?
5452//! .connect("127.0.0.1:8001".parse()?)
6159//!
6260//! // create transport from std io
6361//! #[cfg(feature = "client")]
64- //! #[cfg_attr(docsrs, doc(cfg(feature = "client")))]
6562//! async fn io() -> Result<(), Box<dyn std::error::Error>> {
6663//! let client = ().serve((tokio::io::stdin(), tokio::io::stdout())).await?;
6764//! let tools = client.peer().list_tools(Default::default()).await?;
@@ -77,56 +74,42 @@ use crate::service::{RxJsonRpcMessage, ServiceRole, TxJsonRpcMessage};
7774pub mod sink_stream;
7875
7976#[ cfg( feature = "transport-async-rw" ) ]
80- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-async-rw" ) ) ) ]
8177pub mod async_rw;
8278
8379#[ cfg( feature = "transport-worker" ) ]
84- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-worker" ) ) ) ]
8580pub mod worker;
8681#[ cfg( feature = "transport-worker" ) ]
87- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-worker" ) ) ) ]
8882pub use worker:: WorkerTransport ;
8983
9084#[ cfg( feature = "transport-child-process" ) ]
91- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-child-process" ) ) ) ]
9285pub mod child_process;
9386#[ cfg( feature = "transport-child-process" ) ]
94- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-child-process" ) ) ) ]
9587pub use child_process:: { ConfigureCommandExt , TokioChildProcess } ;
9688
9789#[ cfg( feature = "transport-io" ) ]
98- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-io" ) ) ) ]
9990pub mod io;
10091#[ cfg( feature = "transport-io" ) ]
101- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-io" ) ) ) ]
10292pub use io:: stdio;
10393
10494#[ cfg( feature = "auth" ) ]
105- #[ cfg_attr( docsrs, doc( cfg( feature = "auth" ) ) ) ]
10695pub mod auth;
10796#[ cfg( feature = "auth" ) ]
108- #[ cfg_attr( docsrs, doc( cfg( feature = "auth" ) ) ) ]
10997pub use auth:: {
11098 AuthClient , AuthError , AuthorizationManager , AuthorizationSession , AuthorizedHttpClient ,
11199 CredentialStore , InMemoryCredentialStore , InMemoryStateStore , ScopeUpgradeConfig , StateStore ,
112100 StoredAuthorizationState , StoredCredentials , WWWAuthenticateParams ,
113101} ;
114102
115103// #[cfg(feature = "transport-ws")]
116- // #[cfg_attr(docsrs, doc(cfg(feature = "transport-ws")))]
117104// pub mod ws;
118105#[ cfg( feature = "transport-streamable-http-server-session" ) ]
119- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-streamable-http-server-session" ) ) ) ]
120106pub mod streamable_http_server;
121107#[ cfg( feature = "transport-streamable-http-server" ) ]
122- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-streamable-http-server" ) ) ) ]
123108pub use streamable_http_server:: tower:: { StreamableHttpServerConfig , StreamableHttpService } ;
124109
125110#[ cfg( feature = "transport-streamable-http-client" ) ]
126- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-streamable-http-client" ) ) ) ]
127111pub mod streamable_http_client;
128112#[ cfg( feature = "transport-streamable-http-client" ) ]
129- #[ cfg_attr( docsrs, doc( cfg( feature = "transport-streamable-http-client" ) ) ) ]
130113pub use streamable_http_client:: StreamableHttpClientTransport ;
131114
132115/// Common use codes
0 commit comments