@vike-io/cli 0.21.0 → 0.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/README.md +5 -5
- package/package.json +1 -1
- package/skills/vike/SKILL.md +7 -7
- package/skills/vike-alerts-setup/SKILL.md +9 -1
- package/skills/vike-hl-asset-briefing/SKILL.md +1 -1
- package/skills/vike-hl-trader-profile/SKILL.md +2 -2
- package/skills/vike-pm-l2-archive/SKILL.md +6 -5
- package/skills/vike-stream/SKILL.md +2 -1
- package/src/commands/alerts.js +10 -6
- package/src/commands/hl.js +19 -13
- package/src/commands/polymarket.js +2 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.23.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- c5b5c49: `polymarket archive --category <c>`: the Polymarket archive's third layout, every market by Polymarket category (sports, crypto, weather, elections, finance, ...), the up/down series inside their category (crypto series under crypto; stocks, indices, FX and commodities under finance); `--asset`/`--tenor` work as before. The archive download link is valid for 1 day, not 7.
|
|
8
|
+
|
|
9
|
+
## 0.22.0
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- b440e85: `hl orders` takes four new views. `walls`: the large orders (`--min-usd`, default $1M) of a `--symbol` and/or a `--wallet` last seen in a window (`--from`, `--to`, default 24 hours, at most 7 days) and what became of each, `filled`, `partially_filled`, `pulled` (left the book with no fill), `open` or `unknown` (`--kind both|resting|trigger`, `--outcome`, `--touch-bps`, `--market`, `--limit`, `--cursor`). `order_stats --address`: one wallet's walls in totals and per symbol, with `pulled_share` and `cancel_to_fill_ratio` (`--from`, `--to`, `--min-usd`, default $100k, `--market`). `squeeze`: one perp's price ladder at one instant, per bucket the resting book, the stops and the liquidations, and `pressure` (above 1 = a squeeze) (`--symbol`, `--at`, `--step-bps`, `--range-pct`, `--cohort-axis`, `--cohort`). `book_cohorts`: which cohorts own the book near the mid over time (`--symbol`, `--from`, `--to`, `--cohort-axis size|pnl`, `--band-bps 50|200|1000`, `--interval 5m|1h|1d`, `--market`). README and the vike, vike-hl-asset-briefing, vike-hl-trader-profile and vike-stream skills name them.
|
|
14
|
+
- 2b5d0fc: `alerts create` and `alerts edit` take the `hl_wallet_orders` type: one wallet's Hyperliquid orders placed in or gone from the book, private to the account (`--wallet`, required; `--min-usd`, the order's size x price, default 10000, at least 1000; `--token`; new `--side buy|sell` and `--events placed gone`, both by default; `--side ''` and `--events ''` clear them on edit). Each check is one `wallet_orders` event whose `data.orders` lists every order with the check's totals, 200 orders an event (`part` of `parts`); the full list is kept 1 hour, then the event carries the totals only (`data.orders_removed: true`). `alerts events` help says a page also ends at about 2 MB: page on with `--cursor` while `has_more` is true. README and the vike, vike-alerts-setup and vike-hl-trader-profile skills name the new type and the paging rule.
|
|
15
|
+
|
|
3
16
|
## 0.21.0
|
|
4
17
|
|
|
5
18
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -52,11 +52,11 @@ The key is read from `VIKE_API_KEY` first, then from `~/.vike/config.json`
|
|
|
52
52
|
|
|
53
53
|
| Dataset | What is in it | Access | Page |
|
|
54
54
|
|---|---|---|---|
|
|
55
|
-
| **Polymarket historical order book** (archive) | `book_events` (full L2: snapshots, `price_change` deltas, trades, tick-size and status markers), `trades` (taker tape), `l1_quotes` (derived top of book). One Parquet file per stream per UTC day since 2026-07-25, every recorded market (crypto up/down, sports, politics). | Manifest + sample: no key. Full days:
|
|
56
|
-
| **Polymarket up/down families** (archive) | The same archive
|
|
55
|
+
| **Polymarket historical order book** (archive) | `book_events` (full L2: snapshots, `price_change` deltas, trades, tick-size and status markers), `trades` (taker tape), `l1_quotes` (derived top of book). One Parquet file per stream per UTC day since 2026-07-25, every recorded market (crypto up/down, sports, politics). | Manifest + sample: no key. Full days: key (2 days a month, each older than 14 days); every day with the Files plan. | [polymarket-historical-data](https://vike.io/data/polymarket-historical-data) |
|
|
56
|
+
| **Polymarket up/down families** (archive) | The same archive by Polymarket category (`category=sports`, `crypto`, `finance`, ...), each up/down series (`asset=btc&tenor=5m` and so on) in its own file inside its category | key (2 days a month, each older than 14 days); every day with the Files plan | [polymarket-updown-markets](https://vike.io/data/polymarket-updown-markets) |
|
|
57
57
|
| **Polymarket API** `/v1/polymarket` | Markets, the raw event and trade tape (about 30 days back), order-book snapshots, candles, on-chain settlements | free key | [polymarket](https://vike.io/data/polymarket) |
|
|
58
58
|
| **Hyperliquid cohorts** `/v1/hyperliquid/coins/{coin}/cohort-metrics` | Long vs short per cohort, hourly, up to 8,760 hours in one request. Axes: `size` (account value, shrimp to 4x whale), `tier` (position notional), `pnl` (realized-PnL percentile), `pnl_abs` (PnL in dollars). `labelBasis=point_in_time` grades each hour with the label it had then (from 2026-04-07). | free key | [hl-cohorts](https://vike.io/data/hl-cohorts) |
|
|
59
|
-
| **Hyperliquid API** `/v1/hyperliquid` | Trader rankings and leaderboards, 5-minute position snapshots kept for a year, wallet fills, funding and ledger, standing orders and the order book (perp and spot), liquidations (inferred from snapshots), builders, candles since the start of 2026; closed bars also stream live as the `hl.candles` channel of `wss://stream.vike.io/v1/stream/hl` | free key | [hyperliquid](https://vike.io/data/hyperliquid) |
|
|
59
|
+
| **Hyperliquid API** `/v1/hyperliquid` | Trader rankings and leaderboards, 5-minute position snapshots kept for a year, wallet fills, funding and ledger, standing orders and the order book (perp and spot), order walls and fake walls, squeeze maps, liquidations (inferred from snapshots), builders, candles since the start of 2026; closed bars also stream live as the `hl.candles` channel of `wss://stream.vike.io/v1/stream/hl` | free key | [hyperliquid](https://vike.io/data/hyperliquid) |
|
|
60
60
|
| **Predict.fun API** `/v1/predictfun` | Prediction markets on BNB Chain: a venue overview, the market catalog with 24h volume, one market's outcomes and stats, the newest recorded order book (the ~1,000 most active open markets), every on-chain fill with the wallet behind it, per-wallet positions and P&L, and a leaderboard of every wallet by realized and unrealized P&L, volume and fills | free key | [predictfun](https://vike.io/predictfun) |
|
|
61
61
|
| **Event streams** `wss://stream.vike.io/v1/stream/<path>` | Live events with a resume cursor on four paths: `hl` (fills, liquidations, positions, top-10 positions per coin, closed trades, liquidation risk, order walls, candles, TWAPs, ledger, leverage changes, funding), `hl-cohorts` (cohort flow, indices, cohort bias, cohort leverage), `onchain` (transfers on eth, bsc, base, hyperevm), `polymarket` (trades, wallet position changes, resolutions, price moves, new markets). `vike-data stream` reads them; `vike-data stream info` lists every channel and filter. Connections are not counted against the hourly limit. | free key | [stream channels](https://vike.io/docs/data/reference/stream-channels) |
|
|
62
62
|
| **On-chain API** `/v1/onchain` | Wallet summaries, transactions, counterparties, PnL, address labels with per-source provenance, token holders and transfers. Ethereum on every route, BNB Chain on the wallet and token-flow routes, Base on token transfers. | free key | [onchain](https://vike.io/data/onchain) |
|
|
@@ -144,11 +144,11 @@ Every data command is one `tools/call` to the MCP server. `vike-data <group> --h
|
|
|
144
144
|
| `vike-data wallet` | `summary`, `transactions` (`txs`), `compare`, `trace`, `batch`, `counterparties`, `pnl-history`, `balances`, `ens`, `discover`, `first-funder`, `exchange-usage` | `wallet_summary`, `wallet_transactions`, `wallet_compare`, `wallet_trace`, `wallet_batch_labels`, `wallet_counterparties`, `wallet_pnl_history`, `wallet_token_balances`, `wallet_ens`, `wallet_discover`, `wallet_first_funder`, `wallet_exchange_usage` |
|
|
145
145
|
| `vike-data labels <address>` | multi-source label provenance for one wallet | `wallet_label_provenance` |
|
|
146
146
|
| `vike-data perp` | `top-traders`, `find-position` (Hyperliquid); `funding`, `spreads` (cross-venue funding rates and perp-vs-perp price gaps) | `hl_perp_top_traders`, `hl_position_match`, `perp_funding`, `perp_spreads` |
|
|
147
|
-
| `vike-data hl` | `cohort-metrics <symbol>`, `segments`, `wallet <address>`, `wallet-activity <address>`, `wallet-trades <address>`, `leaderboard`, `liquidations`, `market`, `orders` (`--view open`: resting orders with each owner's size and PnL cohort; `wallet`; `clusters`; `book`: the order book at one instant; `--market spot` for a spot pair such as `HYPE/USDC`), `twaps`, `ledger`, `leverage-changes`, `stats`, `hype-holders`, `builders`, `vaults`, `vault <vault>`, `archive`; a tool with several views takes `--view` | `hl_cohort_metrics`, `hl_segments`, `hl_wallet`, `hl_wallet_activity`, `hl_wallet_trades`, `hl_leaderboard`, `hl_liquidations`, `hl_market`, `hl_orders`, `hl_twaps`, `hl_ledger`, `hl_leverage_changes`, `hl_stats`, `hl_hype_holders`, `hl_builders`, `hl_vaults`, `hl_vault`, `hl_archive` |
|
|
147
|
+
| `vike-data hl` | `cohort-metrics <symbol>`, `segments`, `wallet <address>`, `wallet-activity <address>`, `wallet-trades <address>`, `leaderboard`, `liquidations`, `market`, `orders` (`--view open`: resting orders with each owner's size and PnL cohort; `wallet`; `clusters`; `book`: the order book at one instant; `walls`: orders of $1M+ and what became of each, filled or pulled with no fill (fake walls); `order_stats`: one wallet's pulled share and cancel-to-fill ratio; `squeeze`: the book, stops and liquidations per price, `pressure` above 1 = a squeeze; `book_cohorts`: which cohorts own the book near the mid over time; `--market spot` for a spot pair such as `HYPE/USDC`), `twaps`, `ledger`, `leverage-changes`, `stats`, `hype-holders`, `builders`, `vaults`, `vault <vault>`, `archive`; a tool with several views takes `--view` | `hl_cohort_metrics`, `hl_segments`, `hl_wallet`, `hl_wallet_activity`, `hl_wallet_trades`, `hl_leaderboard`, `hl_liquidations`, `hl_market`, `hl_orders`, `hl_twaps`, `hl_ledger`, `hl_leverage_changes`, `hl_stats`, `hl_hype_holders`, `hl_builders`, `hl_vaults`, `hl_vault`, `hl_archive` |
|
|
148
148
|
| `vike-data candles` | `hl <symbol>` (Hyperliquid perp or spot, from executed fills; `--view export`, or `--view latest` for the newest bar of every symbol), `polymarket <token_id>` (one outcome token); live bars: `stream hl --channel hl.candles` | `hl_ohlcv`, `polymarket_ohlcv` |
|
|
149
149
|
| `vike-data polymarket` (`pm`) | `markets`, `market <condition_id>`, `wallet <address>`, `smart-money`, `leaderboard`, `market-trades <condition_id>`, `tape`, `orderbook <token_id>`, `market-stats <token_id>`, `settlement <condition_id>`, `settlements`, `chainlink-prices <symbol>` (the Chainlink prices the crypto up/down markets resolve on), `archive` | `polymarket_markets`, `polymarket_market_detail`, `polymarket_wallet`, `polymarket_smart_money`, `polymarket_leaderboard`, `polymarket_market_trades`, `polymarket_tape`, `polymarket_orderbook`, `polymarket_market_stats`, `polymarket_settlement`, `polymarket_settlements_bulk`, `polymarket_chainlink_prices`, `polymarket_archive` |
|
|
150
150
|
| `vike-data predictfun` (`pf`) | `overview`, `markets`, `market <market_id>`, `orderbook <market_id>`, `market-trades <market_id>`, `wallet <address>` (positions and P&L), `wallet-trades <address>`, `wallet-flows <address>` (USDT deposits and withdrawals), `leaderboard` | `predictfun_overview`, `predictfun_markets`, `predictfun_market_detail`, `predictfun_market_book`, `predictfun_market_trades`, `predictfun_wallet_positions`, `predictfun_wallet_trades`, `predictfun_leaderboard` |
|
|
151
|
-
| `vike-data alerts` | `list`, `channels`, `create`, `edit`, `delete`, `events`, `resend`, `register-webhook`, `test-webhook`, `rotate-secret`: transfer alerts (a token or one wallet, on eth, bsc, base, hyperevm) Hyperliquid alerts (`--type hl_wallet`, `hl_cohort_fill`, `hl_liquidation`, `hl_cohort_bias`, `hl_liq_proximity`) and Polymarket alerts (`--type pm_wallet_trade`, `pm_market_trade`, `pm_price_move`, `pm_resolution`), by email or an HTTPS webhook, HMAC-signed; at most 200 active alerts per account | `alerts_*` |
|
|
151
|
+
| `vike-data alerts` | `list`, `channels`, `create`, `edit`, `delete`, `events`, `resend`, `register-webhook`, `test-webhook`, `rotate-secret`: transfer alerts (a token or one wallet, on eth, bsc, base, hyperevm) Hyperliquid alerts (`--type hl_wallet`, `hl_cohort_fill`, `hl_liquidation`, `hl_cohort_bias`, `hl_liq_proximity`, `hl_wallet_orders`: one wallet's orders placed or gone, `--side`, `--events placed gone`) and Polymarket alerts (`--type pm_wallet_trade`, `pm_market_trade`, `pm_price_move`, `pm_resolution`), by email or an HTTPS webhook, HMAC-signed; at most 200 active alerts per account; `events` pages by `--cursor` while `has_more` is true (a page ends at about 2 MB) | `alerts_*` |
|
|
152
152
|
| `vike-data stream <path>` | live events from `wss://stream.vike.io/v1/stream/<path>` (`hl`, `hl-cohorts`, `onchain`, `polymarket`) as NDJSON: `--channel` (one or more), `--filter key=value`, `--cursor` | WebSocket, not MCP |
|
|
153
153
|
| `vike-data stream` | `info`, `check <channel>` (the server's validator), `events <channel>` (stored events, 3 days), `connections` (yours) | `stream_info`, `stream_check_filter`, `stream_events`, `stream_connections` |
|
|
154
154
|
| `vike-data search <q>` | tokens, wallets and entities, HL traders, vaults, builders, Polymarket wallets and markets by name, symbol, address or ENS name | `search` |
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "0.
|
|
6
|
+
"version": "0.23.0",
|
|
7
7
|
"description": "CLI, agent skills and MCP client for the free Vike Data API: a Polymarket full-L2 order-book archive in Parquet, Hyperliquid positions, fills and cohorts, and labelled Ethereum/BNB wallets",
|
|
8
8
|
"type": "module",
|
|
9
9
|
"main": "src/index.js",
|
package/skills/vike/SKILL.md
CHANGED
|
@@ -7,7 +7,7 @@ description: "Use this skill whenever the user asks any question about on-chain
|
|
|
7
7
|
|
|
8
8
|
This skill is for anyone who asks an AI agent about crypto data: who is buying a token, what a wallet holds, what Hyperliquid or Polymarket traders are doing right now. It tells the agent which vike tool answers which question and how to read the result, so it does not guess or invent numbers. It reads its data from vike.io and needs a free vike API key.
|
|
9
9
|
|
|
10
|
-
What the platform has: wallet and token analytics on Ethereum, BSC, Base and HyperEVM (each tool's chain list is under "What each tool really returns"), multi-source wallet labels, CEX perpetual funding and cross-venue spreads, Hyperliquid wallets, cohorts, leaderboards, liquidations, markets, builders, vaults and candles, Polymarket markets, traders, tape, order books, settlements and the Parquet archive, Predict.fun (BNB Chain) markets, order books, on-chain fills, wallet positions and P&L, USDT deposits and withdrawals and its leaderboard, transfer, Hyperliquid and Polymarket alerts, and live event streams over WebSocket.
|
|
10
|
+
What the platform has: wallet and token analytics on Ethereum, BSC, Base and HyperEVM (each tool's chain list is under "What each tool really returns"), multi-source wallet labels, CEX perpetual funding and cross-venue spreads, Hyperliquid wallets, cohorts, leaderboards, liquidations, markets, builders, vaults and candles, Polymarket markets, traders, tape, order books, settlements and the Parquet archive, Predict.fun (BNB Chain) markets, order books, on-chain fills, wallet positions and P&L, USDT deposits and withdrawals and its leaderboard, transfer, Hyperliquid and Polymarket alerts, and live event streams over WebSocket. 84 tools in one MCP server.
|
|
11
11
|
|
|
12
12
|
**MCP endpoint for all calls:** `https://data.vike.io/mcp` (JSON-RPC 2.0)
|
|
13
13
|
**Or use the CLI:** `npm install -g @vike-io/cli` → `vike-data <command>`
|
|
@@ -25,7 +25,7 @@ Hard rules — agents that violate these produce wrong answers. Read once, apply
|
|
|
25
25
|
1. **Addresses are always full 0x-hex (42 chars).** Never truncate when querying. Never display truncated when the user asks for the address — they'll copy-paste it.
|
|
26
26
|
2. **Perp and Hyperliquid symbols are upper-cased by the server.** Echo back what the user wrote.
|
|
27
27
|
3. **Windows are counted in UTC calendar days, not a rolling 24 hours.** On the token screener `24h` spans yesterday and today; on Hyperliquid `30d` is today plus the previous 30 days.
|
|
28
|
-
4. **Page sizes are small and differ per tool; these have no paging.** Max 20: `wallet_discover` (`size`), `polymarket_smart_money`. Max 30: `polymarket_markets`. Max 50: `token_holders`, `wallet_counterparties`, `wallet_compare`. Max 100: `token_screener`, `hl_perp_top_traders` (`size`), and 100 addresses for `wallet_batch_labels`. Max 500: `wallet_transactions`, `hl_position_match`. `token_transfers` has no limit: it always returns 10 rows. To go deeper, narrow the filter or the window instead of asking for more rows. The `hl` commands, `polymarket market-trades`, `tape`, `settlements`, `chainlink-prices`, `predictfun markets` (max 100), `market-trades` and `wallet-trades` (max 10000) and `alerts events` DO page: pass the answer's next cursor back with `--cursor` (on `predictfun`, until `next_cursor` is `null`); `predictfun leaderboard` (max 50) pages by `--offset`, at most 1000. Page while `has_more` is true, not by page size: a `chainlink-prices` page can be shorter than `--limit` with more to come, and near now an empty page with `has_more` false means caught up: ask again later with `--from-ms` = the last row's `ts_ms` + 1.
|
|
28
|
+
4. **Page sizes are small and differ per tool; these have no paging.** Max 20: `wallet_discover` (`size`), `polymarket_smart_money`. Max 30: `polymarket_markets`. Max 50: `token_holders`, `wallet_counterparties`, `wallet_compare`. Max 100: `token_screener`, `hl_perp_top_traders` (`size`), and 100 addresses for `wallet_batch_labels`. Max 500: `wallet_transactions`, `hl_position_match`. `token_transfers` has no limit: it always returns 10 rows. To go deeper, narrow the filter or the window instead of asking for more rows. The `hl` commands, `polymarket market-trades`, `tape`, `settlements`, `chainlink-prices`, `predictfun markets` (max 100), `market-trades` and `wallet-trades` (max 10000) and `alerts events` DO page: pass the answer's next cursor back with `--cursor` (on `predictfun`, until `next_cursor` is `null`); `predictfun leaderboard` (max 50) pages by `--offset`, at most 1000. Page while `has_more` is true, not by page size: a `chainlink-prices` page can be shorter than `--limit` with more to come, and near now an empty page with `has_more` false means caught up: ask again later with `--from-ms` = the last row's `ts_ms` + 1. An `alerts events` page also ends at about 2 MB, with `has_more` true; keep its `next_cursor` and ask again later for new events.
|
|
29
29
|
5. **Refresh differs per tool; never promise "minutes".** `wallet_discover` and `wallet_summary` are rebuilt nightly, so a wallet active an hour ago may not show. Transfers are synced block by block. `hl_position_match` only matches positions seen within 15 minutes of the newest snapshot batch. For events as they happen use `vike-data stream` (`vike-stream`).
|
|
30
30
|
6. **USD amounts are floats in dollars.** `--min-usd 10000` = ten thousand dollars, not micro-USD.
|
|
31
31
|
7. **`--json` is always available** on CLI commands and gives stable machine-readable output. The default (human) format may change; `--json` will not.
|
|
@@ -108,7 +108,7 @@ Pick by the question, then read the named skill for the recipe and the traps. If
|
|
|
108
108
|
| Liquidation risk by symbol, liquidation heatmap, recent or live liquidations | `vike-data hl liquidations`; `stream hl --channel hl.liq_risk hl.liquidations` | `vike-hl-liquidation-radar` |
|
|
109
109
|
| Builder codes: fees, users, routed share | `vike-data hl builders` | `vike-hl-builder-intel` |
|
|
110
110
|
| HL open interest, vaults | `vike-data hl market`, `hl vaults`, `hl vault` | this skill |
|
|
111
|
-
| HL orders, order clusters and the order book (perp, or spot with `--market spot`), TWAPs, the ledger, leverage changes, closed trades, venue stats, HYPE holders, the Parquet archive | `vike-data hl orders`, `hl twaps`, `hl ledger`, `hl leverage-changes`, `hl wallet-trades`, `hl stats`, `hl hype-holders`, `hl archive` | this skill |
|
|
111
|
+
| HL orders, order clusters and the order book (perp, or spot with `--market spot`), order walls and fake walls (pulled with no fill), a symbol's squeeze map, which cohorts own the book, TWAPs, the ledger, leverage changes, closed trades, venue stats, HYPE holders, the Parquet archive | `vike-data hl orders`, `hl twaps`, `hl ledger`, `hl leverage-changes`, `hl wallet-trades`, `hl stats`, `hl hype-holders`, `hl archive` | this skill |
|
|
112
112
|
| A name, symbol, address, ENS name or polymarket.com link → what it is | `vike-data search <q>` / `search` | this skill |
|
|
113
113
|
| Candles: Hyperliquid perp/spot (history, or the newest bar of every symbol), Polymarket outcome token; live HL bars | `vike-data candles hl` (`--view latest`), `candles polymarket`; `stream hl --channel hl.candles` | `vike-candles` |
|
|
114
114
|
| Trending Polymarket markets (by 24h volume) | `vike-data polymarket markets` / `polymarket_markets` | `vike-polymarket-markets` |
|
|
@@ -165,7 +165,7 @@ Any MCP tool, including one with no command of its own, is one `call` away; it p
|
|
|
165
165
|
vike-data call hl_wallet --args '{"address":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045","view":"summary"}'
|
|
166
166
|
```
|
|
167
167
|
|
|
168
|
-
**B) Via an MCP connector (recommended when your client has one).** All
|
|
168
|
+
**B) Via an MCP connector (recommended when your client has one).** All 84 tools live at `https://data.vike.io/mcp`. Connect the client to that address with the `X-API-KEY` header above, then call a tool by name with its arguments, for example `wallet_summary` with `address` set to a full 0x address.
|
|
169
169
|
|
|
170
170
|
Run `vike-data schema --pretty` (or call MCP `tools/list`) to see the live arg shape for every tool. Always read the schema before constructing arguments — defaults and enum values change.
|
|
171
171
|
|
|
@@ -223,7 +223,7 @@ These two have no command: `vike-data call perp_open_interest --args '{"symbol":
|
|
|
223
223
|
| `hl_segments` (`hl segments`) | the cohort labels (`--view cohorts`), one cohort now (`summary`), the symbol x cohort board (`heatmap`), one cohort hour by hour (`history`) |
|
|
224
224
|
| `hl_leaderboard` (`hl leaderboard`) | traders on 20 metrics; `--min-win-rate` is a FRACTION here (0.6), a percent in `perp top-traders` |
|
|
225
225
|
| `hl_liquidations`, `hl_market`, `hl_builders`, `hl_vaults`, `hl_vault` | liquidations / risk / heatmap; open interest, symbol series, positions, indices, large fills, an hourly panel of up to 64 symbols; builder codes; vaults |
|
|
226
|
-
| `hl_orders`, `hl_twaps`, `hl_ledger`, `hl_leverage_changes` | resting orders at one instant (each with its owner's `sizeCohort`, `pnlCohort`, `pnlCumUsd`; `--cohort-axis` + `--cohort` keep one cohort's), one wallet's orders, order clusters, the order book (`--view book`: price levels best first, `--side`, `--levels`); `open`, `
|
|
226
|
+
| `hl_orders`, `hl_twaps`, `hl_ledger`, `hl_leverage_changes` | resting orders at one instant (each with its owner's `sizeCohort`, `pnlCohort`, `pnlCumUsd`; `--cohort-axis` + `--cohort` keep one cohort's), one wallet's orders, order clusters, the order book (`--view book`: price levels best first, `--side`, `--levels`); walls (`--view walls`: orders of `--min-usd`, default $1M, of a `--symbol` and/or `--wallet` and their `outcome`: `filled`, `partially_filled`, `pulled` = left with no fill, a fake wall if it keeps happening, `open`, `unknown`; `near_touch` = the price was close when it left); `--view order_stats --address`: one wallet's walls in totals and per symbol, `pulled_share` and `cancel_to_fill_ratio`; `--view squeeze`: per price bucket the resting book, the stops and the liquidations that would trade into it, `pressure` = that forced flow over the book, above 1 = a squeeze; `--view book_cohorts`: each cohort's share of the bids and asks within `--band-bps` of the mid, per `--interval`; `open`, `clusters`, `book`, `book_cohorts`, `walls` and `order_stats` read the perp books unless `--market spot` (a pair, `HYPE/USDC`), `squeeze` is perp only; the cross-wallet feeds (follow one with `--order asc` and each `nextCursor`, stop on an empty page) |
|
|
227
227
|
| `hl_wallet_trades`, `hl_stats`, `hl_hype_holders`, `hl_archive` | one wallet's closed trades; hourly venue equity / open interest / volume; HYPE holders; the daily Parquet files: `fills`, `positions`, and from 2026-05-01 `positions_hourly`, `cohorts_hourly`, `wallets_hourly` (`--view url` = a 7-day link) |
|
|
228
228
|
|
|
229
229
|
Every `hl` command takes `--view` (the first view is the default) and only the flags that view uses: a flag the view does not take is refused by name, not ignored.
|
|
@@ -259,8 +259,8 @@ Create + manage on-chain transfer alerts, Hyperliquid alerts and Polymarket aler
|
|
|
259
259
|
| Tool | Does |
|
|
260
260
|
|---|---|
|
|
261
261
|
| `alerts_list`, `alerts_list_channels` | list rules / enabled channels |
|
|
262
|
-
| `alerts_create`, `alerts_edit`, `alerts_delete` | manage a rule: transfer (token and/or one `address`, chain `eth`/`bsc`/`base`/`hyperevm`, USD thresholds) or Hyperliquid (`--type hl_wallet`, `hl_cohort_fill`, `hl_liquidation`, `hl_cohort_bias`, `hl_liq_proximity`) or Polymarket (`--type pm_wallet_trade`, `pm_market_trade`, `pm_price_move`, `pm_resolution`) |
|
|
263
|
-
| `alerts_events`, `alerts_resend_delivery` | what fired and each delivery's status (15 days); send one again |
|
|
262
|
+
| `alerts_create`, `alerts_edit`, `alerts_delete` | manage a rule: transfer (token and/or one `address`, chain `eth`/`bsc`/`base`/`hyperevm`, USD thresholds) or Hyperliquid (`--type hl_wallet`, `hl_cohort_fill`, `hl_liquidation`, `hl_cohort_bias`, `hl_liq_proximity`, `hl_wallet_orders`: one wallet's orders placed or gone, private to the account) or Polymarket (`--type pm_wallet_trade`, `pm_market_trade`, `pm_price_move`, `pm_resolution`) |
|
|
263
|
+
| `alerts_events`, `alerts_resend_delivery` | what fired and each delivery's status (15 days); send one again. A page ends at about 2 MB: page with `--cursor` while `has_more` is true |
|
|
264
264
|
| `alerts_register_webhook`, `alerts_test_webhook`, `alerts_rotate_webhook_secret` | an HTTPS webhook (HMAC-signed deliveries): register, test, rotate its secret |
|
|
265
265
|
|
|
266
266
|
A token-wide transfer alert fires on ANY transfer of the token above the USD threshold on that chain; an address alert on every transfer of that wallet. Every match is recorded in `alerts events` (15 days) whatever the channels; a transfer alert left with no enabled channel e-mails the account address. Hyperliquid and Polymarket alerts go to email (one mail per pass, at most 10 a day except `hl_wallet`), a webhook, or are read with `alerts events`. An account has at most 200 active alerts in all (any mix of on-chain, Hyperliquid, Polymarket); pausing frees a slot. There is no token price or funding alert (a Polymarket market's price moves: `pm_price_move`), no Discord (off) and no Telegram delivery. For a live feed without a rule, use `vike-data stream`.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: vike-alerts-setup
|
|
3
|
-
description: Create, list, edit, and delete alerts - on-chain transfer alerts (a token, one wallet, USD thresholds; eth, bsc, base, hyperevm) Hyperliquid alerts (a wallet's fills, cohort fills, liquidations, cohort bias, liquidation proximity) and Polymarket alerts (a wallet's trades, big trades in a market, price moves, a market resolving) - and read the events they produced. Delivered by email or an HTTPS webhook. Use when the user asks "alert me when X" / "watch for big transfers" / "notify on whale moves" / "tell me when this wallet trades".
|
|
3
|
+
description: Create, list, edit, and delete alerts - on-chain transfer alerts (a token, one wallet, USD thresholds; eth, bsc, base, hyperevm) Hyperliquid alerts (a wallet's fills, cohort fills, liquidations, cohort bias, liquidation proximity, a wallet's orders placed or gone) and Polymarket alerts (a wallet's trades, big trades in a market, price moves, a market resolving) - and read the events they produced. Delivered by email or an HTTPS webhook. Use when the user asks "alert me when X" / "watch for big transfers" / "notify on whale moves" / "tell me when this wallet trades".
|
|
4
4
|
allowed-tools: Bash(vike-data:*)
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -52,12 +52,18 @@ Hyperliquid alerts (`--type`; leave out `--chain`, `--address`, `--max-usd`; del
|
|
|
52
52
|
| `hl_liquidation` | liquidations | optional `--wallet`, cohorts, `--token`, `--min-usd` |
|
|
53
53
|
| `hl_cohort_bias` | a cohort index crossing a level | `--token` and `--index smi\|wsi\|smart_bias\|whale_bias\|smi_wsi_gap` (required), `--threshold`, `--band`, `--direction up\|down\|both` |
|
|
54
54
|
| `hl_liq_proximity` | a wallet getting close to liquidation | `--wallet` (required), `--threshold` (0-1, default 0.8), `--band` |
|
|
55
|
+
| `hl_wallet_orders` | one wallet's orders placed in or gone from the book (5-minute snapshots) | `--wallet` (required), `--min-usd` (the order's size x price, default 10000, at least 1000), `--token`, `--side buy\|sell` (default both), `--events placed gone` (default both) |
|
|
55
56
|
|
|
56
57
|
```bash
|
|
57
58
|
vike-data alerts create --label "BTC smart money flips" --type hl_cohort_bias \
|
|
58
59
|
--token BTC --index smi --threshold 0 --band 0.1 --channel webhook
|
|
60
|
+
|
|
61
|
+
vike-data alerts create --label "Whale's BTC sell orders" --type hl_wallet_orders \
|
|
62
|
+
--wallet 0x... --token BTC --side sell --min-usd 50000 --events placed gone
|
|
59
63
|
```
|
|
60
64
|
|
|
65
|
+
An `hl_wallet_orders` alert is private to the account (no stream carries it). Each check, about every 5 minutes, is ONE event of kind `wallet_orders`: `data.orders` lists every matching order with its `action` (`placed`, or `gone` with its `outcome`: `filled`, `partially_filled`, `canceled`, or `unknown` when its fills are late) and the check's totals beside it (`n_placed`, `n_gone`, `placed_usd`, `gone_usd`, a count per outcome). A check of more than 200 orders (a market maker) comes as several events, each with `part` of `parts` and the same totals. The full order list is kept 1 hour after the alert; after that the event in `alerts events` carries the totals only, with `data.orders_removed: true`, so read or receive it (webhook) within the hour.
|
|
66
|
+
|
|
61
67
|
Polymarket alerts (`--type`; leave out `--chain`, `--address`, `--max-usd`; the same channels). `--wallet` is the proxy wallet the site shows at `vike.io/polymarket/wallet/<address>`; `--condition-id` is the market (`0x` + 64 hex: the id in `vike.io/polymarket/market/<id>`, or find it with `vike-data polymarket markets --view search --query <slug>`):
|
|
62
68
|
|
|
63
69
|
| `--type` | Fires on | Flags |
|
|
@@ -89,6 +95,8 @@ vike-data alerts events --rule-id 42 --json
|
|
|
89
95
|
vike-data alerts resend <delivery_id> # send one delivery again
|
|
90
96
|
```
|
|
91
97
|
|
|
98
|
+
A page ends at `--limit` events or at about 2 MB, whichever comes first, so it can hold fewer events with `has_more` true: pass `next_cursor` back with `--cursor` while `has_more` is true; nothing is skipped. An empty page returns the same cursor: keep it and ask again later.
|
|
99
|
+
|
|
92
100
|
### Delete (only when the user explicitly asks)
|
|
93
101
|
|
|
94
102
|
```bash
|
|
@@ -22,7 +22,7 @@ vike-data hl liquidations --view heatmap --symbol $S --bins 20 --json # where
|
|
|
22
22
|
vike-data hl market --view large_fills --symbol $S --json # the newest fills of $50k+ (at most 200)
|
|
23
23
|
```
|
|
24
24
|
|
|
25
|
-
Optional: `hl orders --view clusters --symbol $S` (standing orders bucketed around the mid, `--range-pct`, `--step-bps`; `--cohort-axis size --cohort whale` for one cohort's), `hl orders --view book --symbol $S --levels 20` (the order book, price levels best first; the spot book with `--market spot --symbol HYPE/USDC`), `hl market --view size_breakdown --symbol $S` (position-size tiers with `value_close_to_liquidation`), `hl liquidations --view fills --symbol $S --limit 20` (the latest liquidations).
|
|
25
|
+
Optional: `hl orders --view clusters --symbol $S` (standing orders bucketed around the mid, `--range-pct`, `--step-bps`; `--cohort-axis size --cohort whale` for one cohort's), `hl orders --view book --symbol $S --levels 20` (the order book, price levels best first; the spot book with `--market spot --symbol HYPE/USDC`), `hl orders --view squeeze --symbol $S` (per price the book, the stops and the liquidations that would trade into it; `pressure` above 1 = a squeeze if price gets there), `hl orders --view walls --symbol $S --outcome pulled` (walls of $1M+ pulled with no fill in the last 24 hours: fake walls; `near_touch` = pulled as the price came close), `hl orders --view book_cohorts --symbol $S` (which cohorts own the bids and asks near the mid, hour by hour), `hl market --view size_breakdown --symbol $S` (position-size tiers with `value_close_to_liquidation`), `hl liquidations --view fills --symbol $S --limit 20` (the latest liquidations).
|
|
26
26
|
|
|
27
27
|
## Reading each section
|
|
28
28
|
|
|
@@ -20,7 +20,7 @@ vike-data hl wallet-activity $W --view ledger --limit 50 --json # deposits, w
|
|
|
20
20
|
vike-data hl liquidations --wallet $W --json # has it been liquidated
|
|
21
21
|
```
|
|
22
22
|
|
|
23
|
-
Optional, by question: `hl wallet-activity $W --view fills --symbol BTC` (raw fills), `--view builders` (which front-ends it routes through), `hl orders --view wallet --address $W` (what became of its orders, 7 days by default, at most 30), `hl orders --view open --wallet $W` (its orders resting now; `--market spot` for its spot orders), `hl twaps --wallet $W`, `hl leverage-changes --wallet $W`, `hl market --view positions --wallet $W` (open positions with liquidation price). `--window` is `1d|7d|30d|all` (default `all`); page with `nextCursor` -> `--cursor`.
|
|
23
|
+
Optional, by question: `hl wallet-activity $W --view fills --symbol BTC` (raw fills), `--view builders` (which front-ends it routes through), `hl orders --view wallet --address $W` (what became of its orders, 7 days by default, at most 30), `hl orders --view open --wallet $W` (its orders resting now; `--market spot` for its spot orders), `hl orders --view order_stats --address $W` (does it spoof: its walls of $100k+ over 7 days, `pulled_share` = pulled with no fill, `cancel_to_fill_ratio`, per symbol), `hl orders --view walls --wallet $W` (those walls one by one, with `outcome`), `hl twaps --wallet $W`, `hl leverage-changes --wallet $W`, `hl market --view positions --wallet $W` (open positions with liquidation price). `--window` is `1d|7d|30d|all` (default `all`); page with `nextCursor` -> `--cursor`.
|
|
24
24
|
|
|
25
25
|
## Reading
|
|
26
26
|
|
|
@@ -41,7 +41,7 @@ Optional, by question: `hl wallet-activity $W --view fills --symbol BTC` (raw fi
|
|
|
41
41
|
vike-data stream hl --channel hl.fills hl.liquidations hl.ledger hl.closed_trades --filter wallet=$W --filter min_usd=0
|
|
42
42
|
```
|
|
43
43
|
|
|
44
|
-
`hl.fills` alone defaults to fills of $1,000 or more; `min_usd=0` is every fill. `hl.closed_trades` sends each round trip once, when it is written as closed, in batches every 30 minutes (a trade that closed at 08:12 arrives around 08:35); its `data` is the item of `hl wallet-trades` (`realized_pnl`, `entry_price`, `exit_price`, `duration_seconds`, `max_size_usd`) and `min_usd` on it is the trade's largest size. A close shows at once as an `hl.fills` event whose `data.action` is `close`. One key holds one `stream hl` connection: add channels to this command, never start a second one. A stored rule instead: `vike-data alerts create --type hl_wallet --wallet $W ...` (see `vike-alerts-setup`).
|
|
44
|
+
`hl.fills` alone defaults to fills of $1,000 or more; `min_usd=0` is every fill. `hl.closed_trades` sends each round trip once, when it is written as closed, in batches every 30 minutes (a trade that closed at 08:12 arrives around 08:35); its `data` is the item of `hl wallet-trades` (`realized_pnl`, `entry_price`, `exit_price`, `duration_seconds`, `max_size_usd`) and `min_usd` on it is the trade's largest size. A close shows at once as an `hl.fills` event whose `data.action` is `close`. One key holds one `stream hl` connection: add channels to this command, never start a second one. A stored rule instead: `vike-data alerts create --type hl_wallet --wallet $W ...` for its fills, `--type hl_wallet_orders --wallet $W ...` for its orders placed or gone (see `vike-alerts-setup`).
|
|
45
45
|
|
|
46
46
|
## Verdict rubric (rules of thumb, not tool output)
|
|
47
47
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: vike-pm-l2-archive
|
|
3
|
-
description: Find and fetch the
|
|
3
|
+
description: Find and fetch the Polymarket L2 archive - daily Parquet files of the full order-book events, the trade tape and top-of-book quotes, whole, or by Polymarket category (sports, crypto, finance, ...) with each up/down series such as BTC 5-minute in its own file inside its category - with their sizes, a 1-day download link, and the on-chain outcomes to join them to. Says when the API tape is enough instead. Use when the user asks "get me Polymarket order book history" / "BTC 5m up/down L2 data for last week" / "download the Polymarket trades for a day" / "Polymarket sports order books" / "data to backtest a Polymarket strategy".
|
|
4
4
|
allowed-tools: Bash(vike-data:*)
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -14,15 +14,16 @@ The archive is one Parquet file per UTC day and stream, recorded since 2026-07-2
|
|
|
14
14
|
vike-data polymarket archive --view datasets --asset btc --tenor 5m --stream trades --date-from 2026-10-15 --date-to 2026-10-17 --json
|
|
15
15
|
vike-data polymarket archive --view url --stream trades --date 2026-10-16 --json # multi-asset file, one day
|
|
16
16
|
vike-data polymarket archive --view url --stream trades --asset btc --tenor 5m --date 2026-10-16 --json # family file
|
|
17
|
+
vike-data polymarket archive --view url --stream trades --category sports --date 2026-11-29 --json # category file
|
|
17
18
|
vike-data polymarket settlements --slug-prefix btc-updown-5m- --from-ms <start> --to-ms <end> --limit 1000 --json # how each market resolved
|
|
18
19
|
```
|
|
19
20
|
|
|
20
|
-
Streams: `book_events` (full L2: snapshots, `price_change` deltas, trades, tick-size and status markers), `trades` (taker tape), `l1_quotes` (derived top of book). A row carries `date`, `stream`, `layout` (`flat` = every market
|
|
21
|
+
Streams: `book_events` (full L2: snapshots, `price_change` deltas, trades, tick-size and status markers), `trades` (taker tape), `l1_quotes` (derived top of book). A row carries `date`, `stream`, `layout` (`flat` = every market; `family` = one up/down series, one asset and interval, with its `category`: crypto series under crypto, stocks, indices, FX and commodities under finance; `category` = one Polymarket category's markets outside the up/down series: sports, crypto, weather, elections, politics, finance, ... and `unknown`), `bytes`, `rows`, `url`. `datasets` pages with `--limit` (max 1000) and `--offset` against `total`.
|
|
21
22
|
|
|
22
23
|
## Pick the right file
|
|
23
24
|
|
|
24
|
-
- `--asset`
|
|
25
|
-
- **Check `bytes` first.** Measured 2026-10-19: one day of `trades` about 12 MB; a BTC 5m family `trades` day 3-5 MB; one day of `book_events` **8.5 GB (532 million rows)**. Tell the user before any `book_events` download, and prefer the family file for one asset.
|
|
25
|
+
- `--asset` with `--tenor` for one series (as before), `--category` alone for a category's markets outside the series, or none of them for the whole-day file. In `datasets`, `--category crypto` lists the crypto file and every crypto series; `--asset`/`--tenor` list series only. Without any filter `datasets` mixes the layouts: filter on `layout`, or the same market appears in more than one file.
|
|
26
|
+
- **Check `bytes` first.** Measured 2026-10-19: one day of `trades` about 12 MB; a BTC 5m family `trades` day 3-5 MB; one day of `book_events` **8.5 GB (532 million rows)**. Tell the user before any `book_events` download, and prefer the family or category file for one asset or one kind of market (sports, elections, ...).
|
|
26
27
|
- A few hours or one token: use the API, not a bulk file: `vike-data polymarket tape --token-id <id> --from-ms ... --to-ms ... --event-type trade` (at most 24 h a call, no wallets), `vike-data polymarket market-trades <condition_id>` (with wallets) or `vike-data candles polymarket <token_id>`.
|
|
27
28
|
|
|
28
29
|
## Fetch (outside this skill's tool grant; hand the user the command)
|
|
@@ -31,7 +32,7 @@ Streams: `book_events` (full L2: snapshots, `price_change` deltas, trades, tick-
|
|
|
31
32
|
curl -C - -o trades-2026-10-16.parquet "<url from the row>"
|
|
32
33
|
```
|
|
33
34
|
|
|
34
|
-
The link needs no API key and is valid for
|
|
35
|
+
The link needs no API key and is valid for 1 day (`expires_at`): treat it as a secret, don't paste it anywhere shared. **Download the file whole and read the local copy** with DuckDB, polars or pyarrow: pointing a reader at the URL turns one file into thousands of range requests. The manifest and a small sample need no key at all: `https://data.vike.io/archive/manifest.json`, `https://data.vike.io/archive/samples/`.
|
|
35
36
|
|
|
36
37
|
## Reading the files
|
|
37
38
|
|
|
@@ -37,7 +37,8 @@ channel the path does not serve is refused with `unknown_channel` and the list.
|
|
|
37
37
|
`sl` / `tp` / `trailing` and `trigger_px`); `dex` is `HL` or the HIP-3 dex, `source` the snapshot feed. A
|
|
38
38
|
`disappeared` says what happened: `outcome` (`filled`, `partially_filled`, `canceled`, `unknown`) and `filled_usd`;
|
|
39
39
|
it waits for the order's fills, up to ~12 minutes after the snapshot that found the order gone. Filters `side`,
|
|
40
|
-
`event` and `kind` take one value each.
|
|
40
|
+
`event` and `kind` take one value each. The same walls after the fact, with a wallet's pulled share:
|
|
41
|
+
`vike-data hl orders --view walls` and `--view order_stats`.
|
|
41
42
|
- `hl.closed_trades`: a finished round trip (entry and exit price, `realized_pnl`, `duration_seconds`), in batches
|
|
42
43
|
every 30 minutes; unfiltered up to ~32,000 an hour (measured 2026-11-02): filter by `wallet` or `min_usd`.
|
|
43
44
|
- `hl.cohort_leverage` (`hl-cohorts`): once an hour per cohort of one `axis`, `perp_bias` and `equity_exposure`
|
package/src/commands/alerts.js
CHANGED
|
@@ -8,9 +8,11 @@ import { addTool } from './tool-command.js';
|
|
|
8
8
|
const TARGET_OPTIONS = [
|
|
9
9
|
['--address <a>', 'transfer: one wallet to watch (0x + 40 hex), sent or received'],
|
|
10
10
|
['--address-role <r>', 'transfer: any | from | to (default any; needs --address)'],
|
|
11
|
-
['--wallet <a>', 'Hyperliquid account or Polymarket wallet (0x + 40 hex): required by hl_wallet, hl_liq_proximity and pm_wallet_trade, optional for hl_liquidation'],
|
|
11
|
+
['--wallet <a>', 'Hyperliquid account or Polymarket wallet (0x + 40 hex): required by hl_wallet, hl_wallet_orders, hl_liq_proximity and pm_wallet_trade, optional for hl_liquidation'],
|
|
12
12
|
['--condition-id <id>', 'Polymarket market (0x + 64 hex): required by pm_market_trade, pm_price_move and pm_resolution, optional for pm_wallet_trade'],
|
|
13
13
|
['--actions <a...>', 'hl_wallet: open close flip increase reduce (default all but reduce)'],
|
|
14
|
+
['--side <s>', 'hl_wallet_orders: buy | sell (default both)'],
|
|
15
|
+
['--events <e...>', 'hl_wallet_orders: placed gone (default both)'],
|
|
14
16
|
['--pnl-cohorts <c...>', 'hl_cohort_fill, hl_liquidation: PnL cohorts, e.g. "3x smart" "2x smart"'],
|
|
15
17
|
['--size-cohorts <c...>', 'hl_cohort_fill, hl_liquidation: size cohorts, e.g. "4x whale" whale'],
|
|
16
18
|
['--index <i>', 'hl_cohort_bias (required): smi | wsi | smart_bias | whale_bias | smi_wsi_gap'],
|
|
@@ -28,6 +30,8 @@ function targetArgs(opts) {
|
|
|
28
30
|
address_role: opts.addressRole,
|
|
29
31
|
wallet: opts.wallet,
|
|
30
32
|
actions: list(opts.actions),
|
|
33
|
+
side: opts.side,
|
|
34
|
+
events: list(opts.events),
|
|
31
35
|
pnl_cohorts: list(opts.pnlCohorts),
|
|
32
36
|
size_cohorts: list(opts.sizeCohorts),
|
|
33
37
|
index: opts.index,
|
|
@@ -41,7 +45,7 @@ function targetArgs(opts) {
|
|
|
41
45
|
export function registerAlerts(program) {
|
|
42
46
|
const cmd = program
|
|
43
47
|
.command('alerts')
|
|
44
|
-
.description('Manage alerts: on-chain transfers, Hyperliquid fills, liquidations, cohort bias and
|
|
48
|
+
.description('Manage alerts: on-chain transfers, Hyperliquid fills, liquidations, cohort bias, liquidation proximity and a wallet\'s orders, and Polymarket trades, price moves and resolutions (at most 200 active per account)');
|
|
45
49
|
|
|
46
50
|
cmd
|
|
47
51
|
.command('list')
|
|
@@ -87,11 +91,11 @@ export function registerAlerts(program) {
|
|
|
87
91
|
.command('create')
|
|
88
92
|
.description('Create an alert: an on-chain transfer alert (default), a Hyperliquid or a Polymarket alert (--type)')
|
|
89
93
|
.requiredOption('--label <l>', 'Alert label (user-visible name)')
|
|
90
|
-
.option('--type <t>', 'transfer | hl_wallet | hl_cohort_fill | hl_liquidation | hl_cohort_bias | hl_liq_proximity | pm_wallet_trade | pm_market_trade | pm_price_move | pm_resolution (default transfer)')
|
|
94
|
+
.option('--type <t>', 'transfer | hl_wallet | hl_cohort_fill | hl_liquidation | hl_cohort_bias | hl_liq_proximity | hl_wallet_orders | pm_wallet_trade | pm_market_trade | pm_price_move | pm_resolution (default transfer)')
|
|
91
95
|
.option('--token <sym>', 'transfer: token ticker, UPPERCASE (e.g. USDC); Hyperliquid: the coin (BTC, kPEPE), required by hl_cohort_bias')
|
|
92
96
|
// No default chain: a Hyperliquid alert refuses one.
|
|
93
97
|
.option('--chain <c>', 'transfer only: eth | bsc | base | hyperevm (default eth)')
|
|
94
|
-
.option('--min-usd <n>', 'transfer: minimum USD value; Hyperliquid, Polymarket: fill, liquidation or trade floor (hl_cohort_fill: required, >= 10000; pm_market_trade: required, >= 1000)')
|
|
98
|
+
.option('--min-usd <n>', 'transfer: minimum USD value; Hyperliquid, Polymarket: fill, liquidation or trade floor (hl_cohort_fill: required, >= 10000; hl_wallet_orders: the order\'s size x price, >= 1000, default 10000; pm_market_trade: required, >= 1000)')
|
|
95
99
|
.option('--max-usd <n>', 'transfer only: maximum USD value');
|
|
96
100
|
for (const [flags, text] of TARGET_OPTIONS) create.option(flags, text);
|
|
97
101
|
create
|
|
@@ -162,10 +166,10 @@ export function registerAlerts(program) {
|
|
|
162
166
|
|
|
163
167
|
addTool(cmd, 'events', {
|
|
164
168
|
tool: 'alerts_events',
|
|
165
|
-
desc: 'Events your alerts produced, oldest first, with each delivery\'s status (kept 15 days)',
|
|
169
|
+
desc: 'Events your alerts produced, oldest first, with each delivery\'s status (kept 15 days); a page also ends at about 2 MB: page on while has_more is true',
|
|
166
170
|
options: [
|
|
167
171
|
['--cursor <c>', 'next_cursor from the previous page (an empty page returns the same one)'],
|
|
168
|
-
['--limit <n>', 'Events per page, 1-500 (default 100)'],
|
|
172
|
+
['--limit <n>', 'Events per page, 1-500 (default 100); a page can hold fewer with has_more true'],
|
|
169
173
|
['--rule-id <id>', 'Only the events of this alert'],
|
|
170
174
|
],
|
|
171
175
|
});
|
package/src/commands/hl.js
CHANGED
|
@@ -184,25 +184,31 @@ export function registerHl(program) {
|
|
|
184
184
|
|
|
185
185
|
addTool(hl, 'orders', {
|
|
186
186
|
tool: 'hl_orders',
|
|
187
|
-
desc: 'Standing orders: resting at one instant (with the owner\'s cohorts), one wallet\'s orders over a window, one symbol\'s order clusters or
|
|
187
|
+
desc: 'Standing orders: resting at one instant (with the owner\'s cohorts), one wallet\'s orders over a window, one symbol\'s order clusters, order book, squeeze map or book by cohort; walls (large orders) and what became of them',
|
|
188
188
|
options: [
|
|
189
|
-
view(['open', 'wallet', 'clusters', 'book']),
|
|
190
|
-
['--symbol <s>', 'open: symbol and/or --wallet required; clusters, book: required. With --market spot a pair, e.g. HYPE/USDC'],
|
|
191
|
-
['--market <m>', 'open, clusters, book: perp (default) | spot'],
|
|
192
|
-
['--wallet <a>', 'open: one wallet\'s resting orders'],
|
|
193
|
-
['--address <a>', 'wallet: the wallet (required)'],
|
|
194
|
-
['--at <t>', 'open, clusters, book: ISO-8601 UTC instant (default the newest snapshot)'],
|
|
189
|
+
view(['open', 'wallet', 'clusters', 'book', 'squeeze', 'book_cohorts', 'walls', 'order_stats']),
|
|
190
|
+
['--symbol <s>', 'open, walls: symbol and/or --wallet required; clusters, book, squeeze, book_cohorts: required. With --market spot a pair, e.g. HYPE/USDC'],
|
|
191
|
+
['--market <m>', 'open, clusters, book, book_cohorts, walls, order_stats: perp (default) | spot'],
|
|
192
|
+
['--wallet <a>', 'open: one wallet\'s resting orders; walls: one wallet\'s walls'],
|
|
193
|
+
['--address <a>', 'wallet, order_stats: the wallet (required)'],
|
|
194
|
+
['--at <t>', 'open, clusters, book, squeeze: ISO-8601 UTC instant (default the newest snapshot)'],
|
|
195
195
|
['--oid <n>', 'open: one order id'],
|
|
196
196
|
['--order-type <t>', 'open: Limit | Stop Market | Stop Limit | Take Profit Market | Take Profit Limit | Trailing Stop Market'],
|
|
197
197
|
['--created-from <t>', 'open: placed at or after (ISO-8601 UTC)'],
|
|
198
198
|
['--created-to <t>', 'open: placed at or before (ISO-8601 UTC)'],
|
|
199
|
-
['--from <t>', 'wallet: window start (default 7 days before --to)'],
|
|
200
|
-
['--to <t>', 'wallet: window end (default the newest snapshot; at most 30 days)'],
|
|
199
|
+
['--from <t>', 'wallet, order_stats: window start (default 7 days before --to); walls, book_cohorts: default 24 hours before --to'],
|
|
200
|
+
['--to <t>', 'wallet, walls, order_stats: window end (default the newest snapshot; book_cohorts: now); at most 30 days after --from (wallet), 7 days (the others)'],
|
|
201
201
|
['--status <s>', 'wallet: open | filled | partially_filled | canceled_or_expired'],
|
|
202
|
-
['--
|
|
203
|
-
['--
|
|
204
|
-
['--
|
|
205
|
-
['--
|
|
202
|
+
['--min-usd <usd>', 'walls, order_stats: smallest wall in USD, at least 100000 (default walls 1000000, order_stats 100000)'],
|
|
203
|
+
['--kind <k>', 'walls: both (default) | resting | trigger'],
|
|
204
|
+
['--outcome <o>', 'walls: filled | partially_filled | pulled | open | unknown (default all)'],
|
|
205
|
+
['--touch-bps <n>', 'walls: near_touch when the other side of the book was this close, in basis points (default 10, max 500)'],
|
|
206
|
+
['--step-bps <n>', 'clusters, squeeze: bucket width in basis points (default 10; squeeze 25)'],
|
|
207
|
+
['--range-pct <n>', 'clusters, squeeze: half-width around the mid in percent (default 10; squeeze 8)'],
|
|
208
|
+
['--cohort-axis <a>', 'open, clusters, squeeze: size | pnl | pnl_abs (default size); book_cohorts: size | pnl, the ladder the book is split by'],
|
|
209
|
+
['--cohort <c>', 'open, clusters: one cohort label; squeeze: that cohort\'s stops and liquidations (with --at, the labels of the hour before that snapshot)'],
|
|
210
|
+
['--band-bps <n>', 'book_cohorts: orders within 50 | 200 (default) | 1000 basis points of the mid'],
|
|
211
|
+
['--interval <i>', 'book_cohorts: one point per 5m | 1h (default) | 1d'],
|
|
206
212
|
['--side <s>', 'book: both (default) | bid | ask'],
|
|
207
213
|
['--levels <n>', 'book: price levels per side, best first (default 100, max 1000)'],
|
|
208
214
|
LIMIT, CURSOR,
|
|
@@ -156,7 +156,7 @@ export function registerPolymarket(program) {
|
|
|
156
156
|
|
|
157
157
|
addTool(cmd, 'archive', {
|
|
158
158
|
tool: 'polymarket_archive',
|
|
159
|
-
desc: 'Index of the Parquet L2 archive, or a
|
|
159
|
+
desc: 'Index of the Parquet L2 archive, or a 1-day download link for one file (--view url)',
|
|
160
160
|
options: [
|
|
161
161
|
['--view <v>', 'datasets | url (default datasets)'],
|
|
162
162
|
['--stream <s>', 'book_events | trades | l1_quotes (required for url)'],
|
|
@@ -165,6 +165,7 @@ export function registerPolymarket(program) {
|
|
|
165
165
|
['--date-to <d>', 'datasets: last UTC day, inclusive'],
|
|
166
166
|
['--asset <a>', 'Family files only, e.g. btc (with --tenor)'],
|
|
167
167
|
['--tenor <t>', 'Family files only, e.g. 5m (with --asset)'],
|
|
168
|
+
['--category <c>', 'A category folder, e.g. sports, crypto, finance: alone = its markets outside the up/down series; datasets also lists its series'],
|
|
168
169
|
['--limit <n>', 'datasets: files per page (default 50)'],
|
|
169
170
|
['--offset <n>', 'datasets: skip this many files'],
|
|
170
171
|
],
|