GOAT Network

GOAT BitVM2 Testnet User Guide

GOAT BitVM2 Testnet enables trust-minimized BTC interoperability between Bitcoin and GOAT Network. Access the current testnet UI at bitvm2-testnet4.goat.network.

BitVM2 is a permissionless bridge design that combines presigned transactions, one-time signatures, and SNARK-based dispute resolution. GOAT BitVM2 extends the base model with faster reimbursement and stronger operator-accountability mechanisms.

This page documents the active GOAT BitVM2 testnet flows. References to GOAT testnet iterations such as "Testnet V3" refer to the testnet release cycle, not to BitVM3 as the active bridge version.

What This Guide Covers

AreaAudience
Bridge in / bridge outEnd users moving BTC between Bitcoin and GOAT Network
Peg-outOperators participating in the protocol
Graph statesUsers or operators monitoring dispute paths
Node setupOperators, challengers, and watchtowers

BitVM2 Bridge Guide

BitVM2 Bridge is the user-facing entry point for moving BTC through the BitVM2 flow.

Bridge In

BitVM2 bridge-in screen

Connect both wallets

Connect your BTC wallet and your EVM wallet first.

Choose the amount and Bitcoin fee rate

The Bitcoin fee rate affects how quickly the source transaction confirms.

Wait for committee verification

Move to the next step, then refresh the status until the transaction becomes ready to submit.

Submit and sign

Click Submit, confirm the transaction in your wallet, and pay the required base fee.

Track confirmation

The transfer typically arrives in about 60 minutes, but Bitcoin congestion can extend the timeline.

Bridge Out

BitVM2 bridge-out screen

Connect the EVM and BTC wallets

Make sure the receiving BTC wallet is the one you intend to use for withdrawal.

Enter the amount

Confirm that it satisfies the minimum amount shown in the UI.

Review the transfer details

Double-check the amount, exchange rate, and bridge fee before continuing.

Submit within the valid window

Confirm the transaction in the wallet and pay the GOAT Network gas fee.

Monitor the arrival

Use the history page to follow progress until the BTC lands in the receiving wallet.

History

Every bridge-in and bridge-out transfer appears in the history view for status tracking.

BitVM2 bridge history screen

BitVM2 Peg-out Guide

Peg-out is an operator-oriented flow that redeems PegBTC back to native BTC.

BitVM2 peg-out screen

Connect the EVM wallet

The UI automatically shows the peg-out instances available to the connected operator.

Approve PegBTC

Click Approve and approve the maximum amount you intend to use for the operation.

Submit the peg-out

Return to the UI, click Submit, sign the transaction, and pay the gas fee.

Track the graph

Use BitVM2 Graph and peg-out history to follow reimbursement progress and dispute state.

Verify settlement

When the peg-out completes successfully, the BTC appears in the destination wallet.

BitVM2 Graph States

The BitVM2 graph explains how deposits, challenges, and reimbursements evolve on-chain.

BitVM2 graph overview

CaseStatusMeaning
Initial statePending peg-out / active depositsFunds are locked and no operator has started reimbursement yet
Standard pathWithdrawal completed (Take-1)No valid challenge was raised during the first time-lock
Challenge succeedsWithdrawal intercepted (Disprove)Operator misconduct was proven and collateral was slashed
Challenge failsWithdrawal finalized (Take-2)Operator defended the withdrawal and completed reimbursement

Join GOAT BitVM2 Testnet

Role Requirements

RoleRequirements
WatchtowerCommittee-approved role, enough L1 balance for roughly 4,000 sats per challenge
VerifierPermissionless role, enough balance for bond and transaction fees
OperatorPermissionless role, must prepay graph fees on L1 and stake PBTC on L2

Operator funding and staking requirements

LayerRequirement
Bitcoin L1Prepay roughly 10,000 sats per graph and keep at least 50,000 sats available at startup
GOAT Network L2Stake WGBTC; the effective minimum locked stake is 0.06 WGBTC

Staking flow

Operator staking flow
stakeManagement.registerPubkey(xonlyPubkey);
WGBTC.approve(stakeManagementAddress, amount);
stakeManagement.stake(amount);
stakeManagement.lockStake(amount);

A compressed public key is 33 bytes and usually starts with 02 or 03. The x-only public key is the 32-byte suffix after removing that prefix.

Run a BitVM2 Node

RoleCPURAMDisk
Operator / Verifier32 vCPU64 GiB500 GB

Installation

Ensure the ZKM toolchain is installed. See ProjectZKM/toolchain, then confirm ~/.zkm-toolchain/env exists.

Install from source
source ~/.zkm-toolchain/env
cargo install --git https://github.com/GOATNetwork/bitvm2-node bitvm-noded

Download a release from bitvm-noded releases and verify the version after installation.

After the installation, run the bitvm-noded --version to check that the version should be 0.4.0.

$ bitvm-noded --version
bitvm-noded 0.4.0

Generate Peer Key

Generate one peer key per node:

$ bitvm-noded key peer
PEER_KEY=
PEER_ID=

Use PEER_KEY in the node .env.

Prepare GC Artifacts

Operator and Verifier nodes must have the GC artifacts on disk before running C&C. Point the runtime to those files with:

FGC_GATES_PATH=
FGC_OUT_INDICES_PATH=
SGC_GATES_PATH=
SGC_OUT_INDICES_PATH=
FGC_COMPACT_GATES_PATH=
FGC_COMPACT_OUT_INDICES_PATH=
SGC_COMPACT_GATES_PATH=
SGC_COMPACT_OUT_INDICES_PATH=

Funding Address

