API Documentation Terra Classic

The TFM DEX aggregator API can be found under the following URL:
The API consists of the following endpoints:

/route

Parameter name
Type
Description
token0
string
Contract address of the token to sell, e.g. uusd
token1
string
Contract address of the token to buy, e.g. uluna
amount
integer
Amount of the token to sell, set in minimal divisible units, e.g. 1.00 UST set as 1000000, and 13.45 Luna set as 13450000
exchange
string
Optional parameter to limit the search of the best route within a given exchange. For example, input of "astroport" will only search on Astroport, while "astroport, terraswap" will search on both Astroport and Terraswap. The default setting is to search on all the DEX's if no value is passed.

List of available exchanges:

astroport
terraswap
loopmarket
terraformer
terrafloki