Add API calls and their infrastructure
- Add dependencies - Add authentification (email, password) - Add token request - Fetch /self - Fetch /conversations - Add infrastructure for above - Add auth example
This commit is contained in:
1 parent
3c21cf6f4a
commit
3ee205e6bc
12 files changed
+355
-106
No files matched your search
@@ -0,0 +1,17 @@
|
||||
use irssi_wire::net::wire_api::auth::*;
|
||||
use irssi_wire::net::wire_api::conversations::*;
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() -> Result<(), Box<dyn std::error::Error>> {
|
||||
let mut client = WireClient::new(
|
||||
String::from("marco_thomas@genua.de"),
|
||||
String::from("MarcMK1337#"),
|
||||
Config::Default,
|
||||
);
|
||||
|
||||
let auth_response = client.authentification().await.unwrap();
|
||||
|
||||
let conversations = client.fetch_conversations(&auth_response).await.unwrap();
|
||||
|
||||
Ok(())
|
||||
}
|
||||
Reference in new issue
Block a user