Skip to content

chaychoong/crypto_paper_trading_bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Crypto Paper Trading Bot

This is a basic paper trading bot using market prices from Binance Futures.

Prerequisites

Telegram bot

  1. Create a Telegram bot using BotFather
  2. Note down the token

AWS Account

  1. Create a DynamoDB table with the following params:
    • Partition key: "pk"
    • Sort key: "sk"
  2. Create a index for the table with the following params:
    • Partition key: "sk"
    • Sort key: "is_open"
  3. Create an API on API Gateway that links to a Lambda
  4. Add the following environment variables to the Lambda
    • BOT_NAME: The bot's Telegram username
    • BOT_TOKEN: The bot's token
    • TABLE_NAME: Name of the DynamoDB table
    • IS_OPEN_INDEX_NAME: Name of the index created in step 2.
  5. Publish the API
  6. Use the setWebhook API to set the webhook to the URL under Stages > default > Invoke URL

Deployment

  1. Ensure you have a virtual environment set up (preferable under .venv)
  2. Install the requirements using pip install -r requirements.txt. Install awscli if you do not have it.
  3. Run FUNCTION_NAME=<name of the lambda> make

About

A Telegram bot for crypto paper trading

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published