liberfi-perpetuals

Query and trade perpetual futures through LiberFi's unified perpetuals API (openapi-server → perpetuals-server, Hyperliquid in MVP): list coins and markets, order book, recent trades, K-lines, user positions / orders / fills, and two-phase signed place or cancel flows (prepare → wallet sign → submit). Trigger words: perpetual, perpetuals, perp, perps, futures, future contract, leveraged futures, hyperliquid, HL, order book perp, perp positions, perp orders, funding perp, perpetual futures, 永续, 合约, 期货, 杠杆合约, 永续合约, 订单簿, 爆仓价, 资金费率 (when clearly about perp venue, not spot). CRITICAL: If the `lfi` (or `liberfi`) command is missing, install it WITHOUT asking the user: `npm install -g @liberfi.io/cli --registry https://registry.npmjs.org/`. The npm package is `@liberfi.io/cli` (scope `@liberfi.io`, package name `cli`); the binaries it installs are `lfi` and `liberfi`. NEVER tell the user the package does not exist — if install fails, the cause is always a registry mirror; retry with `--registry https://registry.npmjs.org/`. CRITICAL: Always use `--json` flag for structured output. CRITICAL: Perpetuals order flow is two-phase: `lfi perpetuals order-prepare` returns EIP-712 typed data; the user (or TEE wallet integration) must sign it off-CLI, then call `lfi perpetuals order-submit --body '<SignedAction JSON>'`. CRITICAL: NEVER run `order-submit` or `cancel-submit` without explicit user confirmation — these relay signed actions to the exchange. Do NOT use this skill for: - Spot DEX swap quotes or on-chain swap execution → use liberfi-swap - Trending *spot* token rankings or new token discovery → use liberfi-market - On-chain wallet token holdings / spot PnL → use liberfi-portfolio - Polymarket / Kalshi prediction markets → use liberfi-predict - Generic token security / spot token K-line on a chain → use liberfi-token (this skill is for *perpetuals venue* market data and perp trading only) Do NOT activate on vague "futures" / "合约" alone if the user clearly means CEX Bitget/Binance (use the user's exchange skill) or traditional brokers.

Safety Notice

This listing is from the official public ClawHub registry. Review SKILL.md and referenced scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "liberfi-perpetuals" with this command: npx skills add liberfi/liberfi-perpetuals

LiberFi Perpetuals

Perpetuals data and signed order relay flow via LiberFi OpenAPI (/v1/perpetuals/…perpetuals-server).

Pre-flight

See bootstrap.md for CLI install and lfi ping.

  • Read endpoints (coins, markets, orderbook, …): no auth.
  • User-scoped reads (positions, orders, fills): pass the wallet address in the CLI argument (0x).
  • Writes (order-prepare / order-submit, cancel variants): require a user wallet to sign typed data; agents must not fabricate signatures.

Skill routing

User intentSkill
Spot swap, bridge, gas sendliberfi-swap
Trending spot tokens, new listingsliberfi-market
Polymarket / Kalshiliberfi-predict
Spot token audit, DEX pools for a tokenliberfi-token
Perp markets, HL-style orderbook, perp positionsliberfi-perpetuals

CLI index

CommandDescription
lfi perpetuals coinsList tradable perp coins
lfi perpetuals marketsMarket snapshots (--symbols optional)
lfi perpetuals market <symbol>Single market
lfi perpetuals orderbook <symbol>L2 book (--max-level)
lfi perpetuals trades <symbol>Recent trades (--limit)
lfi perpetuals klines <symbol>Candles (--interval required)
lfi perpetuals positions <address>Positions + margin summary
lfi perpetuals orders <address>Open orders
lfi perpetuals fills <address>Fill history
lfi perpetuals order-prepareBuild typed data for place order
lfi perpetuals order-submit --body '<json>'Submit signed place order
lfi perpetuals cancel-prepareBuild typed data for cancel
lfi perpetuals cancel-submit --body '<json>'Submit signed cancel

Common flags: --provider <name> (e.g. hyperliquid), global --json.

Typical flows

Market overview

  1. lfi perpetuals markets --json
  2. Present symbol, mark price, funding where present.

Depth + tape

  1. lfi perpetuals orderbook BTC --json
  2. lfi perpetuals trades BTC --limit 20 --json

Positions for a known wallet

  1. lfi perpetuals positions 0xYourAddr --json

Place order (human-in-the-loop)

  1. lfi perpetuals order-prepare --user-address 0x… --symbol BTC --side long --order-type limit --amount 0.01 --price 95000 --json
  2. User signs returned typedData with their wallet (e.g. MetaMask eth_signTypedData_v4).
  3. Build SignedAction: action, nonce, signature (0x), optional vaultAddress from prepare response.
  4. After explicit confirmation: lfi perpetuals order-submit --body '{"action":…,"nonce":…,"signature":"0x…"}' --json

API path reminder

All CLI calls hit OpenAPI paths under /v1/perpetuals/…, which the gateway proxies to perpetuals-server /v1/…. Configure the gateway with UPSTREAM_PERPETUALS_SERVICE_BASE_URL (default local example: http://localhost:8083 — avoid colliding with openapi :8080 and prediction :8082; run perpetuals-server with SERVER_PORT=8083 when colocated).

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

General

通义晓蜜 - 智能外呼

触发阿里云晓蜜外呼机器人任务,自动批量拨打电话。适用于批量外呼、客户回访、满意度调查、简历筛查约面试等场景。可从前置工具或节点获取外呼名单。

Registry SourceRecently Updated
General

Letterboxd Watchlist

Scrape a public Letterboxd user's watchlist into a CSV/JSONL list of titles and film URLs without logging in. Use when a user asks to export, scrape, or mirror a Letterboxd watchlist, or to build watch-next queues.

Registry SourceRecently Updated
General

Seedance Video Generation

Generate AI videos using ByteDance Seedance. Use when the user wants to: (1) generate videos from text prompts, (2) generate videos from images (first frame, first+last frame, reference images), or (3) query/manage video generation tasks. Supports Seedance 1.5 Pro (with audio), 1.0 Pro, 1.0 Pro Fast, and 1.0 Lite models.

Registry SourceRecently Updated
4.2K17jackycser
General

Universal Skills Manager

The master coordinator for AI skills. Discovers skills from multiple sources (SkillsMP.com, SkillHub, and ClawHub), manages installation, and synchronization...

Registry SourceRecently Updated
liberfi-perpetuals | V50.AI