#http #httpie #kodumaro #cli #status

nightly bin+lib kodumaro-http-cli

Kodumaro HTTP CLI inspired by HTTPie

2 releases

new 0.5.2 Nov 22, 2024
0.5.0 Oct 10, 2024
0.4.2 Oct 10, 2024
0.3.0 Oct 9, 2024
0.1.0 Oct 8, 2024

#246 in Command-line interface

Download history 670/week @ 2024-10-07 75/week @ 2024-10-14 121/week @ 2024-11-18

121 downloads per month

BSD-3-Clause

35KB
873 lines

Kodumaro HTTP CLI

Kodumaro HTTP CLI inspired by HTTPie.

Project status

It’s still a kinda-usable work in progress.

Installation

cargo +nightly install kodumaro-http-cli

Usage

Usage: http <COMMAND>

Commands:
  connect  performs a CONNECT request
  delete   performs a DELETE request
  get      performs a GET request
  head     performs a HEAD request
  option   performs a OPTION request
  patch    performs a PATCH request
  post     performs a POST request
  put      performs a PUT request
  trace    performs a TRACE request
  help     Print this message or the help of the given subcommand(s)

Options:
      --raw <RAW>                      allows you to pass raw request data without extra processing
  -o, --output <OUTPUT>                save output to file instead of stdout [default: URL path file name]
  -d, --download                       do not print the response body to stdout; rather, download it and store it in a file
  -a, --auth <AUTH>                    basic authentication (user[:password]) or bearer token
  -F, --follow                         follows Location redirects
      --max-redirects <MAX_REDIRECTS>  when following redirects, max redirects [default: 30]
      --verify <VERIFY>                set to "no" to skip checking the host's SSL certificate [default: yes]
      --fail                           fail on error status code
  -v, --verbose                        Show headers

Environment variables

  • HTTP_DOWNLOAD=true: enable --download
  • HTTP_AUTH=<auth>: use <auth> as authentication (--auth=<auth>)
  • HTTP_FOLLOW=true: enable --follow
  • HTTP_MAX_REDIRECTS=<num>: set max redirects to <num> (--max-redirects=<num>)
  • HTTP_VERIFY=no: disable SSL certificate verification (--verify=no)

TODO

  • Support multipart/form-data
  • Support configuration file

Dependencies

~18–33MB
~499K SLoC