Httpie
HTTPie - 人性化的 HTTP 命令行客户端 Skill: Httpie Owner: cn-big-cabbage Summary: HTTPie - 人性化的 HTTP 命令行客户端 Tags: latest:0.1.1 Version history: v0.1.1 | 2026-06-16T06:50:52.712Z | auto - 元数据 now specifies required binary as http (was httpie). - Bumped version to 0.1.1. - Removed skill-card.md file. - No changes to user-facing commands or documentation content. v0.1.0 | 2026-04-15T01:01:42.210Z | user Initial release - HTTPie CLI skill for human-friendly
Rank
62
Safety
84
Downloads
975
Updated
Oct 11, 2026
Version
0.1.1
Source
CLAWHUB
About
What it does, and when to use it.
Capability contract not published. No trust telemetry is available yet. 975 downloads reported by the source. Last updated 10/11/2026.
Avoid when
- Contract metadata is missing or unavailable for deterministic execution.
Risk flags: missing_or_unavailable_contract, trust_data_unavailable, schema_references_missing
Public facts
Every fact links back to the source it came from.
- Vendor
- Clawhubvendor · observed Oct 11, 2026
- Protocol compatibility
- OpenClawcompatibility · observed Oct 11, 2026
- Adoption signal
- 975 downloadsadoption · observed Oct 11, 2026
- Latest release
- 0.1.1release · observed Jun 16, 2026
- Handshake status
- UNKNOWNsecurity
What changed
Newest first. Only changes that point at a source are listed.
Release 0.1.1release
- 元数据 now specifies required binary as http (was httpie). - Bumped version to 0.1.1. - Removed skill-card.md file. - No changes to user-facing commands or documentation content.
Observed Jun 16, 2026 · source
Install and run
Setup complexity: low.
clawhub skill install s17dbd0j0kazk5ay31x9kv1z3n84f04v:httpie- Setup complexity is LOW. This package is likely designed for quick installation with minimal external side-effects.
- Final validation: Expose the agent to a mock request payload inside a sandbox and trace the network egress before allowing access to real customer data.
Contract: missing
curl -s "https://www.xpersona.co/api/v1/agents/clawhub-cn-big-cabbage-httpie/snapshot"
Run-check
$0.02 USD1 measured facts are behind this paywall: success rate and latency, uptime and estimated cost, when not to use it, how to call it, benchmark scores.
Agents pay $0.02 in USDC. A card payment is $0.50, the smallest a card allows.
Documentation
CLAWHUB
66,168 characters of source documentation, loaded on request.
Extracted files
5 files captured from the source.
SKILL.md
---
name: httpie
description: HTTPie - 人性化的 HTTP 命令行客户端
version: 0.1.1
metadata:
openclaw:
requires:
bins:
- http
emoji: 🌐
homepage: https://httpie.io
---
# HTTPie 人性化 HTTP 命令行客户端
## 技能概述
本技能帮助用户通过命令行发送 HTTP 请求,调试 API 接口,适用于以下场景:
- **REST API 调试**: 发送 GET/POST/PUT/DELETE 等各类 HTTP 请求
- **接口测试**: 快速验证 API 端点的请求与响应
- **文件上传下载**: 通过命令行进行文件传输
- **身份认证**: 支持 Basic、Bearer Token、Digest 等多种认证方式
- **会话管理**: 跨请求保持 Cookie 与认证状态
- **格式化输出**: 自动语法高亮显示 JSON、XML 响应体
**主要特点**: 语法简洁、自动格式化、彩色输出、内置 JSON 支持、比 curl 更易读写
## 使用流程
AI 助手将引导你完成以下步骤:
1. 安装 HTTPie(如未安装)
2. 构建 HTTP 请求(方法、URL、请求头、请求体)
3. 执行请求并查看格式化响应
4. 根据响应调整请求参数
5. 将成功的命令保存为可复用脚本
## 关键章节导航
- [安装指南](./guides/01-installation.md)
- [快速开始](./guides/02-quickstart.md)
- [高级用法](./guides/03-advanced-usage.md)
- [常见问题](./troubleshooting.md)
## AI 助手能力
当你向 AI 描述请求需求时,AI 会:
- 自动识别请求类型(GET/POST/PUT/PATCH/DELETE)
- 根据描述构建正确的请求头和请求体
- 执行请求命令并解析响应
- 识别常见 HTTP 错误状态码并给出建议
- 自动处理 JSON 数据序列化
- 管理认证令牌和会话 Cookie
- 将复杂请求转换为可读的 HTTPie 命令
## 核心功能
- 支持全部 HTTP 方法(GET、POST、PUT、PATCH、DELETE、HEAD、OPTIONS)
- 自动 JSON 请求体序列化与响应格式化
- 彩色语法高亮(请求头、响应头、响应体)
- 内置多种认证方式(Basic、Digest、Bearer)
- 持久化 Session 管理(跨请求 Cookie)
- 文件上传与二进制下载支持
- HTTPS 与 SSL 证书验证
- 代理支持(HTTP/HTTPS/SOCKS)
- 离线模式(仅打印请求不发送)
- 与 curl 命令互转
## 命令速查表
### 基础请求
```bash
# GET 请求
http GET https://api.example.com/users
# 简写(默认 GET)
http https://api.example.com/users
# POST JSON(自动推断 Content-Type: application/json)
http POST https://api.example.com/users name="张三" age:=25
# PUT 更新
http PUT https://api.example.com/users/1 name="李四"
# PATCH 部分更新
http PATCH https://api.example.com/users/1 email="[email protected]"
# DELETE 删除
http DELETE https://api.example.com/users/1
```
### 请求参数与请求头
```bash
# URL 查询参数(== 语法)
http https://api.example.com/search q=="hello world" page==2
# 自定义请求头(: 语法)
http https://api.example.com/users "Authorization: Bearer mytoken123"
# 多个请求头
http https://api.example.com/data "X-API-Key: abc123" "Accept: application/json"
```
### 认证
```bash
# Basic 认证
http -a username:password https://api.example.com/protected
# Bearer Token
http https://api.example.com/me "Authorization: Bearer <token>"
# Digest 认证
http --auth-type=digest -a user:pass https://api.example.com/secure
```
### 输出控制
```bash
# 仅显示响应体
http --body https://api.example.com/users
# 仅显示响应头
http --headers https://api.example.com/users
# 显示请求+响应(调试用)
http --verbose https://api.example.com/users
# 安静模式(无输出,只看退出码)
http --quiet https://api.example.com/health
# 保存响应到文件
http https://api.example.com/file.pdf > file.pdf
```
## 安装要求
- Python 3.7+ 或直接使用独立二进制包
- 无其他强制依赖
## 许可证
BSD-3-Clause License
## 项目链接
- GitHub: https://github.com/httpie/cli
- 官网: https://httpie.io
- 文档: https://httpie.io/docs/cli_meta.json
{
"ownerId": "kn7c5ry95ff7x22mt3fx6j0q3d81p8t3",
"slug": "httpie",
"version": "0.1.1",
"publishedAt": 1781592652712
}guides/01-installation.md
# 安装指南
**适用场景**: 首次使用 HTTPie,需要在本地环境中完成安装和配置
---
## 一、安装前准备
### 目标
确保系统具备运行 HTTPie 的基础环境,选择最适合的安装方式
### 前置条件
- 操作系统:macOS、Linux(Ubuntu/Debian/Fedora/Arch)、Windows 10+
- 网络连接(下载安装包)
- (pip 方式)Python 3.7 或更高版本
### 检查现有环境
**AI 执行说明**: AI 将自动检查当前系统环境,判断最佳安装路径
```bash
# 检查是否已安装 httpie
http --version
# 检查 Python 版本(如使用 pip 安装)
python3 --version
# 检查 pip
pip3 --version
```
**期望结果**:
- 若 `http --version` 有输出,说明已安装,无需重复安装
- Python 3.7+ 可用 pip 安装方式
- pip 3.x 可正常使用
---
## 二、安装方式选择
HTTPie 提供多种安装方式,根据你的系统和偏好选择:
| 安装方式 | 适用系统 | 优点 |
|--------|--------|-----|
| Homebrew | macOS / Linux | 最简单,自动管理依赖 |
| pip | 全平台(需要 Python) | 版本最新,适合 Python 开发者 |
| pipx | 全平台(需要 Python) | 隔离安装,推荐方式 |
| apt/yum/pacman | Linux | 系统包管理,稳定 |
| 独立二进制 | macOS / Linux | 无需 Python 依赖 |
| Windows Installer | Windows | 官方安装包,最方便 |
---
## 三、各平台安装步骤
### 方法 1: macOS 使用 Homebrew(推荐)
**AI 执行说明**: AI 可以直接执行 Homebrew 安装命令
```bash
# 安装 HTTPie
brew install httpie
# 验证安装
http --version
```
**期望输出**:
```
HTTPie 3.x.x
```
如果未安装 Homebrew,先执行:
```bash
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
```
---
### 方法 2: 使用 pip 安装(全平台)
**AI 执行说明**: AI 可以直接执行 pip 安装命令
```bash
# 使用 pip 安装(推荐使用 pip3)
pip3 install httpie
# 验证安装
http --version
# 如果 pip3 不可用,尝试 pip
pip install httpie
```
**注意**: 部分系统中 `http` 命令可能与系统命令冲突,可以使用完整路径:
```bash
# 查找安装路径
which http
python3 -m httpie --version
```
---
### 方法 3: 使用 pipx 安装(推荐,隔离环境)
pipx 会将 HTTPie 安装在独立的虚拟环境中,避免依赖冲突:
```bash
# 先安装 pipx(如未安装)
pip3 install pipx
pipx ensurepath
# 安装 HTTPie
pipx install httpie
# 验证安装
http --version
```
---
### 方法 4: Linux 系统包管理器
**Ubuntu / Debian**:
```bash
sudo apt update
sudo apt install httpie
http --version
```
**Fedora / RHEL / CentOS**:
```bash
sudo dnf install httpie
# 或者使用 yum(旧版系统)
sudo yum install httpie
```
**Arch Linux**:
```bash
sudo pacman -S httpie
```
**Alpine Linux**:
```bash
apk add httpie
```
---
### 方法 5: Windows 安装
**方式 A - pip(推荐)**:
```powershell
# 在 PowerShell 或 CMD 中执行
pip install httpie
# 验证
http --version
```
**方式 B - Chocolatey**:
```powershell
choco install httpie
```
**方式 C - Scoop**:
```powershell
scoop install httpie
```
---
### 方法 6: 独立二进制安装(无需 Python)
HTTPie 提供预编译的独立二进制文件,无需 Python 环境:
```bash
# macOS (Apple Silicon)
curl -SsL https://packages.httpie.io/mac/http.latest.arm64 -o /usr/local/bin/http
chmod +x /usr/local/bin/http
# macOS (Intel)
curl -SsL https://packages.httpie.io/mac/http.latest.x86_64 -o /usr/local/bin/http
chmod +x /usr/local/bin/http
# Linux (x86_64)
curl -SsL https://packages.httpie.io/linux/http.latest.x86_64 -o /usr/local/bin/http
chmod +x /usr/local/bin/http
```
---
## 四、验证安装
**AI 执行说明**: AI 将验证安装是否成功并进行简单测试
```bash
# 检查版本
http --version
# 发送一个测试请求(HTTPie 官方测试端点)
http GET https://httpie.io/hello
```
**期望输出(版本检查)**:
```
HTTPie 3.x.x
```
**期望输出(测试请求)**:
```
HTTP/1.1 200 OK
Content-Type: application/json
...
{
"ahoy": [
"Hello, World! 👋"
],
...
}
```
guides/02-quickstart.md
# 快速开始 **适用场景**: 已安装 HTTPie,想快速学习基本用法发送 HTTP 请求 --- ## 一、HTTPie 语法概览 ### 基本命令格式 ``` http [选项] [方法] URL [请求项...] ``` | 部分 | 说明 | 示例 | |-----|-----|-----| | `选项` | 控制行为的标志 | `--verbose`, `--json`, `--follow` | | `方法` | HTTP 方法(可省略,默认 GET) | `GET`, `POST`, `PUT`, `DELETE` | | `URL` | 请求地址 | `https://api.example.com/users` | | `请求项` | 请求头、请求体、查询参数 | `name="张三"`, `"X-Token: abc"` | ### 请求项语法 HTTPie 使用特殊符号区分不同类型的请求项: | 符号 | 类型 | 示例 | |-----|-----|-----| | `:` | 请求头 | `"Content-Type: application/json"` | | `==` | URL 查询参数 | `page==1` | | `=` | JSON 字符串字段 | `name="张三"` | | `:=` | JSON 非字符串字段 | `age:=25`, `active:=true` | | `@` | 表单文件字段 | `[email protected]` | | `=@` | JSON 文件内容(字符串) | `[email protected]` | | `:=@` | JSON 文件内容(解析) | `config:[email protected]` | --- ## 二、发送 GET 请求 **AI 执行说明**: AI 可以直接执行以下命令并返回响应 ### 最简单的 GET 请求 ```bash # 发送 GET 请求(方法可省略) http https://httpbin.org/get # 显式指定方法 http GET https://httpbin.org/get ``` **期望输出**(自动格式化 + 彩色高亮): ``` HTTP/1.1 200 OK Content-Type: application/json Date: Mon, 01 Jan 2024 12:00:00 GMT ... { "args": {}, "headers": { "Accept": "application/json, */*;q=0.5", "Host": "httpbin.org", "User-Agent": "HTTPie/3.x.x" }, "url": "https://httpbin.org/get" } ``` ### 携带查询参数 ```bash # 单个查询参数(== 语法) http https://httpbin.org/get search=="Hello World" page==1 # 等效的 URL 形式 http "https://httpbin.org/get?search=Hello+World&page=1" ``` **AI 执行说明**: 推荐使用 `==` 语法,AI 会自动处理 URL 编码 --- ## 三、发送 POST 请求 ### 发送 JSON 数据(自动推断) 当请求项包含 `=` 或 `:=` 时,HTTPie 自动设置 `Content-Type: application/json`: ```bash # 发送 JSON 对象 http POST https://httpbin.org/post name="张三" email="[email protected]" age:=28 # 等效的 JSON 内容: # {"name": "张三", "email": "[email protected]", "age": 28} ``` **注意**: 字符串用 `=`,数字/布尔/数组用 `:=` ### 发送原始 JSON ```bash # 使用管道传入原始 JSON echo '{"name": "李四", "roles": ["admin", "user"]}' | http POST https://httpbin.org/post # 从文件读取 JSON http POST https://httpbin.org/post < data.json ``` ### 发送表单数据 使用 `--form` 或 `-f` 标志,Content-Type 变为 `application/x-www-form-urlencoded`: ```bash http --form POST https://httpbin.org/post username="user1" password="secret" # 简写 http -f POST https://httpbin.org/post username="user1" password="secret" ``` --- ## 四、自定义请求头 **AI 执行说明**: AI 会根据 API 要求自动添加必要的请求头 ```bash # 添加自定义请求头(使用 : 语法) http https://api.example.com/users "X-API-Key: abc123" "Accept: application/json" # 发送带认证头的 POST 请求 http POST https://api.example.com/data \ "Authorization: Bearer eyJhbGciOiJIUzI1NiJ9..." \ "Content-Type: application/json" \ name="测试" ``` --- ## 五、身份认证 ### Basic 认证 ```bash # -a 或 --auth 指定用户名:密码 http -a admin:secret123 https://api.example.com/protected # 只指定用户名(会提示输入密码) http -a admin https://api.example.com/protected ``` ### Bearer Token 认证 ```bash # 直接在请求头中传入 Token http https://api.example.com/me "Authorization: Bearer my-access-token" ``` ### Digest 认证 ```bash http --auth-type=digest -a user:pass https://api.example.com/digest ``` ---
guides/03-advanced-usage.md
# 高级用法
**适用场景**: 已掌握 HTTPie 基础用法,需要使用会话管理、文件上传、代理、脚本集成等进阶功能
---
## 一、会话管理
HTTPie 的 Session 功能可以在多个请求之间自动保持 Cookie、认证信息和请求头,非常适合需要登录状态的 API 测试。
### 创建和使用具名 Session
```bash
# 第一次请求:登录并保存 Session
http --session=my-api POST https://api.example.com/login \
username="admin" password="secret"
# 后续请求:自动携带登录 Cookie
http --session=my-api https://api.example.com/profile
# Session 数据自动保存到 ~/.config/httpie/sessions/ 目录
```
**AI 执行说明**: AI 会在同一任务的多次请求中自动复用 Session,保持认证状态
### 使用文件路径作为 Session
```bash
# 保存 Session 到指定文件
http --session=/tmp/test-session.json POST https://api.example.com/login \
username="test" password="123456"
# 从指定文件加载 Session
http --session=/tmp/test-session.json https://api.example.com/dashboard
```
### 只读 Session(不修改 Session 文件)
```bash
# 使用 Session 但不更新它
http --session-read-only=my-api https://api.example.com/data
```
### 查看 Session 文件内容
Session 文件是 JSON 格式,可以直接查看:
```bash
# 查看保存的 Session 内容
cat ~/.config/httpie/sessions/api.example.com/my-api.json
```
Session 文件结构示例:
```json
{
"__meta__": {
"about": "HTTPie session file"
},
"auth": {
"password": null,
"type": null,
"username": null
},
"cookies": {
"session_id": {
"expires": null,
"path": "/",
"secure": false,
"value": "abc123xyz"
}
},
"headers": {}
}
```
---
## 二、文件上传
### 单文件上传(multipart/form-data)
```bash
# 上传单个文件(@ 语法)
http --form POST https://api.example.com/upload [email protected]
# 指定字段名
http --form POST https://api.example.com/upload \
profile_picture@/path/to/avatar.png \
username="zhangsan"
```
### 多文件上传
```bash
# 同时上传多个文件
http --form POST https://api.example.com/upload \
[email protected] \
[email protected] \
description="批量上传测试"
```
### 上传时指定 MIME 类型
```bash
# 指定文件的 Content-Type(格式:字段名@文件路径;type=MIME类型)
http --form POST https://api.example.com/upload \
"[email protected];type=text/plain"
```
### 将文件内容作为 JSON 字段
```bash
# 将文件内容作为 JSON 字符串字段(=@ 语法)
http POST https://api.example.com/data [email protected]
# 将 JSON 文件内容解析后嵌入请求体(:=@ 语法)
http POST https://api.example.com/config settings:[email protected]
```
---
## 三、下载文件
### 基本下载
```bash
# 下载文件(自动从 Content-Disposition 或 URL 推断文件名)
http --download https://example.com/report.pdf
# 简写
http -d https://example.com/report.pdf
# 指定保存文件名
http --download --output=my-report.pdf https://example.com/report.pdf
# 简写
http -d -o my-report.pdf https://example.com/report.pdf
```
### 下载时显示进度条
下载大文件时,HTTPie 会自动显示进度条:
```bash
http -d https://example.com/large-file.zip
# 输出:Downloading 125.3 MB to "large-file.zip"
# ████████████████████░░░░░░░░░░ 67% 84.0 MB/s 0:00:01
```
### 断点续传
```bash
# 从断点继续下载(如果服务器支持 Range 请求)
http -d -c https://example.com/large-file.zip
```
---
## 四、代理设置
### 使用 HTTP/HTTPS 代理
```bash
# 指定 HTTP 代理
http --proxy=http:http://proxy.example.com:8080 https://api.example.com/data
# 指定 HTTPS 代理
http --proxy=https:http://proxy.example.com:80AionUi
Free, local, open-source 24/7 Cowork app and OpenClaw for Gemini CLI, Claude Code, Codex, OpenCode, Qwen Code, Goose CLI, Auggie, and more | 🌟 Star if you like it!
activepieces
AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents
cherry-studio
AI productivity studio with smart chat, autonomous agents, and 300+ assistants.
CopilotKit
The Frontend for Agents & Generative UI. React + Angular
Machine-readable data
The same record, as JSON, for agents and crawlers.
- Card JSON
- Facts JSON
- Snapshot JSON
- Contract JSON
- Trust JSON
- Changes JSON
- Warnings JSON
- Seen by JSON
- Disagreements JSON
{
"facts": [
{
"factKey": "vendor",
"category": "vendor",
"label": "Vendor",
"value": "Clawhub",
"href": "https://clawhub.ai/cn-big-cabbage/skills/httpie",
"sourceUrl": "https://clawhub.ai/cn-big-cabbage/skills/httpie",
"sourceType": "profile",
"confidence": "medium",
"observedAt": "2026-10-11T23:35:43.302Z",
"isPublic": true
},
{
"factKey": "protocols",
"category": "compatibility",
"label": "Protocol compatibility",
"value": "OpenClaw",
"href": "https://www.xpersona.co/api/v1/agents/clawhub-cn-big-cabbage-httpie/contract",
"sourceUrl": "https://www.xpersona.co/api/v1/agents/clawhub-cn-big-cabbage-httpie/contract",
"sourceType": "contract",
"confidence": "medium",
"observedAt": "2026-10-11T23:35:43.302Z",
"isPublic": true
},
{
"factKey": "traction",
"category": "adoption",
"label": "Adoption signal",
"value": "975 downloads",
"href": "https://clawhub.ai/cn-big-cabbage/httpie",
"sourceUrl": "https://clawhub.ai/cn-big-cabbage/httpie",
"sourceType": "profile",
"confidence": "medium",
"observedAt": "2026-10-11T23:35:43.302Z",
"isPublic": true
},
{
"factKey": "latest_release",
"category": "release",
"label": "Latest release",
"value": "0.1.1",
"href": "https://clawhub.ai/cn-big-cabbage/httpie",
"sourceUrl": "https://clawhub.ai/cn-big-cabbage/httpie",
"sourceType": "release",
"confidence": "medium",
"observedAt": "2026-06-16T06:50:52.712Z",
"isPublic": true
},
{
"factKey": "handshake_status",
"category": "security",
"label": "Handshake status",
"value": "UNKNOWN",
"href": "https://www.xpersona.co/api/v1/agents/clawhub-cn-big-cabbage-httpie/trust",
"sourceUrl": "https://www.xpersona.co/api/v1/agents/clawhub-cn-big-cabbage-httpie/trust",
"sourceType": "trust",
"confidence": "medium",
"observedAt": null,
"isPublic": true
}
],
"events": [
{
"eventType": "release",
"title": "Release 0.1.1",
"description": "- 元数据 now specifies required binary as http (was httpie). - Bumped version to 0.1.1. - Removed skill-card.md file. - No changes to user-facing commands or documentation content.",
"href": "https://clawhub.ai/cn-big-cabbage/httpie",
"sourceUrl": "https://clawhub.ai/cn-big-cabbage/httpie",
"sourceType": "release",
"confidence": "medium",
"observedAt": "2026-06-16T06:50:52.712Z",
"isPublic": true
}
]
}Record generated Oct 12, 2026.
For crawlers
This page is free to read. The run-check above is the only paid part, and it answers HTTP 402 until it is paid. Everything else here is public.
- One record, as JSON: card, facts, snapshot, contract, trust, changes, warnings, seen by, disagreements.
- Every agent, one feed: /.well-known/ai-catalog.json
- What this site sells, and the price: /.well-known/x402
- Paid run-check: /api/v1/agents/clawhub-cn-big-cabbage-httpie/run-check
