archethic_lib_dart library

Package archEthic aims to provide a easy way to create ArchEthic transaction and to send them over the network.

This implementation is based on Official ArchEthic Javascript library for Node and Browser.

Classes

AddressService
AesAuthEncryptInfos
ApiCoinsService
ApiService
AuthorizedKey
AuthorizedKey represents list of public keys with the encrypted secret for this given key. By decrypting this secret keys, the authorized public keys will be able to decrypt the secret
Balance
Balance represents a ledger balance.
CoinsCodeAdditionsDeletions4Weeks
CoinsCommunityData
CoinsCurrentCodeAdditionsDeletions4Weeks
CoinsCurrentCommunityData
CoinsCurrentDataResponse
CoinsCurrentDeveloperData
CoinsCurrentImage
CoinsCurrentLinksReposUrl
CoinsCurrentMarketData
CoinsCurrentMarketFullyDilutedValuation
CoinsCurrentPublicInterestStats
CoinsCurrentTicker
CoinsCurrentTickerMarket
CoinsCurrentTion
CoinsDeveloperData
CoinsImage
CoinsLinksReposUrl
CoinsMarketData
CoinsMarketFullyDilutedValuation
CoinsPriceResponse
CoinsPublicInterestStats
CoinsResponse
CoinsTicker
CoinsTickerMarket
CoinsTion
CrossValidationStamp
CrossValidationStamp represents the approval of the validation stamp by a cross validation node.
Data
TransactionData represents the data section for every transaction.
Error
Errors
KeyPair
Holds a key pair (private and public key)
Keys
Keys represents a block to set secret and authorized public keys able to read the secret
Ledger
Ledger represents the ledger operations to perform
LedgerOperations
LedgerOperations represents the ledger operations performed by the transaction.
Location
Location of an error
NftBalance
NftBalance represents a NFT ledger balance.
NFTLedger
NFTLedger represents the transfers to perform on the NFT ledger
NFTService
NFTTransfer
NFTTransfer represents the an asset transfer
Node
NodeMovement
NodeMovement represents node transaction movement
Platforms
Secret
SharedSecrets
SharedSecrets represents the public shared secret information
SimplePriceResponse
Transaction
Transaction represents a unitary transaction in the ArchEthic network.
TransactionInput
TransactionInput represents the inputs from the transaction.
TransactionMovement
TransactionMovement represents ledger transaction movement.
TransactionStatus
UCOLedger
UCOLedger represents the transfers to perform on the UCO ledger
UCOTransfer
UCOTransfer represents the an asset transfer
UnspentOutputs
UnspentOutput represents the remaining unspent output of the transaction.
ValidationStamp
ValidationStamp represents the validation performs by the coordinator

Constants

cVersion → const int
txTypes → const Map<String, int>

Functions

aesAuthDecrypt(Uint8List encrypted, Uint8List aesKey, Uint8List iv, Uint8List tag) Uint8List
aesAuthEncrypt(Uint8List data, Uint8List aesKey, Uint8List iv) AesAuthEncryptInfos
aesDecrypt(dynamic cipherText, dynamic key) Uint8List
aesEncrypt(dynamic data, dynamic key) Uint8List
Encrypt a data for a given public key using AES algorithm @param {String | Uint8List} data Data to encrypt @param {String | Uint8List} key Symmetric key
coinsCurrentDataResponseFromJson(String str) CoinsCurrentDataResponse
coinsCurrentDataResponseToJson(CoinsCurrentDataResponse data) String
coinsPriceResponseFromJson(String str) CoinsPriceResponse
coinsPriceResponseToJson(CoinsPriceResponse data) String
coinsResponseFromJson(String str) CoinsResponse
coinsResponseToJson(CoinsResponse data) String
concatUint8List(Iterable<Uint8List> list) Uint8List
Concat a list of Uint8List @param {Array} arrays Uint8List
decodeBigInt(Uint8List bytes) BigInt
Decode a BigInt from bytes in big-endian encoding. @param {Uint8List} Uint8List to decode
deriveKeyPair(String seed, int index, {String curve = 'P256'}) KeyPair
Generate a keypair using a derivation function with a seed and an index. Each keys is prepending with a curve identification. @param {String} seed Keypair derivation seed @param {int} index Number to identify the order of keys to generate @param {String} curve Elliptic curve to use (P256", "secp256k1", "ed25519")
derivePrivateKey(dynamic seed, int index) Uint8List
deriveSecret(dynamic sharedKey) Secret
ecDecrypt(dynamic cipherText, dynamic privateKey) Uint8List
Decrypt a ciphertext for a given private key using ECIES algorithm @param {String | Uint8List} ciphertext Ciphertext to decrypt @param {String | Uint8List} privateKey Private key for the shared secret encryption
ecEncrypt(dynamic data, dynamic publicKey) Uint8List
Encrypt a data for a given public key using ECIES algorithm @param {String | Uint8List} data Data to encrypt @param {String | Uint8List} publicKey Public key for the shared secret encryption
encodeBigInt(BigInt number) Uint8List
Encode a big integer into a Uint8List (8 bytes) @param {Number} number Number to encode
encodeFloat64(double number) Uint8List
Encode a float into a Uint8List (8 bytes) @param {Number} number Number to encode
encodeInt32(int number) Uint8List
Encode a integer into a Uint8List (4 bytes) @param {Number} number Number to encode
hash(dynamic content, {String algo = 'sha256'}) Uint8List
Create a hash digest from the data with an hash algorithm identification prepending the digest @param {String | Uint8List} content Data to hash (string or buffer) @param {String} algo Hash algorithm ("sha256", "sha512", "sha3-256", "sha3-512", "blake2b")
hexToUint8List(String hexString) Uint8List
Encode an hexadecimal string into a Uint8List @param {Uint8List} hexString Hexadecimal string
isHex(String inputString) bool
Determines if a string is an hexadecimal @param {String} inputString Potential hexadecimal string
sign(dynamic data, dynamic privateKey) Uint8List
Sign the data @param {String | Uint8List} data Data to sign @param {String | Uint8List} privateKey Private key to use to sign the data
transactionStatusFromJson(String str) TransactionStatus
transactionStatusToJson(TransactionStatus data) String
uint8ListToHex(Uint8List bytes) String
Encode an Uint8List into an hexadecimal string @param {Uint8List} bytes Uint8List
verify(dynamic sig, dynamic data, dynamic publicKey) bool