Set BITVM_SECRET to your hex-format private key, then deposit tBTC4 (Bitcoin Testnet4) to the generated P2WSH address:

$ bitvm-noded key funding-address
Funding P2WSH address (for operator and verifier): tb1q...

Operator Node Deployment

Create an Operator .env:

RUST_LOG=info
ACTOR=Operator

BTC_CHAIN_URL=https://mempool.space/testnet4/api
GOAT_PROOF_BUILD_URL=http://16.146.8.146:8900

GOAT_GATEWAY_CONTRACT_ADDRESS=
GOAT_GATEWAY_EVENT_THE_GRAPH_URL=
GOAT_GATEWAY_EVENT_FILTER_FROM=
GOAT_SWAP_CONTRACT_ADDRESS=0x3FbbA0eb82cf1247cbf92B3D51641226310F0Ca5
GOAT_SWAP_EVENT_THE_GRAPH_URL=https://graph.goat.network/subgraphs/name/bitvm2_escrow_manager_0x3Fbb
GOAT_SWAP_EVENT_FILTER_FROM=14587962

GOAT_CHAIN_URL=https://rpc.testnet3.goat.network
PEER_KEY=
BITVM_SECRET=
GOAT_ADDRESS=
PROTO_NAME=bitvm2t4
BOOTNODES=/ip4/16.146.8.146/tcp/8445/p2p/12D3KooWCrPTAmhFdC5DBGgkxZvJi6iuSeiDWKRL87isrt4iMHXv

SOLDERING_PROOF_PAYLOAD_STORE_PATH=

OPERATOR_VK_HASH=0x00d9cbe73ff862786141fb11376884c0052ae94631ad97bfc892e01680d623fe
OPERATOR_ZKM_VERSION=v1.2.5
GENESIS_SEQUENCER_COMMIT_TXID=9c730b76ee4793248a3b1e605745f0c102207f60eb5023850e3e121c5f539303

CAC_BATCH_SIZE=100

FGC_GATES_PATH=
FGC_OUT_INDICES_PATH=
SGC_GATES_PATH=
SGC_OUT_INDICES_PATH=
FGC_COMPACT_GATES_PATH=
FGC_COMPACT_OUT_INDICES_PATH=
SGC_COMPACT_GATES_PATH=
SGC_COMPACT_OUT_INDICES_PATH=

Start the Operator:

./bitvm-noded \
  --rpc-addr 0.0.0.0:8901 \
  --p2p-port 8445 \
  --db-path sqlite:./operator.db \
  --bootnodes /ip4/16.146.8.146/tcp/8445/p2p/12D3KooWCrPTAmhFdC5DBGgkxZvJi6iuSeiDWKRL87isrt4iMHXv

Verifier Node Deployment

Create a Verifier .env:

RUST_LOG=info
ACTOR=Verifier

BITCOIN_NETWORK=testnet4
BTC_CHAIN_URL=https://mempool.space/testnet4/api

GOAT_GATEWAY_CONTRACT_ADDRESS=
GOAT_GATEWAY_EVENT_THE_GRAPH_URL=
GOAT_GATEWAY_EVENT_FILTER_FROM=
GOAT_SWAP_CONTRACT_ADDRESS=0x3FbbA0eb82cf1247cbf92B3D51641226310F0Ca5
GOAT_SWAP_EVENT_THE_GRAPH_URL=https://graph.goat.network/subgraphs/name/bitvm2_escrow_manager_0x3Fbb
GOAT_SWAP_EVENT_FILTER_FROM=14587962

GOAT_CHAIN_URL=https://rpc.testnet3.goat.network
GOAT_ADDRESS=
PEER_KEY=
BITVM_SECRET=
PROTO_NAME=bitvm2t4
BOOTNODES=/ip4/16.146.8.146/tcp/8445/p2p/12D3KooWCrPTAmhFdC5DBGgkxZvJi6iuSeiDWKRL87isrt4iMHXv

OPERATOR_VK_HASH=0x00d9cbe73ff862786141fb11376884c0052ae94631ad97bfc892e01680d623fe
OPERATOR_ZKM_VERSION=v1.2.5
GENESIS_SEQUENCER_COMMIT_TXID=9c730b76ee4793248a3b1e605745f0c102207f60eb5023850e3e121c5f539303

SOLDERING_PROOF_PAYLOAD_STORE_PATH=
CAC_BATCH_SIZE=100

FGC_GATES_PATH=
FGC_OUT_INDICES_PATH=
SGC_GATES_PATH=
SGC_OUT_INDICES_PATH=
FGC_COMPACT_GATES_PATH=
FGC_COMPACT_OUT_INDICES_PATH=
SGC_COMPACT_GATES_PATH=
SGC_COMPACT_OUT_INDICES_PATH=

Start the Verifier:

./bitvm-noded \
  --rpc-addr 0.0.0.0:8902 \
  --p2p-port 8446 \
  --db-path sqlite:./verifier.db \
  --bootnodes /ip4/16.146.8.146/tcp/8445/p2p/12D3KooWCrPTAmhFdC5DBGgkxZvJi6iuSeiDWKRL87isrt4iMHXv

Operate with Agent Skills

If you prefer an agent-driven workflow, the BitVM2 node repository also publishes operation documents for common tasks.

Agent skillPurposeCommand document
/run-operator-nodeStart an operator noderun-operator-node.md
/pegin-requestRequest, prepare, or cancel a peg-inpegin-request.md
/pegoutInitiate peg-out as an operatorpegout.md
/bridge-outInitiate bridge-out flowbridge-out.md
/challengeBroadcast a challenge transactionchallenge.md

On this page