POST request to Tendermint yields empty string

I have a Tendermint 0.33.9-1baf670c running on my machine. I can contact it through GET, as follows:

curl --request GET localhost:26657/genesis

and I see the resulting JSON on the screen, correctly. However, the same call, in POST version, prints the empty string (and no error):

curl -H “Content-Type: application/json; utf-8” -H “Accept: application/json” --request POST --data ‘{“method”:“genesis”}’ localhost:26657

What am I doing wrong?


Please get in touch with the Core Devs on discord!

You need to send across an empty parameters array and an id.


curl -H "Content-Type: application/json; utf-8" -H "Accept: application/json" --request POST --data '{"method":"genesis", "params": [], "id": 1}' localhost:26657

Thank you David! This solved my issue.

1 Like