From 2f50dab2adfee44a198742a87a8ece4559c0be24 Mon Sep 17 00:00:00 2001 From: Daniel Kaczmarczyk Date: Mon, 7 Aug 2023 02:07:47 -0700 Subject: [PATCH] httpie: add osx page (#10588) --- pages/osx/httpie.md | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 pages/osx/httpie.md diff --git a/pages/osx/httpie.md b/pages/osx/httpie.md new file mode 100644 index 0000000000..4c8ecaf979 --- /dev/null +++ b/pages/osx/httpie.md @@ -0,0 +1,36 @@ +# httpie + +> A user friendly HTTP tool. +> More information: . + +- Send a GET request (default method with no request data): + +`http {{https://example.com}}` + +- Send a POST request (default method with request data): + +`http {{https://example.com}} {{hello=World}}` + +- Send a POST request with redirected input: + +`http {{https://example.com}} < {{file.json}}` + +- Send a PUT request with a given JSON body: + +`http PUT {{https://example.com/todos/7}} {{hello=world}}` + +- Send a DELETE request with a given request header: + +`http DELETE {{https://example.com/todos/7}} {{API-Key:foo}}` + +- Show the whole HTTP exchange (both request and response): + +`http -v {{https://example.com}}` + +- Download a file: + +`http --download {{https://example.com}}` + +- Follow redirects and show intermediary requests and responses: + +`http --follow --all {{https://example.com}}`