Logon issue
Logon issue
10 Mar 2017, 17:54
Hello,
I am sending a logon:
8=FIX.4.49=11235=A34=149=pepperstone.XXX50=QUOTE52=20170310-15:13:10.94956=cServer98=0108=0553=XXX554=XXX10=156
And get a log off as answer:
8=FIX.4.49=15235=534=149=cServer52=20170310-15:13:17.14456=pepperstone.XXX57=QUOTE58=TargetSubID is assigned with the unexpected value '', expected 'QUOTE'10=095
Could you kindly check my logon message as I do not find the error and tried a lot of changes but none of them worked.
Greetings,
Jan.
Replies
#EOL
13 Mar 2017, 15:49
RE:
j.tarno said:
I am sending a logon:
8=FIX.4.4|9=112|35=A|34=1|49=pepperstone.XXX|50=QUOTE|52=20170310-15:13:10.949|56=cServer|98=0|108=0|553=XXX|554=XXX|10=156
Hi Jan
You should set field TargetSubID (tag 57) to QUOTE for your outgoint FIX messages and set SenderSubID (tag 50) to any string you want or don't set it at all.
From the other hand, server will respond you with FIX messages with QUOTE in SenderSubID (tag 50), so, don't be confused with this, take a look on Exaples section (chapter 5) of the specification: https://www.spotware.com/pdf/cTraderFixApi_v2.9.1.pdf?v2.9.1
Good luck
@#EOL
j.tarno
16 Mar 2017, 22:46
Hi,
thank you for your answers. When I change tag 50 I simply do not get no answer at all from the server. Here is what I send:
8=FIX.4.49=13035=A34=149=pepperstone.XYZ50=101701452=20170316-20:36:27.66256=CSERVER57=QUOTE98=0108=30141=Y553=XYZ554=XXX10=075
I cannot figure out what´s the differnce to the example log on from https://www.spotware.com/pdf/cTraderFixApi_v2.9.1.pdf?v2.9.1. Can someone who has a working logon kindly post his/her logon message that is working? I tried plain text socket and SSL.
Regards,
Jan
@j.tarno
#EOL
20 Mar 2017, 10:40
That's strange. This log works for me and I don't see any major difference comparing with yours.
< 8=FIX.4.4|9=115|35=A|49=pepperstone.3185673|56=CSERVER|34=1|52=20170320-08:10:50|57=QUOTE|141=Y|108=30|98=0|553=3185673|554=sqR0de|10=134| > 8=FIX.4.4|9=96|35=A|34=1|49=CSERVER|50=QUOTE|52=20170320-08:10:50.125|56=pepperstone.3185673|98=0|108=30|141=Y|10=198|
What host and port do you use?
@#EOL
Spotware
20 Mar 2017, 10:56
Hi j.tarno
This is an example of a login message for a pepperstone demo account
8=FIX.4.4|9=120|35=A|49=pepperstone.3185604|56=CSERVER|57=QUOTE|50=3185604|34=1|52=20170320-08:50:58|98=0|108=30|553=3185604|554=password|10=090|
and this is the reply
8=FIX.4.4|9=101|35=A|34=1|49=CSERVER|50=QUOTE|52=20170320-08:50:58.122|56=pepperstone.3185604|57=3185604|98=0|108=30|10=212|
You can use our FIX API code sample to see how the messages are constructed. You can find it here. You can use your credentials in the example and test it.
@Spotware
Spotware
13 Mar 2017, 14:29
Hi j.tarno,
Tag 50 is wrong. It should be your account's id. Please check the FIX API sample here to see how to properly contruct a logon message https://github.com/spotware/FIX-API-Sample
Best Regards,
@Spotware