perp-cli 0.12.8 → 0.12.9

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.
@@ -383,6 +383,15 @@ export class HyperliquidAdapter {
383
383
  return "portfolio";
384
384
  if (raw === "disabled")
385
385
  return "standard";
386
+ // "default" is the implicit pre-set value HL returns when a user has
387
+ // never invoked `userSetAbstraction`. Per HL docs the four modes are
388
+ // Standard / Unified / Portfolio / (legacy) DEX abstraction. The set
389
+ // API only accepts the latter three; Standard is the de-facto baseline
390
+ // for unset accounts. Map "default" → "standard" so accounting branches
391
+ // pick the perp clearinghouse path. Users can opt into unified explicitly
392
+ // via `wallet manage account-mode unified`.
393
+ if (raw === "default")
394
+ return "standard";
386
395
  throw new PerpError("INVALID_PARAMS", `UNKNOWN_ACCOUNT_MODE: HL returned unrecognized userAbstraction mode: ${JSON.stringify(raw)}`, { remediation: "Check app.hyperliquid.xyz Settings → Account Mode" });
387
396
  });
388
397
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "perp-cli",
3
- "version": "0.12.8",
3
+ "version": "0.12.9",
4
4
  "description": "Multi-DEX Perpetual Futures CLI - Pacifica, Hyperliquid, Lighter, Aster",
5
5
  "bin": {
6
6
  "perp": "dist/index.js",
@@ -5,7 +5,7 @@ allowed-tools: "Bash(perp:*), Bash(npx perp-cli:*), Bash(npx -y perp-cli:*)"
5
5
  license: MIT
6
6
  metadata:
7
7
  author: hypurrquant
8
- version: "0.12.8"
8
+ version: "0.12.9"
9
9
  ---
10
10
 
11
11
  # perp-cli Agent Guide
@@ -41,7 +41,7 @@ Multi-DEX perpetual futures CLI + MCP server — Pacifica (Solana), Hyperliquid
41
41
  ## Install
42
42
 
43
43
  ```bash
44
- perp --version 2>/dev/null # check if exists (must be >= 0.12.8)
44
+ perp --version 2>/dev/null # check if exists (must be >= 0.12.9)
45
45
  npm install -g perp-cli@latest 2>/dev/null || npx -y perp-cli@latest --json --version
46
46
  ```
47
47