# SingleAddressBitcoinWallet

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:19](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L19)

Bitcoin wallet implementation deriving a single address from a WIF encoded private key

## Extends

* [`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md)

## Constructors

### Constructor

```
new SingleAddressBitcoinWallet(

   mempoolApi, 

   _network, 

   addressDataOrWIF, 

   feeMultiplier, 

   feeOverride?): SingleAddressBitcoinWallet;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:26](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L26)

#### Parameters

| Parameter          | Type                                                                                                                                          | Default value |
| ------------------ | --------------------------------------------------------------------------------------------------------------------------------------------- | ------------- |
| `mempoolApi`       | [`BitcoinRpcWithAddressIndex`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/interfaces/BitcoinRpcWithAddressIndex.md)<`any`> | `undefined`   |
| `_network`         | `any`                                                                                                                                         | `undefined`   |
| `addressDataOrWIF` | \| `string` \| { `address`: `string`; `publicKey`: `string`; }                                                                                | `undefined`   |
| `feeMultiplier`    | `number`                                                                                                                                      | `1.25`        |
| `feeOverride?`     | `number`                                                                                                                                      | `undefined`   |

#### Returns

`SingleAddressBitcoinWallet`

#### Overrides

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`constructor`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#constructor)

## Properties

### address

```
protected readonly address: string;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:23](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L23)

***

### addressType

```
protected readonly addressType: CoinselectAddressTypes;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:24](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L24)

***

### feeMultiplier

```
protected feeMultiplier: number;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:75](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L75)

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`feeMultiplier`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#feemultiplier)

***

### feeOverride?

```
protected optional feeOverride: number;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:76](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L76)

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`feeOverride`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#feeoverride)

***

### network

```
protected readonly network: BTC_NETWORK;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:74](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L74)

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`network`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#network)

***

### privKey?

```
protected readonly optional privKey: Uint8Array;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:21](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L21)

***

### pubkey

```
protected readonly pubkey: Uint8Array;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:22](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L22)

***

### rpc

```
protected readonly rpc: BitcoinRpcWithAddressIndex<any>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:73](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L73)

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`rpc`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#rpc)

## Methods

### bitcoinNetworkToObject()

```
static bitcoinNetworkToObject(network): BTC_NETWORK;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:424](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L424)

#### Parameters

| Parameter | Type                                                                                                             |
| --------- | ---------------------------------------------------------------------------------------------------------------- |
| `network` | [`BitcoinNetwork`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/enumerations/BitcoinNetwork.md) |

#### Returns

`BTC_NETWORK`

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`bitcoinNetworkToObject`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#bitcoinnetworktoobject)

***

### fundPsbt()

```
fundPsbt(inputPsbt, feeRate?): Promise<Transaction>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:91](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L91)

Funds (populates the inputs) for a given PSBT from wallet's UTXO set

#### Parameters

| Parameter   | Type          | Description                                             |
| ----------- | ------------- | ------------------------------------------------------- |
| `inputPsbt` | `Transaction` | PSBT to add the inputs to                               |
| `feeRate?`  | `number`      | Optional fee rate in sats/vB to use for the transaction |

#### Returns

`Promise`<`Transaction`>

#### Overrides

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`fundPsbt`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#fundpsbt)

***

### generateRandomMnemonic()

```
static generateRandomMnemonic(): string;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:188](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L188)

Generates a random 12-word long mnemonic

#### Returns

`string`

***

### generateRandomPrivateKey()

```
static generateRandomPrivateKey(network?): string;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:166](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L166)

Generates a new random private key WIF that can be used to instantiate the bitcoin wallet instance

#### Parameters

| Parameter  | Type  |
| ---------- | ----- |
| `network?` | `any` |

#### Returns

`string`

A WIF encoded bitcoin private key

***

### getBalance()

```
getBalance(): Promise<{

  confirmedBalance: bigint;

  unconfirmedBalance: bigint;

}>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:143](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L143)

Returns confirmed and unconfirmed balance in satoshis of the wallet

#### Returns

`Promise`<{ `confirmedBalance`: `bigint`; `unconfirmedBalance`: `bigint`; }>

#### Overrides

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`getBalance`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#getbalance)

***

### getFeeRate()

```
getFeeRate(): Promise<number>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:92](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L92)

Returns the current fee rate in sats/vB

#### Returns

`Promise`<`number`>

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`getFeeRate`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#getfeerate)

***

### getFundedPsbtFee()

