charmtraders-apps / issue_tracker

Issue tracker and feature requests
2 stars 0 forks source link

Sending an order from OptiTrade to TOS error #12

Open 12Andresen opened 3 months ago

12Andresen commented 3 months ago

I do think I may have uncovered a potential bug for orders that OptiTrade sends to TOS.

Below is the order that OptiTrade generated for me to send to TOS, but when I pasted this order into TOS, I received an error.

BUY 1 -1/1/3/-9/6 CUSTOM SPX 100 17 Jan 25/17 Jan 25/17 Jan 25/17 Jan 25/17 Jan 25 6400/6000/5400/4875/4050 C/C/P/P/P @76.05 LMT

I believe the correct format for sending orders to TOS is like this:

BUY 1 -1/1/3/-9/6 CUSTOM SPX 100 17 Jan 25/17 Jan 25/17 Jan 25/17 Jan 25/17 Jan 25 6400/6000/5400/4875/4050 Call/Call/Put/Put/Put @76.05 LMT

Note, the ONLY difference is that the Call and Put word is filled out instead of abbreviated.

Can you please give this a try and let me know if that can be changed?

By the way, I have gained extensive experience with the coding nuances when trying to pass code orders into and out of TOS, so if there is any way I can help, please let me know.

charmtraders-apps commented 3 months ago

Thank you for bringing this to our attention. It appears that the issue you encountered may indeed be related to the formatting of the order syntax when sending orders from OptiTrade to TOS.

You mentioned that replacing the abbreviated option types with their full names (Call and Put) might resolve the issue. The only change would be expanding "C" to "Call" and "P" to "Put." Could you please test this modification to see if it resolves the error in TOS?

We appreciate your extensive experience with coding nuances related to TOS order submissions. Your expertise could be invaluable in ensuring the orders are formatted correctly and work seamlessly. If you have any suggestions or insights on this issue, we would be eager to hear them.

Thank you for your assistance. As we do not have direct access to TOS, your support in testing and confirming these changes is crucial. We have updated the format to replace P/C with Put/Call, but we will need to conduct further testing to ensure compatibility in all cases.

Please let us know if you encounter any further issues or if there is any other way we can assist you.

This fix will be released in our update of June 12. 2024