⚡ Titan Swap API

Простые и сверхэффективные свапы в сети TON. Начните всего за 30 минут.

Post swap messages

post

Creates messages to send swap on-chain using sendTransaction-like methods. Should be used in combination with the response object from /v1/quote.

Body
senderAddressstringOptional

Address of the user who is sending the transaction

destinationAddressstringOptional

Optional address to where the tokens should be sent to. This defaults to senderAddress

Responses
chevron-right
200

Messages to send on-chain for a swap

application/json
validUntilnumberRequired

Unix timestamp indicating when the validity of this data expires

post
/v1/swap-messages

Get swap quote

get

Get a quote to swap one token to another

Query parameters
inputMintstringRequired

The input mint address. Can be user friendly format, or raw.

outputMintstringRequired

The output mint address. Can be user friendly format, or raw.

amountstringRequired

The amount to swap. Must be in raw format.

maxSplitPathsnumberOptional

The maximum number of split paths. There can be up to this many simultaneous swaps in one transaction.

maxEdgeLengthnumberOptional

The maximum edge length. This is the maximum number of hops allowed.

slippageBpsstringOptional

Slippage allowed in basis points eg. 250 is 2.5% slippage

dexsstringOptional

DEXs that can be used to route the swap. Comma separated values eg DeDust,StonFi

minPoolLiquiditynumberOptional

Minimum liquidity in USD for each pool to be used in the swap

Responses
chevron-right
200

Quote for a swap

application/json
amountInstringRequired
expectedAmountOutstringRequired
minimumAmountOutstringRequired
inputMintstringRequired
outputMintstringRequired
get
/v1/quote

Get tokens

get

Get a list of all swappable tokens

Responses
chevron-right
200

Success

application/json
string[]Optional
get
/v1/tokens

Get DEXs

get

Get a list of all supported DEXs

Responses
chevron-right
200

Success

application/json
string[]Optional
get
/v1/dexs

Get token price

get

Get current token price in USD and TON

Query parameters
tokenstringRequired

A valid TON address for which to get the price

Responses
chevron-right
200

Prices for a token in TON and USD

application/json
priceUsdstringRequired

The price in USD, rounded to 5 significant digits

priceTonstringRequired

The price in TON, rounded to 5 significant digits

get
/v1/price

Get user's swap history

get

Retrieve the swap history for a specific user address, with pagination support

Path parameters
addressstringRequired

The user's wallet address

Query parameters
pageinteger · min: 1Optional

Page number for paginated results, starting at 1

Default: 1
Responses
chevron-right
200

An array of swap records for the given user

application/json
txHashstringOptional

The transaction hash of the swap

statusstringOptional

Status of the transaction, e.g., 'success'

senderAddressstringOptional

The address of the sender

destinationAddressstringOptional

The address of the destination

failureReasonstring · nullableOptional

The reason for transaction failure, if any

amountInRawstringOptional

The raw amount of the input token

amountOutRawstringOptional

The raw amount of the output token

poolSourcestringOptional

The liquidity pool source of the swap

createdAtstring · date-timeOptional

Unix timestamp of when the trade was created

completedAtstring · date-timeOptional

Unix timestamp of when the trade was completed

get
/v1/user/{address}/swaps

Get the quote for a specific transaction

get

Gets the original quote details for a transaction based on its unique hash

Path parameters
txHashstringRequired

The hash of the transaction you want the quote for

Responses
chevron-right
200

Quote for a swap

application/json
amountInstringRequired
expectedAmountOutstringRequired
minimumAmountOutstringRequired
inputMintstringRequired
outputMintstringRequired
get
/v1/transaction/{txHash}/quote