2

I have built a simple erc-20 token. I used the code given on ethereum.org code as a reference. There they have talked about setting the price of my token. But how do I set it dynamically, as in automatically change the buy and sell price based on market ? Where do I get this price from ? Ethereum.org has said something about data feeds, what is that ? and How do you use it ?

  • Usually the price is determined by the market's demand and offer. You can study Bancor algorithms how they works as a reserve to control the price. – Ismael Feb 19 '18 at 1:07
  • Ok. But what I was talking about is, how do i call the functions in my contract to set the prices when market price changes ? – sushantmit Feb 25 '18 at 7:23
  • You can add a function setPrice to your contract but without more details of your contract is hard to say if that is useful. – Ismael Feb 25 '18 at 16:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.