bitcoin-cli getaddressofwallet #23256

issue Johnsavadkuhi opened this issue on October 11, 2021
  1. Johnsavadkuhi commented at 8:37 PM on October 11, 2021: none

    sorry to ask for this feature

    i have created a regtest network on ubuntu but when i create a bitcoin wallet i can not get the address of that with bitcoin-cli please provide a method to get the current wallet address

  2. Johnsavadkuhi added the label Feature on Oct 11, 2021
  3. Johnsavadkuhi commented at 8:37 PM on October 11, 2021: none

    add getcurrentaddress

  4. sipa commented at 8:41 PM on October 11, 2021: member

    There is no concept of a "current address". You can request a new address using the getnewaddress RPC.

  5. sipa closed this on Oct 11, 2021

  6. Johnsavadkuhi commented at 8:42 PM on October 11, 2021: none

    @sipa

    getnewaddress is address of loaded wallet ?

    thank you .

  7. ghost commented at 9:14 PM on October 11, 2021: none

    getnewaddress is address of loaded wallet ?

    You can mention the wallet with -rpcwallet followed by command trying to execute for this wallet

    Example:

    If there are two wallets w1 and w2 and I want to get a new address from w1 wallet, the command will be:

    $ bitcoin-cli -rpcwallet=w1 getnewaddress
    

    If the wallet is not loaded it will return error and you will have to load the wallet first with loadwallet

  8. DrahtBot locked this on Oct 30, 2022
Labels

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-05-02 12:14 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me