-
-
Save Gwill/1c1f84341a0815afc76d64927093b0de to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import sys | |
| from ibapi.contract import * | |
| from ibapi.order import Order | |
| from ibapi import wrapper | |
| from ibapi.client import EClient | |
| contract = Contract() | |
| contract.symbol = "SIE" | |
| contract.secType = "STK" | |
| contract.currency = "EUR" | |
| contract.exchange = "SMART" | |
| order = Order() | |
| order.action = "BUY" | |
| order.orderType = "LMT" | |
| order.totalQuantity = 100 | |
| order.lmtPrice = 20 | |
| w = wrapper.EWrapper() | |
| c = EClient(w) | |
| c.connect("127.0.0.1", 7496, clientId=0) | |
| c.placeOrder(1, contract, order) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment