asset list FX CFD with Interactive Brokers

Posted By: fab

asset list FX CFD with Interactive Brokers - 03/26/20 17:23

Hi,
Im trying to create an asset list of G10 currency pairs to be used with Interactive Brokers.
Obviously I went through this page https://zorro-trader.com/manual/en/ib.htm
but I cannot figure out how to specify that I dont want IDEALPRO symbols but CFD (and CFDs are prices using IDEALPRO underliers)

basically Im using the default value in the name field (EUR/USD) but in the symbol field Im not sure how to tell zorro/ib that I want CFD, not Spot FX.

I've tried all possible combinations as far as I can tell, but I always get Error 053: EUR/USD unavailable at this time.

attempts

EUR.USD-CFD-SMART
EUR/USD-CFD-SMART
EUR.USD-CFD-IDEALPRO
EUR/USD-CFD-IDEALPRO
EUR.USD-CFD
EUR/USD-CFD

Any help much appreciated.

Thanks
Posted By: jcl

Re: asset list FX CFD with Interactive Brokers - 03/27/20 07:07

Are you sure that IB has those CFDs? I never heard of them.
Posted By: fab

Re: asset list FX CFD with Interactive Brokers - 03/27/20 07:50

Hi jcl,

I have a UK based account, and this is the link to the information page on IBK website

https://ibkb.interactivebrokers.com/node/2707

thanks
Posted By: jcl

Re: asset list FX CFD with Interactive Brokers - 03/27/20 08:06

Ok, then you have to experiment with the symbol - the usual IB API problem. Try this:

EUR-CFD-IDEALPRO-USD

or variants.
Posted By: fab

Re: asset list FX CFD with Interactive Brokers - 03/27/20 08:12

and this is a screenshot from my TWS where EUR.USD CFD ticking, and selection for the pair GBP.USD is asking whether I want the CASH or CFD product..

https://paste.pics/8GHG6
Posted By: jcl

Re: asset list FX CFD with Interactive Brokers - 03/27/20 09:47

That would be then

GBP-CFD-SMART-USD
Posted By: fab

Re: asset list FX CFD with Interactive Brokers - 03/27/20 10:01

that worked ! thanks a lot
Posted By: fab

Re: asset list FX CFD with Interactive Brokers - 03/30/20 12:56

Hi jcl,

I thought it worked as I was no longer seeing Error "053: XYZ unavailable at this time" when running my script.
however when I started running TradeTest to try and populate asset list properly, I realized the issue was still there
in Zorro log I see 053, but when I look at TWS api log I see the "market data in not provided" error message, which at times also pops in Zorro.
Now I definitely have all the instruments in my asset list currently ticking fine in TWS. both CFDs and underlying pairs.
please take a look at my screenshot and let me know what you think

https://paste.pics/8HKMT

thanks
Posted By: fab

Re: asset list FX CFD with Interactive Brokers - 03/30/20 16:06

But if I run the ApiDemo provided with the Java API download, Im able to select EUR CFD SMART USD and submit and order that I can immediately see filled in TWS.
While through Zorro TestTrade script I've only been able to transmit CASH FX orders

see screenshot. the culprit must be in the Asset List Symbol format

https://paste.pics/8HNC4

thanks
Posted By: fab

Re: asset list FX CFD with Interactive Brokers - 04/01/20 06:25

Hi jcl,

in Zorro manual the following statement sheds some light on the possible issue we are facing here.

--
Two special symbol types are supported by the bridge. The type STKCFD trades as a CFD, but gets the price quotes and historical prices of the underlying stock. This is useful for stock CFDs (f.i. AAPL-STKCFD) which can be traded, but get no price quotes from IB. The type FUTX can be used for downloading historical data of expired futures contracts.
--

Given that FX CFD have similar behaviour at IB, as in they can be traded, but quotes are to be taken from the underlier, it sounds like a similar approach would be needed by Zorro to fully support FX CFD.

Please confirm if my understanding is correct.

Many thanks
Posted By: jcl

Re: asset list FX CFD with Interactive Brokers - 04/01/20 17:18

Yes, it's entirely possible that Fx CFDs can only be traded, but get no prices via API. But newer Zorro versions support this with a symbol string, special types like STKCFD are not needed anymore. The symbol to get prices from GBP/USD cash, but trade the GBP/USD CFD would look like this:

GBP-CFD-SMART-USD!GBP/USD!GBP/USD
© 2024 lite-C Forums