(
State(_state): State<Arc<ServerState>>,
Path(name): Path<String>,
)
| 2641 | } |
| 2642 | |
| 2643 | async fn connect_mcp( |
| 2644 | State(_state): State<Arc<ServerState>>, |
| 2645 | Path(name): Path<String>, |
| 2646 | ) -> Result<Json<bool>> { |
| 2647 | let manager = get_mcp_oauth_manager(); |
| 2648 | ensure_mcp_server_registered(manager, &name).await?; |
| 2649 | manager |
| 2650 | .connect(&name) |
| 2651 | .await |
| 2652 | .map_err(mcp_error_to_api_error)?; |
| 2653 | Ok(Json(true)) |
| 2654 | } |
| 2655 | |
| 2656 | async fn disconnect_mcp( |
| 2657 | State(_state): State<Arc<ServerState>>, |
nothing calls this directly
no test coverage detected