本文へ移動
cccskills
無料GitHub で公開

api-error-triage

Diagnose failing HTTP API calls - 4xx/5xx responses, timeouts, TLS errors, and auth failures - by isolating the fault layer and producing a minimal reproduction. Use when the user reports an API request failing, pastes an HTTP error response or status code, or asks why a request works in one client but not another. Do not use for designing new APIs or for performance tuning of requests that already succeed.

日本語の概要は準備中です。原文の説明を表示しています。

インストール方法を見る

含まれるファイル(1)

  • SKILL.md3.6 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

API Error Triage

Find which layer broke — network, TLS, auth, request shape, or server — and prove it with a minimal reproduction. Resist the urge to change code before the fault layer is known.

Step 1: Capture the actual failure

Get the exact request and response, not a paraphrase. Ask for (or reproduce with curl -v) the method, URL, headers (secrets redacted), body, and the full response including status and body. Error bodies usually name the real problem; status codes alone often lie (see table below).

Step 2: Walk the layers in order

Test each layer with the simplest possible probe; stop at the first one that fails.

LayerProbeIf it fails
DNS / networkcurl -sv https://host/ -o /dev/nullwrong host, VPN, firewall, proxy env vars
TLSsame probe, read handshake outputcorporate MITM proxy, expired cert, old TLS version
Authminimal authenticated GET to a cheap endpointexpired/wrong key, wrong header scheme, wrong environment's key
Request shapereal endpoint, minimal valid bodymissing required field, wrong content-type, encoding
Server / dataoriginal requestresource state, rate limit, genuine server bug

Step 3: Decode the status honestly

Common misdirections to check before trusting the code at face value:

  • 401 vs 403: 401 = who are you (credentials); 403 = you, specifically, may not (permissions/scopes). Rotating the key fixes only the first.
  • 404: often means "exists but you lack access" (deliberate masking), or a path typo — check for a stray trailing slash or missing API version segment.
  • 400 with vague body: diff the failing request against a known-good one from the docs, field by field, including header casing and content-type.
  • 429: read Retry-After; check whether the limit is per-key or per-IP before concluding the client is too chatty.
  • 5xx: not always the server's fault — malformed bodies that crash parsers frequently surface as 500. If a minimal valid body succeeds, it's the request.
  • Timeout: distinguish connect timeout (network layer) from read timeout (server slow) — the fix lives in different places.

Step 4: Minimal reproduction

Reduce to the smallest curl that still fails, then confirm the inverse: the same command with one thing changed succeeds. That pair — failing command plus passing command — is the diagnosis.

# fails: 400 {"error":"invalid_date"}
curl -s https://api.example.com/v2/bookings -H "$AUTH" \
  -d '{"date":"07/19/2026"}'
# passes: only the date format changed
curl -s https://api.example.com/v2/bookings -H "$AUTH" \
  -d '{"date":"2026-07-19"}'

Step 5: Report

Deliver: the fault layer, the failing/passing pair, the fix, and — if the bug was in client code — why it worked before, if it did. If the fault is on the server side, draft the support ticket with the reproduction included.

Rules

  • Never print or log credentials; redact keys in every reproduction you show.
  • Do not retry mutating requests (POST/DELETE) blindly during triage — probe with GETs or idempotent calls wherever possible.
  • One variable per experiment. A probe that changes two things proves nothing.

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

コメント

ログインなしで書き込めます。使ってみた感想、質問、動かなかった環境などを気軽にどうぞ。

まだコメントはありません。最初のコメントを書いてみませんか。

送信するとすぐに公開されます。メールアドレスや電話番号などの個人情報は書かないでください。URL は 2 つまでです。

0 / 1000 文字

このフォームは reCAPTCHA で保護されており、Google のプライバシーポリシーと利用規約が適用されます。

同じリポジトリのスキル

Reduce a failing test case, script, or input file to the smallest version that still reproduces a bug. Use when the user has a large reproduction and asks to minimize, bisect, or isolate it, or says things like "it stops failing when I remove half the file". Do not use when there is no reliable reproduction yet - help build one first, then minimize it.

日本語の概要は準備中です。原文の説明を表示しています。

Krusty84/SKILL.md-Inspector432026年8月1日 更新

Generate or update a CHANGELOG.md from merged commits and pull requests, grouped by change type and written for end users. Use when the user asks to write release notes, update the changelog, or summarize what changed between two versions or tags. Do not use for writing individual commit messages or for API-reference documentation.

日本語の概要は準備中です。原文の説明を表示しています。

Krusty84/SKILL.md-Inspector432026年8月1日 更新

Apply the team style guide to source files - naming conventions, comment style, and file organization. Use when the user asks to align code with the style guide or clean up naming.

日本語の概要は準備中です。原文の説明を表示しています。

Krusty84/SKILL.md-Inspector432026年8月1日 更新

Run the project's configured formatter (prettier, black, gofmt, rustfmt) on changed files and fix formatting-only CI failures. Use when the user asks to format code, fix a lint/format CI step, or normalize whitespace and import order. Do not use for logic changes or refactoring.

日本語の概要は準備中です。原文の説明を表示しています。

Krusty84/SKILL.md-Inspector432026年8月1日 更新

Clean and normalize messy CSV/TSV files - fix malformed rows, inconsistent headers, mixed encodings, stray delimiters, and duplicated records - and deliver a valid, verified file. Use when the user mentions a broken, messy, or malformed CSV, a file a spreadsheet tool refuses to open, or asks to deduplicate or normalize tabular data. Do not use when the deliverable is analysis or a chart rather than a cleaned file, or for Excel-native features like formulas and pivot tables.

日本語の概要は準備中です。原文の説明を表示しています。

Krusty84/SKILL.md-Inspector432026年8月1日 更新

Does data things.

日本語の概要は準備中です。原文の説明を表示しています。

Krusty84/SKILL.md-Inspector432026年8月1日 更新

Krusty84 のスキルをすべて見る

このスキルの問題を報告する