Guest User

Untitled

a guest
Mar 10th, 2018
428
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 10.61 KB | None | 0 0
  1. var c = module.exports = {}
  2.  
  3. // mongo configuration
  4. c.mongo = {}
  5. c.mongo.db = 'zenbot4'
  6.  
  7. c.mongo.host = process.env.MONGODB_PORT_27017_TCP_ADDR || 'localhost'
  8. c.mongo.port = 27017
  9. c.mongo.username = null
  10. c.mongo.password = null
  11. // when using mongodb replication, i.e. when running a mongodb cluster, you can define your replication set here; when you are not using replication (most of the users), just set it to `null` (default).
  12. c.mongo.replicaSet = null
  13.  
  14. var Whatexchange = "binance";
  15. var CryptocurrencySelect = new Array(22)
  16. CryptocurrencySelect[0] = Whatexchange + ".LTC-BTC";
  17. CryptocurrencySelect[1] = Whatexchange + ".NEO-BTC";
  18. CryptocurrencySelect[2] = Whatexchange + ".ETH-BTC";
  19. CryptocurrencySelect[3] = Whatexchange + ".BCC-BTC";
  20. CryptocurrencySelect[4] = Whatexchange + ".DASH-BTC";
  21. CryptocurrencySelect[5] = Whatexchange + ".DGD-BTC";
  22. CryptocurrencySelect[6] = Whatexchange + ".XRM-BTC";
  23. CryptocurrencySelect[7] = Whatexchange + ".XRP-BTC";
  24. CryptocurrencySelect[8] = Whatexchange + ".ETC-BTC";
  25. CryptocurrencySelect[9] = Whatexchange + ".IOTA-BTC";
  26. CryptocurrencySelect[10] = Whatexchange + ".NANO-BTC";
  27. CryptocurrencySelect[11] = Whatexchange + ".XZC-BTC";
  28. CryptocurrencySelect[11] = Whatexchange + ".XEC-BTC";
  29. CryptocurrencySelect[12] = Whatexchange + ".TRX-BTC";
  30. CryptocurrencySelect[12] = Whatexchange + ".RDN-BTC";
  31. CryptocurrencySelect[13] = Whatexchange + ".PPT-BTC";
  32. CryptocurrencySelect[14] = Whatexchange + ".LSK-BTC";
  33. CryptocurrencySelect[15] = Whatexchange + ".LUN-BTC";
  34. CryptocurrencySelect[16] = Whatexchange + ".KMD-BTC";
  35. CryptocurrencySelect[17] = Whatexchange + ".EOS-BTC";
  36. CryptocurrencySelect[18] = Whatexchange + ".ENG-BTC";
  37. CryptocurrencySelect[19] = Whatexchange + ".EVX-BTC";
  38. CryptocurrencySelect[20] = Whatexchange + ".EDO-BTC";
  39. CryptocurrencySelect[21] = Whatexchange + ".BTG-BTC";
  40. CryptocurrencySelect[22] = Whatexchange + ".BNT-BTC";
  41. CryptocurrencyNumber = Math.floor(Math.random()* (CryptocurrencySelect.length-1));
  42. var Cryptocurrency= CryptocurrencySelect[CryptocurrencyNumber];
  43.  
  44. // default selector. only used if omitting [selector] argument from a command.
  45. c.selector = 'binance.BTC-USDT'
  46. //c.selector = Cryptocurrency
  47. // name of default trade strategy
  48. c.strategy = 'rsi'
  49.  
  50. // Exchange API keys:
  51.  
  52. // to enable GDAX trading, enter your API credentials:
  53. c.gdax = {}
  54. c.gdax.key = 'YOUR-API-KEY'
  55. c.gdax.b64secret = 'YOUR-BASE64-SECRET'
  56. c.gdax.passphrase = 'YOUR-PASSPHRASE'
  57.  
  58. // to enable Poloniex trading, enter your API credentials:
  59. c.poloniex = {}
  60. c.poloniex.key = 'YOUR-API-KEY'
  61. c.poloniex.secret = 'YOUR-SECRET'
  62. // please note: poloniex does not support market orders via the API
  63.  
  64. // to enable Kraken trading, enter your API credentials:
  65. c.kraken = {}
  66. c.kraken.key = 'YOUR-API-KEY'
  67. c.kraken.secret = 'YOUR-SECRET'
  68. // Please read API TOS on https://www.kraken.com/u/settings/api
  69. c.kraken.tosagree = 'disagree'
  70.  
  71. // to enable Binance trading, enter your API credentials:
  72. c.binance = {}
  73. c.binance.key = 'bWvvn2Zvo7nY1eVgfJpYzM8Z8EV0BgylqEh9jES2uIlfv2OvthlQ4loV4IUIVe6z'
  74. c.binance.secret = '3IBTCDBDlPRk4MW8vnTNR0FBchsutKyyEi3BpqXjuZf93ERQY6FqFhVuHtvk6s9H'
  75.  
  76.  
  77. // to enable Bittrex trading, enter your API credentials:
  78. c.bittrex = {}
  79. c.bittrex.key = 'YOUR-API-KEY'
  80. c.bittrex.secret = 'YOUR-SECRET'
  81. // make sure to give your API key access to only: "Trade Limit" and "Read Info",
  82. // please note that this might change in the future.
  83. // please note that bittrex API is limited, you cannot use backfills or sims (paper/live trading only)
  84.  
  85. // to enable Bitfinex trading, enter your API credentials:
  86. c.bitfinex = {}
  87. c.bitfinex.key = 'YOUR-API-KEY'
  88. c.bitfinex.secret = 'YOUR-SECRET'
  89. // May use 'exchange' or 'trading' wallet balances. However margin trading may not work...read the API documentation.
  90. c.bitfinex.wallet = 'exchange'
  91.  
  92. // to enable Bitstamp trading, enter your API credentials:
  93. c.bitstamp = {}
  94. c.bitstamp.key = 'YOUR-API-KEY'
  95. c.bitstamp.secret = 'YOUR-SECRET'
  96. // A client ID is required on Bitstamp
  97. c.bitstamp.client_id = 'YOUR-CLIENT-ID'
  98.  
  99. // to enable CEX.IO trading, enter your API credentials:
  100. c.cexio = {}
  101. c.cexio.username = 'YOUR-CLIENT-ID'
  102. c.cexio.key = 'YOUR-API-KEY'
  103. c.cexio.secret = 'YOUR-SECRET'
  104.  
  105. // to enable QuadrigaCX tranding, enter your API credentials:
  106. c.quadriga = {}
  107. c.quadriga.key = 'YOUR-API-KEY'
  108. // this is the manual secret key entered by editing the API access
  109. // and NOT the md5 hash you see in the summary
  110. c.quadriga.secret = 'YOUR-SECRET'
  111. // replace with the client id used at login, as a string, not number
  112. c.quadriga.client_id = 'YOUR-CLIENT-ID'
  113.  
  114. // to enable WEX.NZ trading, enter your API credentials:
  115. // Note: WexNZ only supports backfilling the last ~1/4 day ATM.
  116. c.wexnz = {}
  117. c.wexnz.key = 'YOUR-API-KEY'
  118. c.wexnz.secret = 'YOUR-SECRET'
  119.  
  120. // to enable Gemini trading, enter your API credentials:
  121. c.gemini = {}
  122. c.gemini.key = 'YOUR-API-KEY'
  123. c.gemini.secret = 'YOUR-SECRET'
  124. // set to false to trade on the live platform API
  125. c.gemini.sandbox = true
  126.  
  127. // to enable hitBTC trading, enter your API credentials:
  128. c.hitbtc = {}
  129. c.hitbtc.key = 'YOUR-API-KEY'
  130. c.hitbtc.secret = 'YOUR-SECRET'
  131.  
  132. // to enable therock trading, enter your API credentials:
  133. c.therock = {}
  134. c.therock.key = 'YOUR-API-KEY'
  135. c.therock.secret = 'YOUR-SECRET'
  136.  
  137. // Optional stop-order triggers:
  138.  
  139. // sell if price drops below this % of bought price (0 to disable)
  140. c.sell_stop_pct = 0
  141. // buy if price surges above this % of sold price (0 to disable)
  142. c.buy_stop_pct = 0
  143. // enable trailing sell stop when reaching this % profit (0 to disable)
  144. c.profit_stop_enable_pct = 0
  145. // maintain a trailing stop this % below the high-water mark of profit
  146. c.profit_stop_pct = 1
  147.  
  148. // Order execution rules:
  149.  
  150. // avoid trading at a slippage above this pct
  151. c.max_slippage_pct = 5
  152. // compre com este% do saldo da moeda (AVISO: o sim não funcionará corretamente se você definir esse valor para 100)
  153. c.buy_pct = 99
  154. // venda com este % de saldo de ativos (AVISO: sim não funcionará corretamente se você definir esse valor para 100)
  155. c.sell_pct = 99
  156. // ms to adjust non-filled order after
  157. c.order_adjust_time = 5000
  158. // avoid selling at a loss below this pct set to 0 to ensure selling at a higher price...
  159. c.max_sell_loss_pct = 25
  160. // avoid buying at a loss above this pct set to 0 to ensure buying at a lower price...
  161. c.max_buy_loss_pct = 25
  162. // ms to poll order status
  163. c.order_poll_time = 5000
  164. // ms to wait for settlement (after an order cancel)
  165. c.wait_for_settlement = 5000
  166. // % para marcar o preço de compra para pedidos
  167. c.markdown_buy_pct = 0
  168. // % para marcar o preço de venda para pedidos
  169. c.markup_sell_pct = 0
  170. // become a market taker (high fees) or a market maker (low fees)
  171. c.order_type = 'maker'
  172. // when supported by the exchange, use post only type orders.
  173. c.post_only = true
  174.  
  175. // Misc options:
  176.  
  177. // default # days for backfill and sim commands
  178. c.days = 14
  179. // defaults to a high number of lookback periods
  180. c.keep_lookback_periods = 50000
  181. // ms to poll new trades at
  182. c.poll_trades = 30000
  183. // amount of currency to start simulations with
  184. c.currency_capital = 1000
  185. // amount of asset to start simulations with
  186. c.asset_capital = 0
  187. // for sim, reverse time at the end of the graph, normalizing buy/hold to 0
  188. c.symmetrical = false
  189. // number of periods to calculate RSI at
  190. c.rsi_periods = 14
  191. // period to record balances for stats
  192. c.balance_snapshot_period = '15m'
  193. // avg. amount of slippage to apply to sim trades
  194. c.avg_slippage_pct = 0.045
  195. // time to leave an order open, default to 1 day (this feature is not supported on all exchanges, currently: GDAX)
  196. c.cancel_after = 'day'
  197. // load and use previous trades for stop-order triggers and loss protection (live/paper mode only)
  198. c.use_prev_trades = false
  199.  
  200. // Notifiers:
  201. c.notifiers = {}
  202.  
  203. // xmpp config
  204. c.notifiers.xmpp = {}
  205. c.notifiers.xmpp.on = false // false xmpp disabled; true xmpp enabled (credentials should be correct)
  206. c.notifiers.xmpp.jid = 'trader@domain.com'
  207. c.notifiers.xmpp.password = 'Password'
  208. c.notifiers.xmpp.host = 'domain.com'
  209. c.notifiers.xmpp.port = 5222
  210. c.notifiers.xmpp.to = 'MeMyselfAndI@domain.com'
  211. // end xmpp configs
  212.  
  213. // pushbullets configs
  214. c.notifiers.pushbullet = {}
  215. c.notifiers.pushbullet.on = false // false pushbullets disabled; true pushbullets enabled (key should be correct)
  216. c.notifiers.pushbullet.key = 'YOUR-API-KEY'
  217. c.notifiers.pushbullet.deviceID = 'YOUR-DEVICE-ID'
  218. // end pushbullets configs
  219.  
  220. // ifttt configs
  221. c.notifiers.ifttt = {}
  222. c.notifiers.ifttt.on = false // false ifttt disabled; true ifttt enabled (key should be correct)
  223. c.notifiers.ifttt.makerKey = 'YOUR-API-KEY'
  224. c.notifiers.ifttt.eventName = 'zenbot'
  225. // end ifttt configs
  226.  
  227. // slack config
  228. c.notifiers.slack = {}
  229. c.notifiers.slack.on = false
  230. c.notifiers.slack.webhook_url = ''
  231. // end slack config
  232.  
  233. // discord configs
  234. c.notifiers.discord = {}
  235. c.notifiers.discord.on = false // false discord disabled; true discord enabled (key should be correct)
  236. c.notifiers.discord.id = 'YOUR-WEBHOOK-ID'
  237. c.notifiers.discord.token = 'YOUR-WEBHOOK-TOKEN'
  238. c.notifiers.discord.username = '' // default "Zenbot"
  239. c.notifiers.discord.avatar_url = ''
  240. c.notifiers.discord.color = null // color as a decimal
  241. // end discord configs
  242.  
  243. // prowl configs
  244. c.notifiers.prowl = {}
  245. c.notifiers.prowl.on = false // false prowl disabled; true prowl enabled (key should be correct)
  246. c.notifiers.prowl.key = 'YOUR-API-KEY'
  247. // end prowl configs
  248.  
  249. // textbelt configs
  250. c.notifiers.textbelt = {}
  251. c.notifiers.textbelt.on = false // false textbelt disabled; true textbelt enabled (key should be correct)
  252. c.notifiers.textbelt.phone = '3121234567'
  253. c.notifiers.textbelt.key = 'textbelt'
  254. // end textbelt configs
  255.  
  256. // pushover configs
  257. c.notifiers.pushover = {}
  258. c.notifiers.pushover.on = false // false pushover disabled; true pushover enabled (keys should be correct)
  259. c.notifiers.pushover.token = 'YOUR-API-TOKEN' // create application and supply the token here
  260. c.notifiers.pushover.user = 'YOUR-USER-KEY' // this is your own user's key (not application related)
  261. c.notifiers.pushover.priority = '0' // choose a priority to send zenbot messages with, see https://pushover.net/api#priority
  262. // end pushover configs
  263.  
  264. // telegram configs
  265. c.notifiers.telegram = {}
  266. c.notifiers.telegram.on = false // false telegram disabled; true telegram enabled (key should be correct)
  267. c.notifiers.telegram.bot_token = 'YOUR-BOT-TOKEN'
  268. c.notifiers.telegram.chat_id = 'YOUR-CHAT-ID' // the id of the chat the messages should be send in
  269. // end telegram configs
  270.  
  271. // output
  272. c.output = {}
  273.  
  274. // REST API
  275. c.output.api = {}
  276. c.output.api.on = true
  277. c.output.api.ip = '0.0.0.0' // IPv4 or IPv6 address to listen on, uses all available interfaces if omitted
  278. c.output.api.port = 0 // 0 = random port
Add Comment
Please, Sign In to add comment