| Crates.io | account |
| lib.rs | account |
| version | 0.1.1-beta1 |
| created_at | 2024-01-28 08:38:56.381355+00 |
| updated_at | 2024-01-28 08:38:56.381355+00 |
| description | Provides a simple tool library for managing web3 accounts.It provides a set of APIs for account management, including account creation, account import, account export, account deletion, account balance query, account transfer, etc. |
| homepage | |
| repository | |
| max_upload_size | |
| id | 1117404 |
| size | 35,038 |
Account
Provides a simple tool library for managing web3 accounts. It provides a set of APIs for account management, including account creation, account import, account export, account deletion, account balance query, account transfer, etc.
use account::account::Account;
fn main() {
// create account
let password = None;
let account = Account::new(password);
// using a child path to sign and verify
let child_path = "m/44'/0'/0'/0/0'";
// sign and verify
let example_msg = b"Hello, world!";
let sign_message = account.sign(child_path, example_msg);
account.verify(child_path, example_msg, &sign_message.unwrap());
}