chiwei-platform: Skill for Claude Code

.claude/skills/api-test/SKILL.md

api-test is a skill for Claude Code from bezhai/chiwei-platform. It costs 69 tokens per session (951 once invoked), scanned A, original, MIT.

A project helper for making HTTP requests, where HTTP is the standard way software communicates with web services. It fills in the service address and authentication details, and returns the status, response time, and response body.

In plain words
What is it for?
Use it to test API endpoints with GET, POST, or PUT requests, send JSON data, use a specific lane, save responses, or inspect response timing.
Why use it?
It removes repeated setup when testing internal APIs and supports requests through a selected testing lane. It also makes failures easier to assert in scripts by checking the expected status code.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter. Also seen: reads .claude/ paths.

This is bezhai/chiwei-platform's own configuration. It tells Claude Code how to work on chiwei-platform itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything chiwei-platform configures →

Reuse

Borrowing it

Nothing to install: this file belongs to bezhai/chiwei-platform. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/bezhai/chiwei-platform/main/.claude/skills/api-test/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/bezhai/chiwei-platform

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for api-test

README.md
[![agentmods](https://agentmods.dev/badge/skills/bezhai/chiwei-platform/api-test/github.svg)](https://agentmods.dev/skills/bezhai/chiwei-platform/api-test)
Your own site
<a href="https://agentmods.dev/skills/bezhai/chiwei-platform/api-test"><img src="https://agentmods.dev/badge/skills/bezhai/chiwei-platform/api-test/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for api-test

Your own site · 80×15
<a href="https://agentmods.dev/skills/bezhai/chiwei-platform/api-test"><img src="https://agentmods.dev/badge/skills/bezhai/chiwei-platform/api-test.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 69 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 951 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00069 $0.00951
Opus 5.5 $0.00028 $0.00380
Sonnet 5.5 $0.00014 $0.00190
Haiku 4.5 $0.00007 $0.00095

Measured 2mo ago against content hash dfd245a0fdac, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

api-test scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/http.sh, scripts/test_http.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

description: 项目 HTTP API 调用 helper。写路径就行,scripts/http.sh 自动补 $PAAS_API、注 PAAS_TOKEN、透泳道,统一返回 {status, ms, body}。需要复杂 curl 能力(stream、文件、TLS/proxy、详细调试)时直接 curl,并说明原因。
.claude/skills/api-test/SKILL.md · 70 lines

What it actually says

/api-test

scripts/http.sh 比裸 curl 强的地方:你只写路径,剩下的它办。

  • 以 / 开头的路径自动拼上 $PAAS_API;完整 http(s):// URL 原样使用。
  • 路径在 /dashboard/... 或 /api/paas/... 下时,自动注入 X-API-Key: $PAAS_TOKEN。对内对外一把钥匙——dashboard 也认 PAAS_TOKEN,两个面同一个 token,调用方不用再想该传哪个。
  • --lane LANE 自动加 x-lane 头;显式传了 X-API-Key / x-lane 或 --no-auth 时不覆盖。
  • 始终返回 {"status":..,"ms":..,"body":..},ms 是耗时。

完整 http(s):// URL 永远不自动注 token,所以历史上"传完整 URL + 显式 header"的调用方不受影响。

这个 helper 不替代 curl。它不支持的场景直接用 curl,不要让用户手动代劳:stream、文件上传/下载、长日志、复杂 TLS/proxy/redirect、-v 看握手。

用法

HTTP=.claude/skills/api-test/scripts/http.sh

# 裸路径:自动补 base + 自动注 PAAS_TOKEN
$HTTP GET /dashboard/api/ops/services
$HTTP GET "/api/paas/apps/agent-service/resolved-config?lane=prod"

# 带泳道
$HTTP --lane ppe-foo GET /api/paas/apps/agent-service/pods

# POST(第三个参数是 JSON body)
$HTTP POST /api/paas/apps/x '{"a":1}'

# 选项放任意位置都认(含末尾)
$HTTP GET /dashboard/api/ops/services --jq '.apps | length'

# 断言状态码:不匹配则退出码非 0(脚本里好用)
$HTTP --expect 200 GET /dashboard/api/health

# 其它选项:--timeout SEC(默认 60)、--save FILE、--no-auth、--raw
$HTTP --timeout 180 GET /dashboard/api/...
$HTTP PUT /api/paas/apps/x @/tmp/body.json
$HTTP POST /api/paas/... --data "plain text" "Content-Type: text/plain"

# 需要原生 curl 能力时显式透传
$HTTP --curl -v --max-time 300 -H "X-API-Key: $PAAS_TOKEN" "<url>"

选项

  • --lane LANE 加 x-lane(也可用 HTTP_LANE 环境变量)
  • --jq FILTER 对原始 body(不是 {status,ms,body} 外层)跑 jq -r,只打印结果
  • --expect CODE 状态码 ≠ CODE 时退出码非 0
  • --save FILE 额外把原始 body 落盘
  • --no-auth 不自动注 token;--raw 直出原始 body(不包 JSON、不计时)
  • --curl <args...> 后续参数原样交给 curl

输出

{"status": 200, "ms": 36, "body": {"key": "value"}}
{"status": 500, "ms": 12, "body": {"message": "error detail"}}
{"status": 0, "error": "curl exit 28: timeout"}

测试

scripts/test_http.sh:dry-run 单测(解析/补 base/注 token/透泳道)+ 本地 server e2e(计时/--jq/--expect)。改 http.sh 后跑 bash .claude/skills/api-test/scripts/test_http.sh。

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 70 lines · 69 tokens per session scan A dfd245a0fdac

Subscribe to this mod's changes

api-test is a skill published in the GitHub repository bezhai/chiwei-platform (22 stars, last pushed 2d ago), licensed MIT. It adds 69 tokens to every session and 951 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

api-test compared with skills from other repositories

api-test next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
api-testbezhai/chiwei-platformSkill222d agoMITA69Claude Code
mem0-oss-to-platformmem0ai/mem0Skill68k2d agoApache-2.0A217Claude Code, Codex
azure-mgmt-botservice-dotnetmicrosoft/skillsSkill3.2kyesterdayMITA78Claude Code
fastapi-router-pymicrosoft/skillsSkill3.2kyesterdayMITA46Claude Code
dev-runtimelangwatch/langwatchSkill5.0kyesterdayApache-2.0A172Claude Code
api-designericrisco/rsc-harnessSkill5032d agoMITA105Claude Code, Codex
migrate-segw-to-raparc-mcp/arc-1Skill252yesterdayMITA106Claude Code