@matsutake/wallets
TypeScript icon, indicating that this package has built-in type declarations

1.1.1 • Public • Published

Matsutake Wallets

Example wallets using the matsutake.io Chia defi application development framework.

import { PasswordLockedCoin } from '@matsutake/wallets/browser'; // Web browser compatible import

const passwordLockedCoinWallet = new PasswordLockedCoin('foobar');

// Generate an address that receives password locked coins
const address = passwordLockedCoinWallet.getAddress(); // xch1sgput8rxzuvkh0t7g8aq8te92x9kqhrqexunl70fj5v2j2g3kkmscnmcqh

// Spend a password locked coin
const passwordLockedCoin = {
    parent_coin_info: '0xffff',
    amount: 1000000,
    puzzle_hash: '0x8203c59c6617196bbd7e41fa03af25518b605c60c9b93ff9e99518a92911b5b7'
};
await wallet.spendCoin(passwordLockedCoin, 'xch1f0ryxk6qn096hefcwrdwpuph2hm24w69jnzezhkfswk0z2jar7aq5zzpfj')

Please enjoy!

/@matsutake/wallets/

    Package Sidebar

    Install

    npm i @matsutake/wallets

    Weekly Downloads

    7

    Version

    1.1.1

    License

    ISC

    Unpacked Size

    23.2 kB

    Total Files

    28

    Last publish

    Collaborators

    • taro199