Create a New BTC Testnet Wallet
To start receiving and sending Bitcoin on the SUBTC testnet, you need to create a wallet linked to your API key.
Command:
RESP=$(curl -sS -X POST "https://api.subtc.net/v1/btc?mode=wallet_create" \<br>-H "X-SUBTC-KEY: $KEY" \<br>-H "Content-Type: application/json" \<br>-d '{"net":"test"}')
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_cf21a601a3f461a92699e5b5dac80ad6d9d66de4592d
What happened:
A new testnet wallet was created and linked to your SUBTC API key.<br>This wallet ID (WID) will be used for all future wallet operations.
API Base:<br>https://subtc.net/api