BUSD/WBNBSpot
Dodo V2 Dpp · BNB Chain
- Last trade
- Unlock Last trade
- 24h change
- Unlock 24h change
- 24h range
- Unlock 24h range
- 24h volume
- Unlock 24h volume
Prices and trades of this tokenized version come with the feed
Price history, live trades and volume for this market are part of Dune's Spot Feed.
Code
import asyncio, json, os, websockets
async def main():
async with websockets.connect("wss://api.dune.com/api/v1/feed") as ws:
await ws.send(json.dumps({"id": 1, "type": "auth", "api_key": os.environ["DUNE_API_KEY"]}))
await ws.send(json.dumps({"id":2,"type":"subscribe","instruments":["WBNB-BUSD.DDV2DPP.BNB"]}))
async for frame in ws:
msg = json.loads(frame)
for trade in msg.get("trades", []):
print(trade["instrument_code"], trade["side"], trade["executed_price"],
trade["value"]["notional_usd"], trade["tx"]["hash"])
asyncio.run(main())