openapi-rust-sdk
openapi-rust-sdk copied to clipboard
Openapi SDK not working with tokio runtime in existing CLI
My CLI project uses:
#[tokio::main]
async fn main() {
let sdk = openapi_sdk::Client::new("API_KEY");
sdk.get_products().await.unwrap();
}
Sometimes I get Runtime already running errors when calling from subcommands. How to properly integrate the SDK into existing tokio apps?