| Crates.io | personio-rs |
| lib.rs | personio-rs |
| version | 0.1.1 |
| created_at | 2025-02-13 00:45:29.437241+00 |
| updated_at | 2025-02-13 01:23:09.987247+00 |
| description | Async Rust client for the Personio HR management system. |
| homepage | |
| repository | |
| max_upload_size | |
| id | 1553650 |
| size | 49,900 |
Async Rust client for Personio backed by tokio.
Add this to your Cargo.toml:
[dependencies]
personio-rs = "0.1.0"
tokio = { version = "1.0", features = ["full"] }
To get auth token:
use personio_rs::client::Client;
use std::env;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
println!("Authenticating...");
let client_id = env::var("CLIENT_ID")?;
let client_secret = env::var("CLIENT_SECRET")?;
let client = Client::new("MY_COMPANY", "MY_APP")?;
let creds = client.auth(&client_id, &client_secret).await?;
println!("{creds}");
Ok(())
}