Expand description
This crate contains the logic to read B2 credentials following the same logic used by the B2 CLI.
let creds = b2creds::Credentials::locate().unwrap();
println!("Key ID: {} Key: {}", creds.application_key_id, creds.application_key);Look at the Credentials::locate, Credentials::from_env. and
Credentials::from_file to understand how to parse B2 credentials.
Structs§
- Credentials
- Holds the application key id and application key which make up your credentials
Enums§
- Credentials
Error - Error enum for crate functions. Used for all
Resultreturns as the error enum.
Functions§
- default_
creds_ file - Returns the default credentials file path.