Presenting the 'Leave it to Fate' bot.
Fill in the config with your GUID, and Blockchain.info password.
Fill in a min bet for each color. Run with Cron or through the browser. A bet between your minimum and max will be placed on a random color.
Enjoy.
// Start Config
$blueMin = 0.005;
$blueMax = 0.01;
$greenMin = 0.003;
$greenMax = 0.005;
$yellowMin = 0.0025;
$yellowMax = 0.004;
$redMin = 0.002;
$redMax = 0.0025;
$promoMin = 0.002;
$promoMax = 0.0025;
$guid = 'YOURGUIDHERE';
$password = urlencode('YOURBLOCKCHAINPASSHERE');
//endConfig
$blueAmount = rand(($blueMin * 100000000),($blueMax * 100000000)); //convert user values to satoshis
$greenAmount = rand(($greenMin * 100000000),($greenMax * 100000000));
$yellowAmount = rand(($yellowMin * 100000000),($yellowMax * 100000000));
$redAmount = rand(($redMin * 100000000),($redMax * 100000000));
$promoAmount = rand(($promoMin * 100000000),($promoMax * 100000000));
$blueAddress = '1LuckyB5VGzdZLZSBZvw8DR17iiFCpST7L';
$greenAddress = '1LuckyG4tMMZf64j6ea7JhCz7sDpk6vdcS';
$yellowAddress = '1LuckyY9fRzcJre7aou7ZhWVXktxjjBb9S';
$redAddress = '1LuckyR1fFHEsXYyx5QK4UFzv3PEAepPMK';
$promoAddress = '1LuckyP83urTUEJE9YEaVG2ov3EDz3TgQw';
function send_to_one ($colorAddress, $amount, $guid, $password) {
$apiBase = 'https://blockchain.info/es/merchant/';
$url = $apiBase . $guid . '/payment?password=' .
$password . '&to=' . $colorAddress . '&amount=' . $amount;
echo $url;
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_URL, $url); // get the file
$response = curl_exec($ch); // execute curl request
curl_close($ch);
echo $response;
echo '' . $amount . ' sent to ' . $colorAddress . '';
}
$singleColor = rand(0,4);
switch ($singleColor) {
case 0 :
send_to_one($blueAddress, $blueAmount, $guid, $password);
break;
case 1:
send_to_one($greenAddress, $greenAmount, $guid, $password);
break;
case 2:
send_to_one($yellowAddress, $yellowAmount, $guid, $password);
break;
case 3:
send_to_one($redAddress, $redAmount, $guid, $password);
case 4:
send_to_one($promoAddress, $promoAmount, $guid, $password);
break;
}
?>