Sigma Rust
Rust implementation of ErgoScript (sigmastate-interpreter) cryptocurrency scripting language.
Crates
- ergo-lib – crates.io | docs
Overarching crate exposing wallet-related features: chain types (transactions, boxes, etc.), JSON serialization, box selection for tx inputs, tx builder and signing. Exports other crates API, probably the only crate you'd need to import. - ergotree-interpreter – crates.io | docs
ErgoTree interpreter - ergotree-ir – crates.io | docs
ErgoTree IR and serialization. - ergoscript-compiler – crates.io | docs
ErgoScript compiler. - sigma-ser – crates.io | docs
Ergo binary serialization primitives.
Bindings
This section lists available language bindings for sigma-rust, allowing developers to interact with the Ergo blockchain using various programming languages.
- Wasm: ergo-lib-wasm – crates.io | docs
- JavaScript / TypeScript: ergo-lib-wasm-browser (browser), ergo-lib-wasm-nodejs (Node.js)
- Swift (iOS): ergo-lib-ios
- Java / JVM: ergo-lib-jni – crates.io | docs
- C: ergo-lib-c – crates.io | docs
- Go: ergo-lib-go – Go Reference (Community maintained)
- Ruby: sigma_rb – Gem Version (Community maintained)
- Python: ergo-lib-python – PyPI | docs (Uses ergo-lib crate docs)
Usage Examples
To get better understanding on how to use it in your project check out how its being used in the following projects:
Rust
- Oracle Core
- Ergo Headless dApp Framework
- Ergo Node Interface Library
- Spectrum Off-Chain Services for Ergo
- AgeUSD Stablecoin Protocol
- ErgoNames SDKs
TS/JS
- Ergo SDK (Wasm bindings)
- Yoroi wallet (Wasm bindings)
- Ergo Desktop Wallet (Wasm bindings)
Examples
Also take a look at tests where various usage scenarios were implemented.