tbtc.js
provides JS bindings to the tBTC system. The
tBTC system provides a method for locking up BTC in many
single-use BTC wallets to enable their corresponding usage on the Ethereum
chain, primarily through the minting of a TBTC ERC20 token whose supply is
guaranteed to be backed by at least 1 BTC per TBTC in circulation.
For now, see example.js for usage. Note that currently the example is not fully
functional. All tBTC contracts (in @truffle/contract
form) are exposed
through the wrappers for the system; deposits expose their per-deposit contract
at deposit.contract
, while the DepositFactory
exposes all system contracts
at DepositFactory.systemContract
, Deposit.tokenContract
,
DepositFactory.depositTokenContract
, Deposit.feeRebateTokenContract
,
DepositFactory.factoryTokenContract
, and Deposit.vendingMachineContract
.