expand.network
  • Overview
  • Getting Started
  • 🔑How do I get my API Key?
  • 📑List of All Endpoints
  • ⚙️SDK
    • Overview
    • Getting Started
  • ⛓️INTEGRATIONS
    • ⚡Blockchains
      • EVM based blockchains
        • Ethereum
        • Binance Smart Chain
        • Avalanche - C
        • Avalanche - P
        • Avalanche - X
        • Polygon
        • Cronos
        • Arbitrum
        • Fantom
        • Optimism
        • Base
        • zkSync Era
        • Mantle
      • Non-EVM based chains
        • Tron
        • Solana
        • Near
        • Algorand
        • Aptos
        • Sui
        • Starknet
        • TON
        • Cosmos Hub
        • Osmosis
        • Stacks
        • Bitcoin
        • Stellar
          • Stellar RWA
        • XRP Ledger
          • XRP Ledger RWA
    • ⚡Bridges
      • Stargate
      • Stargate V2
      • Squid Router
      • Squid Router V2
      • Allbridge Classic
      • Allbridge Core
    • ⚡DEX & DEX Aggregators
      • Uniswap V2
      • Uniswap V3
      • Uniswap X
      • Sushiswap V2
      • PancakeSwap V2
      • PancakeSwap V3
      • Aerodrome
      • Camelot V3
      • Curve V2
      • Balancer V2
      • STON.fi
      • Trader Joe
      • Orca
      • Raydium
      • SDEX
      • Cetus
      • REF Finance
      • Liquidswap
      • Sologenic
      • Alex
      • 0x (Aggregator)
      • 1inch (Aggregator)
      • Kyberswap (Aggregator)
        • Kyberswap ( Limit Order Endpoints )
      • Jupiter (Aggregator)
    • ⚡Derivatives
      • dYdX V4
    • ⚡Fungible Tokens
      • ERC20
      • WETH
    • ⚡Lending Protocols
      • Aave V2
      • Aave V3
      • Compound V2
      • Compound V3
      • Morpho
    • ⚡Yield Aggregators
      • Yearn Finance V2
      • Harvest Finance
      • Pendle
    • ⚡Liquid Staking
      • Chorus One
      • Lido V2
      • Stader
      • Benqi
      • Jito
      • EigenLayer
    • ⚡Non Fungible Tokens
      • ERC721
      • ERC1155
      • Metaplex
    • ⚡Oracles
      • ChainLink
      • WinkLink
      • Pyth Network
      • RedStone
    • ⚡Stablecoins
      • EVM
    • ⚡Synthetics
      • Synthetix
    • ⚡Supported Wallets
      • MPC Wallets
        • DFNS
        • FORDEFI
        • FIREBLOCKS
        • CIRCLE
      • HD Wallets
        • PHANTOM
        • COINBASE
        • TON Wallet
      • Wallet Connect v2
  • How To
    • Execute a Local Swap
    • Execute a Cross Chain Swap
    • Use Limit Orders
    • Lend and Borrow
    • Provision Liquidity
      • Adding Liquidity
      • Removing liquidity
    • Yield Farm
    • Use Our Transaction Decoder
    • Submit an RFQ
    • Subscribe to Events
    • Stream Data (WebSocket)
      • Stream Transaction
      • Stream Trade
      • Stream Gas
      • Stream Ticker Price
    • Source Pricing
    • Track Memecoins
    • Manage Token Approvals
  • Use Cases
    • Trade Reconciliation
    • Portfolio Management
    • Trading Features
    • On-Chain Data: DEX Liquidity Pool Forensics
    • Transaction and Pool Analysis
  • Account Abstraction
    • Overview
      • User Endpoints
      • Paymaster Endpoint
      • Bundler Endpoint
    • ⚙️SDK - Overview
  • Additional Info
    • Error Messages
    • Client-Side Security Essentials
    • Compute Unit Costs
    • API Metadata
    • Audit Certificate
    • Brand Assets
    • FAQs
    • Quicknode Marketplace
      • DEX
      • Lending Protocols
  • ID's
    • Chain IDs
    • Bridge IDs
      • Internal Chain IDs for Bridges
    • DEX IDs
    • Lending Protocol IDs
    • Yield Aggregator ID
    • Liquid Staking IDs
    • Oracle IDs
    • Stablecoin IDs
    • Derivatives IDs
    • Synthetics IDs
  • Mapping
    • Blockchains
    • DEXs
      • Uniswap V2
      • Uniswap V3
      • Sushiswap
      • PancakeSwap
      • Curve
      • Balancer
    • Lending Protocols
      • Aave
      • Compound
  • Protocol Spender
    • Spender list
