Settings

Theme

Better Curl Saul: a lightweight API testing CLI focused on UX and simplicity

github.com

71 points by jicea 3 months ago · 14 comments

Reader

esafak 3 months ago

In https://github.com/ducaale/xh it's something like

  xh POST api.github.com/repos/owner/repo/issues \
    Authorization:'Bearer ghp_token123' \
    Accept:application/vnd.github.v3+json \
    title='Bug Report' \
    body='Something is broken' \
    labels:='["bug","priority-high"]' \
    assignees:='["developer1","developer2"]'
  • kbd 3 months ago

    curlie has had the best balance of ergonomics and power of all the cli tools I've tried. It's full curl underneath but provides a nice ergonomics layer that matches tools like httpie. https://github.com/rs/curlie

davidkunz 3 months ago

It's all good, man!

imiric 3 months ago

I suppose this helps with managing sessions specifically during testing, but IMO the "disgusting" curl command looks fine to me. The UX of iteratively running commands to change request values instead of changing a single curl command seems worse to me. With the curl approach you can see exactly what is being sent at all times, you can press `v` (or `C-x C-e` if you're a masochist) to edit the command in $EDITOR, and the command remains in your shell history for quick lookup.

I think that all these tools that try to replace curl for the sake of improving UX miss the mark in some way. Just use curl, and wrap it in some aliases or shell scripts if you must. curl is brilliantly designed, already has great UX, and is available everywhere.

  • skydhash 3 months ago

    I’m running OpenBSD (Debian before) and I’m using more and more tools like ps, top, and curl. They’re available everywhere. And you mostly have the same queries, so you can turn them into something easier to type if you want to.

fcpguru 3 months ago

and if anyone needs an actual lawyer https://bettercallsy.com/

selectnull 3 months ago

A few years ago I was thinking about that same problem and came up with this: https://github.com/selectnull/endpoint

I don't see myself having the time to implement all the features I sometimes (half-assed) think of. It's semi useful tool, sometimes.

tux1968 3 months ago

These guys must be very smart. Does this thing solve cache invalidation too?

mvieira38 3 months ago

The UX seems genuinely good

dominicq 3 months ago

Do you think a man just happens to call an API without an authorization header? Give me a break. He orchestrated it! Jimmy!

landonia 3 months ago

best tool name ever

felhr 3 months ago

I will start using it only because of the name

chooma 3 months ago

Upvoted because I giggled :)

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection