Bitcoin Forum
April 19, 2024, 04:46:06 PM *
News: Latest Bitcoin Core release: 26.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Curl bitcoind setaccount call  (Read 505 times)
whattheshittyface (OP)
Newbie
*
Offline Offline

Activity: 1
Merit: 0


View Profile
February 23, 2014, 04:05:33 AM
 #1

Need some help with this issue, also I'm using the D language.

auto p = pipe();
      auto cpid = spawnProcess(["curl", "--user", "user:password", "--data-binary",
                                       "{\"jsonrpc\": \"2.0\", \"method\": \"setaccount\", \"params\": [mvJ4Yb7dz42kJXGPZ4Sq2XrUEwiX8hMzx8, nothing] }'
                                          -H 'content-type: text/plain;'", "--url", "http://127.0.0.1:18332/"],
                           std.stdio.stdin, p.writeEnd);
      
      scope(exit) {wait(cpid);

      string data = p.readEnd.readln();

      writeln(data);

Returns {"result":null,"error":{"code":-32700,"message":"Parse error"},"id":null}

I can get other API calls to work like listunspent so I know I don't have a connection issue.  Also im trying to set the account from an address that is local to my wallet.   bitcoind does set the account name itself, i just can't do it with Curl.  Any ideas?
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!