Skip to main content

DeFi Overview

Introducing

Changelly DeFi Swap is an open liquidity layer that connects fragmented liquidity across multiple blockchains. It enables users to swap any token to any token across Ethereum, Solana, Tron, and Bitcoin through a single unified execution layer.


Key features

  • Cross-Chain Swaps: Swap tokens between Ethereum, Solana, Tron, and Bitcoin.
  • Best Execution: Smart routing analyzes all available paths to minimize costs.
  • Universal Access: Swap any supported token across any supported chain.
  • Non-Custodial: Users maintain control of their assets throughout the swap process.

User Flow

The process involves two main participants: the user, who initiates the swap, and the resolver, who executes it.

The swap process starts with a quote request.

Quote Request

The user specifies the currency pair they would like to swap and the amount. The client sends these parameters to the Changelly DeFi Quote API. The API returns a quote, a time-limited execution estimate that includes all pricing information.

Intent Creation

After receiving a quote, the client creates an intent, a structured representation of the user's swap intention, by specifying the user's addresses and the quote identifier the user agreed to. This represents the user's intention to execute the swap under the quoted conditions.

Signing an Intent

After intent creation, the API provides all the necessary information for the user to sign the swap. The user signs the intent off-chain, cryptographically approving the swap parameters defined in the intent and authorizing resolvers to execute it according to the quoted conditions.

Execution

Once the user has signed an intent, the system notifies the winning resolver to start swap execution by depositing the maker's assets into an escrow contract on the source chain and then transferring the corresponding assets to the user. During execution, the user can query the Changelly DeFi Intent API to retrieve the swap status.