Birbla

Login
    Hurl: Run and test HTTP requests with plain text (github.com)
    388 points by flykespice - 16 hours ago

  • What's missing from Hurl is snapshot testing. After using `insta` for testing APIs, I cannot go back.
    by laerus - 15 hours ago
  • Hi Hurl maintainer here, happy to answer any question and get feedbacks!
    by jicea - 14 hours ago
  • Looks a bit like this:

    https://marketplace.visualstudio.com/items?itemName=humao.re...

    Which is a banger VS Code extension for all sorts of http xyz testing.

    by chvid - 14 hours ago
  • The main thing I find missing with hurl is an rc file.
    by davidcalloway - 14 hours ago
  • Isn't this similar to HTTP Client tool available for IntelliJ? - https://www.jetbrains.com/help/idea/http-client-in-product-c...
    by the_arun - 14 hours ago
  • This looks great, would definitely use it for testing if websocket support ever gets added https://github.com/Orange-OpenSource/hurl/issues/1096
    by zoidb - 14 hours ago
  • Is that POST in the readme sending the password in the query params? Is this shorthand or literally adding them to the params?

    I don't really feel the need for a curl replacement. In the past I've used httpie which is pretty slick but I end up falling back to writing tests in python using requests library.

    Maybe I'm not the target audience here, but I should still say something nice I guess. It's nice that it's written in Rust, and open source tooling is in need of fresh projects ever since everyone started bunkering up against the AI monolith scraping all their work. We should celebrate this kind of project, I just wish I had a use for it.

    by antisceptic - 14 hours ago
  • If I want to open a modal & check something, could it simulate clicking on open modal button? Or is it first level for now (without any support for interactions / javascript magic)
    by the_arun - 14 hours ago
  • This looks awesome. I've searched for something like this many times and made a half dozen half-hearted attempts to build it too. Great job!
    by gabesullice - 14 hours ago
  • this looks nice. is it possible to set a variable after a request and use it later in another request?
    by kaan_keskin - 13 hours ago
  • Can you have different environments or profiles or whatever, with different global variables?
    by genericspammer - 13 hours ago
  • Yeah love Hurl, we stared using it back in 2023-09.

    We had a test suite using Runscope, I hated that changes weren't versioned controlled. Took a little grunt work and I converted them in Hurl (where were you AI?) and got rid of Runscope.

    Now we can see who made what change when and why. It's great.

    by 1a527dd5 - 12 hours ago
  • interesting tool !

    première fois que je vois qqch de cool sortir d'orange.

    by QuiCasseRien - 12 hours ago
  • For automated testing I use hurl, but my personal dev roadmap is to create another tool.

    The deficiencies in huel with client state management is not easy to fix.

    What I'd like is full client state control with better variable management and use.

    For my last project I used Python to write the tests, which appears to work well initially. Dunno how well it will hold up for ongoing maintenance.

    by lelanthran - 12 hours ago
  • I am using it and I love it :)
    by molszanski - 12 hours ago
  • In the JVM projects, I use Karate for integration tests: https://github.com/karatelabs/karate

    It gives you full control of constructing requests and assertions because test scenarios may include arbitrary JavaScript.

    by a57721 - 12 hours ago
  • Can you share "fixtures" amongst tests? For example, I wouldn't want to have to copy/paste the signup and login process for each type of user across hundreds of tests.

    What about test isolation? Are people using something else to "prime" the service before/after running these tests?

    by globular-toast - 11 hours ago
  • I love this kind of tools (easy, simple and cli). I remember that https://httpie.io/cli or https://jqlang.org/ .
    by mdtrooper - 11 hours ago
  • This looks interesting. Longtime user of the Vscode-restclient, but have been moving over to httpyac lately for the scripting and cli use. Will take a look to see if hurl is a good fit.

    One annoying thing I've found in testing these tools is that a standard hasn't emerged for using the results of one request as input for another in the syntax of `.http` files. These three tools for instance have three different ways of doing it:

    * hurl uses `[Captures]`

    * Vscode-restclient does it by referencing request names in a variable declaration (like: `@token = {{loginAPI.response.body.token}}`).

    * While httpyac uses `@ref` syntax.

    From a quick round of testing it seems like using the syntax for one might break the other tools.

    [1]: https://hurl.dev/docs/capturing-response.html

    [2]: https://github.com/Huachao/vscode-restclient

    [3]: https://httpyac.github.io/guide/metaData.html#ref-and-forcer...

    by kalli - 10 hours ago
  • Isn't that very similar to Jetbrains HTTP Client ?
    by lambda-science - 10 hours ago
  • This is interesting. I’m wondering how programmable this is. Would this project (or any similar ones) be able to POST a json payload with a field set to “now()”?
    by epalm - 10 hours ago
  • Is there any program code that is not based on plain text? Punch cards maybe? For the value of "plain text" that includes a programming language with its own syntax and grammar, like Hurl.
    by blueflow - 9 hours ago
  • I must say, the sample section[1] does an excellent job of making a case for the tool, especially to people who are inclined to make a snap judgement about the usefulness of the tool within the first 5 minutes (I'm sometimes guilty of this).

    [1] https://github.com/Orange-OpenSource/hurl?tab=readme-ov-file...

    by hliyan - 8 hours ago
  • The one thing I never understood about the Hurl format is why the response status code assertion happens at the request section and not under the `[Asserts]` section. I wonder what the rationale behind that is.
    by yoavm - 7 hours ago
  • So we are not doing telnet anymore?
    by jorgeleo - 7 hours ago
  • One thing not really advertised about Claude Code is it makes all command line tools plain text/plain English.

    “Get data from the last log entry in <file> and post it to <url>”

    by WhitneyLand - 7 hours ago
  • Hurl is awesome. A while back I ported a small web service from Python to Rust. Having rigorous tests of the public API is amazing; a language-independent integration test! I was able to swap it out with no changes to the public API or website.

    Worth mentioning that using Hurl in Rust specifically gives you a nice bonus feature: integration with cargo test tooling. Since Hurl is written in Rust, you can hook into hurl-the-library and reuse your .hurl files directly in your test suite. Demo: https://github.com/perrygeo/axum-hurl-test

    by perrygeo - 7 hours ago
  • I took a lot of inspiration from this project when designing my own HTTP testing tool[0]. We needed to be able to run hundreds of tests quickly, and in parallel. If that is something you need and you like Hurl, then you might like Nap also.

    [0] https://naprun.dev

    by twodave - 7 hours ago
  • It looks interesting, I had a look a the dependencies, 1.5k lines for a cli tool to test http calls ( and more ), is it the norm in Rust?

    https://github.com/Orange-OpenSource/hurl/blob/master/Cargo....

    by Thaxll - 7 hours ago
  • This is cool, but also genuine question why this over some scripting language that can easily do http calls as well?

    I don’t think the DSL is significantly easier than a PL and it’s more limited to?

    Is it because of raw speed or ease of reading the DSL?

    by ninetyninenine - 6 hours ago
  • I just started using hurl a couple months ago.

    For my uses it's great that it has both test suite mode and individual invocation mode. I use it to execute a test suite of HTTP requests against a service in CI.

    I'm not a super big fan of the configuration language, the blocks are not intuitive and I found some lacking in the documentation assertions that are supported.

    Overall the tool has been great, and has been extremely valuable.

    I started using interface testing when working on POCs. I found this helps with LLM-assisted development. Tests are written to directly exercise the HTTP methods, it allows for fluidity and evolution of the implementations as the project is evolving.

    I also found the separation of testing very helpful, and it further enforces the separation between interface and implementation. Before hurl, the tests I wrote would be written in the test framework of the language the service is written in. The hurl-based tests really help to enforce the "client" perspective. There is no backdoor data access or anything, just strict separation betwen interface, tests and implementation :)

    by dm03514 - 6 hours ago
  • I created something different yet similar.

    You make GET request to server with any of supported crawlers and obtain result in JSON

    https://github.com/rumca-js/crawler-buddy/

    Supports request, selenium, Httpx, curl cffi, etc

    by renegat0x0 - 6 hours ago
  • Oh wow! This reminds me so much of what I was trying to do almost 10 years ago but I was too much of a noob to make it make more sense haha.

    https://github.com/zackify/legible

    by zackify - 5 hours ago
  • Nice. This looks way better than this one written in Go: https://github.com/vdobler/ht it uses hjson.

    We used it very often a couple of years ago. Will try hurl.

    by cyri - 5 hours ago
  • It's nice, and there's an emacs mode for it: https://github.com/JasZhe/hurl-mode
    by jcmfernandes - 5 hours ago
  • IntelliJ has had this "plain text HTTP" feature for a while. I'm wondering if it is backed by Hurl?
    by wiradikusuma - 5 hours ago
  • With nice editor integration (especially emacs), hurl is a good postman replacement.

    Kinda niche, but I wrapped libhurl to make it really easy to make an AWS Lambda availability monitor out of a hurl file https://gitlab.com/manithree/hurl_lambda

    by manithree - 5 hours ago
  • Hurl has been great for testing in my RAD templating web server project. Like dm03514 says itt, 'The hurl-based tests really help to enforce the "client" perspective.' It's packaged for 3 application environments including a docker image (x2 archs, x3 oses) and with Hurl its easy to ensure the tests pass at the client level in all three environments.

    It would be nice to have fancy-regex; today I tried to write a regex to match a case like this ~ <link href="/assets/reset.css\\?hash=(.*)" integrity="\\1" rel="stylesheet"> ~ but the regex crate (and thus hurl asserts) can't do backreferences so I guess I'll just live without checking that these two substrings match.

    I wish there was some way to test streamed updates / SSE. Basically, open a connection and wait, then run some other http requests, then assert the accumulated stream from the original connection. https://github.com/Orange-OpenSource/hurl/discussions/2636

    by infogulch - 4 hours ago
  • I think the idea is nice, but I am struggling for why I should use it. I write using Django, which has plenty of hooks for testing within the framework. Why switch to a tool which is blind to my backend and is going to create more work to keep in sync? At minimum, I lose the ability to easily drop into my debugger to inspect why a result went wrong.

    There is probably something to be said for keeping a hard boundary between the backend and testing code, but this would require more effort to create and maintain. I would still need to run the native test suite, so reaching out to an external tool feels a little weird. Unless it was just to ensure an API was fully generic enough for people to run their own clients against it.

    by 3eb7988a1663 - 4 hours ago
  • Shout out to the OG Hurl HTTP tool https://web.archive.org/web/20100112040154/http://hurl.it/
    by johns - 3 hours ago
  • > It's somewhere between a curl script and Postman

    Sounds a lot like Emacs' restclient-mode, and I can absolutely see the appeal for those which don't already have an Emacs session open.

    by kqr - 2 hours ago
  • I believe it's built-in to IntelliJ, just create a file with .https extension.
    by deepsun - 22 minutes ago

© 2025 Birbla.com, a Hacker News reader · Content · Terms · Privacy · Support