Bitcoin Forum
May 14, 2024, 12:13:17 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: [BOT] BLOSHI, iMacros script for pingpong trading in CoinExchange.io  (Read 664 times)
bitkominer (OP)
Newbie
*
Offline Offline

Activity: 49
Merit: 0


View Profile
July 09, 2017, 12:59:37 AM
Last edit: July 09, 2017, 12:48:01 PM by bitkominer
 #1

Hi guys...

This is not a professional trading bot which costs millions of satoshi to purchase and start with, but if you want a free script that is worth to try you're pleased to try and give your comment later on.  Smiley

The script follows only one rule: Buy LO and Sell HI (that's why I call it BLOSHI). It does not use a complicated trading strategy using many kinds of analysis, but the result will definitely tell you the truth.

Here are the steps:
1. Install iMacros addon to your firefox or palemoon browser.
2. Copy the following script and save as .js file using your notepad, place it inside iMacros folder (\My Documents\iMacros\Macros\).
Code:
var i = 0, macro, stat = [0], currentbid = 0, currentask = 0, toask = 0, tobid = 0, lobid = 0, hiask = 0, nextorder = 0, ordermore = 0, orderamount = 0, basebalance = ordermore = 0, assetbalance = 0, delta = 0, basemarket = String(prompt(" >> Welcome to BLOSHI Ver.1.1 << \n The bot follows only 1 rule: Buy Low and Sell High \n \n Type the base market for trading:", "BTC")), asset = String(prompt("Type the asset code to trade with:", "DNR")), bidstake = Number(prompt("Amount to bid/Buy-LO (in the base market currency):", 
0.00035000)), askstake = Number(prompt("Amount to ask/Sell-HI (in the base market currency):", 0.00050000)), attempt = Number(prompt("How many BLOSHI attempts before cancelling all orders?", 3)), satoshidelta = Number(prompt("Minimum delta between bid and ask (satoshi or smallest coin unit):", 7)), mindelta = satoshidelta / 100000000;
function CheckHighestBid() {
  for (var a = 0; a < a + 1; a++) {
    if (macro = "CODE:", macro += "WAIT SECONDS=1\n", macro += "TAG POS=1 TYPE=SPAN ATTR=CLASS:market-summary-bid-price extract=txt\n", iimPlay(macro), stat[a] = iimGetExtract(), currentbid = stat[a], macro = null, -1 != stat[a].search(".")) {
      stat = null;
      stat = [0];
      break;
    }
  }
  return currentbid;
}
function CheckLowestAsk() {
  for (var a = 0; a < a + 1; a++) {
    if (macro = "CODE:", macro += "WAIT SECONDS=1\n", macro += "TAG POS=1 TYPE=SPAN ATTR=CLASS:market-summary-ask-price extract=txt\n", iimPlay(macro), stat[a] = iimGetExtract(), currentask = stat[a], macro = null, -1 != stat[a].search(".")) {
      stat = null;
      stat = [0];
      break;
    }
  }
  return currentask;
}
function getRandom() {
  return Math.floor(100 * Math.random()) + 1;
}
function CloseOrders() {
  macro = "CODE:";
  macro += "TAG POS=1 TYPE=A ATTR=TXT:Cancel<SP>All<SP>Orders\n";
  macro += "WAIT SECONDS=3\n";
  macro += "TAG POS=1 TYPE=BUTTON ATTR=ID:confirm-all-orders-cancel\n";
  macro += "WAIT SECONDS=10\n";
  iimPlay(macro);
  macro = null;
}
function ScanningMarket() {
  macro = "CODE:";
  macro += "URL GOTO=https://www.coinexchange.io/market/" + asset + "/" + basemarket + "\n";
  macro += "WAIT SECONDS=10\n";
  iimPlay(macro);
  macro = null;
}
function CheckBaseBalance() {
  for (var a = 0; a < a + 1; a++) {
    if (macro = "CODE:", macro += "WAIT SECONDS=1\n", macro += "TAG POS=1 TYPE=SPAN ATTR=ID:secondary-balance-clickable extract=txt\n", iimPlay(macro), stat[a] = iimGetExtract(), basebalance = stat[a], macro = null, -1 != stat[a].search(".")) {
      stat = null;
      stat = [0];
      break;
    }
  }
  return basebalance;
}
function CheckAssetBalance() {
  for (var a = 0; a < a + 1; a++) {
    if (macro = "CODE:", macro += "WAIT SECONDS=1\n", macro += "TAG POS=1 TYPE=SPAN ATTR=ID:primary-balance-clickable extract=txt\n", iimPlay(macro), stat[a] = iimGetExtract(), assetbalance = stat[a], macro = null, -1 != stat[a].search(".")) {
      stat = null;
      stat = [0];
      break;
    }
  }
  return assetbalance;
}
for (i = 0; i < i + 1; i++) {
  ScanningMarket(), CheckHighestBid(), CheckLowestAsk(), tobid = (100000000 * currentbid + 1) / 100000000, lobid = (100000000 * currentbid - 5) / 100000000, delta = currentask - currentbid, delta >= mindelta || (tobid = lobid), orderamount = nextorder = 100000000 * bidstake / 100000000 / tobid, CheckBaseBalance(), basebalance > bidstake && (macro = "CODE:", macro += "WAIT SECONDS=3\n", macro += "TAG POS=1 TYPE=INPUT:TEXT FORM=ID:buy-form ATTR=ID:inputPrice CONTENT=" + tobid + "\n", macro += "TAG POS=1 TYPE=INPUT:TEXT FORM=ID:buy-form ATTR=ID:inputAmount CONTENT=" +
  orderamount + "\n", macro += "WAIT SECONDS=3\n", macro += "TAG POS=1 TYPE=BUTTON FORM=ID:buy-form ATTR=ID:buy-order-submit\n", macro += "WAIT SECONDS=3\n", macro += "TAG POS=1 TYPE=BUTTON ATTR=ID:confirm-order-submit\n", macro += "TAG POS=1 TYPE=BUTTON ATTR=TXT:\u00d7Close\n", iimPlay(macro), orderamount = macro = null, orderamount = 0, nextorder = null, nextorder = 0, tobid = null, tobid = 0, lobid = null, lobid = 0, basebalance = null, basebalance = 0), ScanningMarket(), CheckLowestAsk(), CheckHighestBid(),
  toask = (100000000 * currentask - 1) / 100000000, hiask = (100000000 * currentask + 5) / 100000000, delta = currentask - currentbid, delta >= mindelta || (toask = hiask), orderamount = nextorder = 1E8 * askstake / 1E8 / toask, CheckAssetBalance(), assetbalance > orderamount && (macro = "CODE:", macro += "WAIT SECONDS=3\n", macro += "TAG POS=1 TYPE=INPUT:TEXT FORM=ID:sell-form ATTR=ID:inputPrice CONTENT=" + toask + "\n", macro += "TAG POS=1 TYPE=INPUT:TEXT FORM=ID:sell-form ATTR=ID:inputAmount CONTENT=" +
  orderamount + "\n", macro += "WAIT SECONDS=3\n", macro += "TAG POS=1 TYPE=BUTTON FORM=ID:sell-form ATTR=ID:sell-order-submit\n", macro += "WAIT SECONDS=3\n", macro += "TAG POS=1 TYPE=BUTTON ATTR=ID:confirm-order-submit\n", macro += "TAG POS=1 TYPE=BUTTON ATTR=TXT:\u00d7Close\n", iimPlay(macro), orderamount = macro = null, orderamount = 0, nextorder = null, nextorder = 0, toask = null, toask = 0, hiask = null, hiask = 0, assetbalance = null, assetbalance = 0), macro = "CODE:", macro += "WAIT SECONDS=5\n",
  iimPlay(macro), macro = null, ScanningMarket(), macro = "CODE:", macro += "WAIT SECONDS=10\n", iimPlay(macro), macro = null, 0 == i % attempt && CloseOrders();
}
;

3. Open your firefox/palemoon browser with iMacros addon installed, login to your coinexchange account, then run the script. (Remember, you have to load some amount of satoshi or whatever altcoins you like to start trading with it).


------------------------------------------------------------
If you hate the script, you might send some SHIT here: 5wcSnmC64o2m8TuVhqHoXHNmUnSnV7WXkw
or, you might send your DOGE to bark onto my wallet here: DJJC8m9xiRVu6CkrhgDmLCvSUyDy8R8WQN

If you like the script you can share some of your profit to my BTC wallet here: 1K9znQp1xuifyQfVWjyrz4qAXeRnhv2pWL


Enjoy the trade guys!
1715645597
Hero Member
*
Offline Offline

Posts: 1715645597

View Profile Personal Message (Offline)

Ignore
1715645597
Reply with quote  #2

1715645597
Report to moderator
1715645597
Hero Member
*
Offline Offline

Posts: 1715645597

View Profile Personal Message (Offline)

Ignore
1715645597
Reply with quote  #2

1715645597
Report to moderator
1715645597
Hero Member
*
Offline Offline

Posts: 1715645597

View Profile Personal Message (Offline)

Ignore
1715645597
Reply with quote  #2

1715645597
Report to moderator
"Your bitcoin is secured in a way that is physically impossible for others to access, no matter for what reason, no matter how good the excuse, no matter a majority of miners, no matter what." -- Greg Maxwell
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
bitkominer (OP)
Newbie
*
Offline Offline

Activity: 49
Merit: 0


View Profile
July 09, 2017, 01:01:04 AM
 #2

.....reserved
KingLOL
Full Member
***
Offline Offline

Activity: 130
Merit: 100


View Profile
October 06, 2017, 03:35:12 AM
 #3

someone reviewed the code? experience?

im also searching for a script for adding a stop limit feature. is this integreated here?


thx
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!