Replies

Groenewald.a.m
25 Jan 2023, 21:54 ( Updated at: 21 Dec 2023, 09:23 )

RE: No Hostname in Fix API Dialog.

I ran into the same issue. The way to resolve it is to use a reverse IP lookup (Nslookup.io for example) with the IP address to get the hostname. In this case 173.249.39.250 maps to 

h18.p.ctrader.com

 

 

85percent said:

PanagiotisChar said:

Hi, 

What do you mean "The hostname has disappeared"? Looks good to me.

Aieden Technologies

Need help? Join us on Telegram

Need premium support? Trade with us

 

 

 


@Groenewald.a.m

Groenewald.a.m
30 Nov 2022, 18:31

RE: No Hostname in Fix API Dialog.

I use the website but I did resolve it fine. I used a revers nslookup and entered the IP address from the FIX dialog which gave me a domain name. 

 

m


@Groenewald.a.m

Groenewald.a.m
27 Nov 2022, 22:30

No Hostname in Fix API Dialog.

Hi there, 

 

I think we are missing each other. The dialog that presents the FIX configuration on the cTrader website does not have the Hostname present, just the IP address. In other words, it looks like follows:

Host name: [there is no text here]
(Current IP address 178.62.53.225 can be changed without notice)
Port: 5211 (SSL), 5201 (Plain text)

 

And when I paste the IP address into the configuration It does not work. Does that make sense ?

 


@Groenewald.a.m

Groenewald.a.m
13 Apr 2022, 21:13

Fix heartbeat and connection issues. - fixed

Hi,

I downloaded the new version and it worked like a charm, ta !


@Groenewald.a.m

Groenewald.a.m
13 Apr 2022, 11:47

Fix heartbeat and connection issues.

Thank you for responding.

Yes, I based my work on your package (thank you, it gave me a great start)

The issue here is that the sample package does not do the kind of handshake that I am looking for. To be clear, as is the connection is re-established after the connection is terminated and the log-on happens through the Open Connection callback.

The problem here is that I have seen if a trade happens around that time, I get a 'Resend Request' which opens up a whole other can of worms which I will ask guidance on in a separate mail

What I am trying to achieve is to use the heartbeats to minimise the number of times a connection gets re-established and login happens again. If I leave the connection timeout at 30 seconds, the connection is re-esttablished every ~ 60 seconds (after heartbeat---30 seconds passes -- TestRequest --- 30 seconds passes --- Connection drops and reconnects then process repeats.)

In this scenario I need to have a real robust resend strategy. Here I will need to re-synchronise the FIX messageIDs and it does not look like I have an obvious way to set that in the python implementation. This is a bunch of work (if you have an example of this in any language it would be much apprecited)


@Groenewald.a.m

Groenewald.a.m
12 Apr 2022, 20:38

RE: Connect / disconnect cycle for Fix / Python

The problem went away, I suspect it had something todo with the Fix server.

Groenewald.a.m said:

Hi,

I use Fix / Python in my trading service

I continue to get continuous connection disconnects on the account below. The reset is almost immediate so I basically log on, i get a connection callback and then immediately a disconnection callback rendering the trading part of my service untestable.When I use my live account configuration  I dont get any connection resets on my live account - please advise.

 

Regards

{
  "Host": "h35.p.ctrader.com",
  "Port": 5202,
  "SSL": false,
  "Username": "9105135",
  "Password": "testing",
  "BeginString": "FIX.4.4",
  "SenderCompID": "demo.skilling.9105135",
  "SenderSubID": "TRADE",
  "TargetCompID": "CSERVER",
  "TargetSubID": "TRADE",
  "HeartBeat": "30"
}

 


@Groenewald.a.m

Groenewald.a.m
16 Mar 2022, 11:38

RE: Cannot access FIX API Password to test the FIX API using the Python example

I found the issue. Two things - the cTrade website did accept my password change request - but the confirmation dialog was internittent and the dialog did not show that anything was set - My suggestion would be to make it explicit in the dialog, for example: "Password: Set / Not set for acc.

3463567

 

 

Secondly, The demo's work fine. however the first instruction to be sent should be:

Command (ex: Help): LogonRequest ResetSeqNum=Y

Sent:  8=FIX.4.4|9=126|35=A|49=demo.ctrader.3463567|56=CSERVER|57=QUOTE|50=QUOTE|34=1|52=20220316-09:31:34|98=0|108=30|141=Y|553=3463567|554=testing|10=148|

Received:  8=FIX.4.4|9=106|35=A|34=1|49=CSERVER|50=QUOTE|52=20220316-09:31:34.706|56=demo.ctrader.3463567|57=QUOTE|98=0|108=30|141=Y|10=054|

 

After that other commands worked.

 

Finally, the console app after a short while breaks with the following message :

 

Command (ex: Help): Unhandled Error
Traceback (most recent call last):
  File "/Users/Michael/IdeaProjects/cTraderFixPy-main/samples/ConsoleSample/main.py", line 125, in <module>
    reactor.run()
  File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/twisted/internet/base.py", line 1318, in run
    self.mainLoop()
  File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/twisted/internet/base.py", line 1328, in mainLoop
    reactorBaseSelf.runUntilCurrent()
--- <exception caught here> ---
  File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/twisted/internet/base.py", line 994, in runUntilCurrent
    call.func(*call.args, **call.kw)
  File "/Users/Michael/IdeaProjects/cTraderFixPy-main/samples/ConsoleSample/main.py", line 80, in executeUserCommand
    userInput = inputimeout("Command (ex: Help): ", timeout=30)
  File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/inputimeout/inputimeout.py", line 32, in posix_inputimeout
    termios.tcflush(sys.stdin, termios.TCIFLUSH)
termios.error: (25, 'Inappropriate ioctl for device')

 


@Groenewald.a.m

Groenewald.a.m
16 Mar 2022, 09:20 ( Updated at: 21 Dec 2023, 09:22 )

RE: Cannot Set Fix password on Demo Account.

There is a pop up that appears for a second after i have changed the password but then it disappears. I have not made any changes to settings on the website. And this is the only notification setting page I could find.( I am using FireFox 97):

 

 

 

 

PanagiotisCharalampous said:

Hi Groenewald.a.m,

Can you please check if your Notifications are enabled and that your receive this notification when you change your account password?

Best Regards,

Panagiotis 

Join us on Telegram and Facebook

 


@Groenewald.a.m

Groenewald.a.m
16 Mar 2022, 08:47 ( Updated at: 21 Dec 2023, 09:22 )

Cannot Set Fix password on Demo Account.

Hi,

I am learning how to use the ctrade FIX API for experimentation. I get unstuck when I need to get the credentials from the https://ct.spotware.com/  website. When I go to Settings -> Advanced -> FIX API, there is no Password. When I select 'Change Password' and type in a new password, it still does not update the page, nor do I have success when I try to send a message using the Python console app provided by yourself. Please advise.

Regards


@Groenewald.a.m