```
getFundedPsbtFee(basePsbt, feeRate?): Promise<number>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:121](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L121)

Estimates a total fee in satoshis for a given transaction as identified by the PSBT

#### Parameters

| Parameter  | Type          | Description                                                                              |
| ---------- | ------------- | ---------------------------------------------------------------------------------------- |
| `basePsbt` | `Transaction` | A PSBT to which additional inputs from wallet's UTXO set will be added and fee estimated |
| `feeRate?` | `number`      | Optional fee rate in sats/vB to use for the transaction                                  |

#### Returns

`Promise`<`number`>

#### Overrides

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`getFundedPsbtFee`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#getfundedpsbtfee)

***

### getPublicKey()

```
getPublicKey(): string;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:136](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L136)

Returns the public key of the wallet

#### Returns

`string`

***

### getReceiveAddress()

```
getReceiveAddress(): string;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:129](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L129)

Returns the bitcoin address suitable for receiving funds

#### Returns

`string`

#### Overrides

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`getReceiveAddress`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#getreceiveaddress)

***

### getSpendableBalance()

```
getSpendableBalance(psbt?, feeRate?): Promise<{

  balance: bigint;

  feeRate: number;

  totalFee: number;

}>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:153](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L153)

Returns the maximum spendable balance in satoshis given a specific PSBT that should be funded

#### Parameters

| Parameter  | Type          | Description                                                                              |
| ---------- | ------------- | ---------------------------------------------------------------------------------------- |
| `psbt?`    | `Transaction` | A PSBT to which additional inputs from wallet's UTXO set will be added and fee estimated |
| `feeRate?` | `number`      | Optional fee rate in sats/vB to use for the transaction                                  |

#### Returns

`Promise`<{ `balance`: `bigint`; `feeRate`: `number`; `totalFee`: `number`; }>

#### Overrides

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`getSpendableBalance`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#getspendablebalance)

***

### getTransactionFee()

```
getTransactionFee(

   address, 

   amount, 

feeRate?): Promise<number>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:113](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L113)

Estimates a total fee in satoshis for a given transaction

#### Parameters

| Parameter  | Type     | Description                                             |
| ---------- | -------- | ------------------------------------------------------- |
| `address`  | `string` | Destination address of the transaction                  |
| `amount`   | `bigint` | Amount of satoshis to send (1 BTC = 100,000,000 sats)   |
| `feeRate?` | `number` | Optional fee rate in sats/vB to use for the transaction |

#### Returns

`Promise`<`number`>

#### Overrides

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`getTransactionFee`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#gettransactionfee)

***

### mnemonicFromEntropy()

```
static mnemonicFromEntropy(entropy): string;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:179](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L179)

Generates a 12-word long mnemonic from any entropy source with 128-bits or more, the entropy is first hashed using sha256, and the first 16 bytes of the hash are used to generate the mnemonic

#### Parameters

| Parameter | Type     | Description                                |
| --------- | -------- | ------------------------------------------ |
| `entropy` | `Buffer` | Entropy to use for generating the mnemonic |

#### Returns

`string`

***

### mnemonicToPrivateKey()

```
static mnemonicToPrivateKey(

   mnemonic, 

   network?, 

derivationPath?): Promise<string>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:199](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L199)

Generates a WIF private key from mnemonic phrase

#### Parameters

| Parameter         | Type     | Description                                                    |
| ----------------- | -------- | -------------------------------------------------------------- |
| `mnemonic`        | `string` | Mnemonic to generate the WIF key from                          |
| `network?`        | `any`    | Optional bitcoin network to generate the WIF for               |
| `derivationPath?` | `string` | Optional custom derivation path to use for deriving the wallet |

#### Returns

`Promise`<`string`>

***

### sendTransaction()

```
sendTransaction(

   address, 

   amount, 

feeRate?): Promise<string>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:78](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L78)

Signs and broadcasts a transaction sending `amount` of sats to `address`, optionally with the `feeRate` sats/vB fee rate.

#### Parameters

| Parameter  | Type     | Description                                             |
| ---------- | -------- | ------------------------------------------------------- |
| `address`  | `string` | Destination address of the transaction                  |
| `amount`   | `bigint` | Amount of satoshis to send (1 BTC = 100,000,000 sats)   |
| `feeRate?` | `number` | Optional fee rate in sats/vB to use for the transaction |

#### Returns

`Promise`<`string`>

#### Overrides

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`sendTransaction`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#sendtransaction)

***

### signPsbt()

```
signPsbt(psbt, signInputs): Promise<Transaction>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:102](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L102)

Signs inputs in the provided PSBT

#### Parameters

| Parameter    | Type          | Description                   |
| ------------ | ------------- | ----------------------------- |
| `psbt`       | `Transaction` | A PSBT to sign                |
| `signInputs` | `number`\[]   | Indices of the inputs to sign |

#### Returns

`Promise`<`Transaction`>

#### Overrides

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`signPsbt`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#signpsbt)

***

### \_fundPsbt()

```
protected _fundPsbt(

   sendingAccounts, 

   psbt, 

   feeRate?): Promise<{

  fee: number;

  inputAddressIndexes?: {

   [address: string]: number[];

  };

  psbt?: Transaction;

}>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:196](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L196)

