LogoLogo
  • Introduction to Unizen
    • Unizen Overview
      • Unizen Liquidity Distribution Mechanism (ULDM)
        • ULDM Performance
      • Unizen Interoperability Protocol (UIP)
        • LayerZero
        • DeBridge
        • Stargate
        • Celer
        • Axelar
        • Thorchain
    • Unizen Dashboard
      • General
      • Portfolio
      • History
    • Unizen Trade
      • Fees
    • Unizen Explore
      • Unizen Omni-Chain Data Pool
    • Unizen Earn
  • ZCX
    • Token Utility
    • Tokenomics
  • API - Introduction
    • Introduction
    • Before you get started
      • Understanding Price Impact and Price Slippage in Token Swaps
      • Token Allowance Management for Non-updatable Allowance Tokens
      • Tokens with taxes
      • Wrapping and Unwrapping Native Tokens
      • Quote expiration deadline
    • Security Best Practices for Integrating Unizen
      • Why disable CORS
      • How to integrate with a reverse proxy
    • Version 2 of our smart contracts
      • Migration to smart contract v2
  • API - GET STARTED
    • QuickStart guide
    • Swagger
    • Information endpoints
      • GET /trade/v1/info/chains
      • GET /trade/v1/info/sources
      • GET/v1/info/cross-providers
      • GET /trade/v1/info/token/search
      • GET /v1/info/token/popular
      • GET /trade/v1/info/token/{chainId}/{tokenAddress}
      • GET /trade/v1/info/tokenLogo/{chainId}/{tokenAddress}
      • GET /info/thorchain-inbound-address
      • GET /trade/v1/info/tx/{txHash}
      • GET /trade/v1/info/trade/{chainId}/{txHash}
      • GET /trade/v1/info/trades
    • Approval
      • GET /trade/v1/{chainId}/approval/spender
      • GET /trade/v1/{chainId}/approval/transaction
      • GET /trade/v1/{chainId}/approval/allowance
    • Single-Chain Swap
      • GET /trade/v1/{chainId}/quote/single
      • GET /trade/v1/{chainId}/swap/single
      • Send transaction in evm chains
      • Send transaction in Solana
    • Cross-Chain Swap
      • GET /trade/v1/{chainId}/quote/cross
      • GET /trade/v1/{chainId}/swap/cross
      • Send transaction
    • Gasless orders
      • POST /trade/v1/gasless/typed-data
      • POST /v1/gasless/estimate
      • POST /v1/gasless/create
      • POST /v1/gasless/cancel
      • GET /trade/v1/gasless/status/{orderId}
      • GET /v1/gasless/orderByAddress/{address}
    • UTXO Assets and Cosmos Swap
      • GET /trade/v1/{chainId}/quote/cross 1
      • GET /trade/v1/{chainId}/swap/cross
      • Sending transactions
    • Efficient Quote Retrieval with Batch Processing
      • GET /trade/v1/{chainId}/batch_quote/single
    • Error Messages
  • GASLESS TRADES
    • Obtaining gasless quotes
    • Gas estimation
    • Executing the trade
    • Following the orders
  • On-Chain Contracts - Get Started
    • Integration with Unizen Contracts for Token Swapping
    • Registering Errors on Smart Contract Calls
  • PERMIT2
    • What is Permit2?
    • Usage in our api
  • WIDGET - Get Started
    • Embed the Unizen Widget
    • Playground
  • Other
    • Smart Contracts
    • Security Audits
    • Roadmap
  • links
    • Unizen
    • Marketing Website
    • Medium
    • Twitter
    • Discord
    • Telegram
Powered by GitBook
On this page

Was this helpful?

  1. API - Introduction

Version 2 of our smart contracts

We are excited to introduce Version 2 of our smart contract, bringing significant enhancements to improve security, efficiency, and user experience.

What’s New in Version 2?

  • Gasless Trades – Users can now execute trades without needing to pay gas fees in the native token. This eliminates the requirement to hold native tokens for transactions, improving accessibility and user profitability.

  • Permit2 Integration – This version implements Permit2, a more secure and cost-efficient alternative to the traditional allowance system, reducing approval costs and enhancing security.

  • Unified approval address and executor – In Version 2, approvals are now simplified with a single address—the Unizen Router.

    • No more handling approvals across multiple smart contracts (v1, v2, v3).

    • Users only need to approve the Unizen Router once, streamlining the trading experience.

    • This reduces complexity for integrators and improves efficiency for end users.

    With this update, managing approvals is easier, faster, and more consistent across all trades.

  • Optimized Gas Usage – Internal improvements have reduced overall gas costs, making transactions more efficient.

  • Enhanced Fee Flexibility – Version 2 provides better handling of integrator fees, allowing for more customization and adaptability.

  • New chains - you will be able to swap on newly added chains like Unichain and Berachain.

Migration & Adoption

We strongly recommend using Version 2 of the smart contract:

  • New Integrators: If you are integrating for the first time, you should use Version 2 from the start.

  • Existing Integrators: If you are currently using the previous version, we highly encourage you to migrate to Version 2. The migration process is straightforward and will allow you to take full advantage of the new features.

By upgrading, you ensure better efficiency, lower costs, and improved user experience for your platform.

PreviousHow to integrate with a reverse proxyNextMigration to smart contract v2

Last updated 2 months ago

Was this helpful?