OasisDex
OasisDEX connector triggers the methods like buy and sell tokens You can view details like source code, ABIs on Etherscan.
Use
0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
to indicate ETH.Slippage amount is in percentage. For example, use
2 * 10 ** 16
to denote 2%.If not sure about the arguments
getId
andsetId
, pass 0.
Buy
Buy tokens
Parameter | Type | Description |
buy_token | address | The token address to buy. |
sell_token | address | The token address to sell. |
buy_amt | number | The amount of tokens to buy. |
unit_amt | number | sell token amt per buy token |
getId | number | ID fetches the amount of token to deposit. |
setId | number | ID stores the amount of token deposited. |
Sell
Sell tokens
Parameter | Type | Description |
buy_token | address | The token address to buy. |
sell_token | address | The token address to sell. |
sell_amt | number | The amount of tokens to sell. |
unit_amt | number | buy token amt per sell token |
getId | number | ID fetches the amount of token to deposit. |
setId | number | ID stores the amount of token deposited. |
Last updated