Server
Server utilities and health
Base URL https://api.lexx-trade.com/api/v2 · All endpoints
require Ed25519 request signatures unless marked "no auth" — see Authentication.
Get server time
Returns current server timestamp for clock synchronization (required for Ed25519 signing).
Request samples
curl 'https://api.lexx-trade.com/api/v2/server/time' // Public endpoint — plain fetch works too
const { data, meta } = await lexx("GET", "/server/time");
console.log(data); # Public endpoint — no signature required
res = lexx("GET", "/server/time")
print(res["data"]) Response 200 — Server time
data Current server time for Ed25519 signature synchronization
serverTime required Current server time as a Unix timestamp in milliseconds. Use this to compute the X-LEXX-TIMESTAMP header.
timezone required Server timezone (always "UTC")
meta Standard response envelope metadata included in every successful API response. Rate-limit state is NOT in the body — it is delivered via the X-RateLimit-* response headers.
requestId required Unique identifier for this API request, useful for support tickets and debugging
timestamp required Response timestamp in Unix milliseconds
version required API version
idempotencyKey Echoed back on a successful mutating request (POST/DELETE) when the caller sent an X-Idempotency-Key header. Absent otherwise.
Error responses (429, 500)
| 429 | Rate limit exceeded |
| 500 | Internal server error |
All errors share the { error: { code, status, message }, meta } envelope —
see Errors for every code.
Get API status
Returns API health and exchange connectivity status.
Request samples
curl 'https://api.lexx-trade.com/api/v2/server/status' // Public endpoint — plain fetch works too
const { data, meta } = await lexx("GET", "/server/status");
console.log(data); # Public endpoint — no signature required
res = lexx("GET", "/server/status")
print(res["data"]) Response 200 — Service status
data API status
status required Overall API health (currently a constant "operational")
apiVersion API version string
timestamp Server time (Unix ms) when the status was generated
meta Standard response envelope metadata included in every successful API response. Rate-limit state is NOT in the body — it is delivered via the X-RateLimit-* response headers.
requestId required Unique identifier for this API request, useful for support tickets and debugging
timestamp required Response timestamp in Unix milliseconds
version required API version
idempotencyKey Echoed back on a successful mutating request (POST/DELETE) when the caller sent an X-Idempotency-Key header. Absent otherwise.
Error responses (429, 500)
| 429 | Rate limit exceeded |
| 500 | Internal server error |
All errors share the { error: { code, status, message }, meta } envelope —
see Errors for every code.
Get build/version info
Returns service name, API version, Node runtime, and uptime. Unauthenticated, like the other /server/* endpoints.
Request samples
curl 'https://api.lexx-trade.com/api/v2/server/version' // Public endpoint — plain fetch works too
const { data, meta } = await lexx("GET", "/server/version");
console.log(data); # Public endpoint — no signature required
res = lexx("GET", "/server/version")
print(res["data"]) Response 200 — Version info
data service required apiVersion required node required Node.js runtime version.
startedAt required Process start time, Unix milliseconds.
uptimeSec required Seconds since process start.
meta Standard response envelope metadata included in every successful API response. Rate-limit state is NOT in the body — it is delivered via the X-RateLimit-* response headers.
requestId required Unique identifier for this API request, useful for support tickets and debugging
timestamp required Response timestamp in Unix milliseconds
version required API version
idempotencyKey Echoed back on a successful mutating request (POST/DELETE) when the caller sent an X-Idempotency-Key header. Absent otherwise.
Error responses (429, 500)
| 429 | Rate limit exceeded |
| 500 | Internal server error |
All errors share the { error: { code, status, message }, meta } envelope —
see Errors for every code.
Authenticated health check
Authenticated liveness probe. Unlike the other endpoints, this one returns the legacy response envelope ({ status: "success", data: { message, timestamp } }), not the v2 { data, meta } envelope. Requires a valid signed request.
Request samples
# Sign: timestamp + "GET" + "/v2/ping" + "" → see Authentication
curl -X GET 'https://api.lexx-trade.com/api/v2/ping' \
-H "X-LEXX-KEY: $LEXX_PUBLIC_KEY" \
-H "X-LEXX-SIGN: $SIGNATURE" \
-H "X-LEXX-TIMESTAMP: $TIMESTAMP" // lexx() — the signing helper from the Quickstart guide
const { data, meta } = await lexx("GET", "/ping");
console.log(data); # lexx() — the signing helper from the Quickstart guide
res = lexx("GET", "/ping")
print(res["data"]) Response 200 — Pong.
status data message timestamp Server time (Unix ms).
Error responses (401, 429, 500)
| 401 | Invalid or missing API key/signature |
| 429 | Rate limit exceeded |
| 500 | Internal server error |
All errors share the { error: { code, status, message }, meta } envelope —
see Errors for every code.