Bitcoin Forum
December 13, 2024, 02:51:33 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Blockchain API: Insufficient funds  (Read 378 times)
IdiotCoder (OP)
Member
**
Offline Offline

Activity: 193
Merit: 26


View Profile
February 18, 2017, 07:27:18 PM
Last edit: February 18, 2017, 07:37:45 PM by IdiotCoder
 #1

I am making a PHP script which uses Blockchain's Node.js API. However, when I try to programmatically send BTC0.0005 to my Bitcoin Core wallet locally installed on my Mac Mini, I get the following error in my Blockchain console:

Quote
1487445233151 - error: Insufficient funds. Value Needed 0.0004BTC. Available amount 0BTC

I followed the instructions listed on the Blockchain API but I still get this error. I googled the problem involving 0 BTC in the Blockchain wallet, but I have more than enough what I'm sending. Here's the rhe relevant code:
Code:
       $guid="(removed)";
        $password="(removed)";
        $amount = "30000";
        $to = '1CSjpwvXPzRMG3ksVq7PFA2tz7PumnNNbS';


        $json_url = "http://localhost:3000/merchant/$guid/payment?password=$password&to=$to&amount=$amount&from=1qmAhtjgYKv12RMRM18t5HAPMrxM24f8t";

        $json_data = file_get_contents($json_url);

        $json_feed = json_decode($json_data);

        return var_dump($json_feed);


Thanks in advance for the help!
eckmar
Legendary
*
Offline Offline

Activity: 1878
Merit: 1038


Telegram: https://t.me/eckmar


View Profile
February 18, 2017, 10:13:03 PM
 #2

I am making a PHP script which uses Blockchain's Node.js API.

I don't really understand what you are trying to do (or wanted to say)here ? Anyway since you pretty much copy/pasted code from their example there is no error there I guess. Check if you are using guid from wallet that actually have any funds or maybe you made mistake with wallets ? 
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!