4 releases
new 0.1.3 | Apr 17, 2025 |
---|---|
0.1.2 | Apr 17, 2025 |
0.1.1 | Apr 17, 2025 |
0.1.0 | Apr 15, 2025 |
#608 in Magic Beans
286 downloads per month
545KB
2.5K
SLoC
ICRC3 Library
A comprehensive implementation of the ICRC3 standard for Internet Computer canisters. This library provides a standardized interface for managing transactions and blocks in a blockchain system.
Features
- Transaction management and validation
- Blockchain operations
- Archive management
- Data certification
- Configurable throttling and purging
Quick Start
use icrc3_library::{ICRC3, ICRC3Config};
// Create a new ICRC3 instance
let config = ICRC3Config::default();
let mut icrc3 = ICRC3::new(config);
// Add a transaction
let result = icrc3.add_transaction(transaction).await;
// Get blocks
let blocks = icrc3.icrc3_get_blocks(args).await;
Modules
blockchain
: Core blockchain implementationconfig
: Configuration managementicrc3
: Main ICRC3 implementationinterface
: Public interfacestransaction
: Transaction handlingtypes
: Custom typesutils
: Utility functions
Security
The library implements several security measures:
- Transaction validation
- Duplicate protection
- DOS protection through throttling
- Data certification
Dependencies
icrc_ledger_types
candid
serde_bytes
bity_ic_subcanister_manager
Dependencies
~9–17MB
~238K SLoC