You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
v0.13.0 adds HL HIP-4 Outcome markets as a new asset class. Verified
end-to-end against mainnet (real place + cancel on asset id 100,000,010).
Two rounds of independent Codex review closed before tag.
Tests: 1305 → 1323 (+18).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: .claude-plugin/marketplace.json
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -11,7 +11,7 @@
11
11
{
12
12
"name": "perp-cli",
13
13
"description": "Trade, bridge, arbitrage, and manage perp positions across 4 DEXes (Pacifica, Hyperliquid, Lighter, Aster) via natural language. Ships an MCP server with 18 tools / 3 resources / 2 prompts and an agentskills.io-compatible Skill bundle.",
Copy file name to clipboardExpand all lines: CHANGELOG.md
+27Lines changed: 27 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,33 @@ All notable changes to `perp-cli`. Format follows [Keep a Changelog](https://kee
4
4
5
5
## [Unreleased]
6
6
7
+
## [0.13.0] — 2026-05-03
8
+
9
+
Adds Hyperliquid Outcome markets (HIP-4) support — a new asset class. Verified end-to-end against mainnet (place + cancel real order against asset id `100,000,010`). Two rounds of independent Codex review closed before release.
10
+
11
+
### Added
12
+
-**`perp outcome` command tree** — `list`, `book`, `positions`, `orders`, `buy`, `sell`, `cancel`. USDH-quoted, fully collateralized binary/range contracts; no leverage / no liquidation. $10 USDH min order. Currently 1 live market on mainnet (BTC binary daily settling at 06:00 UTC).
13
+
-**`HyperliquidOutcomeAdapter`** — composes with `HyperliquidAdapter` for signing. Asset id formula `100_000_000 + (10 * outcome + side)`. Bypasses HL's cached spot-state for fresh post-fill positions, then invalidates the `acct:` cache after place/cancel for downstream readers.
14
+
-**`OutcomeAdapter` interface** in `src/exchanges/outcome-interface.ts` (mirrors the SpotAdapter shape; ready for additional venues if HIP-4 pattern spreads).
15
+
-**Probe scripts** under `scripts/probe-outcome-{ws,order}.ts` documenting the WebSocket and exchange-action shapes that informed this implementation.
16
+
-**+16 unit tests** covering encoding (`10*outcome+side`), coin name conventions (`#<enc>`/`+<enc>`), description parsing, venue-rejection assertion helpers, and cancel-status validation. Total: 1305 → 1323.
17
+
18
+
### SSOT compliance
19
+
-**Rule #2 (No Fallback):** venue rejections embedded in `status:"ok"` + `statuses[0].error` are now thrown as `EXCHANGE_ERROR` (not silently masked); unknown outcome → `SYMBOL_NOT_FOUND`; out-of-range side / encoding overflow → `INVALID_PARAMS`. `_resolveUserAddress()` prefers `_hl.address`, falls back to OWS-stored agent meta `userEvmAddress`, and throws `NO_SIGNER_AVAILABLE` only if both are absent (no silent zero-balance substitution).
20
+
-**Rule #3 (Single Secret Source):** no new env vars; reuses existing HL agent.
21
+
22
+
### UX
23
+
-**`--dry-run`** uses `command.optsWithGlobals()` so the parent program's flag is not shadowed; pre-validates min-notional so the dry-run output cannot lie about a viable order.
24
+
-**Encoded-side mismatch detection** — `outcome buy 2 #10` (where `#10` encodes outcome 1) throws `INVALID_PARAMS` with guidance instead of silently routing to outcome 2.
25
+
-**Pre-checks spot USDH balance** on buy and surfaces `INSUFFICIENT_BALANCE` with a "bridge USDC→USDH" remediation instead of an opaque venue error.
26
+
-**`outcome orders`** uses the normalised lowercase `buy`/`sell` from the HL adapter (was rendering all buys as SELL).
27
+
28
+
### Out of scope (deferred)
29
+
- Portfolio aggregation of outcome holdings (roll into `perp portfolio`).
30
+
- Landing page outcome line.
31
+
-`outcome close <outcome> <side>` shortcut (use `outcome sell <outcome> <side> <usd>` for now).
32
+
- HIP-4 builder/deployer mechanics for creating new outcomes/questions.
33
+
7
34
## [0.12.18] — 2026-05-02
8
35
9
36
Closes Codex independent review of v0.12.17. 1 HIGH regression + 1 MEDIUM Rule #2 gap.
compatibility: "Requires Node.js 20 or newer and the perp-cli npm package (global install or npx). Network access required for exchange APIs and bridge providers. Mutating commands need wallet keys configured via 'perp wallet set EXCHANGE KEY' (Solana base58 / EVM hex / Aster API key). Skill is portable across Claude Code, Claude.ai, Cursor, Codex, and Gemini CLI — no platform-specific features."
7
7
metadata:
8
8
author: hypurrquant
9
-
version: "0.12.18"
9
+
version: "0.13.0"
10
10
---
11
11
12
12
# perp-cli
@@ -44,7 +44,7 @@ Also bundled under `scripts/`: `preflight.sh`, `arb-monitor.sh`, `funding-analys
0 commit comments