Double Orders & OpenAPIMessagesFactory Missed in Open API Library 6.7

Created at 06 May 2020, 19:19
How’s your experience with the cTrader Platform?
Your feedback is crucial to cTrader's development. Please take a few seconds to share your opinion and help us improve your trading experience. Thanks!
VA

vamsi.rc

Joined 05.05.2020

Double Orders & OpenAPIMessagesFactory Missed in Open API Library 6.7
06 May 2020, 19:19


Hi Team,

 

I am unable to proceed further with below 2 issues.

1. Every Order placing through Open API opening 2 orders. This issue from Open API 2.0 .Net Sample.sln. I have updated the Open API Library by following the instructions mentioned here : https://connect.spotware.com/docs/open_api_2/introduction_to_protocol_buffers_v2

2. After updating Open API Library 6.7, OpenAPIMessagesFactory disappeared and the application stopped working. Unable to find equivalent method for GetMessages functionality.

3. Further, request to provide the functionality / document to get Running Positions / Orders.

4. I found another issue in this OpenAPI. When I click on Get Orders button, I am getting below info, which doesn't have any info about orders / positions. 

Send: ProtoMessage{ReconcileRequest{}}
Received: ProtoMessage{ReconcileList{ID: True
Status: POSITION_STATUS_OPEN
Volume: 100000
ID: True
Status: POSITION_STATUS_OPEN
Volume: 100000
ID: True
Status: POSITION_STATUS_OPEN
Volume: 100000 }}

5. I didn't find any method returning PID.

I would like to request to update below repository for smooth functioning.

Thanks

R C Vamsi Vardhan


@vamsi.rc
Replies

PanagiotisCharalampous
07 May 2020, 09:05

Hi Vamsi,

1. We will need more information about this. You will need to provide us with the source code and steps to reproduce this behavior. It is almost certain that there is something wrong on your side.

2. You can find OpenAPIMessagesFactory here. Note that there are no instructions to update the Open API Library project. The instructions refer to updating only the proto classes found in the Proto folder.

3. Positions and pending orders can be retrieved using ProtoOAReconcileReq.

4. It seems to be a bug in the example project. Please go to OpenApiMessagesPresentation, Line 114 and change 

 sbReconcile.Append("ID: " + position.HasPositionId + Environment.NewLine);

to

sbReconcile.Append("ID: " + position.PositionId + Environment.NewLine);

5. See point 4

Best Regards,

Panagiotis 

Join us on Telegram


@PanagiotisCharalampous

vamsi.rc
07 May 2020, 09:13

RE: Will check and let you know.

Excellent Panagiotis!

Thanks for your time and support. I will go through it and update you.

R C Vamsi Vardhan

 

PanagiotisCharalampous said:

Hi Vamsi,

1. We will need more information about this. You will need to provide us with the source code and steps to reproduce this behavior. It is almost certain that there is something wrong on your side.

2. You can find OpenAPIMessagesFactory here. Note that there are no instructions to update the Open API Library project. The instructions refer to updating only the proto classes found in the Proto folder.

3. Positions and pending orders can be retrieved using ProtoOAReconcileReq.

4. It seems to be a bug in the example project. Please go to OpenApiMessagesPresentation, Line 114 and change 

 sbReconcile.Append("ID: " + position.HasPositionId + Environment.NewLine);

to

sbReconcile.Append("ID: " + position.PositionId + Environment.NewLine);

5. See point 4

Best Regards,

Panagiotis 

Join us on Telegram

 


@vamsi.rc