• Forum has been upgraded, all links, images, etc are as they were. Please see Official Announcements for more information

Difference between commands. getaccountaddress, getaddressesbyaccount, listaddressgroupings

chaeplin

Well-known member
Difference between commands.

getaccountaddress :
Code:
getaccountaddress will return the same address until coins are received on that address;
once coins have been received, it will generate and return a new address.

listaddressgroupings :
Code:
Returns all addresses in the wallet and info used for coincontrol

getaddressesbyaccount :
Code:
Use the getaddressesbyaccount method to list all addresses associated with an account.

example(in testnet)
Code:
ms06@x60t:~> darkcoind getaddressesbyaccount 0
[
    "mgosBEJMvd27HiHcm1LLJqTekMAkaxHAvZ"
]
Code:
ms06@x60t:~> darkcoind listaddressgroupings
[
    [
        [
            "mgosBEJMvd27HiHcm1LLJqTekMAkaxHAvZ",
            2032.89400000,
            "0"
        ]
    ]
]

This one will make new address for account 0.
Code:
ms06@x60t:~> darkcoind getaccountaddress 0
muj9oHwCtoWLcrALSfV7yQS2yh1KLpbXo6

Code:
ms06@x60t:~> darkcoind listaddressgroupings
[
    [
        [
            "mgosBEJMvd27HiHcm1LLJqTekMAkaxHAvZ",
            2032.89400000,
            "0"
        ]
    ]
]
Code:
ms06@x60t:~> darkcoind validateaddress muj9oHwCtoWLcrALSfV7yQS2yh1KLpbXo6
{
    "isvalid" : true,
    "address" : "muj9oHwCtoWLcrALSfV7yQS2yh1KLpbXo6",
    "ismine" : true,
    "isscript" : false,
    "pubkey" : "02001c88f3399a1150c47f2e383762997da1f3dde2b94ecfeffac3ac31751853c7",
    "iscompressed" : true,
    "account" : "0"
}
Code:
ms06@x60t:~> darkcoind getaddressesbyaccount 0
[
    "muj9oHwCtoWLcrALSfV7yQS2yh1KLpbXo6",
    "mgosBEJMvd27HiHcm1LLJqTekMAkaxHAvZ"
]
 
Last edited by a moderator:
Back
Top