mcpField
S
styx

styx

github.com/aibtcdevOther11139 installsUpdated 1d ago
Repository

About styx

Styx Skill converts Bitcoin L1 BTC to sBTC on Stacks L2 through managed liquidity pools, using `@faktoryfun/styx-sdk`. It is for agents that need to reserve liquidity, sign and broadcast deposits, and track their status.

Key features

  1. 01Check pool liquidity and configuration
  2. 02Reserve deposits and prepare transactions
  3. 03Sign locally and broadcast Bitcoin transactions
  4. 04Check status by deposit or transaction ID
  5. 05View deposit history for a Stacks address

Use cases

  1. 01Check pool capacity before depositing BTC
  2. 02Track deposit confirmations and sBTC minting
  3. 03Review an address's past deposits

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/aibtcdev/skills --skill styx

After installing, type/styxin Claude Code to confirm it loaded.

Bundled filesAGENT.mdstyx.ts

Details

From the project README

Styx Skill

Trustless BTC→sBTC conversion via the Styx protocol by FaktoryFun. Agents deposit BTC on L1 and receive sBTC on Stacks L2 through managed liquidity pools. Uses @faktoryfun/styx-sdk.

How It Works

  1. Check pool liquidity — pool-status shows available sBTC in the pool
  2. Create deposit reservation — deposit reserves pool liquidity and returns a deposit ID
  3. Build & sign transaction — The SDK provides UTXOs and deposit address; the agent builds and signs locally with @scure/btc-signer
  4. Broadcast — Signed transaction is broadcast to mempool.space
  5. Track status — status monitors the deposit through confirmation

Pools

Pool IDTypeMin DepositMax DepositSwap Types
mainLegacy10,000 sats300,000 satssbtc, usda, pepe
aibtcAI BTC10,000 sats1,000,000 satssbtc, aibtc

Subcommands

pool-status
bun run styx/styx.ts pool-status [--pool main|aibtc]

Returns realAvailable, estimatedAvailable (BTC), and lastUpdated.

pools
bun run styx/styx.ts pools

Lists all available pools with configs and active status.

fees
bun run styx/styx.ts fees

Returns current Bitcoin network fee estimates (low/medium/high in sat/vB).

price
bun run styx/styx.ts price

Returns current BTC price in USD.

deposit
bun run styx/styx.ts deposit --amount <sats> --stx-receiver <addr> --btc-sender <addr> [--pool main|aibtc] [--fee low|medium|high]

Full headless deposit flow: creates reservation, prepares PSBT, signs with wallet key, broadcasts to mempool.space, and updates deposit status. Requires an unlocked wallet.

status
bun run styx/styx.ts status --id <deposit-id>
bun run styx/styx.ts status --txid <btc-txid>

Check deposit status by deposit ID or Bitcoin transaction ID.

history
bun run styx/styx.ts history --address <stx-addr>

Get deposit history for a Stacks address.

Deposit Statuses

  • initiated — Deposit record created, liquidity reserved
  • broadcast — Bitcoin tx broadcast to mempool
  • processing — At least 1 BTC confirmation
  • confirmed — Required confirmations reached, sBTC minted
  • refund-requested — User requested refund
  • canceled — Deposit canceled, liquidity released

Notes

  • Always check pool-status before depositing to verify sufficient liquidity
  • Update deposit status after broadcast — this is critical for accurate pool accounting
  • Min deposit: 10,000 sats (0.0001 BTC). Max varies by pool.
  • The SDK uses a pre-configured API key for the Styx backend

Comments

Markdown supported