Skip to content

Commit

Permalink
Feature: download specification (#110)
Browse files Browse the repository at this point in the history
* feat: json specification

* feat: add Handle brokerage message to log messages

* refactor: style json

* feat: missing support markets

* remove: not support market name
  • Loading branch information
Romazes authored May 2, 2024
1 parent 3d2118f commit 487c1c5
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,19 @@ public IBDataDownloader()
Config.Get("ib-trading-mode"),
Config.GetValue("ib-agent-description", Brokerages.InteractiveBrokers.Client.AgentDescription.Individual),
loadExistingHoldings: false);

_brokerage.Message += (object _, Brokerages.BrokerageMessageEvent e) =>
{
if (e.Type == Brokerages.BrokerageMessageType.Error)
{
Logging.Log.Error(e.Message);
}
else
{
Logging.Log.Trace(e.Message);
}
};

_brokerage.Connect();
}

Expand Down
41 changes: 40 additions & 1 deletion interactivebrokers.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,44 @@
"order-types": ["Market", "Limit", "Limit-If-Touched", "Stop Market", "Stop Limit", "Trailing", "Market On Open", "Market On Close", "Combo Market", "Combo Limit", "Combo Leg Limit", "Exercise"],
"assets": ["Equity", "Equity Options", "Futures", "Future Options", "Index Options", "Forex"],
"brokerage-url": "https://www.interactivebrokers.com/",
"documentation": "/docs/v2/cloud-platform/live-trading/brokerages/interactive-brokers"
"documentation": "/docs/v2/cloud-platform/live-trading/brokerages/interactive-brokers",
"module-specification": {
"download": {
"data-types": [
"Trade",
"Quote"
],
"resolutions": [
"Second",
"Minute",
"Hour",
"Daily"
],
"security-types": [
"Equity",
"Option",
"Forex",
"Future",
"Cfd",
"FutureOption",
"Index",
"IndexOption"
],
"markets": [
"USA",
"CME",
"NYMEX",
"COMEX",
"CBOT",
"CBOE",
"HKFE",
"SGX",
"ICE",
"CFE",
"NYSELIFFE",
"Oanda",
"InteractiveBrokers"
]
}
}
}

0 comments on commit 487c1c5

Please sign in to comment.