Transaction Builder API
Build order
Build a buy or sell order — works on both bonding curve and AMM
POST
Builds an unsigned buy or sell order for any Snekfun token. The endpoint automatically detects where the token is trading and routes the order accordingly — to the bonding curve pre-graduation, or to the Splash DEX AMM pool once the token has graduated. Callers don’t need to know which venue the token lives on.
Sign via
Possible errors:
/sign, sign and submit via /sign-and-submit, or submit an already signed transaction via /submit.
Auth: Public
Request body
Token asset ID in
{policyId}.{hexAssetName} format.Trade amount. For
BUY this is the lovelace input. For BUY_WITH_OUTPUT this is the token amount you want to receive. For SELL this is the token amount you want to sell.One of
BUY, BUY_WITH_OUTPUT, or SELL.Slippage bucket. One of
15, 30, 50, 75, or infinity.Bech32 change address.
Response
Hex-encoded unsigned transaction CBOR.
Builder transaction ID.
Optional order beacon emitted by the builder.
Optional execution price ratio.
Quote asset ID used for the computed price.
Base asset ID used for the computed price.
Output amount as a bigint-safe string.
Input amount as a bigint-safe string.
Output asset ID.
Input asset ID.
Error response
Machine-readable error code.
Human-readable error message.
400 INVALID_PARAMS— one or more required fields are missing, malformed, or outside the allowed enum values.500 ASSET_NOT_FOUND— the requested token could not be found.500 MIN_TRADE_AMOUNT— the trade amount is below the minimum allowed amount.500 MAX_TRADE_AMOUNT— the trade amount exceeds the maximum allowed amount.500 PROTOCOL_CONFIG— protocol config loading or validation failed.500 OPERATIONS_CONFIG— operations config loading or validation failed.500 UNKNOWN— unexpected builder failure.