You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 16, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Jul 16, 2026. It is now read-only.
I would like to place an order to close a long position in futures dual position mode.
The API manual says "In dual position mode, to close one side position, you need to set auto_size side, reduce_only to true and size to 0",
so I coded and ran it as follows.
models_1.ObjectSerializer.serialize(futuresOrder, 'FuturesOrder') is supposed to check the values of the input params and convert case to lowercase letters, etc., but there was a problem with the conversion of the auto_size part. But, I solved it by just changing that part of futuresApi.js without touching the model object code.
Activity
zhouguanglong1 commentedon Dec 2, 2023
maybe you can try by this way
peacmake commentedon Dec 2, 2023
I solved it by changing line 868 of the node_modules/gate-api/dist/api/futuresApi.js source code as follows.
models_1.ObjectSerializer.serialize(futuresOrder, 'FuturesOrder') is supposed to check the values of the input params and convert case to lowercase letters, etc., but there was a problem with the conversion of the auto_size part. But, I solved it by just changing that part of futuresApi.js without touching the model object code.