LevelPing

API

Alerts your bot can create

The same REST surface the web app uses, with an API key instead of a session. Create levels from your own strategy code and receive the crossings on a signed webhook.

Live Pro plan

Authentication

Create a key in Settings → API keys. It is shown once, so store it where your code reads it from. Send it as a bearer token against https://levelping.com/api/v1:

curl https://levelping.com/api/v1/alerts \
  -H "Authorization: Bearer lp_live_xxx"

A key carries the same permissions as the account that created it, and nothing more: it reads and writes your own markets, alerts and history. It cannot create or revoke keys — that only happens from your session, so a leaked key cannot outlive the moment you revoke it. Revoking takes effect on the next request.

Create an alert

POST /api/v1/alerts
{
  "market": "hyperliquid:BTC",
  "direction": "above",
  "price": 72000,
  "mode": "oneshot",
  "note": "breakout entry"
}

market is the pair as you see it in the app, venue:symbol; you can also send the opaque marketId that /markets returns. The level is snapped to the exchange tick size, so the response tells you the exact price that was stored. mode accepts oneshot or recurring; recurring alerts take an optional cooldownS (300–604800) and hysteresisPct (0–20). Alerts always go to every channel you have enabled at the moment they fire, so connecting Telegram later covers the levels you already set.

The response carries willFireImmediately when the price is already on the other side of the level: the alert is valid, it will just ping as soon as the engine sees the next tick.

Endpoints

MethodPathDoes
GET/marketsSearch available markets (?q=BTC&venue=binance)
GET/venuesExchanges and how many markets each has
GET/candlesCandles for a market (?market=<id>&interval=1h)
GET/alertsList your alerts
POST/alertsCreate an alert
PATCH/alerts/:idMove the level, switch direction or mode, pause or re-arm
DELETE/alerts/:idDelete an alert
POST/alerts/bulk-deleteDelete several at once: {"ids": [...]}, up to 500
GET/channelsYour notification channels and their ids
GET/eventsHistory of triggers and deliveries
GET/meYour plan, usage and channels

Errors

Every error is JSON with an error code you can branch on.

StatusCodeMeans
401missing_api_keyNo Authorization: Bearer lp_live_… header
401invalid_api_keyThe key does not exist or was revoked
402plan_featureYour plan does not include that (the API itself, recurring, webhooks)
402plan_limitYou are at your plan's alert limit
400invalid_bodyValidation failed; details says which field
400market_unavailableThat market does not exist or is not trading
404not_foundNot yours, or already deleted
429rate_limitedOver the per-key rate limit

Limits

Two requests per second per key, measured over ten-second windows so a short burst is not punished; the ratelimit-* response headers tell you where you stand. Five live keys per account. A paused alert still uses one of your plan's slots.

Webhook payload

When a level is crossed we POST this to the endpoint you registered in Settings:

{
  "type": "alert.triggered",
  "alert":  { "id": "...", "direction": "above", "price": 72000, "note": "breakout entry", "mode": "oneshot" },
  "market": { "venue": "hyperliquid", "symbol": "BTC", "base": "BTC", "quote": "USD" },
  "trigger": { "price": 72014.5, "at": "2026-08-18T09:41:12.004Z" }
}

Verifying the signature

Every request carries x-levelping-timestamp and x-levelping-signature. The signature is an HMAC-SHA256 of timestamp + "." + rawBody using your webhook secret.

const expected = crypto
  .createHmac('sha256', secret)
  .update(`${req.get('x-levelping-timestamp')}.${rawBody}`)
  .digest('hex')

// compare with the value after "sha256=" using timingSafeEqual

Reject requests whose timestamp is more than a few minutes old, and always compare in constant time.

Failed deliveries are retried three times with backoff; an endpoint that keeps failing is disabled and you get an email about it.

Getting started: the guides cover pointing an alert at your own webhook, and the API is part of the Pro plan.