Skip to main content
Build an unsigned unstake transaction. The route depends on strategy and kind: The returned transaction is base64 unsigned bytes. Sign and broadcast via POST /api/v1/broadcast.

Request


Response shapes

The response shape mirrors /stake: transaction (base64 unsigned), hubra_token (required at /broadcast), plus route metadata.

Sanctum-routed kinds

For sol-native-stake instant, sol-liquid-stake instant, and sol-liquid-stake slow:
sanctumKind varies by route: Forward hubra_token, sanctumKind, and sanctum_order to /broadcast.

Voltr-routed (usdc-earn instant)

Broadcast via route: "rpc".

Plain native deactivate (sol-native-stake deactivate)

No Sanctum or Voltr involvement. Broadcast via route: "rpc". After the deactivation epoch passes, call POST /api/v1/withdraw to close the stake account and pull SOL back.

Leveraged (sol-leveraged-stake instant)

Burns raSOL Max LP (amount) and pays out raSOL. Routes through the rasol-max SDK’s dual path — path tells you which ran:
  • vault-idle — one instruction, when the vault holds enough idle raSOL.
  • flash-bracket — 8–10 instructions + an address-lookup-table, deleveraging your slice through a MarginFi flashloan. The first redemption per wallet lazily initialises a MarginFi account (~0.005 SOL one-shot rent), flagged by initializedMarginfiAccount.
Broadcast via route: "rpc".

Finishing to SOL (outputAsset: "SOL")

The leveraged exit pays out raSOL, not SOL. Pass outputAsset: "SOL" to get the same single LP → raSOL transaction plus a ready-to-run next step for the raSOL → SOL conversion:
The SOL leg is a second signed transaction, not atomic. Sanctum won’t quote raSOL → SOL until the burned raSOL actually lands in your wallet. So: broadcast the withdraw, read the raSOL your wallet actually received, then fire the next call sized by that real balance — next.body.amount is only the build-time estimate.

Examples


Errors


See also

POST /quote

Preview the output before unstaking.

POST /withdraw

Complete a native deactivate.

POST /broadcast

Submit the signed transaction.