Class: BitcoinAddress ​
Defined in: packages/bitcoin/src/client/rest/address.ts:8
Address-related Esplora REST API operations.
Constructors ​
Constructor ​
new BitcoinAddress(
protocol,exec):BitcoinAddress
Defined in: packages/bitcoin/src/client/rest/address.ts:12
Parameters ​
protocol ​
exec ​
(req) => Promise<any>
Returns ​
BitcoinAddress
Methods ​
getConfirmedTxs() ​
getConfirmedTxs(
addressOrScripthash,lastSeenTxId?):Promise<RawTransactionRest[]>
Defined in: packages/bitcoin/src/client/rest/address.ts:65
Get confirmed transaction history for the specified address/scripthash, sorted with newest first. Returns 25 transactions per page.
Parameters ​
addressOrScripthash ​
string
The address or scripthash to check.
lastSeenTxId? ​
string
The last transaction id seen by the previous query for pagination.
Returns ​
Promise<RawTransactionRest[]>
Confirmed transactions.
getInfo() ​
getInfo(
addressOrScripthash):Promise<AddressInfo>
Defined in: packages/bitcoin/src/client/rest/address.ts:54
Get information about an address/scripthash.
Parameters ​
addressOrScripthash ​
string
The address or scripthash to check.
Returns ​
Promise<AddressInfo>
Address information.
getTxs() ​
getTxs(
addressOrScripthash):Promise<RawTransactionRest[]>
Defined in: packages/bitcoin/src/client/rest/address.ts:24
Get transaction history for the specified address/scripthash, sorted with newest first. Returns up to 50 mempool transactions plus the first 25 confirmed transactions. See Esplora GET /address/:address/txs for details.
Parameters ​
addressOrScripthash ​
string
The address or scripthash to check.
Returns ​
Promise<RawTransactionRest[]>
Transaction history.
getTxsMempool() ​
getTxsMempool(
addressOrScripthash):Promise<RawTransactionRest[]>
Defined in: packages/bitcoin/src/client/rest/address.ts:45
Get unconfirmed transaction history for the specified address/scripthash. Returns up to 50 transactions (no paging).
Parameters ​
addressOrScripthash ​
string
The address or scripthash to check.
Returns ​
Promise<RawTransactionRest[]>
Unconfirmed transactions.
getUtxos() ​
getUtxos(
addressOrScripthash):Promise<AddressUtxo[]>
Defined in: packages/bitcoin/src/client/rest/address.ts:75
Get the list of unspent transaction outputs associated with the address/scripthash. See Esplora GET /address/:address/utxo for details.
Parameters ​
addressOrScripthash ​
string
The address or scripthash to check.
Returns ​
Promise<AddressUtxo[]>
Unspent transaction outputs.
isFundedAddress() ​
isFundedAddress(
addressOrScripthash):Promise<boolean>
Defined in: packages/bitcoin/src/client/rest/address.ts:33
Checks if an address has any confirmed funded transactions.
Parameters ​
addressOrScripthash ​
string
The address or scripthash to check.
Returns ​
Promise<boolean>
True if the address has confirmed funds.