Interacting with the HIVE blockchain API using Postman
These days I've been playing around with the API of the Hive blockchain in order to retrieve different data available and maybe find some new use cases. As I am a QA-Testing Software Engineer I've tried to interact with the API by using the tools that I am most accustomed to and one of them is Postman. I've looked up in the documentation related to the JSON RPC API from the Hive Developer Portal and found some samples about the available endpoints and how to send data to them. For example, get_account_reputations can be invoked using curl with the following command: curl -s --data '{"jsonrpc":"2.0", "method":"condenser_api.get_accounts", "params":[["hiveio"]], "id":1}' https://api.hive.blog.
With the given sample, I've moved to Postman, and added the api.hive.blog endpoint and gave it a try. But unexpectedly I got back a "Parse error" and I kinda was stuck at this point. I've tried different ways to POST data to the API, and changed parameters, but I had the same results. When I had no more ideas I went to the Hive Developers Discord server and posted a question about the issue that I was facing. And fast and luckily enough I was guided to what the problem might be and what I needed to do to solve this: instead of having the Body parameters set as "x-www-form-urlencoded" (which is the Default) to have it as raw.
And magically it worked and I could POST data on the HIVE API using Postman. I've written this post as even if I searched for a solution to it by targeting hive.blog content, I could find the solution for it. Hopefully, this will help somebody else.
Leave Interacting with the HIVE blockchain API using Postman to:
Read more #hivedevs posts
Best Posts From behiver
We have not curated any of behiver's posts yet. But you can encourage our curation team to review posts by visiting them regularly and by referring other readers. Because we give priority to frequently read content.
More Posts From behiver
- The work week is here, but I have no desire for it
- Hive engagement - We shouldn't overlook the power of commenting
- Behind the scenes of building HivePulse
- In our team it is forbidden to use AI
- Are crypto and stocks becoming one market?
- Hive Power is a long term investment on the Hive blockchain
- Hive blockchain - KE should include HIVE and HBD holdings altogether
- New Hive blockchain communities created in the past three months
- My view and experiences of work life invading the personal life
- HivePulse.app - Improving Goals functionality after community feedback