Tristero LogoTristero

Tristero Introduction

Cross-chain trading API for spot swaps, margin positions, and non-EVM asset exchanges

Tristero is a trustless, cross-chain trading protocol. Using it, on-chain traders are able to access deep liquidity across DEXs and CEXs to make spot trades, take out leveraged margin positions, and execute cross-VM swaps into non-EVM assets like BTC, XMR, and LTC. Unlike traditional DEXs, Tristero ensures that you will get the best execution price compared across known CEX and DEX exchanges - all while ensuring full MEV protection.

Non-custodial

Tristero never holds assets. All execution is handled by permissionless smart contracts. Your wallet, your keys, your trades.

Getting started

The fastest way to use Tristero programmatically is through the Python SDK:

pip install tristero
poetry add tristero
uv add tristero
private_key = os.getenv("TEST_ACCOUNT_PRIVKEY")
w3 = make_async_w3(os.getenv("ARB_RPC_URL"))
account = Account.from_key(private_key)

result = await execute_permit2_swap(
    w3=w3,
    account=account,
    src_t=TokenSpec(
      chain_id=ChainID(42161),
      token_address="0xaf88d065e77c8cC2239327C5EDb3A432268e5831"
    ),  # USDC (Arbitrum)
    dst_t=TokenSpec(
      chain_id=ChainID(8453),
      token_address="0xfde4C96c8593536E31F229EA8f37b2ADa2699bb2"
    ),  # USDT (Base)
    raw_amount=1_000_000,  # 1 USDC (6 decimals)
    timeout=300,
)
print(result) # Print the result if the trade succeeded

Spot trading

With Tristero, you can swap any ERC-20 token across supported EVM chains using Permit2 signatures. No token approval transactions needed — sign an EIP-712 message and Tristero will handle the rest of the execution.

  • Cross-chain: swap USDC on Arbitrum for USDT on Base
  • Same-chain: swap USDC for WETH on Arbitrum
  • Native ETH support
  • Real-time quote streaming via WebSocket (~500ms updates) - [Learn how]

Tristero's DeFI swap protocol supports the following EVM chains: Ethereum, Avalanche, Polygon, Optimism, Solana, Monad, Unichain, Mantle, Sonic, Sei, Gnosis, Scroll, Ronin, Mode, Linea, Ink, Injective EVM, BOB, ApeChain, Abstract

For more information on placing spot trades, reference the Python SDK documentation or the API.

Margin trading

You can also open leveraged positions (up to 10x) on numerous ERC-20s and tokenized assets as collateral.

  • ERC-20s and tokenized assets as collateral: PAXG, TSLA, WBTC and more are all tradeable in the app now.
  • Configurable leverage ratios
  • Partial or full position closes
  • Automatic liquidations and payments

Tristero's margin feature was built to avoid ADL - an unhealthy market condition in which the positions on one side of a market are forcibly closed on one side of a market in order to maintain solvency, without any gains on the other side. Tristero instead takes a lending based approach - any position onto which a counterparty agrees to allow leverage on will be allowed, avoiding the liquidation risks that are introduced by creating a global orderbook for the asset.

For more information on placing margin trades, reference the Python SDK documentation or the API.

Cross-VM

Feather is a permissionless cross-chain relay integrated into Tristero for swapping into and out of non-EVM assets. No smart contracts, no LPs, no wallet connections — deposit to an address, receive output from Feather's reserves.

Feather supports the following assets: Bitcoin, Monero, Ethereum, USDC (Ethereum), Litecoin, Solana

Feather uses a balance-sheet market making model: it holds reserves in each currency and adjusts pricing to stay balanced. This means it can support chains that bridges and DEXes typically can't — including UTXO chains and privacy coins.

You can get started with making cross-VM trades by referencing the Feather Quickstart.