Docs / Builders
SDK
One JavaScript module, served by this site, no dependencies. It reads the public API and asks the MCP server for quotes and calldata. You sign with your own wallet.
import * as S from "/sdk/selene.js"
const ref = await S.reference() // HyperCore mids, basis, reference, keeper post, pool
const tides = await S.tides() // ranges, totals, share price, fees, status
const q = await S.quoteDeposit("hype-usdc", "1.5", "90")
const tx = await S.depositCalldata("hype-usdc", { to: "0xYou", amount0: "1.5", amount1: "90" })
// tx = { to, data, value, approve }: approve the tide for USDC, then send { to, data, value }
const w = await S.withdrawCalldata("hype-usdc", { shares: "1000000000000", to: "0xYou" })
const st = await S.rebalanceStatus("hype-usdc") // canRebalance, reason, calldata when ready
const h = await S.hedgeSize("hype-usdc", { valueQuote: 1000 })
const plan = S.rangeFor(61.2, { halfWidth: 600, innerBandBps: 5000 })Fetch it from the command line: curl -O {site}/sdk/selene.js.