2

anyone knows a command to list the current schedule for the active BPs? thank you

2 Answers 2

3

This can be done in 2 steps:

1. Find the latest block

This can be done using the get_info() end-point. Example:

$ curl http://publicapi-mainnet.eosauthority.com/v1/chain/get_info

and save head_block_id (e.g. 0064aed8bf489f860ea6897f36fcd0ca3d60c0364479afc6259e7262d7bd200b)

2. Check the header of the latest block

    curl --request POST \
         --url http://publicapi-mainnet.eosauthority.com/v1/chain/get_block_header_state \  
         --data '{"block_num_or_id":"0064aed8bf489f860ea6897f36fcd0ca3d60c0364479afc6259e7262d7bd200b"}'

and look for the active_schedule key. It should look something like this:

>>> response['active_schedule']
{'version': 162, 'producers': [{'producer_name': 'argentinaeos', 'block_signing_key': 'EOS7jq4FHrFrtCXxpRQ39dBeDMa5AjM4VaRbqBECkSa5aZnizJzrx'}, {'producer_name': 'bitfinexeos1', 'block_signing_key': 'EOS6sgKjHUFtY1XxxQaMDwfxBac6nDBibVzZHb8LFMVmvSjcCdDhE'}, {'producer_name': 'cypherglasss', 'block_signing_key': 'EOS5rTrUiqvgu7YCVyKCeQ1QXA7Uo94FZhq7zKcNPqbrCP5u5fQXo'}, {'producer_name': 'eos42freedom', 'block_signing_key': 'EOS4tw7vH62TcV
tMgm2tjXzn9hTuHEBbGPUK2eos42ssY7ip4LTzu'}, ...
1
  • second url should be curl --request POST --url publicapi-mainnet.eosauthority.com/v1/chain/… --data '{"block_num_or_id":"0082587fb060f5f10f270065e8b3a29932819f4f8819f03085899f296d8bfe07"}' the one from the provided answer is missing "v1/chain" other than that it is a perfect answer
    – ovi
    Commented Jul 30, 2018 at 11:14
1

You can try this :

cleos get schedule

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.