Powered by GitBook
On this page
  • Supported Chains
  • Available Endpoints:
  • DEX IDs
  • Endpoint Details
  • /getprice
  • /getuserliquidity
  • /getpoolliquidity
  • /gettokenliquidity
  • /swap
  • /addliquidity
  • /removeliquidity
  1. INTEGRATIONS
  2. DEX & DEX Aggregators

Liquidswap

PreviousREF FinanceNextSologenic

Last updated 4 months ago

Supported Chains

Available on Aptos Mainnet

Available Endpoints:

Click on the endpoint to jump to the section with full details

  • GET - Returns the swap quotation for a given token pair on Liquidswap.

  • GET - Returns the balance of a particular token pair of accounts.

  • GET - Returns the total liquidity for a specified pool.

  • GET - Returns the individual token liquidity within the specified liquidity pool.

  • POST - Initiate a swap transaction on a specified DEX.

  • POST - Add liquidity to a specified pool in a specified DEX.

  • POST - Remove liquidity from a specified pool for a specified DEX.

DEX IDs

Many endpoints have a parameter where you can provide a DEX ID.

Below is a list of DEX IDs related to Liquidswap. For a complete list and more information, please see the page.

DEX Name
Chain
DEX ID

Liquidswap

Aptos Mainnet

3200

Endpoint Details

/getprice

Returns the swap quotation for a given token pair.

GET https://api.expand.network/dex/getprice

Query Parameter

Name
Type
Description

rpc

String

Remote procedural call URL.

dexId*

String

amountIn*

String

Amount of token.

path*

String

Comma separated values of token addresses whose price is to be fetched.

https://api.expand.network/dex/getprice?dexId=3200&path=0x1::aptos_coin::AptosCoin,0xf22bede237a07e121b56d91a491eb7bcdfd1f5907926a9e58338f964a01b17fa::asset::USDC&amountIn=10000000
{
    "status": 200,
    "msg": "success",
    "data": {
        "amountIn": "10000000",
        "path": [
            "0x1::aptos_coin::AptosCoin",
            "0xf22bede237a07e121b56d91a491eb7bcdfd1f5907926a9e58338f964a01b17fa::asset::USDC"
        ],
        "amountsOut": [
            "10000000",
            "864252"
        ]
    }
}

/getuserliquidity

Returns the balance of a particular token pair of an account.

GET https://api.expand.network/dex/getuserliquidity

Query Parameter

Name
Type
Description

rpc

String

Remote procedural call URL.

dexId*

String

address*

String

Public address of liquidity provider.

poolAddress*

String

Pool address whose liquidity is to be fetched.

https://api.expand.network/dex/getuserliquidity?dexId=3200&poolAddress=0x61d2c22a6cb7831bee0f48363b0eec92369357aece0d1142062f7d5d85c7bef8::lp_coin::LP<0x1::aptos_coin::AptosCoin, 0x111ae3e5bc816a5e63c2da97d0aa3886519e0cd5e4b046659fa35796bd11542a::stapt_token::StakedApt, 0x163df34fccbf003ce219d3f1d9e70d140b60622cb9dd47599c25fb2f797ba6e::curves::Uncorrelated>&address=0x485300d3fc4fb6b0bcf4431556b13a2e55eec71cbbb33a770aad8958d63c13fd
{
    "status": 200,
    "msg": "success",
    "data": {
        "pairAddress": "0x61d2c22a6cb7831bee0f48363b0eec92369357aece0d1142062f7d5d85c7bef8::lp_coin::LP<0x1::aptos_coin::AptosCoin, 0x111ae3e5bc816a5e63c2da97d0aa3886519e0cd5e4b046659fa35796bd11542a::stapt_token::StakedApt, 0x163df34fccbf003ce219d3f1d9e70d140b60622cb9dd47599c25fb2f797ba6e::curves::Uncorrelated>",
        "liquidity": "25368400",
        "tokenA": "29931130",
        "tokenB": "27129313"
    }
}

/getpoolliquidity

Returns the total liquidity for a specified pool.

GET https://api.expand.network/dex/getpoolliquidity

Query Parameter

Name
Type
Description

rpc

String

Remote procedural call URL.

dexId*

String

poolAddress*

String

Pool address whose liquidity is to be fetched.

