Connecting to the Wallet
Connect Wallet
This function is designed to initiate the connection process to a user's Bitcoin wallet. It leverages the Sats Connect getAddress API to request a user's payment address (native segwit) and ordinals/runes address (taproot).
It makes use of the getBtcProvider
method we defined in Detecting the Provider.
The getAddresss
method returns a Promise that resolves if the user approves the connection request.
Once resolved, the method returns an array of the user’s wallet address objects, defined as:
Where:
address field | Description |
---|---|
| The user’s connected address |
| A hex string representing the bytes of the public key of the account. |
| The purpose of the address:
|
Last updated