Bitcoin Forum
May 27, 2024, 11:52:45 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Summary of Wallet balance and transactions -> grouping wallet addresses  (Read 188 times)
FiNaR76 (OP)
Newbie
*
Offline Offline

Activity: 17
Merit: 6


View Profile
December 30, 2019, 06:52:20 AM
 #1

Hello,

I am a noob on using electrum wallet... It seems to me that for each transaction in exit (withdraw), Electrum generate a "change" transaction on a "change" address...

I do understand the concepts of "multiple-wallet addresses", including the "change wallet addresses", but I was wondering if there is a way that I can simply request the holding and all transaction of the entire wallet (not by querying each individual address)...

Lets assume that I use https://blockexplorer.com/ is there any way I can simply check the overall wallet balance and transaction history?

I am building an app, and it is annoying for me to check each wallet address in order to get the total balance and the overall transaction list...

thank you all
RapTarX
Hero Member
*****
Offline Offline

Activity: 1358
Merit: 850



View Profile
December 30, 2019, 07:13:13 AM
 #2

If you want to have the change BTC on the same address of origin-

Go to setting
Click on transaction
In "Use change address" option, remove the tick.

Now, when you will send BTC, the change BTC will still remain in the same address from where you have sent; in fact, you will be using the address as change address. There will be no more a lot of change address.



Lets assume that I use https://blockexplorer.com/ is there any way I can simply check the overall wallet balance and transaction history?
It's not possible through an explorer. Wallet explorer may detect some of your addresses from same wallet as long as they already have been linked through transaction.

pooya87
Legendary
*
Offline Offline

Activity: 3458
Merit: 10594



View Profile
December 30, 2019, 07:33:07 AM
 #3

Lets assume that I use https://blockexplorer.com/ is there any way I can simply check the overall wallet balance and transaction history?

I am building an app, and it is annoying for me to check each wallet address in order to get the total balance and the overall transaction list...

Electrum is an HD wallets which means all your keys (and addresses) are being generated from a single seed. you can use that seed or the extended key to re-generate all the addresses. some block explorers support extended keys. all you have to do is to give it your extended public key (starts with xpub) and the explorer generates all your public keys and addresses and returns their history.

warning
there is both privacy and security problems with doing this.
privacy issue is rather obvious since the explorer can now link ALL your current and future addresses that you use together.
security risk is that since Electrum is not using a hardened path, if a single private key of your wallet is leaked ALL your keys will be revealed and you can lose money.

a better solution is that you stick to using Electrum itself either through the client or if you insist on creating your own application then first generate your addresses from your extended public key locally in your own app and then using a loop through the list fetch their history from either an explorer or from any Electrum node using the Electrum communication protocol.

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
nc50lc
Legendary
*
Offline Offline

Activity: 2422
Merit: 5649


Self-proclaimed Genius


View Profile
December 30, 2019, 08:33:17 AM
 #4

Lets assume that I use https://blockexplorer.com/ is there any way I can simply check the overall wallet balance and transaction history?
The GUI does it for you, it's in the bottom part labeled as "Balance" and the history is listed in the "history".
I don't get why you need to query your balance using a third-party client/explorer.

If you're using the daemon, you can import your "master public key" to the GUI client to create a watch-only wallet for this purpose.

It's best if you can provide some info about your operating system, Electrum version and your goal.

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
CryptoBrick
Newbie
*
Offline Offline

Activity: 19
Merit: 0


View Profile WWW
December 30, 2019, 09:27:18 AM
 #5


The GUI does it for you, it's in the bottom part labeled as "Balance" and the history is listed in the "history".
I don't get why you need to query your balance using a third-party client/explorer.


Thank you for this... I am trying to run an app that summarize my holding across multiple blockchains... therefore, instead of remembering many addresses for electrum (receiving and change addresses) I was wondering if I could somehow only have one for wallet...

I agree with you that the GUI does that for me, but I need to have a dashboard with BTC holding, ETH holding etc... I need to be able to get all the info from somewhere... so I was wondering, if I include one of the many Addresses of my wallet, somehow could I "get also the other addresses associated with the same wallet (read only)...

is it feasible?
ranochigo
Legendary
*
Offline Offline

Activity: 2982
Merit: 4193



View Profile
December 30, 2019, 09:55:31 AM
 #6

I agree with you that the GUI does that for me, but I need to have a dashboard with BTC holding, ETH holding etc... I need to be able to get all the info from somewhere... so I was wondering, if I include one of the many Addresses of my wallet, somehow could I "get also the other addresses associated with the same wallet (read only)...

is it feasible?
You can't. Having an address will not reveal the other addresses generated with the same seed. The only way for you to obtain all the addresses within the wallet is by using the master public key to generate them all. If you were to disable change address, all your Bitcoins would be consolidated within one address, provided that you also only use that one address. This would greatly affect your privacy however,

