bitcoin: rpc: doc: RPCHelpMan missing request parameters for getblocktemplate

Motivation

The getblocktemplate help currently shows these available request parameters (as part of the template_request object):

$ ./bitcoin-cli help getblocktemplate
$ ./bitcoin-cli help getblocktemplate

...

Arguments:
1. template_request         (json object, optional, default={}) Format of the template
     {
       "mode": "str",       (string, optional) This must be set to "template", "proposal" (see BIP 23), or omitted
       "capabilities": [    (json array, optional) A list of strings
         "str",             (string) client side supported feature, 'longpoll', 'coinbasevalue', 'proposal', 'serverlist', 'workid'
         ...
       ],
       "rules": [           (json array, required) A list of strings
         "segwit",          (string, required) (literal) indicates client side segwit support
         "str",             (string) other client side supported softfork deployment
         ...
       ],
     }
...

It seems two (optional) parameters are missing: longpollid and data.

Possible solution

Seems like a good first issue to me:

  1. Understand what both parameters do, their type etc.
  2. Add two entries to the template_request object, with a helpful concise description, and consider their optional status
  3. Verify output is correct by calling ./bitcoin-cli help getblocktemplate

Useful Skills

No response

Guidance for new contributors

Want to work on this issue?

For guidance on contributing, please read CONTRIBUTING.md before opening your pull request.

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Comments: 15 (13 by maintainers)

Commits related to this issue

Most upvoted comments

hey i am a newbie can anyone guide me what to do next to become a first contributor (this is my first project)

Hi @iemafzalhassan (and other future contributors), I suggest the articles section of https://jonatack.github.io.

hey i am a newbie can anyone guide me what to do next to become a first contributor (this is my first project)

Hi @iemafzalhassan (and other future contributors), I suggest the articles section of https://jonatack.github.io.

Thanks a lot for this @jonatack!

hey i am a newbie can anyone guide me what to do next to become a first contributor (this is my first project)

Hi @iemafzalhassan (and other future contributors), I suggest the articles section of https://jonatack.github.io.

Thnkew so much 🤩🥳

Yeah the approach is good. Great, have a look and then for further implementation feedback I’d suggest you open a PR with the code changes (definitely worth going through CONTRIBUTING.md first).

Update: I downloaded and installed Bitcoin Core, which then helped me to run bitcoind and bitcoin-cli. I’ll try to make the changes to a new branch 😄

Absolutely, just open the PR whenever you feel ready, or ask away here if you have any problems you can’t figure out.