Contracts on HyperEVM
Mooner's contracts on HyperEVM, Hyperliquid's EVM: what to call and what to listen to.
On Hyperliquid, Mooner is three Solidity contracts on HyperEVM (chain 999; testnet 998), with every rule in these docs. Anything that can send an EVM transaction can launch, buy and sell exactly like the Mooner website does.
| Contract | What it does |
|---|---|
MoonerLaunchpad | Every coin's bonding curve and every rule: max per wallet and its 5% tax, the launch block, one ticker forever, fees, creator rewards, graduation. |
MoonerToken | One per coin: a plain ERC-20 with a fixed supply, minted once at launch. |
V3Graduator | Opens the coin's Project X pool at the curve's last price, holds the liquidity forever, and pays out the pool's fees. |
| Network | Addresses |
|---|---|
| Mainnet | Published here at launch |
| Testnet | Published here once deployed |
Amounts are in wei (18 decimals) for both HYPE and every coin.
Trading
| Call | Notes |
|---|---|
buy(token, minTokensOut) | Send HYPE as the value. Must come from the wallet itself, not a contract. In the launch block only the creator can buy. Past the coin's max, the excess pays 5% more; what can't be bought is refunded. |
sell(token, tokenAmount, minNativeOut) | No approval needed. A wallet can't sell a coin in the block it bought it. Sells keep working while launches are paused; once the curve is complete, the coin is sold in its pool. |
buyBurn(token, minTokensOut) | Buys the coin and burns it on the spot; anyone can. |
quoteBuy(token, wallet, budget) / quoteSell(token, tokenAmount) | What a trade gives right now: tokens or HYPE out, the trading fee and the 5% tax. Whatever a buy can't spend is refunded. |
curves(token) | The curve's state: reserves, complete, migrated. |
maxWalletOf(token) | The coin's max per wallet, in tokens. It shrinks as the supply is burned. |
graduate(token) | Once the curve is complete, moves the coin to Project X. Anyone can call it; Mooner does it automatically. |
Creator rewards
| Call | Notes |
|---|---|
claimCreatorFees(token) | The creator takes their rewards from the curve. |
setCreatorBurns(token, burns) | The creator switches between paid and buy back and burn. |
burnCreatorFees(token, minTokensOut) | In burn mode, spends the rewards buying the coin and burns it; returns the tokens burned. Only the creator or Mooner's keeper, and the buy must bring at least minTokensOut (simulate the call for a quote, then send it less a margin), so a bot that moves the price first makes it fail instead of selling into it. |
V3Graduator.collect(token, minTokensOut) | After graduation, collects the pool's fees and pays them out, the HYPE side as HYPE (WHYPE to a wallet that refuses HYPE) and the coin side as the coin: 0.30% of the volume through Mooner's position to the creator (or bought back and burned), the rest to the protocol. Anyone in paid mode (minTokensOut is ignored); in burn mode the creator or the keeper, with minTokensOut as in burnCreatorFees. |
Once complete is true the curve has sold out; once migrated is true the coin trades in its Project X pool (V3Graduator.poolFor(token)), a normal 1% Uniswap V3-style pool, with no max and no tax.
Launching
createCoin(launch, signature, minTokensOut) launches a coin. The launch (name, ticker, metadata URI, the name's skeleton, the max per wallet, a deadline) must carry the signature of Mooner's launch service, which checks the coin isn't a copy of one already out there. The value sent pays the launch fee; anything above it is the creator's first buy, in the launch block.
Events
| Event | When |
|---|---|
CoinCreated(token, creator, name, ticker, uri, maxWalletTokens) | A coin launches. |
Trade(token, trader, isBuy, nativeAmount, tokenAmount, protocolFee, creatorFee, excessTax, virtualNative, virtualToken) | Every buy and sell on the curve; excessTax is the 5% paid past the max. |
Burned(token, by, nativeSpent, tokensBurned) | A buy & burn. |
CurveCompleted(token, realNative) | The curve sells out. |
Graduated(token, pool, poolNative, poolTokens, burnedTokens) | The coin moves to Project X. |
CreatorFeesClaimed, CreatorModeSet | A creator claims, or switches between paid and buy back and burn. |
burnCreatorFees shows up as a Trade with the launchpad itself as the trader while the coin is on its curve, and as a Burned with the tokens it bought and burned in the pool after graduation.
Graduation contract events and calls
Graduated(token, pool, tokenId, sqrtPriceX96, tokens, native) | Emitted by V3Graduator as it opens the pool: the position's NFT id, the opening price and what went in. |
FeesCollected(token, tokenId, creatorToken, creatorNative, protocolToken, protocolNative) | Each collection of the pool's fees and how it was split. |
V3Graduator.buyAndBurn(token, minTokensOut) | Buys a graduated coin in its pool with the HYPE sent and burns it, if that brings at least minTokensOut; returns the tokens burned. Anyone can. |
withdrawProtocolFees() | Sends the protocol's accrued HYPE to its fee wallet. |