Author [EN] [ZH] [ES] [PT] [IT] [DE] [FR] [NL] [TR] [SR] [AR] [RU] [EN] [ZH] [ES] [PT] [IT] [DE] [FR] [NL] [TR] [SR] [AR] [RU] [EN] [ZH] [ES] [PT] [IT] [DE] [FR] [NL] [TR] [SR] [AR] [RU] Topic: How do we publish the price feed?  (Read 887 times)

0 Members and 1 Guest are viewing this topic.

Ggozzo

  • Guest
How do we publish the price feed?
« on: August 22, 2014, 02:09:19 PM »

I can't find anything explaining how to publish price feeds? Is there a how to somewhere?

I think I saw that we are not supposed to publish until Monday? I'd just like to know what we are supposed to do when the time comes.


Code: [Select]
blockchain_get_feeds_for_asset USD
Code: [Select]
wallet_publish_price_feed <delegate_account>  0.035645 USD
« Last Edit: August 25, 2014, 01:51:21 PM by bytemaster »

Ggozzo

  • Guest
Re: How do we publish the price feed?
« Reply #1 on: August 25, 2014, 12:05:41 AM »
Anyone?

Offline ripplexiaoshan

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 1955
    • View Profile
  • BTS: xiaoshan
Re: How do we publish the price feed?
« Reply #2 on: August 25, 2014, 12:10:26 AM »
using command in console
wallet_publish_price_feed
BTS ID:xiaoshan                   www.btsabc.org

Ggozzo

  • Guest
Re: How do we publish the price feed?
« Reply #3 on: August 25, 2014, 02:14:56 AM »
I was looking for more details than that. Do I just post an arbitrary number I come up with?

Offline maqifrnswa

  • Hero Member
  • *****
  • Posts: 661
    • View Profile
Re: How do we publish the price feed?
« Reply #4 on: August 25, 2014, 02:43:40 AM »
I was looking for more details than that. Do I just post an arbitrary number I come up with?

the point of a feed is to give the market a starting point from which people can buy/sell. You can use:
http://coinmarketcap.com/currencies/bitshares-x/#markets
as a guide. Someone has already posted a python script that checks and posts a new feed if the value changed by 5% since the last update.

as of this second, a valid feed could be
wallet_publish_price_feed <delegate_account>  0.035645 USD
maintains an Ubuntu PPA: https://launchpad.net/~showard314/+archive/ubuntu/bitshares [15% delegate] wallet_account_set_approval maqifrnswa true [50% delegate] wallet_account_set_approval delegate1.maqifrnswa true

Offline Gentso1

Re: How do we publish the price feed?
« Reply #5 on: August 25, 2014, 04:05:55 AM »
These feeds are just manually put in? There isn't a script that checks a reputable
currency exchange?

Offline Riverhead

Re: How do we publish the price feed?
« Reply #6 on: August 25, 2014, 04:16:38 AM »
These feeds are just manually put in? There isn't a script that checks a reputable
currency exchange?


It is the job of the delegates to find a reputable source. The idea here is the market doesn't "trust" a source. It trusts delegates. Once 51 delegates have submitted a a value the market can start (if it has sufficient depth).

Offline liondani

Re: How do we publish the price feed?
« Reply #7 on: August 25, 2014, 04:30:21 AM »
when we put a feed can we update it whenever we want manualy?

What if for a feed exist big difference in value from delegates?
« Last Edit: August 25, 2014, 04:32:59 AM by liondani »
  https://bitshares.OPENLEDGER.info/?r=GREECE  | You are in Control | BUY | SELL | SHORT | SWAP | LOAN | TRADE |  

Ggozzo

  • Guest
Re: How do we publish the price feed?
« Reply #8 on: August 25, 2014, 05:17:57 AM »
I was looking for more details than that. Do I just post an arbitrary number I come up with?

the point of a feed is to give the market a starting point from which people can buy/sell. You can use:
http://coinmarketcap.com/currencies/bitshares-x/#markets
as a guide. Someone has already posted a python script that checks and posts a new feed if the value changed by 5% since the last update.

as of this second, a valid feed could be
wallet_publish_price_feed <delegate_account>  0.035645 USD

Thanks,

Still confused about the validity of the feeds then. The price is extremely volatile right now and has moved near 100% in one day. A manually entered price feed could be obsolete within minutes of posting.

I found this from coinmarketcap.com :http://coinmarketcap-nexuist.rhcloud.com/api/btsx/price but I would have no idea how to implement it other than manually typing it into the console.

