Bitcoin Forum
September 05, 2024, 04:06:08 AM *
News: Latest Bitcoin Core release: 27.1 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: BitN00B: Python/JSON - getNewAddress(account) - fail / How To?  (Read 144 times)
ThisCryptoFail (OP)
Newbie
*
Offline Offline

Activity: 2
Merit: 0


View Profile
October 14, 2018, 05:13:02 PM
 #1

When making a JSON call, RPC to bitcoind, what is the "account" parameter in getNewAddress(account).  What does 'account' mean? and where I am supposed to get it?

Does anyone have actual code to demo this?  This is frustrating given how much time I have spent ( a day ),
trying to get this to work in code, trying different things, googling all over, following things to a dead end.

In my Bitcoin QT, I see no reference to "account", I don't know what to put there as a parameter.

Reference:
 https://en.bitcoin.it/wiki/Original_Bitcoin_client/API_calls_list#Full_list

If I leave it blank, or I make up something to put there, I get a socket timeout.
I can successfully call: getblockchaininfo, and a few others with no socket timeout, but not getNewAddress.

--
Also if anyone can help, I please need a clear concise exmple of sending a transaction.  I can find no good code examples on how to create a raw transaction and send with any Python/RPC/Bitcoind library out there.  None.  It should not take more than a few lines of code to send a transaction.

 1. set variables
 2. make a call to send the transaction (that's it).
 
 I would like to have the raw transaction printed out to debug, both raw transaction and the actual hex code that is sent.
 
 Thank You,
 
 
 JC
psycodad
Legendary
*
Offline Offline

Activity: 1631
Merit: 1721


精神分析的爸


View Profile
October 15, 2018, 06:20:51 AM
 #2

When making a JSON call, RPC to bitcoind, what is the "account" parameter in getNewAddress(account).  What does 'account' mean? and where I am supposed to get it?


Try an empty string for account, which addresses the default account.
Most BTC/LTC based wallets allow the organisation of your wallet into "accounts", though hardly anybody uses this feature AFAIK.

HTH

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!