Skip to content

talhaaltinkaya/binance-spot-order-notification-heroku

 
 

Repository files navigation

Welcome to Binance Spot Order Notifier(NodeJS) via Telegram👋

Binance order notification when order created, cancelled or filled etc.. With this repo you will receive telegram notification for your binance spot order status.

If You want Futures Positions Bot, Goto to Futures Position Notification Bot

Version License: MIT Twitter: PiyushDixit_

- when new commit happens, you need to create new heroku app using Deploy to heroku button, So that you can use the new feature.
- Supported Order Type: LIMIT, MARKET, STOP LOSS, STOP LOSS LIMIT, TAKE PROFIT, TAKE PROFIT LIMIT, LIMIT MAKER
- OCO not supported

Deploy to DO Deploy

Setup before Deploy

SETUP TELEGRAM BOT

  1. Create account on Telegram (skip if you have)
  2. Create Telegram Bot Goto Bot help follow steps at the END Copy TOKEN save to Notepad for later use
  3. Open created Bot and click START
  4. Goto @getuseridbot and click START and copy NUMERIC VALUE this is your CHAT ID save to Notepad for later use

SETUP BINANCE ACCOUNT

  1. Signup for Binance (skip if you have)
  2. Enable Two-factor Authentication (skip if you're done already)
  3. Go API Center, Create New Api Key and follow steps and at the END, SET API restrictions to **ENABLE READING ** only
  4. Copy API Key and Secret Key save to Notepad for later use

DEPLOY TO HEROKU

  1. Create account on Heroku (skip if you have)
  2. Login to Heroku (if you are not)
  3. Click Deploy

createAPP

  1. Give any name in "App name" field
  2. Fill required fields in "Config Vars"
  3. Click "Deploy app"
  4. When you see , "Your app was successfully deployed." then your bot started automatically.
  5. important step for preventing idling heroku app.
  6. Click Manage App

manageApp

  1. Click Heroku Scheduler

MopenScheduler

  1. Click Create job

createJob

  1. Enter your App URL On Run Command Text Box
  2. To get your APP URL Go to Step 10 Page Click Open App a new window open with your APP URL.

App URL

  1. Copy this URL look like this https://floating-fjord-30360.herokuapp.com/

Capture

  1. Paste This URL with curl On Run Command Text Box, Example curl https://floating-fjord-30360.herokuapp.com/

jobEditor

  1. Click Save Job

Give a ⭐️ if this project helped you!


Run Locally

  • Download and install NodeJs
  • Download Repo and open Repo root folder.
  • Create .env in root folder and copy , paste below code
TELEGRAM_TOKEN="your telegram token"
TELEGRAM_CHAT_ID="your telegram chat id"
BINANCE_API_KEY="binance api key"
BINANCE_SECRET_KEY="binance api secret"
TIME_ZONE_STRING="your time zone string"
NOTIFICATION_SETTINGS="[{'NEW': 1, 'CANCELED': 1, 'TRADE': 1},{'LIMIT': 1, 'MARKET': 1, 'STOP_LOSS': 1},{'BUY': 1, 'SELL': 1}]"
  • TIME_ZONE_STRING is not required. Default "Asia/Kolkata"
  • NOTIFICATION_SETTINGS is not required. Default [{"NEW":1,"CANCELED":1,"TRADE":1},{"LIMIT":1,"MARKET":1,"STOP_LOSS":1},{"BUY":1,"SELL":1}]

NOTIFICATION_SETTINGS Description

- 0 is Disable and 1 is Enable
- when 'NEW': 0 it means you will not notify when new order created.
- when 'LIMIT': 0 it means you will not notify any LIMIT order.
- Example 1 : if you want only Filled orders alert,
  so settings are [{'NEW': 0, 'CANCELED': 0, 'TRADE': 1},{'LIMIT': 1, 'MARKET': 1, 'STOP_LOSS': 1},{'BUY': 1, 'SELL': 1}]
- Example 2 : if you want only Sell Filled orders alert,
  so settings are [{'NEW': 0, 'CANCELED': 0, 'TRADE': 1},{'LIMIT': 1, 'MARKET': 1, 'STOP_LOSS': 1},{'BUY': 0, 'SELL': 1}]
- All settings depends on another settings.

Time zone string example "Asia/Kolkata" and this is not required. See Time zone string here

  • Edit required fields in .env file and save
  • Open terminal on current folder
  • Run this command to install npm install
  • Run this to start npm start

Donate using Binance Pay

Scan this QR Code Using Binance App Scanner

BinancePayQR

My Binance Pay ID

182311933

Author

👤 Piyush Dixit

Show your support

Give a ⭐️ if this project helped you!


If this library helped you out feel free to donate.

  • BTC: bc1qqewkmv335jdrt0jz6rn9sdm4jltd60qfw24fr9
  • ETH: 0xE7212AAD5A8cE7eb02eF9Bee05332A679811dAf1
  • NEO: AUp6giUAxQ3Y3RY8bUCuHrTa7HU25Ltuh4

📝 License

Copyright © 2021 @PiyushDixit96.
This project is MIT licensed.


About

[Binance order trade fill notification] Telegram Notification when Binance order created, cancelled or filled. Ready to Deploy on Heroku

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 99.8%
  • Procfile 0.2%