Interactive Brokers IBAPI - 无法获取 ForEx 合约的逐笔报价数据

Interactive Brokers IBAPI - Cannot get tick-by-tick data for ForEx contract

我正在使用 Interactive Brokers IBAPI 连接到 TWS 的 运行 实例。

我想获取外汇对 EUR/USD 的逐笔报价数据。 (特定的一对并不重要。)

我正在使用以下 API 函数来请求逐笔报价数据:

_ibClient.ClientSocket.reqTickByTickData(tickerId, contract, "Last", 0, false);

此调用适用于股票合约,例如 TSLA

ForEx 合约返回的错误消息是:

Error. Id: 2, Code: 10189, Msg: Failed to request tick-by-tick data:No historical market data for EUR/CASH@FXSUBPIP Last 0

我不是在请求历史数据。

这里是合约对象:

contract = new Contract
{
    Symbol = "EUR",
    SecType = "CASH",
    Exchange = "IDEALPRO",
    PrimaryExch = "IDEALPRO",
    Currency = "USD",
};

日志文件的内容如下:

Next Valid Id: 1
Account list: *********
Market data farm connection is OK:cashfarm
Market data farm connection is OK:usfarm
HMDS data farm connection is OK:euhmds
HMDS data farm connection is OK:cashhmds
HMDS data farm connection is OK:fundfarm
HMDS data farm connection is OK:ushmds
Sec-def data farm connection is OK:secdefil
Error. Id: 2, Code: 10189, Msg: Failed to request tick-by-tick data:No historical market data for EUR/CASH@FXSUBPIP Last 0

谁能帮我理解为什么我无法获得 ForEx 合约的逐笔报价数据?

最后一个不适用于外汇,只有中间点。它不在交易所交易。

_ibClient.ClientSocket.reqTickByTickData(tickerId, contract, "MidPoint", 0, false);

http://interactivebrokers.github.io/tws-api/tick_data.html

n.b。它将进入 public void tickByTickMidPoint(int reqId, long time, double midPoint)