█████████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████
█████████████████████████
.
BC.GAME
▄▄░░░▄▀▀▄████████
▄▄▄
██████████████
█████░░▄▄▄▄████████
▄▄▄▄▄▄▄▄▄██▄██████▄▄▄▄████
▄███▄█▄▄██████████▄████▄████
███████████████████████████▀███
▀████▄██▄██▄░░░░▄████████████
▀▀▀█████▄▄▄███████████▀██
███████████████████▀██
███████████████████▄██
▄███████████████████▄██
█████████████████████▀██
██████████████████████▄
.
..CASINO....SPORTS....RACING..
█░░░░░░█░░░░░░█
▀███▀░░▀███▀░░▀███▀
▀░▀░░░░▀░▀░░░░▀░▀
░░░░░░░░░░░░
▀██████████
░░░░░███░░░░
░░█░░░███▄█░░░
░░██▌░░███░▀░░██▌
░█░██░░███░░░█░██
░█▀▀▀█▌░███░░█▀▀▀█▌
▄█▄░░░██▄███▄█▄░░▄██▄
▄███▄
░░░░▀██▄▀


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
Abdussamad
Legendary
*
Offline Offline

Activity: 3612
Merit: 1564



View Profile
December 30, 2019, 10:41:41 AM
Merited by nc50lc (1)
 #7

install electrum on your server, create a watch only version of your wallet and then have your app interact with electrum over json rpc.
HCP
Legendary
*
Offline Offline

Activity: 2086
Merit: 4316

<insert witty quote here>


View Profile
December 30, 2019, 11:09:33 AM
 #8

I agree with you that the GUI does that for me, but I need to have a dashboard with BTC holding, ETH holding etc... I need to be able to get all the info from somewhere... so I was wondering, if I include one of the many Addresses of my wallet, somehow could I "get also the other addresses associated with the same wallet (read only)...

is it feasible?
With addresses? No... but as mentioned previously... using "Master Public Keys", Yes.

Goto "Wallet -> Information" in your Electrum wallet... and look for the Master Public Key displayed there. Using that you will be able to generate all the addresses from your wallet (including the change addresses).

There will likely be code examples floating around that show how to get from Xpub to address etc.

You can read more about key derivation here: https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki
And you can experiment using Ian Coleman's tool: https://iancoleman.io/bip39/ (don't recommend that you put your actual seeds or master private/public keys into this, unless you're running a local offline copy etc)

█████████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████
█████████████████████████
.
BC.GAME
▄▄░░░▄▀▀▄████████
▄▄▄
██████████████
█████░░▄▄▄▄████████
▄▄▄▄▄▄▄▄▄██▄██████▄▄▄▄████
▄███▄█▄▄██████████▄████▄████
███████████████████████████▀███
▀████▄██▄██▄░░░░▄████████████
▀▀▀█████▄▄▄███████████▀██
███████████████████▀██
███████████████████▄██
▄███████████████████▄██
█████████████████████▀██
██████████████████████▄
.
..CASINO....SPORTS....RACING..
█░░░░░░█░░░░░░█
▀███▀░░▀███▀░░▀███▀
▀░▀░░░░▀░▀░░░░▀░▀
░░░░░░░░░░░░
▀██████████
░░░░░███░░░░
░░█░░░███▄█░░░
░░██▌░░███░▀░░██▌
░█░██░░███░░░█░██
░█▀▀▀█▌░███░░█▀▀▀█▌
▄█▄░░░██▄███▄█▄░░▄██▄
▄███▄
░░░░▀██▄▀


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
Lucius
Legendary
*
Offline Offline

Activity: 3248
Merit: 5694


Blackjack.fun🎲


View Profile WWW
December 30, 2019, 11:54:58 AM
 #9

I agree with you that the GUI does that for me, but I need to have a dashboard with BTC holding, ETH holding etc... I need to be able to get all the info from somewhere...

Electrum is have many forks for other coins, but you need to download wallet for every coin you want to use (BTC,DASH,LTC,BCH...). That dashboard you are thinking is something you can get only if you use some multi-coin wallet like Coinomi, or a hardware wallet like Ledger Nano S/X with Ledger Live where you can see all coins in one dashboard.

If you only want to watch your BTC balance in a watch-only wallet, then just follow HCP advice and use Master Public Key from your Electrum.

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
CryptoBrick
Newbie
*
Offline Offline

Activity: 19
Merit: 0


View Profile WWW
December 30, 2019, 12:59:41 PM
 #10


if i perform this, how can I consolidate the change balance into the "deposit balance"

is there an easy way to consolidate all the addresses into one?

Thank you all
RapTarX
Hero Member
*****
Offline Offline

Activity: 1358
Merit: 850



View Profile
December 30, 2019, 01:07:35 PM
 #11

if i perform this, how can I consolidate the change balance into the "deposit balance"

is there an easy way to consolidate all the addresses into one?

Thank you all
I guess I didn't get you.
If you are talking about consolidate all the previous change into one; send all of your BTC into any one of your addresses. I guess you have a lot of inputs but that will not be a problem since the fee is very low now.

By the way, it's better if you use different change address for having privacy.

HCP
Legendary
*
Offline Offline

Activity: 2086
Merit: 4316

<insert witty quote here>


View Profile
December 30, 2019, 07:44:16 PM
 #12

