I am building an dApp and want to integrate 0x in the smart contract directly instead of me depending on the http request and passing that. Is there a way to implement 0x directly from the smart contract.
1 Answer
the official documentation of the 0x protocol gives you an example how to do that: https://docs.0x.org/0x-api-swap/guides/use-0x-api-liquidity-in-your-smart-contracts
And also an example of simple SmartContract implementing these tokens swap: https://github.com/0xProject/0x-api-starter-guide-code/blob/master/contracts/SimpleTokenSwap.sol