https://api.expand.network/dex/getpoolliquidity?dexId=3200&poolAddress=0x61d2c22a6cb7831bee0f48363b0eec92369357aece0d1142062f7d5d85c7bef8::lp_coin::LP<0xf22bede237a07e121b56d91a491eb7bcdfd1f5907926a9e58338f964a01b17fa::asset::USDT,0x9770fa9c725cbd97eb50b2be5f7416efdfd1f1554beb0750d4dae4c64e860da3::fa_to_coin_wrapper::WrappedUSDT,0x163df34fccbf003ce219d3f1d9e70d140b60622cb9dd47599c25fb2f797ba6e::curves::Stable>
{
    "status": 200,
    "msg": "success",
    "data": {
        "totalLiquidity": "586808351357"
    }
}

/gettokenliquidity

Returns the individual token liquidity within the specified liquidity pool.

GET https://api.expand.network/dex/gettokenliquidity

Query Parameter

Name
Type
Description

rpc

String

Remote procedural call URL.

dexId*

String

poolAddress*

String

Pool address whose liquidity is to be fetched.

https://api.expand.network/dex/gettokenliquidity?dexId=3200&poolAddress=0x61d2c22a6cb7831bee0f48363b0eec92369357aece0d1142062f7d5d85c7bef8::lp_coin::LP<0x1::aptos_coin::AptosCoin, 0xf8fa55ff4265fa9586f74d00da4858b8a0d2320bbe94cb0e91bf3a40773eb60::GREATDANE::GREATDANE, 0x163df34fccbf003ce219d3f1d9e70d140b60622cb9dd47599c25fb2f797ba6e::curves::Uncorrelated>
{
    "status": 200,
    "msg": "success",
    "data": {
        "APT": "6649459",
        "GREATDANE": "60847704895806"
    }
}

/swap

Initiate a swap transaction on a specified DEX.

POST https://api.expand.network/dex/swap

Request Body

Name
Type
Description

rpc

String

Remote procedural call URL.

dexId*

String

path*

String

Comma separated values of token addresses.

amountIn*

String

Amount of token to be swapped.

gas*

String

Maximum gas limit provided by the sender, for the transaction.

from*

String

Address of the sender of the token.

slippage

String

Percentage of total swap value. By default, 1.

0 <= slippage value <= 10

{
    "amountIn": "100000",
    "from": "0xa182b65f4bf10be7ef870496893c170af3079a2540c63b470445417fcfb21c5b",
    "path": [
        "0x1::aptos_coin::AptosCoin",
        "0xf22bede237a07e121b56d91a491eb7bcdfd1f5907926a9e58338f964a01b17fa::asset::USDC"
    ],
    "slippage": "99",
    "dexId": "3200",
    "gas": "10000"
}
{
    "status": 200,
    "msg": "success",
    "data": {
        "chainId": "1400",
        "from": "0xa182b65f4bf10be7ef870496893c170af3079a2540c63b470445417fcfb21c5b",
        "to": "0x61d2c22a6cb7831bee0f48363b0eec92369357aece0d1142062f7d5d85c7bef8",
        "data": "oYK2X0vxC+fvhwSWiTwXCvMHmiVAxjtHBEVBf8+yHFsOAAAAAAAAAAIBY980/MvwA84hnT8dnnDRQLYGIsud1HWZwl+y95e6bgdzY3JpcHRzBHN3YXADBwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABCmFwdG9zX2NvaW4JQXB0b3NDb2luAAfyK+3iN6B+EhtW2RpJHre839H1kHkmqeWDOPlkoBsX+gVhc3NldARVU0RDAAcBY980/MvwA84hnT8dnnDRQLYGIsud1HWZwl+y95e6bgZjdXJ2ZXMMVW5jb3JyZWxhdGVkAAIIoIYBAAAAAAAIXAAAAAAAAAAQJwAAAAAAAGQAAAAAAAAAqWRpZwAAAAAB",
        "referenceId": "c20cdb1e18534d62bc8188b3381b0354"
    }
}

/addliquidity

Add liquidity to a specified pool in a specified DEX.

POST https://api.expand.network/dex/addliquidity

Request Body

Name
Type
Description

rpc

String

Remote procedural call URL.

dexId*

String

path*

String

Comma separated values of token addresses.

amountIn*

String

Amount of token0 and token1 to be added.

slippage

String

Percentage of total swap value. By default, 1.

0 <= slippage value <= 10

from*

String

Address of the sender of the token.

gas*

String

Maximum gas limit provided by the sender, for the transaction.

curveType

String

Type of curve for pool pair. stable/uncorrelated. By Default, stable

