From 7cf0ca5cd39c21d1e1a113e4e26c4a476a49716b Mon Sep 17 00:00:00 2001 From: "zihao.jiang" Date: Wed, 18 Oct 2023 10:46:12 +0800 Subject: [PATCH] fix --- okx/SpreadTrading.py | 2 +- okx/__init__.py | 2 +- okx/consts.py | 12 ++++++++++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/okx/SpreadTrading.py b/okx/SpreadTrading.py index d1ba162..5dadd52 100644 --- a/okx/SpreadTrading.py +++ b/okx/SpreadTrading.py @@ -2,7 +2,7 @@ from .client import Client from .consts import * -class SpreadAPI(Client): +class SpreadTradingAPI(Client): def __init__(self, api_key='-1', api_secret_key='-1', passphrase='-1', use_server_time=False, flag='1', domain = 'https://www.okx.com',debug = True): Client.__init__(self, api_key, api_secret_key, passphrase, use_server_time, flag, domain,debug) diff --git a/okx/__init__.py b/okx/__init__.py index d03ebb0..118fbbf 100644 --- a/okx/__init__.py +++ b/okx/__init__.py @@ -2,4 +2,4 @@ Python SDK for the OKX API v5 """ -__version__="0.2.2" \ No newline at end of file +__version__="0.2.3" \ No newline at end of file diff --git a/okx/consts.py b/okx/consts.py index aec0f09..1b137d6 100644 --- a/okx/consts.py +++ b/okx/consts.py @@ -277,3 +277,15 @@ GET_PROFIT_SHARING_DETAILS = '/api/v5/copytrading/profit-sharing-details' GET_TOTAL_PROFIT_SHARING = '/api/v5/copytrading/total-profit-sharing' GET_UNREALIZED_PROFIT_SHARING_DETAILS = '/api/v5/copytrading/unrealized-profit-sharing-details' +# Spread Trading˚ +SPREAD_PLACE_ORDER= '/api/v5/sprd/order' +SPREAD_CANAEL_ORDER = '/api/v5/sprd/cancel-order' +SPREAD_CANAEL_ALL_ORDERS = '/api/v5/sprd/mass-cancel' +SPREAD_GET_ORDER_DETAILS = '/api/v5/sprd/order' +SPREAD_GET_ACTIVE_ORDERS = '/api/v5/sprd/orders-pending' +SPREAD_GET_ORDERS = '/api/v5/sprd/orders-history' +SPREAD_GET_TRADES = '/api/v5/sprd/trades' +SPREAD_GET_SPREADS = '/api/v5/sprd/spreads' +SPREAD_GET_ORDER_BOOK = '/api/v5/sprd/books' +SPREAD_GET_TICKER = '/api/v5/sprd/ticker' +SPREAD_GET_PUBLIC_TRADES = '/api/v5/sprd/public-trades'