All Projects → hootnot → Oandapyv20 Examples

hootnot / Oandapyv20 Examples

Licence: mit
Examples demonstrating the use of oandapyV20 (oanda-api-v20)

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Oandapyv20 Examples

Oanda Api V20
OANDA REST-V20 API wrapper. Easy access to OANDA's REST v20 API with oandapyV20 package. Checkout the Jupyter notebooks!
Stars: ✭ 325 (+218.63%)
Mutual labels:  trading-bot, trading, finance, forex
AutoTrader
A Python-based development platform for automated trading systems - from backtesting to optimisation to livetrading.
Stars: ✭ 227 (+122.55%)
Mutual labels:  finance, trading, trading-bot, forex
Mida
The open-source and cross-platform trading framework
Stars: ✭ 263 (+157.84%)
Mutual labels:  finance, trading, trading-bot, forex
Lean
Lean Algorithmic Trading Engine by QuantConnect (Python, C#)
Stars: ✭ 5,675 (+5463.73%)
Mutual labels:  trading-bot, finance, forex, trading
Alpaca Backtrader Api
Alpaca Trading API integrated with backtrader
Stars: ✭ 246 (+141.18%)
Mutual labels:  trading-bot, trading, finance
Siis
Trading bot including terminal, for crypto and traditionals markets. Assisted or fully automated strategy.
Stars: ✭ 45 (-55.88%)
Mutual labels:  trading-bot, trading, forex
cira
Cira algorithmic trading made easy. A Façade library for simpler interaction with alpaca-trade-API from Alpaca Markets.
Stars: ✭ 21 (-79.41%)
Mutual labels:  finance, trading, trading-bot
Ostia
Ostia is a cryptocurrency trading platform that allows you to run algorithmic trading strategies across all major exchanges.
Stars: ✭ 61 (-40.2%)
Mutual labels:  finance, trading, trading-bot
Jiji2
Forex algorithmic trading framework using OANDA REST API.
Stars: ✭ 211 (+106.86%)
Mutual labels:  trading, finance, forex
binaryapi
Binary.com & Deriv.com API for Python
Stars: ✭ 32 (-68.63%)
Mutual labels:  trading, trading-bot, forex
Sequence-to-Sequence-Learning-of-Financial-Time-Series-in-Algorithmic-Trading
My bachelor's thesis—analyzing the application of LSTM-based RNNs on financial markets. 🤓
Stars: ✭ 64 (-37.25%)
Mutual labels:  finance, trading, forex
Trading Server
A multi-asset, multi-strategy, event-driven trade execution and management platform for running many algorithms/bots at many venues simultaneously with unified risk management and reporting. Uses MongoDB for storage and Telegram for user notifications/trade consent.
Stars: ✭ 191 (+87.25%)
Mutual labels:  trading-bot, trading, forex
Pipeline Live
Pipeline Extension for Live Trading
Stars: ✭ 154 (+50.98%)
Mutual labels:  trading-bot, trading, finance
Turingtrader
The Open-Source Backtesting Engine/ Market Simulator by Bertram Solutions.
Stars: ✭ 132 (+29.41%)
Mutual labels:  trading-bot, trading, finance
trading sim
📈📆 Backtest trading strategies concurrently using historical chart data from various financial exchanges.
Stars: ✭ 21 (-79.41%)
Mutual labels:  finance, trading, trading-bot
futu algo
Futu Algorithmic Trading Solution (Python) 基於富途OpenAPI所開發量化交易程序
Stars: ✭ 143 (+40.2%)
Mutual labels:  finance, trading, trading-bot
Bot18
Bot18 is a high-frequency cryptocurrency trading bot developed by Zenbot creator @carlos8f
Stars: ✭ 157 (+53.92%)
Mutual labels:  trading, finance, forex
Metatrader
Expert advisors, scripts, indicators and code libraries for Metatrader.
Stars: ✭ 99 (-2.94%)
Mutual labels:  trading, trading-bot, forex
Machine Learning And Ai In Trading
Applying Machine Learning and AI Algorithms applied to Trading for better performance and low Std.
Stars: ✭ 258 (+152.94%)
Mutual labels:  trading-bot, trading, finance
Stocksharp
Algorithmic trading and quantitative trading open source platform to develop trading robots (stock markets, forex, crypto, bitcoins, and options).
Stars: ✭ 4,601 (+4410.78%)
Mutual labels:  trading, finance, forex

oandapyV20 - examples

This repo contains a number of examples to demonstrate how to use OANDA's REST-V20 API with the oandapyV20_ Python API-wrapper.

.. _oandapyV20: https://github.com/hootnot/oanda-api-v20 .. _pydantic: https://github.com/samuelcolvin/pydantic

Setup

Install


Clone the repository:

.. code-block:: bash

   $ git clone https://github.com/hootnot/oandapyV20-examples


Install *oandapyV20* and other pypi-packages the examples depend on. Maybe
you want to do this from a *virtual environment*.

.. code-block:: bash

   $ pip install -r requirements.txt



Token
~~~~~

Access to the OANDA V20 REST-API requires a token. If you do not have a token
you can obtain one. Check developer.oanda.com_ for details.
Edit the file *token.txt*  and put the token in it.

.. _developer.oanda.com: http://developer.oanda.com

AccountID

If you have a token, you have an account. Edit the file account.txt and put the accountID in it. Verify that it is your V20 accountID!

Warning


   Make sure you have made the setup based on a **practice** account !
   Leveraged trading is high risk. Losses can exceed investment!



Examples
--------

All examples can be run from the cloned repo directory as:

.. code-block:: bash

   $ python src/<example.py>

.. |CONSOLE_APP| image:: oanda_console.gif
   :width: 500px


=============================  =============
Source                         Description
=============================  =============
**Account**
`src/instruments_list.py`      Get list of tradable instruments for account
**Streams**
`src/streaming_prices.py`      Simple streaming prices using pydantic_ to process records
`src/streaming_trans.py`       Simple streaming transactions
`src/concurrent_streaming.py`  Demonstrate concurrent streaming of prices and events along with the polling of account changes based on gevent greenlets
**Data**
`src/candle-data.py`           Retrieve candle data
**Orders**
`src/market_order.py`          Placing market orders / logging
`src/market_order_request.py`  Placing market orders using contrib.requests / logging
`src/contrib_mo_tp_sl.py`      Placing market order with takeprofit on-fill and stoploss on-fill
**Console**
`src/oanda_console.py`         Console application showing realtime tickdata (Linux/Unix only / python 3 only)
                               |CONSOLE_APP|
**Auto Trading**
`src/simplebot.py`             Simple trading bot based on a moving-average crossover. The bot gets initialized by retrieving the longest MA period of candles. After that new records are fabricated from the stream. When there is a state change an order is placed with a takeprofit and a stoploss order with it. 
                               The positions can be traced with the `src/oanda_console` application.
=============================  =============

About this software
-------------------
The *oanda-api-v20* / *oandapyV20* software is a personal project.
I have no prior or existing relationship with OANDA.

If you have any questions regarding this software, please take a look at
the documentation first:

 * oandapyV20 : http://oanda-api-v20.readthedocs.io/en/latest/?badge=latest
 * OANDA developer docs : http://developer.oanda.com
 * examples : https://github.com/hootnot/oandapyV20-examples
 * Github: https://github.com/hootnot/oanda-api-v20 check the open and closed issues

If you still have questions/issues you can open an *issue* on Gitub: https://github.com/hootnot/oanda-api-v20

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].