Developers
Open app
Withdrawals

Price a withdrawal

POST/withdraw/quote
Requires a session: Authorization: Bearer <token>Limit: 60 / 10 min per user

Prices moving usd of the user's Cash (Hyperliquid spot USDC) to to on chainId, paid out in that network's USDC (or its main stablecoin; chains as in /deposit-networks). Returns what arrives, the cost, and Relay's two steps, which the user's own wallet signs: an EIP-712 nonce-mapping authorization (send it to /withdraw/authorize), then a Hyperliquid sendAsset submitted to Hyperliquid with the same nonce. Slay deposit addresses are refused as a destination. Minimum $2.

Request

curl -X POST 'https://api.slay.money/api/predict/withdraw/quote' \
  -H 'Authorization: Bearer $SLAY_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"chainId":8453,"to":"0x1f9840a85d5af5bf1d1762f925bdaddc4201f984","usd":25,"token":"USDC"}'

Body

chainIdintegerrequired
tostringrequired
usdnumberrequired
tokenstring
Pay out in the network's USDC, its USDT (USDT0 / USD₮0 where that's its Tether), or PUSD on Polygon to fund the user's Polymarket wallet; converted by Relay. One of USDC, USDT, PUSDDefault USDC

Responses

200The quote.
requestIdstring
receivestring
symbolstring
feeUsdnumber
secondsnumber
stepsobject[]
200 response
{
  "requestId": "0x1793…",
  "receive": "24.973705",
  "symbol": "USDC",
  "feeUsd": 0.03,
  "seconds": 2,
  "steps": []
}
400Bad network, address or amount.
400 response
{
  "error": "That isn't a Base address."
}
401No valid session. Sign in again.
401 response
{
  "error": "Sign in first"
}
403Withdrawals aren't open for this user.
403 response
{
  "error": "Withdrawals aren't open yet."
}
409No wallet yet.
409 response
{
  "error": "Set up your wallet first"
}
429Rate limit reached. Wait for the window to pass.
429 response
{
  "error": "Too many requests. Wait a moment."
}
502Relay couldn't price it.
502 response
{
  "error": "Couldn't price this withdrawal right now. Try again."
}