#### Parameters

| Parameter         | Type          |
| ----------------- | ------------- |
| `sendingAccounts` | `object`\[]   |
| `psbt`            | `Transaction` |
| `feeRate?`        | `number`      |

#### Returns

`Promise`<{ `fee`: `number`; `inputAddressIndexes?`: { \[`address`: `string`]: `number`\[]; }; `psbt?`: `Transaction`; }>

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`_fundPsbt`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#_fundpsbt)

***

### \_getBalance()

```
protected _getBalance(address): Promise<{

  confirmedBalance: bigint;

  unconfirmedBalance: bigint;

}>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:117](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L117)

Internal helper function for fetching the balance of the wallet given a specific bitcoin wallet address

#### Parameters

| Parameter | Type     | Description |
| --------- | -------- | ----------- |
| `address` | `string` |             |

#### Returns

`Promise`<{ `confirmedBalance`: `bigint`; `unconfirmedBalance`: `bigint`; }>

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`_getBalance`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#_getbalance)

***

### \_getPsbt()

```
protected _getPsbt(

   sendingAccounts, 

   recipient, 

   amount, 

   feeRate?): Promise<{

  fee: number;

  inputAddressIndexes?: {

   [address: string]: number[];

  };

  psbt?: Transaction;

}>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:174](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L174)

#### Parameters

| Parameter         | Type        | Description |
| ----------------- | ----------- | ----------- |
| `sendingAccounts` | `object`\[] |             |
| `recipient`       | `string`    |             |
| `amount`          | `number`    |             |
| `feeRate?`        | `number`    |             |

#### Returns

`Promise`<{ `fee`: `number`; `inputAddressIndexes?`: { \[`address`: `string`]: `number`\[]; }; `psbt?`: `Transaction`; }>

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`_getPsbt`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#_getpsbt)

***

### \_getSpendableBalance()

```
protected _getSpendableBalance(

   sendingAccounts, 

   psbt?, 

   feeRate?): Promise<{

  balance: bigint;

  feeRate: number;

  totalFee: number;

}>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:343](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L343)

#### Parameters

| Parameter         | Type          |
| ----------------- | ------------- |
| `sendingAccounts` | `object`\[]   |
| `psbt?`           | `Transaction` |
| `feeRate?`        | `number`      |

#### Returns

`Promise`<{ `balance`: `bigint`; `feeRate`: `number`; `totalFee`: `number`; }>

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`_getSpendableBalance`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#_getspendablebalance)

***

### \_getUtxoPool()

```
protected _getUtxoPool(sendingAddress, sendingAddressType): Promise<BitcoinWalletUtxo[]>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:128](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L128)

Internal helper function for fetching the UTXO set of a given wallet address

#### Parameters

| Parameter            | Type                                                                                                                             | Description |
| -------------------- | -------------------------------------------------------------------------------------------------------------------------------- | ----------- |
| `sendingAddress`     | `string`                                                                                                                         |             |
| `sendingAddressType` | [`CoinselectAddressTypes`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/type-aliases/CoinselectAddressTypes.md) |             |

#### Returns

`Promise`<[`BitcoinWalletUtxo`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/type-aliases/BitcoinWalletUtxo.md)\[]>

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`_getUtxoPool`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#_getutxopool)

***

### \_sendTransaction()

```
protected _sendTransaction(rawHex): Promise<string>;
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/BitcoinWallet.ts:107](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/BitcoinWallet.ts#L107)

Internal helper function for sending a raw transaction through the underlying RPC

#### Parameters

| Parameter | Type     | Description                                          |
| --------- | -------- | ---------------------------------------------------- |
| `rawHex`  | `string` | Serialized bitcoin transaction in hexadecimal format |

#### Returns

`Promise`<`string`>

txId Transaction ID of the submitted bitcoin transaction

#### Inherited from

[`BitcoinWallet`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md).[`_sendTransaction`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/classes/BitcoinWallet.md#_sendtransaction)

***

### toBitcoinWalletAccounts()

```
protected toBitcoinWalletAccounts(): [{

  address: string;

  addressType: CoinselectAddressTypes;

  pubkey: string;

}];
```

Defined in: [atomiq-sdk/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts:69](https://github.com/atomiqlabs/atomiq-sdk/blob/786509324f7f09c427e9ccfe527d82e496f06af5/src/bitcoin/wallet/SingleAddressBitcoinWallet.ts#L69)

Returns all the wallet addresses controlled by the wallet

#### Returns

\[{ `address`: `string`; `addressType`: [`CoinselectAddressTypes`](https://docs.atomiq.exchange/sdk-reference/api/atomiq-sdk/src/type-aliases/CoinselectAddressTypes.md); `pubkey`: `string`; }]
