Skip to content

daniel-lalaina-movile/cryptobash

Repository files navigation

Current capabilities

  • Rebalance all your wallet portifolio based on configuration file (Binance ✔️ / Gate.io ✔️ / FTX ✔️ )
  • Show your results and the balance details represented in USDT BTC FIAT. (Binance ✔️ / Gate.io ✔️ / FTX ✔️ )
  • Sell every token asap at market price (Binance ✔️ / Gate.io ✔️ / FTX ✔️ )
  • Make basic orders at market price (Binance ✔️ / Gate.io ✔️ / FTX ✔️ )
  • Send Telegram messages about your wallet and results. ✔️✔
  • Run as daemon and execute every N minutes. ✔️

Example:

  • `./crypto.bash -p overview

2021-09-10 00-32-42

Installation step 1:

  • git clone git@github.com:daniel-lalaina-movile/cryptobash.git
    (or git clone https://github.com/daniel-lalaina-movile/cryptobash.git)

  • cd cryptobash

  • cp .credentials-example .credentials

  • Include your API credentials in .credentials file
    (If you use only one some exchanges, just keep the other ones empty.)

If you want to receive messages about results and balance:

  • Open @BotFather ( https://telegram.me/BotFather ) in Telegram and click the /start command

  • Send the command /newbot

  • Give a name to the bot

  • Create a username for the bot

  • The godfather will write you a message with the bot url, and your token, so:
    First, copy your token, it should be something like 8394726483:AAGSnTm4FOdmXZkjdoeys8476hcplnZVzkM
    Second, click in the bot url, then click /start and send a "hello" msg to the bot. (It shouln't answer anything, that's right) Third, click on the link below, and copy the chat_id that appears in the the page. (REPLACE XXXXXXXXXXXXXXXXXXXXXX your token) https://api.telegram.org/botXXXXXXXXXXXXXXXXXXXXXXXXXXXX/getUpdates

  • Include your telegram token and chat_id, in the file .credentials

If you want to see your results:

  • cp .fiat_deposits-example .fiat_deposits

  • Include the deposits or sum of deposits in .fiat_deposits

If you want to rebalance your wallet portifolio:

  • You need to have USDT funds in your wallet, it's the most listed and liquid stable currency, so it's easier to operate.

  • cp .rebalance-example .rebalance

  • Cryptobash will make all the necessary orders to get what you put in this file.
    First column is the token without pair
    Second column is the USDT amount.
    It will always try to buy the token/USDT pair. If it's not listed in the exchange, it will see if BTC is listed, and if so, it will buy BTCUSDT first, and then token/BTC.

Installation step 2

Running:

  • ./crypto.bash -h

Security

  • As we are talking about people's money, it's better to be sure about compatibility, so Docker is mandatory, because now a days it's almost impossible to assure 100% POSIX to work in Mac, Debian, Redhat, etc.

  • Instead of creating a custom image already ready2go, I opted to use an official docker image, and include the system and the necessary packages only in the docker build. And I did that because I wouldn't use someone's image to take care of my money, so I don't want you/others to use a custom image also.

  • ATTENTION: Never share your API keys with other people!

Donate

Cryptocurrencies Network Address
pngfind com-cnbc-logo-png-1429336
(or any ERC20)
Ethereum (ERC20) 0x930379d0feDB4e3AE6c39144fCD5f29f08Ee8235
Binance-Logo wine Binance Smart Chain (BSC) 0xa9A739734a2F740C8f998DDFe408bC9e39E3B415

TODO:

  • Logs