{
    "amountIn": ["733700","529428"],
    "from": "0xa182b65f4bf10be7ef870496893c170af3079a2540c63b470445417fcfb21c5b",
    "path": [
        "0x1::aptos_coin::AptosCoin",
        "0x53a30a6e5936c0a4c5140daed34de39d17ca7fcae08f947c02e979cef98a3719::coin::LSD"
    ],
    "slippage": "50",
    "dexId": "3200",
    "gas":"10000"
}
{
    "status": 200,
    "msg": "success",
    "data": {
        "chainId": "1400",
        "from": "0xa182b65f4bf10be7ef870496893c170af3079a2540c63b470445417fcfb21c5b",
        "to": "0x61d2c22a6cb7831bee0f48363b0eec92369357aece0d1142062f7d5d85c7bef8",
        "data": "oYK2X0vxC+fvhwSWiTwXCvMHmiVAxjtHBEVBf8+yHFsOAAAAAAAAAAIBY980/MvwA84hnT8dnnDRQLYGIsud1HWZwl+y95e6bgdzY3JpcHRzDWFkZF9saXF1aWRpdHkDB1OjCm5ZNsCkxRQNrtNN450Xyn/K4I+UfALpec75ijcZBGNvaW4DTFNEAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQphcHRvc19jb2luCUFwdG9zQ29pbgAHAWPfNPzL8APOIZ0/HZ5w0UC2BiLLndR1mcJfsveXum4GY3VydmVzBlN0YWJsZQAECBQUCAAAAAAACAoKBAAAAAAACAQyCwAAAAAACAKZBQAAAAAAECcAAAAAAABkAAAAAAAAAMlkaWcAAAAAAQ==",
        "referenceId": "4125a4481a984782b9077efd85275e83"
    }
}

/removeliquidity

Remove liquidity from a specified pool for a specified DEX.

POST https://api.expand.network/dex/removeliquidity

Request Body

Name
Type
Description

rpc

String

Remote procedural call URL.

dexId*

String

path*

String

Comma separated values of token addresses.

slippage

String

Percentage of total swap value. By default, 1.

0 <= slippage value <= 10

from*

String

Address of the sender of the token.

liquidity*

String

The liquidity to be removed.

gas*

String

Maximum gas limit provided by the sender, for the transaction.

curveType

String

Type of curve for pool pair. stable/uncorrelated. By Default, stable

{
    "liquidity": "10000",
    "from": "0xa182b65f4bf10be7ef870496893c170af3079a2540c63b470445417fcfb21c5b",
    "path": [
        "0x1::aptos_coin::AptosCoin",
        "0x53a30a6e5936c0a4c5140daed34de39d17ca7fcae08f947c02e979cef98a3719::coin::LSD"
    ],
    "slippage": "50",
    "dexId": "3200",
    "curveType": "uncorrelated",
    "gas":"10000"
}
{
    "status": 200,
    "msg": "success",
    "data": {
        "chainId": "1400",
        "from": "0xa182b65f4bf10be7ef870496893c170af3079a2540c63b470445417fcfb21c5b",
        "to": "0x61d2c22a6cb7831bee0f48363b0eec92369357aece0d1142062f7d5d85c7bef8",
        "data": "oYK2X0vxC+fvhwSWiTwXCvMHmiVAxjtHBEVBf8+yHFsOAAAAAAAAAAIBY980/MvwA84hnT8dnnDRQLYGIsud1HWZwl+y95e6bgdzY3JpcHRzEHJlbW92ZV9saXF1aWRpdHkDB1OjCm5ZNsCkxRQNrtNN450Xyn/K4I+UfALpec75ijcZBGNvaW4DTFNEAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQphcHRvc19jb2luCUFwdG9zQ29pbgAHAWPfNPzL8APOIZ0/HZ5w0UC2BiLLndR1mcJfsveXum4GY3VydmVzDFVuY29ycmVsYXRlZAADCBAnAAAAAAAACJZBAAAAAAAACDAJAAAAAAAAECcAAAAAAABkAAAAAAAAAA5laWcAAAAAAQ==",
        "referenceId": "4f3ac95b6cb54eeea6fb74573def0a57"
    }
}

Refer to the page for details.

Refer to the page for details.

Refer to the page for details.

Refer to the page for details.

Refer to the page for details.

Refer to the page for details.

Refer to the page for details.

⛓️
⚡
DEX ID
/getprice
/getuserliquidity
/getpoolliquidity
/gettokenliquidity
/swap
/
addliquidity
/
removeliquidity
DEX ID
DEX ID
DEX ID
DEX ID
DEX ID
DEX ID
DEX ID