As I have also been frustrated with the direction Postman has taken, I have a great alternative to suggest, if the only thing you want to do is fire requests on demand easily and do not need automated testing.
Can it do substitution with some sort of application-based KV store? The main reason I used a rest client like Insomnia is so that I can reference secrets like {{ client_secret }} or {{ api_key }} and have a change to the value in the KV store reflect for every request.
"We support two types of variables, one is Custom Variables which is defined by user and can be further divided into Environment Variables, File Variables and Request Variables, the other is System Variables which is a predefined set of variables out-of-box."
However, what I can't figure out is if it supports programmatic variable setting. I have an API where I need to retrieve a token from an endpoint before using it for every other endpoint, and I'm using Postman's test scripts to set that token as an environment variable before sending all the other requests so they can all use it. I don't see a way to replicate that with this extension.
Hi, one of the maintainer of Hurl [1].
It is effectively basically just curl (we're using libcurl under the hood). I would say that we have added the ability to chain request (you could use curl in a shell script), and a bunch of assert (like jsonpath, xpath etc...) on response (which you could arguably do also with shell script).
We also wanted something text based, that could easily be integrated in a CI [2] for instance. We are using Hurl to test our web application (~2M unique visitors/month).
Very happy with it currently, but there are really a lot of very good tools in this space (as we can see in these comments).
I too like this approach, because the format is simple and text-based and you can maintain it in your git repository.
My main gripe with Postman and Insomnia isn't actually the web based UI, but the lock-in. You can't access the files that they store their data in easily. Postman especially tries to push people towards getting their per-seat 'cloud' subscription if you want to share sets of HTTP requests.
But using this text-based REST client, you don't have this file lock-in.
For IntelliJ this feature is actually built in, I believe it uses the same syntax.
Shameless plug: There's also Prestige at https://prestigemad.com, which is very similar but works right in the browser. You can save your files as Gists as well. Templating with variables is also supported with `${}` syntax, like Javascript's template strings.
But gRPC support is not built yet. It's on the roadmap.
Sounds a lot easier than curl tbh. No need to deal with shell scripts and their insane quoting, plus you get the response straight in your editor with syntax highlighting.
Maybe it’s just me but I’ve never had those issues. Another benefit of curl is that you have an easily searchable history of every command you’ve run. So you can easily find old invocations and rerun them.
How complicated are your requests? If I need to test a POST request with a JSON payload longer than a line or two, I'll go and construct my curl command in a text editor anyway, since the shell prompt / readline is not easy to edit. Once you need to start escaping single or double quotes or html payloads in the request, it quickly gets cumbersome. At that point I ditch the shell as a middleman and use the editor to submit the request for me.
The VS Code Rest Client extension https://marketplace.visualstudio.com/items?itemName=humao.re... is great for testing and debugging APIs.
You create a "my_request.http" file that contains something like
First line is the method and url, then headers, then a newline, then the request body.Hit ctrl+alt+p, the request is sent and you see the response in a side pane. Everything is encoded and decoded properly.
You can organize your tests under multiple files and folders.
I cannot recommend this extension enough, it has made my life so much easier.