Create a BTC Mainnet Wallet on SUBTC
To send and receive real BTC on SUBTC, you need to create a mainnet wallet.
Command:
RESP=$(curl -sS -X POST "https://api.subtc.net/v1/btc?mode=wallet_create" \
-H "X-SUBTC-KEY: $KEY" \
-H "Content-Type: application/json" \
-d '{"net":"main"}')
Extract the wallet ID:
WID=$(echo "$RESP" | sed -n 's/.*"wallet_id":"\([^"]*\)".*/\1/p')
Print the wallet ID:
echo "WID=$WID"
Example output:
WID=w_87d2a561cdd665948c1d756106f7b2179327927c3b8c
What happened:
A new BTC mainnet wallet was created and linked to your SUBTC API key.
This wallet can now be used for real Bitcoin transactions.
API Base:
https://subtc.net/api