SATURN DEX v4 Developer Documentation

Build on the Saturn DEX
The future of on-chain liquidity.

A complete developer reference for every public method a builder can call.

One Protocol, Many Layers

Quickstart

Saturn contracts are deployed on Phantasma. Use the phantasma-sdk-ts or any Phantasma-compatible library to call them. Every write method requires the caller to be a wallet witness; read methods can be called from anywhere.

1 · Install the SDK

npm install phantasma-sdk-ts

2 · Read contract data

const api = new PhantasmaAPI(rpcUrl);
const script = sb.begin()
  .callContract("saturnrouter", "getPoolInfo", [poolId])
  .endScript();
const res = await api.invokeRawScript("main", script);

3 · Send a transaction

// Poltergeist / Ecto or phantasma-ts builder.
// Call a public write like saturnswap.swap(...).
// The user signs; their wallet becomes the witness.

4 · Browse example scripts

// Ready-made scripts for every Saturn contract:
//   github.com/Infinite-Star-Studios/
//     SaturnDex4ExampleScripts
git clone https://github.com/Infinite-Star-Studios/SaturnDex4ExampleScripts.git

Community & Resources

Join the Saturn builder community, grab ready-to-run example scripts, and ship faster on Phantasma.