Skip to content

Latest commit

 

History

History

minimal-ecash-wallet

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

minimal-ecash-wallet

minimal-ecash-wallet is a minimalist eCash (XEC) wallet 'engine' for use with both front end web apps and back end APIs. It contains all the core functionality needed by a wallet:

  • Create a new XEC wallet, import a mnemonic, or import a private key (WIF)
  • Encrypt a wallets mnemonic for safe storage
  • Send and receive eCash
  • Send and receive eTokens
  • Get balances and UTXOs
  • Retrieve transaction history & transaction details
  • Burn tokens
  • Price XEC in USD
  • Send messages on the blockchain via OP_RETURN data
  • Verify that a UTXO is unspent
  • Get token icons and other media associated with a token

It is 'token aware' and can work with all eTokens, including NFTs. It can interface with Web 2 infrastructure like FullStack.cash or with the Web 3 Cash Stack infrastructure.

Running Examples

You can run each example script by entering its directory and running the JavaScript file with node.js. Example: if the file is named create-wallet.js, run it with this command: node create-wallet.js

If you need to install node.js on your linux system, here are the commands.

If you are trying to start from the first time, here is the recommended path to take when running examples:

  • create-wallet to create a wallet. Send it a few cents of XEC to enable the other examples.
  • get-balance to show the balance of the XEC in the wallet you just created and funded.
  • send-ecash makes an on-chain transaction by sending XEC from the wallet you created in the first example, back to itself. It generates a TXID that you can browse in a block explorer.