@hypelens/hypelens-agent-rail 0.1.27 → 0.1.28
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/README.md +12 -6
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -14,7 +14,7 @@ Outside-agent Hyperliquid **place** rail. Builder fees → `0x9548B8E9554a196884
|
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
16
|
cd skills/hyperliquid-place/scripts && npm install && node setup.mjs
|
|
17
|
-
# or: npx -y @hypelens/hypelens-agent-rail@0.1.
|
|
17
|
+
# or: npx -y @hypelens/hypelens-agent-rail@0.1.28 hypelens-setup
|
|
18
18
|
```
|
|
19
19
|
|
|
20
20
|
`setup.mjs` / `hypelens-setup`:
|
|
@@ -23,15 +23,20 @@ cd skills/hyperliquid-place/scripts && npm install && node setup.mjs
|
|
|
23
23
|
3. Prints `maxBuilderFee` — place stays refused until approved (no silent $0)
|
|
24
24
|
4. Next: fund agent if equity=0 → place on explicit trade intent
|
|
25
25
|
|
|
26
|
-
## Quick path
|
|
26
|
+
## Quick path (setup BEFORE start — start-mcp REFUSED without setup)
|
|
27
27
|
|
|
28
28
|
```bash
|
|
29
|
-
npx
|
|
30
|
-
|
|
29
|
+
# npx setup then MCP:
|
|
30
|
+
npx -y @hypelens/hypelens-agent-rail@0.1.28 hypelens-setup
|
|
31
|
+
npx -y @hypelens/hypelens-agent-rail@0.1.28
|
|
32
|
+
# sticky ClawHub (REQUIRED order — skip setup = $0 / start refused):
|
|
31
33
|
clawhub install hyperliquid-place
|
|
32
|
-
cd skills/hyperliquid-place/scripts && npm install && node
|
|
34
|
+
cd skills/hyperliquid-place/scripts && npm install && node setup.mjs
|
|
35
|
+
# then restart MCP host / node start-mcp.mjs (writes .setup-ok)
|
|
33
36
|
```
|
|
34
37
|
|
|
38
|
+
**Paying path:** setup → maxBuilderFee>=10 → equity>0 → `hl_place_order(..., confirmTrade:true)` → `fillStatus=FILLED` (RESTING≠paid; rail auto-cancels RESTING sizeUsd→IOC once).
|
|
39
|
+
|
|
35
40
|
Env:
|
|
36
41
|
|
|
37
42
|
| Var | Role |
|
|
@@ -47,5 +52,6 @@ Env:
|
|
|
47
52
|
2. `hl_approve_payloads(agentAddress)` — auto if master key; else MASTER signs ApproveBuilderFee **0.01%**
|
|
48
53
|
3. `hl_balances` (+ fundHow if equity=0)
|
|
49
54
|
4. On explicit trade intent: `hl_place_order({coin:"BTC", isBuy:true, sizeUsd:12, leverage:2, confirmTrade:true})`
|
|
55
|
+
5. Poll until **`fillStatus=FILLED`** — RESTING≠paid (rail auto-cancel RESTING→IOC same turn once)
|
|
50
56
|
|
|
51
|
-
Skipping ApproveBuilderFee = **$0 fees**. Place is hard-refused until on-chain `maxBuilderFee` covers 1bp.
|
|
57
|
+
Skipping ApproveBuilderFee / setup / fund / FILLED = **$0 fees**. Place is hard-refused until on-chain `maxBuilderFee` covers 1bp. `start-mcp` REFUSED until `setup.mjs` wrote `.setup-ok`.
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hypelens/hypelens-agent-rail",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "Mainnet place rail. setup.mjs
|
|
3
|
+
"version": "0.1.28",
|
|
4
|
+
"description": "Mainnet place rail. REQUIRED: hypelens-setup/setup.mjs before start-mcp (start refused without .setup-ok). Refuse place until maxBuilderFee>=10 AND equity>0; hl_place_order polls orderStatus and auto-cancels RESTING sizeUsd\u2192IOC until FILLED; builder 1bp. npx @hypelens/hypelens-agent-rail@0.1.28",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"bin": {
|