zoukankan      html  css  js  c++  java
  • HTTPie:一个不错的 HTTP 命令行客户端

    HTTPie (读aych-tee-tee-pie)是一个 HTTP 的命令行客户端。其目标是让 CLI 和 web 服务之间的交互尽可能的人性化。

    这个工具提供了简洁的 http 命令,允许通过自然的语法发送任意 HTTP 请求数据,展示色彩化的输出。HTTPie 可用于与 HTTP 服务器做测试、调试和常规交互。

    主要特性:

    • 直观的语法
    • 格式化和色彩化的终端输出
    • 内置 JSON 支持
    • 支持上传表单和文件
    • HTTPS、代理和认证
    • 任意请求数据
    • 自定义头部
    • 持久性会话
    • 类 Wget 下载
    • 支持 Python 2.6, 2.7 和 3.x
    • 支持 Linux, Mac OS X 和 Windows
    • 插件
    • 文档
    • 测试覆盖率

    HTTPie 是用 Python 编写,用到了 Requests 和 Pygments 这些出色的库。

    目前在 Github 获得了 20k+ star。

     Github地址:HTTPie

    Installation

    On Mac OS X, HTTPie can be installed via Homebrew (recommended):

     $ brew install httpie

    Most Linux distributions provide a package that can be installed using the system package manager, e.g.:

    # Debian-based distributions such as Ubuntu:
    $ apt-get install httpie
    
    # RPM-based distributions:
    $ yum install httpie
    A universal installation method (that works on Windows, Mac OS X, Linux, …, and provides the latest version) is to usepip
    # Make sure we have an up-to-date version of pip and setuptools:
    $ pip install --upgrade pip setuptools
    
    $ pip install --upgrade httpie

    Usage:

    hello  world
    $ http  https://github.com

      ~ http https://www.github.com

      HTTP/1.1 301 Moved Permanently

      Connection: close

      Content-length: 0

      Location: https://github.com/

     Synopsis

    $ http [flags] [METHOD] URL [ITEM [ITEM]]




  • 相关阅读:
    调用https接口 报错:unable to find valid certification path
    POI生成Excel
    杂七杂八记录
    maven 打jar 包 pom.xml配置
    IDEA 全局修改项目版本
    Spring AOP的内部调用问题
    redis 中文乱码
    windows redis cluster 配置
    spring事物失效场景
    Mybatis常用示例
  • 原文地址:https://www.cnblogs.com/andking/p/5511816.html
Copyright © 2011-2022 走看看