WebSocket API
Data
DataMaxi+ currently provides the following datasets through WebSocket API.
Announcement
CEX
Forex
Authentication
All WebSocket endpoints are protected by an API key, which you can obtain upon registering at https://datamaxiplus.com/login. To learn more about WebSocket API authentication you can refer to the Authentication page.
Ping
The DataMaxi+ WebSocket server sends protocol-level Ping frames every 30 seconds to every connected client. Compliant WebSocket libraries respond automatically with a Pong frame — no application-level code is needed to keep the connection alive.
Clients may additionally send an application-level PING message shown below (for example, as a client-side health check). It is not required to keep the connection alive, but sending it will not disconnect you.
Connections that go longer than 30 minutes without any traffic (protocol pings, app-level pings, or subscribed data) will be closed by the server. In practice, our 30-second server-initiated protocol pings mean an idle connection stays open indefinitely as long as the client's WebSocket library responds to Pong.
We recommend implementing exponential-backoff reconnect logic on the client to survive transient network issues (mobile hand-off, brief upstream restarts, etc.).
- schema
- example
{
"method": "PING",
"params": [],
"id": int32
}
{
"method": "PING",
"params": [],
"id": 1
}