What's the purpose to have Options -r in cleos?

in version v1.1.3, there is a -r or --header:

pass specific HTTP header, repeat this option to pass multiple headers

Is there any example to demonstrate how header works?

1 Answer 1


An explanation is provided in the pull request:

In some scenarios, 'nodeos' runs remotely from where 'cleos' locates, that implies the communication between the two parties should go across the network. So a new option '-r,--header' is proposed in this PR to allow user to customized the HTTP request headers sent by 'cleos' in case that some 'middle' devices may require for specific headers to contain some 'token'.

And also, if 'nodeos' is set up to provide HTTPS APIs, say by placing a reverse proxy in front, in many cases, especially for some testing environments, there might not be domains assigned with the 'nodeos' - so 'cleos' needs a way to 'tolerate' with the invalid certificates. To address this, a new option '-n,--no-verify' is proposed in this PR too, to disable the peer verification for current secure connection.

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.