Changelog #0020 — 🔦 Data filtering, search & replace, RegExp, and more

claudiatd

Cláudia Delgado

Posted on October 24, 2022

Changelog #0020 — 🔦 Data filtering, search & replace, RegExp, and more

Hello, API World! We’re back with a new release of HTTPie for Web & Desktop, the API testing client that you’ll enjoy using. Last time, we hinted at additional tools for navigating and processing data. And that’s been our theme for this release. Check out what we shipped in v2022.15.0👇

🔖 Summary

🔦 Filter, transform and analyze structured data

We’ve recently introduced text search to help you navigate large messages. Text search is available everywhere in the app as a universal way to navigate textual content.

When talking to APIs, though, you often deal with structured data like JSON, XML, and HTML. The explicit structure of these formats unlocks additional, more powerful ways of navigating and processing the data they contain.

In this release, we focused on taking advantage of that and added the ability to filter structured formats using various query languages. With filtering, you can quickly analyze, transform, and selectively extract data from structured documents without leaving HTTPie.

Filter

The following data formats and query languages are now available:

Data format Query language
JSON JSONPath
XML XPath
HTML XPath

Activate the filter field via a keyboard shortcut when the textarea is focused (macOS: ⇧⌘F; Windows & Linux: ⇧⌃F) or use the “Filter” item in the panel’s menu.

Data filtering is available everywhere where structured data can appear: in the preview and the request and response panels. To filter the request body data you’re editing, open the preview panel and activate the filter there. The preview shows the effective request body with all variables already substituted, which allows more robust filtering.

Data filtering and text searching are independent features. You can, for example, filter a massive JSON response and still search inside the filtered output. To do that, simply open both the filter field (⇧⌘F) and the text search field (⌘F).

This feature is part of a theme of making data easy to process and digest, and we’ll continue to add more ways to transform and visualize data.

🔣 Upgrade your searches through RegExp

Regular expressions (aka RegExp) are a powerful tool for searching for patterns in text, and now you can use them in HTTPie as well.

RegExp search

🔀 Search & replace in the request body

Any request body should be comfortably editable directly in HTTPie, no matter how big. The new ability to search & replace is another step in that direction!

Replace

Activate the search field via a keyboard shortcut when the textarea is focused (macOS: ⌘F; Windows & Linux: ⌃F), and check out the new replacing options. Either replace the occurrences one by one or all at once — up to you!

When searching using a RegExp, you can reference matching groups using the dollar-group-number syntax, where $0 references the whole match, $1 is the first group, etc.

✨ Other improvements and bug fixes

  • When the response body preview is active, and you invoke search or filter, we automatically turn the preview off so you can operate on the raw body.
  • The app now uses dark mode for the UI by default. No worries, you can still change it back to the system or light one via the settings (⌘,) if that’s what you prefer.
  • All keyboard shortcuts would repeat during a long press. We’ve now streamlined it so that, for example, holding ⌘↩ results only into one request.
  • Now we warn you when you reach or approach the maximum variable name character limit.
  • We’ve fixed a bug that sometimes led to 100% CPU usage with many tabs open.

📢 Help wanted: teams and collaboration

Like with delicious pies, we believe the magic of HTTPie can be best experienced when shared with others. 😋

We’ve been heads down working on a multiplayer mode for a while now. Teams and collaboration are some of the most exciting and requested features on our roadmap. We can’t wait to see what shape they’ll take and all the opportunities they unlock for our users.

Teams and collaboration

If you’re as excited as we are, or the opposite, we’d love to talk to you! We want to ensure we’re building the right thing, and your help would be greatly appreciated & swag-rewarded!

As a start, you can help us by completing a quick survey. Then, if you’re up for it, we’d be delighted to interview you over Zoom.

Get in touch, and help shape the best collaborative API experience! 💪

🤗 Happy API testing, and see you again soon!

💖 💪 🙅 🚩
claudiatd
Cláudia Delgado

Posted on October 24, 2022

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related