Skip to content

Commit

Permalink
Bitcoin deposit fees (#248)
Browse files Browse the repository at this point in the history
  • Loading branch information
fadeev authored Feb 22, 2024
1 parent c6c9300 commit 48338fb
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions docs/developers/tokens/zrc20.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,25 @@ correspond to a contract address on ZetaChain, the token will be deposited to
that contract and the `onCrossChainCall` function of that contract will be
called with the remaining input data as the `message`.

When depositing native gas tokens from EVM-based connected chains, there is no
additional cross-chain fee. If you send 1 token to a TSS address, you will
receive 1 ZRC-20 version of the same token on ZetaChain.

For Bitcoin deposits, which utilize the UTXO (Unspent Transaction Output) model,
the process incurs additional fees. Unlike EVM-based chains, each deposited
Bitcoin output incurs a fee when it is spent. To address this, both the
depositor and the withdrawer share the cost of the spend. This fee is charged in
advance as a deposit fee.

The Bitcoin deposit fee is calculated with the following formula:

$$
DepositFee = AverageFeeRateBlockX * GasPriceMultiplier * DepositIncurredVBytes
$$

Where `DepositIncurredVBytes` is fixed as `68vB` and the `GasPriceMultiplier`
defaults to 2 currently.

## Depositing Supported ERC-20 Tokens as ZRC-20

To deposit a supported ERC-20 token to ZetaChain, use the `deposit` method of
Expand Down

0 comments on commit 48338fb

Please sign in to comment.