Rule Craft
DocsIntegrate as a launcherMenu

Guides

Integrate as a launcher

Use Rule Craft rules from your own launch product.

A launchpad or token tool can open pools with Rule Craft rules from its own interface by calling the RuleCraftLauncher directly.

  1. Validate the user's rule set with the same bounds as the composer (they are listed in module parameters); the contracts revert with BadRules(code) otherwise.
  2. Call launch(LaunchParams) with name, symbol, supply, the opening sqrt price, the Rules struct, an optional blueprint id and the dev-buy minimum; send the dev buy as value.
  3. Route trades with swapExactIn(key, buy, amountIn, minOut, to), quoting first with Uniswap's v4 Quoter.
  4. Link your users to the pool page so they can read the rules.
launch((string name, string symbol, uint256 supply, uint160 sqrtPriceX96,
        Rules rules, uint64 blueprintId, uint256 devBuyMinOut)) payable
  -> (uint256 launchId, address token, bytes32 poolId)
swapExactIn(PoolKey key, bool buy, uint128 amountIn, uint256 minOut, address to) payable
  -> uint256 amountOut

Integration tracks and what each needs are described on build with us. Contract sources and ABIs are in the repository under contracts/.

The contracts are unaudited. Integrate at your own risk until a review is published.