Skip to content

Commit

Permalink
Update ws-connection.md (#229)
Browse files Browse the repository at this point in the history
testnet-dex.binance.org is already decommissioned
  • Loading branch information
STdevK authored Nov 23, 2023
1 parent 576476b commit e5c2f92
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions docs/beaconchain/develop/api-reference/dex-api/ws-connection.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
Several data streams are exposed over standard WebSocket connections, which can be consumed by modern web browsers and server-side WebSocket libraries.

- The base endpoint for mainnet is: **wss://dex.binance.org/api/**.
- The base endpoint for testnet is: **wss://testnet-dex.binance.org/api/**.
- Each connection can consume a single stream or multiple streams may be multiplexed through one connection for more complex apps.
- All symbols in stream names are lowercase.

Expand All @@ -29,16 +28,6 @@ Using this method, stream names are specified in the URLs used to connect to the
const blockHeight = new WebSocket("wss://dex.binance.org/api/ws/$all@blockheight");
```

**Testnet Example:** Various methods of connecting to streams where stream names are provided in URLs:

```javascript
// for personal streams, ex: Account & Transfers
const accountAndOrdersFeeds = new WebSocket("wss://testnet-dex.binance.org/api/ws/<USER_ADDRESS>");

// for all symbols
const blockHeight = new WebSocket("wss://testnet-dex.binance.org/api/ws/$all@blockheight");
```

### Method 2: Subscribe to streams on demand

Using this method, streams are be consumed via subscribe and unsubscribe commands, sent through a single WebSocket connection.
Expand Down

0 comments on commit e5c2f92

Please sign in to comment.