1
2
Fork 0
mirror of https://github.com/mat-1/azalea.git synced 2025-08-02 06:16:04 +00:00
azalea/azalea-auth/examples/auth.rs
2022-10-27 21:22:47 -05:00

19 lines
399 B
Rust

use std::path::PathBuf;
#[tokio::main]
async fn main() {
env_logger::init();
let cache_file = PathBuf::from("example_cache.json");
let auth_result = azalea_auth::auth(
"example@example.com",
azalea_auth::AuthOpts {
cache_file: Some(cache_file),
..Default::default()
},
)
.await
.unwrap();
println!("{auth_result:?}");
}