discrepancy between live/testnet urls

basic_buy_bot
Ebisu 2023-07-12 01:49:17 +02:00
parent 35af5f11fa
commit 2ac8191722
2 changed files with 4 additions and 4 deletions

View File

@ -254,7 +254,7 @@ async def open_trade_dialog(
wss: NoBsWs wss: NoBsWs
async with ( async with (
client.manage_listen_key() as listen_key, client.manage_listen_key() as listen_key,
open_autorecon_ws(f'{wss_url}/ws/{listen_key}') as wss, open_autorecon_ws(f'{wss_url}/?listenKey={listen_key}') as wss,
): ):
nsid: int = time_ns() nsid: int = time_ns()
await wss.send_msg({ await wss.send_msg({

View File

@ -45,8 +45,8 @@ _spot_ws: str = 'wss://stream.binance.com/ws'
# 'wss://ws-api.binance.com:443/ws-api/v3', # 'wss://ws-api.binance.com:443/ws-api/v3',
# https://binance-docs.github.io/apidocs/futures/en/#websocket-market-streams # https://binance-docs.github.io/apidocs/futures/en/#websocket-market-streams
_futes_ws: str = f'wss://fstream.{_domain}/ws/' _futes_ws: str = f'wss://fstream.{_domain}/ws'
_auth_futes_ws: str = 'wss://fstream-auth.{_domain}/ws/' _auth_futes_ws: str = 'wss://fstream-auth.{_domain}/ws'
# test nets # test nets
# NOTE: spot test network only allows certain ep sets: # NOTE: spot test network only allows certain ep sets:
@ -58,7 +58,7 @@ _testnet_spot_ws: str = 'wss://testnet.binance.vision/ws'
# 'wss://testnet.binance.vision/ws-api/v3' # 'wss://testnet.binance.vision/ws-api/v3'
_testnet_futes_url: str = 'https://testnet.binancefuture.com' _testnet_futes_url: str = 'https://testnet.binancefuture.com'
_testnet_futes_ws: str = 'wss://stream.binancefuture.com' _testnet_futes_ws: str = 'wss://stream.binancefuture.com/ws'
MarketType = Literal[ MarketType = Literal[