HTTPie Desktop is a cross-platform API testing client for humans. Use it to test REST, GraphQL, and HTTP APIs painlessly.
Getting started
HTTPie Desktop is available for desktop and mobile browsers and as a dedicated desktop app for macOS, Windows, and Linux.
HTTPie Web
HTTPie’s Web app is equivalent to the desktop app, except for certain limitations.
- Go to httpie.io/app
- Or use the short & sweet alias req.new
HTTPie Desktop
HTTPie's desktop app lets you work locally and has a distraction-free interface.
macOS
- Go to httpie.io/download and click Download for Mac.
- Open your Finder and go to Downloads.
- Open the .dmg file and drag HTTPie into your Applications folder.
Windows
- Go to httpie.io/download and click Download for Windows.
- Open the .exe file and follow the instructions to install.
Linux
The Linux package uses AppImage, and you need to install it using AppImageLauncher for the app to work:
- Install AppImageLauncher (instructions)
- Download
HTTPie-*.AppImage(orHTTPie-*arm64.AppImagefor ARM64 architecture) from the latest release page - Run
$ AppImageLauncher HTTPie-*.AppImage
Defining requests
Create and send requests to APIs with HTTPie.
To perform a request, HTTPie needs at least a method and a URL. Then, you can specify a variety of other details, such as headers, authentication, and body.
Request method
You need a method to indicate the desired action of your request. You can choose a variety of conventional methods (GET, POST, HEAD, PUT, PATCH, DELETE, OPTIONS).
Default methods
When starting a new request, HTTPie defaults GET and auto-switches to POST as soon as you add a body.
Custom methods
When testing APIs that use unconventional HTTP methods, you can supplement the default list with a method of your choosing.
Select the last option in the method drop-down and type away.
Request URL
You need a URL to indicate the address your request will go to. HTTPie highlights its path granularly for readability.
You can also use the URL for inserting query parameters directly.
Query parameters
If you find yourself manually constructing URLs with querystring parameters on the app, you may appreciate the parameters form for appending them to the URL.
Check the preview to debug the final results.
Path parameters
HTTPie supports path parameters, allowing you to parametrize URL path segments. To introduce a path parameter, use the /:param syntax inside the URL. The “Params” request tab then splits into two sections, one for query params and the other for path params, which is already showing the newly added one.
Rename params directly from the URL or in the “Path params” table. Remove it from the URL to get rid of it. As with variables, you can escape path params with a backslash.
Request headers
To set custom HTTP request headers, use the headers form.
HTTPie will send them sorted by name and capitalized. Check them out in the preview.
Default headers
There are a couple of default headers that HTTPie sets.
Content-LengthContent-TypeHost: pie.devUser-Agent: HTTPie
These can be overwritten when you manually insert another header with the same name.
Headers auto-complete
HTTPie auto-completes the header names you start typing. Choose the right one from the suggestions, and you're set.
Same-name headers
If you define multiple headers with the same name, HTTPie will merge their values into a single comma-separated header.
Request auth
You may set Authentication at the request level or collection level.
The currently supported authentication schemes are Basic, Bearer token and API key. Look for the switcher at the bottom left.
Basic auth
Bearer auth
Use the Bearer token auth for OAuth 2.0 and other token-based authentication schemes via the request header Authorization: Bearer my-token
If you need a different prefix than Bearer, you can achieve that by using the generic API key auth instead.
API key auth
For when you need to authenticate requests using API key as a custom header or a URL parameter.
Request body
The currently supported body types are Text, Form, File and GraphQL. Look for the switcher at the bottom left.
Text body type
The text request body has these subtypes:
Raw: Any textual content withtext/plainas the default content type.JSON: JSON-specific text editor andapplication/jsonas the default content type.XML: XML-specific text editor andapplication/xmlas the default content type.YAML: YAML-specific editor andtext/yamlas the default content type.
Check also the ability to search & replace. It might come in handy.
Form body type
HTTPie takes two form types:
URL-encoded- for text or text-files onlyMultipart- accepts any file
You can easily switch from one to the other while keeping its content.
File upload body type
GraphQL body type
HTTPie has built-in support for crafting GraphQL requests.
Multi-body
You can specify multiple body types and quickly toggle between them. This feature is useful when a specific API endpoint accepts both JSON and form data, for example.
There's an indicator in the switcher for each body type that has some data specified.
Prettify
To ensure the body of your request is humanly readable and navigable, use the prettify feature. It will automatically format your code so that your brain’s free to do other things.
Look for the wand icon at the bottom of the code editor. Currently available for JSON and GraphQL requests.
GraphQL
GraphQL is a popular API query language created at Facebook. It’s designed to help develop strongly typed APIs that give clients the power to ask for precisely the data they need while minimizing the number of requests.
GraphQL requests
Under the hood, GraphQL requests are regular POST requests. But HTTPie has built-in support for crafting GraphQL requests to improve your experience when talking to GraphQL APIs.
Choose “GraphQL” as the body type, then specify your GraphQL query and JSON variables separately. You get syntax highlighting and other features specific to each language.
GraphQL schema
HTTPie auto-fetches the schema from the server. That means the app is aware of all the available queries, mutations, and the hierarchy of types, which allows us to boost your productivity with auto-complete and validation.
See auto-complete suggestions as you type, and to invoke the menu manually, press ⌃Space.
Schema auto-fetch
HTTPie auto-fetches the schema using the current request’s URL and authentication. To refresh the schema, select “Update from server” from the new “Schema” menu. And to turn off schema for a particular tab, uncheck “Auto-apply schema.”
Preview
HTTPie provides a real-time updated preview of the raw HTTP request without the need to send it:
The preview panel also supports code snippet generation. Make some changes to your request and see them instantly reflected in the preview — it’s like a WYSIWYG editor for API calls code. Look for the switcher at the bottom left to choose your target language:
See all request export options.
Export
The export and import system allows for data backups, simple sharing, and publishing. You can export/import spaces, environments, collections, and individual requests in a JSON format. You can also export requests as