It sounds like you're trying to change your behaviour to fit your app... rather than change the app to fit your behaviour.

If you're using an HD wallet, then your app will need to work with Master Keys and derive addresses to track transactions/balances. This is just how HD wallets work. That is exactly how Electrum works (and how other wallet monitoring apps work). It will generate all addresses using the xpub, up to the set "gap limit" and then checks each of those addresses for transactions/balance. There isn't an "easier" way.

If you don't want to deal with multiple addresses, then you'll need to stop using HD wallets and use a single address. Even if you switch Electrum to stop using Change addresses, or you manually consolidate all your BTC into one address, when you click "receive", it'll give you a new "unused" address... and you'll be back to this point, trying to figure out an "easy" way to find the balance of multiple addresses in your wallet... unless you manually consolidate again... until you click "receive"... ad infinitum.


Note that If you go the "single addres" route, you'd also be compromising your privacy (and the privacy of others) to a certain extent by re-using addresses

█████████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████
█████████████████████████
.
BC.GAME
▄▄░░░▄▀▀▄████████
▄▄▄
██████████████
█████░░▄▄▄▄████████
▄▄▄▄▄▄▄▄▄██▄██████▄▄▄▄████
▄███▄█▄▄██████████▄████▄████
███████████████████████████▀███
▀████▄██▄██▄░░░░▄████████████
▀▀▀█████▄▄▄███████████▀██
███████████████████▀██
███████████████████▄██
▄███████████████████▄██
█████████████████████▀██
██████████████████████▄
.
..CASINO....SPORTS....RACING..
█░░░░░░█░░░░░░█
▀███▀░░▀███▀░░▀███▀
▀░▀░░░░▀░▀░░░░▀░▀
░░░░░░░░░░░░
▀██████████
░░░░░███░░░░
░░█░░░███▄█░░░
░░██▌░░███░▀░░██▌
░█░██░░███░░░█░██
░█▀▀▀█▌░███░░█▀▀▀█▌
▄█▄░░░██▄███▄█▄░░▄██▄
▄███▄
░░░░▀██▄▀


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
BitMaxz
Legendary
*
Offline Offline

Activity: 3262
Merit: 2979


:( My PC broke due trying to recover an old wallet


View Profile WWW
December 30, 2019, 11:28:01 PM
 #13

if i perform this, how can I consolidate the change balance into the "deposit balance"

is there an easy way to consolidate all the addresses into one?

Thank you all

Are you going to get all of your addresses?
And put it all in your app to show the total amount of your BTC from your addresses in your Electrum?

Or you just want to get the list of your addresses in your addresses tab? so that you can put all of that address in the app you are developing?

If this is what you are talking about you can get all of your address via command and copy them it includes both addresses and change addresses.

This is the command line in console to show all addresses in a single text
Code:
listaddresses()

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
pooya87
Legendary
*
Offline Offline

Activity: 3458
Merit: 10594



View Profile
December 31, 2019, 05:34:24 AM
 #14

I am trying to run an app that summarize my holding across multiple blockchains... therefore, instead of remembering many addresses for electrum (receiving and change addresses) I was wondering if I could somehow only have one for wallet...

I agree with you that the GUI does that for me, but I need to have a dashboard with BTC holding, ETH holding etc... I need to be able to get all the info from somewhere...

if you already have the wallets installed and they are synced then you can easily read the wallet file itself. it is a simple JSON file for Electrum and it contains your addresses, private keys, public keys, seed, transaction history and lots more. you can create a test wallet (on testnet) and receive/send 1 tx and then open the wallet file in a text editor to see its content. then simply write your app to read that data.

.
.BLACKJACK ♠ FUN.
█████████
██████████████
████████████
█████████████████
████████████████▄▄
░█████████████▀░▀▀
██████████████████
░██████████████
████████████████
░██████████████
████████████
███████████████░██
██████████
CRYPTO CASINO &
SPORTS BETTING
▄▄███████▄▄
▄███████████████▄
███████████████████
█████████████████████
███████████████████████
█████████████████████████
█████████████████████████
█████████████████████████
███████████████████████
█████████████████████
███████████████████
▀███████████████▀
█████████
.
Abdussamad
Legendary
*
Offline Offline

Activity: 3612
Merit: 1564



View Profile
December 31, 2019, 07:44:28 AM
 #15

This is very bad for your privacy and the privacy of others you deal with but it can be done:

- go to view menu > show addresses, right click on one of the addresses on that tab and choose to view its private key. copy that to the clipboard.
- create an imported private key wallet using that private key.
- switch to your deterministic wallet (old wallet) via file > open and send all the funds to the address in that imported priv key wallet.
- only use the imported priv key wallet in future.
AltcoinBuilder
Copper Member
Jr. Member
*
Offline Offline

Activity: 85
Merit: 5


View Profile WWW
December 31, 2019, 12:57:54 PM
 #16



Lets assume that I use https://blockexplorer.com/ is there any way I can simply check the overall wallet balance and transaction history?



I think you want to see total balance easily, so you can send all of your coins to one address and request others to send coins to that. but in this way you let others to see your transaction too.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!