4 ms·
This is pretty handy. I usually default to httpie for playing with my APIs and documenting examples - it's much clearer than curl. It doesn't seem to get much
by akvadrako 7y ago
This is pretty handy. I usually default to httpie for playing with my APIs and documenting examples - it's much clearer than curl.
It doesn't seem to get much development attention though. There hasn't really been features I find useful added in the past year. The biggest issue is no support for nested JSON bodies, meaning non-trivial API calls end up just as complex as curl.
- MuffinFlavored 7y ago-H for request headers -d for body -X for method —-verbose to see response headers How much “clearer” could curl get?
- bpfrh 7y agohmmm how about this: -M for Method -B for Body -RH for Request Header you know, so you only have to know the first letter and don't have to remmeber arbitary flags? I know that it is not that easy, but unix tools do have the problem that often the flags don't make sense on the first glance.
- jbreiding 7y ago-H for header -d for data -X for execute There was a reasonable attempt at this already. There are going to opinions on either side. And through regular use the flags would become muscle memory.
- microcolonel 7y ago> I know that it is not that easy, but unix tools do have the problem that often the flags don't make sense on the first glance. Should you be sending HTTP requests to something without knowing precisely what you're doing? httpie just sorta assumes from your arguments what you're trying to do, and for me it has often been wrong. Probably works OK if you have a mostly read-only API.
- bpfrh 7y agoI don't send random things, I either look up curl if I need to script something or I just use postman. EDIT: Depends, most of the time I use standard JSON Rest apis, there is not really that much to misassume I think.