<p>Use <code>getreceivedbylabel</code>. It takes <code>label</code> and <code>minconf</code> as arguments. <code>label</code> is the label, and <code>minconf</code> is the minimum number of confirmations for a transaction to be considered for inclusion in this value. The default is 1 confirmation.</p>

CC BY-SA 4.0
2020-03-12T09:41:21.107Z
@AndrewChow But I do want to categorize the bitcoin addresses without redownloading the whole blockchain(which is a side effect to run bitcoind in different fs namespaces). Is there any ways to do that?
TJM
CC BY-SA 4.0
2020-03-12T09:44:22.397Z
@AndrewChow The default getbalances command only supports printing total available balance, which is not that helpful for audits of different labels.
TJM
CC BY-SA 4.0
2020-03-12T15:28:37.533Z
@TJM If you want separation of "accounts", you should use multiple wallet files. Bitcoin Core supports having multiple wallets loaded simultaneously, with dynamic loading and unloading of said wallets. That will give you logical and actual separation of "accounts".
Ava Chow
CC BY-SA 4.0
2019-06-09T10:49:05.097Z
This only shows the total received amount, not the amount of which is spendabel
Emil Engler
CC BY-SA 4.0
2019-06-09T10:57:24.143Z
Labels cannot be "spent from", so `getreceivedbylabel` gives you the "balance" of the label. You are trying to use labels like the old accounts system, don't do that.
Ava Chow
CC BY-SA 4.0
2019-06-09T08:55:55.123Z
2019-06-09T08:55:55.123Z
Ava Chow
<p>I have lots of addresses organized under a label.<br>
Is there a command to show the total remaining amount available under a label ? (Or address)<br>
I am building a payment gateway and I need get the total remaining amount of an address thats why I cannot use listreceivedbylabel.<br>
I am also not able to rely on some block explorers API.</p>

<bitcoin-core><json-rpc><api>
How to get balance for a label
Emil Engler
# How to get balance for a label

(Asked by: username_0 on 2019-06-09)

I have lots of addresses organized under a label.  
Is there a command to show the total remaining amount available under a label ? (Or address)  
I am building a payment gateway and I need get the total remaining amount of an address thats why I cannot use listreceivedbylabel.  
I am also not able to rely on some block explorers API.

**Tags:** bitcoin-core, json-rpc, api


---

## 1 answers

### Answer by username_1 on 2019-06-09. Score: 1 | Accepted answer

Use `getreceivedbylabel`. It takes `label` and `minconf` as arguments. `label` is the label, and `minconf` is the minimum number of confirmations for a transaction to be considered for inclusion in this value. The default is 1 confirmation.

> **Comments:**
> **username_0**: This only shows the total received amount, not the amount of which is spendabel  
> **username_1**: Labels cannot be "spent from", so `getreceivedbylabel` gives you the "balance" of the label. You are trying to use labels like the old accounts system, don't do that.  
> **username_2**: @AndrewChow But I do want to categorize the bitcoin addresses without redownloading the whole blockchain(which is a side effect to run bitcoind in different fs namespaces). Is there any ways to do that?  
> **username_2**: @AndrewChow The default getbalances command only supports printing total available balance, which is not that helpful for audits of different labels.  
> **username_1**: @username_2 If you want separation of "accounts", you should use multiple wallet files. Bitcoin Core supports having multiple wallets loaded simultaneously, with dynamic loading and unloading of said wallets. That will give you logical and actual separation of "accounts".  

---