How would I implement the script? Is it something we can download and type in the console? Or does it have to be built in?

And is it made by I3 or Bitshares? In other words, is it safe?

drekrob

  • Guest
Re: How do we publish the price feed?
« Reply #9 on: August 25, 2014, 07:47:59 AM »
I think you would implement this by using a scripting language like python or nodejs that simply calls the api with a http get call every x minutes (using cron) and updates your client via rpc. With nodejs this would be something like this (untested coffescript):

Code: [Select]
rpc = require("node-json-rpc")
CronJob = require('cron').CronJob
http = require("http")
options = #place bitshares rpc settings here
  port: 5080
  host: "127.0.0.1"

client = new rpc.Client(options)

c = new CronJob "'00 30 * * * *'", -> #run this hourly
  http.get "http://coinmarketcap-nexuist.rhcloud.com/api/btsx/price", (price) ->
    client.call
      method: "wallet_publish_price_feed"
      params: [
        "yourdelegatename"
        price.usd
      ]
      id: 0
    , (err, res) ->
      throw err if err
c.start()
« Last Edit: August 25, 2014, 08:43:52 AM by drekrob »

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12060
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BTS: xeroc
  • GitHub: xeroc
Re: How do we publish the price feed?
« Reply #10 on: August 25, 2014, 08:07:08 AM »
AFAIK .. in the long run .. price feeds will be unecessary .. because then the price feed will be build from the 24h moving average ..

Our spaceship to moon just needs an initial ignition :)
Give BitShares a try! Use the http://testnet.bitshares.eu provided by http://bitshares.eu powered by ChainSquad GmbH

Offline svk

Re: How do we publish the price feed?
« Reply #11 on: August 25, 2014, 08:14:29 AM »
AFAIK .. in the long run .. price feeds will be unecessary .. because then the price feed will be build from the 24h moving average ..

Our spaceship to moon just needs an initial ignition :)
Think you're right yea. Also, publishing a price feed requires the standard transaction fee of 0.5 BTSX, so I wouldn't setup a script to update it all too often, although I suppose it's a good idea to stay updated in the beginning.
Worker: dev.bitsharesblocks

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12060
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BTS: xeroc
  • GitHub: xeroc
Re: How do we publish the price feed?
« Reply #12 on: August 25, 2014, 09:27:47 AM »
... at least for the first 24-hours :)

however .... conensus is reached over ALL 101 delegates .. I will not stay awake 24 hours just to watch this ;-)   (but I thought about it)
Give BitShares a try! Use the http://testnet.bitshares.eu provided by http://bitshares.eu powered by ChainSquad GmbH

Offline Riverhead

Re: How do we publish the price feed?
« Reply #13 on: August 25, 2014, 12:38:20 PM »
AFAIK .. in the long run .. price feeds will be unecessary .. because then the price feed will be build from the 24h moving average ..

Our spaceship to moon just needs an initial ignition :)
Think you're right yea. Also, publishing a price feed requires the standard transaction fee of 0.5 BTSX, so I wouldn't setup a script to update it all too often, although I suppose it's a good idea to stay updated in the beginning.


BM recommended about once a day until the market was boot strapped and then the feeds wouldn't be required.


I too am still a bit fuzzy on the mechanics but I think it can be just typed into the CLI daily. Since it's a temporary process to bootstrap the market I'm OK doing it by hand once a day. I've had harder jobs :D.

Offline svk

Re: How do we publish the price feed?
« Reply #14 on: August 25, 2014, 12:40:30 PM »
AFAIK .. in the long run .. price feeds will be unecessary .. because then the price feed will be build from the 24h moving average ..

Our spaceship to moon just needs an initial ignition :)
Think you're right yea. Also, publishing a price feed requires the standard transaction fee of 0.5 BTSX, so I wouldn't setup a script to update it all too often, although I suppose it's a good idea to stay updated in the beginning.


BM recommended about once a day until the market was boot strapped and then the feeds wouldn't be required.


I too am still a bit fuzzy on the mechanics but I think it can be just typed into the CLI daily. Since it's a temporary process to bootstrap the market I'm OK doing it by hand once a day. I've had harder jobs :D.

Sounds good to me. I already published mine this morning, but it seems like I'm the only one so far. You can check it using:

Code: [Select]
blockchain_get_feeds_for_asset USD
Worker: dev.bitsharesblocks

 

Google+