| Crates.io | federated-auth-realm-sdk-rust |
| lib.rs | federated-auth-realm-sdk-rust |
| version | 0.4.12 |
| created_at | 2026-01-09 05:56:10.036097+00 |
| updated_at | 2026-01-24 15:32:49.836851+00 |
| description | Federated Auth Realm Rust SDK for authentication and token management. |
| homepage | |
| repository | https://github.com/savant-realms/federated-auth-realm-sdk-rust |
| max_upload_size | |
| id | 2031644 |
| size | 46,130 |
A comprehensive Rust SDK for Federated Auth Realm, providing authentication, token management, and basic API calls.
├── Cargo.toml # Package manifest
├── src
│ ├── lib.rs # Library entry point
│ └── client.rs # Auth client implementation
├── tests
│ └── client_tests.rs # Unit tests
├── example
│ └── main.rs # Usage example
cargo build
cargo test
cargo fmt --all
cargo clippy --all-targets --all-features -- -D warnings
use federated_auth_realm_sdk::AuthClient;
#[tokio::main]
async fn main() {
let client = AuthClient::new("https://api.example.com");
match client.login("user", "pass").await {
Ok(token) => println!("Access token: {}", token.access_token),
Err(e) => eprintln!("Login failed: {}", e),
}
}
## Publishing to crates.io
To publish the package, ensure you have a valid `.env` file with your `CARGO_REGISTRY_TOKEN`.
Run:
If you want to publish with a dirty working directory (not recommended), use:
./scripts/deploy.sh --allow-dirty
This will pass the --allow-dirty flag to cargo publish.
cargo fmt --allcargo clippy --all-targets --all-features -- -D warningscargo testMIT