vnpy_okx 2025.10.5__py3-none-any.whl → 2025.10.29__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- vnpy_okx/__init__.py +1 -1
- vnpy_okx/okx_gateway.py +3 -9
- {vnpy_okx-2025.10.5.dist-info → vnpy_okx-2025.10.29.dist-info}/METADATA +2 -2
- vnpy_okx-2025.10.29.dist-info/RECORD +6 -0
- vnpy_okx-2025.10.5.dist-info/RECORD +0 -6
- {vnpy_okx-2025.10.5.dist-info → vnpy_okx-2025.10.29.dist-info}/WHEEL +0 -0
- {vnpy_okx-2025.10.5.dist-info → vnpy_okx-2025.10.29.dist-info}/licenses/LICENSE +0 -0
vnpy_okx/__init__.py
CHANGED
vnpy_okx/okx_gateway.py
CHANGED
|
@@ -720,7 +720,7 @@ class RestApi(RestClient):
|
|
|
720
720
|
if product == Product.SPOT:
|
|
721
721
|
size: float = 1
|
|
722
722
|
else:
|
|
723
|
-
size = float(d["
|
|
723
|
+
size = float(d["ctVal"])
|
|
724
724
|
|
|
725
725
|
match product:
|
|
726
726
|
case Product.SPOT:
|
|
@@ -1602,16 +1602,10 @@ class PrivateApi(WebsocketApi):
|
|
|
1602
1602
|
"side": DIRECTION_VT2OKX[req.direction],
|
|
1603
1603
|
"ordType": ORDERTYPE_VT2OKX[req.type],
|
|
1604
1604
|
"px": str(req.price),
|
|
1605
|
-
"sz": str(req.volume)
|
|
1605
|
+
"sz": str(req.volume),
|
|
1606
|
+
"tdMode": "cross" # Only support cross margin mode
|
|
1606
1607
|
}
|
|
1607
1608
|
|
|
1608
|
-
# Set trading mode based on product type
|
|
1609
|
-
# "cash" for spot trading, "cross" for futures/swap with cross margin
|
|
1610
|
-
if contract.product == Product.SPOT:
|
|
1611
|
-
arg["tdMode"] = "cash"
|
|
1612
|
-
else:
|
|
1613
|
-
arg["tdMode"] = "cross"
|
|
1614
|
-
|
|
1615
1609
|
# Create websocket request with unique request ID
|
|
1616
1610
|
self.reqid += 1
|
|
1617
1611
|
packet: dict = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: vnpy_okx
|
|
3
|
-
Version: 2025.10.
|
|
3
|
+
Version: 2025.10.29
|
|
4
4
|
Summary: OKX trading gateway for VeighNa.
|
|
5
5
|
Project-URL: Homepage, https://www.github.com/veighna-global
|
|
6
6
|
Project-URL: Source, https://www.github.com/veighna-global
|
|
@@ -33,7 +33,7 @@ Description-Content-Type: text/markdown
|
|
|
33
33
|
</p>
|
|
34
34
|
|
|
35
35
|
<p align="center">
|
|
36
|
-
<img src ="https://img.shields.io/badge/version-2025.10.
|
|
36
|
+
<img src ="https://img.shields.io/badge/version-2025.10.29-blueviolet.svg"/>
|
|
37
37
|
<img src ="https://img.shields.io/badge/platform-windows|linux|macos-yellow.svg"/>
|
|
38
38
|
<img src ="https://img.shields.io/badge/python-3.10|3.11|3.12|3.13-blue.svg" />
|
|
39
39
|
<img src ="https://img.shields.io/github/license/veighna-global/vnpy_okx.svg?color=orange"/>
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
vnpy_okx/__init__.py,sha256=vUnGYogYnu32lZCuriZ2dgrXVbdkCWNqu-aRO0F1SZg,1248
|
|
2
|
+
vnpy_okx/okx_gateway.py,sha256=ixXHZ9gblBpeo6VpfjybHXRAChlCVLfCVweQE0vlUaE,71732
|
|
3
|
+
vnpy_okx-2025.10.29.dist-info/METADATA,sha256=e1F-yrP7CxsVjrfJK-iBpxQU0XUzgrxUISgz1wtPgYM,2841
|
|
4
|
+
vnpy_okx-2025.10.29.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
5
|
+
vnpy_okx-2025.10.29.dist-info/licenses/LICENSE,sha256=vKkW-EmD7w-5lDDjg15L8feZ1nkQeNpEHfyO2v9tprs,1099
|
|
6
|
+
vnpy_okx-2025.10.29.dist-info/RECORD,,
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
vnpy_okx/__init__.py,sha256=DZNB0B9tfZAjsJMN0AaizjZfy61gdCMy3Jsmscltm6I,1248
|
|
2
|
-
vnpy_okx/okx_gateway.py,sha256=FV2FPxOIRmf8H7FjeW3WprIdrQSlQh7vPTltdJx5dww,71927
|
|
3
|
-
vnpy_okx-2025.10.5.dist-info/METADATA,sha256=RHdtoelyQej_WSq3bXUeuohUw1NtPxxWrfkWS3Lkcww,2840
|
|
4
|
-
vnpy_okx-2025.10.5.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
5
|
-
vnpy_okx-2025.10.5.dist-info/licenses/LICENSE,sha256=vKkW-EmD7w-5lDDjg15L8feZ1nkQeNpEHfyO2v9tprs,1099
|
|
6
|
-
vnpy_okx-2025.10.5.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|