sodax-dapp-kit-staking

Installation
SKILL.md

Staking (dapp-kit granular skill)

Granular skill for the staking hooks of @sodax/dapp-kit v2. queryKey/mutationKey first segment: staking. React-only — backend uses @sodax/sdk directly.

Step 1 — Clarify with user before coding

  1. New code or v1 → v2 port?
  2. Which action? useStake, useUnstake (waiting period), useInstantUnstake (slippage, no wait), useClaim, useCancelUnstake.
  3. Allowance gating? stake approves SODA, unstake/instantUnstake approve xSODA — each has its OWN approve + allowance hook pair. claim/cancelUnstake need no approval.
  4. Need reads? useStakingInfo (position), useUnstakingInfoWithPenalty (pending requests + penalty), useStakingConfig (protocol params), useStakeRatio/useInstantUnstakeRatio (previews).

Integration workflow (new v2 code)

  1. ../integration/knowledge/ai-rules.md — DO / DO NOT (read first).
  2. ../integration/knowledge/architecture.md — hook shapes, mutateAsyncSafe, unwrapResult, queryKey conventions.
  3. ../integration/knowledge/features/staking.md — full hook surface, mutation TVars per action, the three approve/allowance pairs, read shapes.
  4. ../integration/knowledge/recipes/staking.md — full worked examples.
  5. Call-shape choice → ../integration/knowledge/recipes/mutation-error-handling.md.
Installs
1
First Seen
Jun 10, 2026
sodax-dapp-kit-staking — icon-project/sodax-sdks