Websocket

This page documents the WebSocket API for real-time updates available at ws.sugar.money

The API delivers real-time updates on token events like new launches, trades, and migrations. Each token event follows a common schema, Token. Specifically, the TokenTradeEvent event includes a trade_data attribute, defined by TokenTradeData.

SDKs

To make integration easier, we provide official SDKs:

  • Node.js SDK (UPDATE THIS WHEN THE NEW SDK IS LIVE)

  • Rust SDK: Coming soon! 🦀

Generic Message Format

All events are sent as generic messages with the following format:

{
  type: string;
  data: object;
};

Available Event Types:

  • SolanaPrice: 'solana_price'

  • NewToken: 'new_token'

  • TokenCreate: 'token_create'

  • TokenTrade: 'token_trade'

  • TokenMigrated: 'token_migrate'

  • TokenCompleted: 'token_complete'

  • TokenFeatured: 'token_featured'

  • TokenComment: 'token_comment'

Last updated