MousaZourob / PyTrader

Automatic trading bot that uses market data to buy or sell stocks (back-end for Falcon)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PyTrader

Overview:

Automatic trading bot that streams market data of specific instruments to buy or sell them by placing bracket orders (back-end for Falcon).

Data Flow:

1. TradingView alert is set off creating a JSON message containing ticker parameters such as open and closing price
2. Using TradingView webhooks, a POST request containing the JSON message is sent to a REST API (AWS Lambda function)
3. This executes a Python script running through the AWS Chalice Serverless Framework
4. The Python script then executes a bracket order using the Alpaca API Paper Trading API (tested requests live and offline using Insomnia REST API Client)

Demo:

1. Deploy Chalice REST API using CMD


2. Set up alerts using Trading View and set Webhook URL to Chalice REST API URL


3. Wait till alarm is triggered and orders are placed through Alpaca

Libraries and Frameworks Used:

About

Automatic trading bot that uses market data to buy or sell stocks (back-end for Falcon)


Languages

Language:Python 100.0%