In this project, there exist two solidity file. "main.sol" is the option oracle contract, with the token address. "SeikaToken.sol" is the token contract, with erc-20.
For owner to transfer the contract control permission. The owner can only set the oracle address, which is the option data provider.
Change the data provider's address.
Check the address's SKT allowance to oracle contract
- coin: the coin's option you want to get.
- date: the option execute date.
- price: the option execute price.
- buytype: Option for buy call or buy put Before you call this function, you need to give the contract address at least 10 SKT allowances, after success calling, you will get a number, which is jobId, is the number that we get your result.
Only for oracle, is the function that you can provide the option data.
With the number you get from getOptionPrice, you can get the result once it is finish.