api-endpoint-tester
Skill3 starsChanged 4 months agoMITView on GitHub
curl-based smoke tests for any API — auth enforcement, happy path, error cases, and latency — reported in a pass/fail results table. Use when the user says "test my API", "check the endpoints", "does auth actually work", "smoke test the backend", or shipped/changed API routes. Don't use for chasing one known bug to its root cause — use bug-triage-protocol.
- Sends data out
1 other project uses a version of this.
Adopted by
Most recently taken up by
- Lethe044/agentskill-kittheir own version, first seen Nov 1, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- Lethe044/agentskill-kit★ 48same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository74 other files it gives its agents.
- agent-eval-harnessSkill
- context-budget-managerSkill
- incident-rollbackSkill
- memory-hygieneSkill
- model-cost-optimizerSkill
- prompt-debuggerSkill
- skill-author-coachSkill
- third-party-skill-vetterSkill
- bug-triage-protocolSkill
- changelog-release-notesSkill
- docs-readme-writerSkill
- env-secrets-hygieneSkill
- github-pr-reviewSkill
- git-ship-flowSkill
- lovable-brief-writerSkill
- supabase-migration-writerSkill
- vercel-deploy-checkSkill
- cold-outreach-sequencerSkill
- competitor-pricing-scanSkill
- contract-redline-scanSkill
- customer-support-inboxSkill
- invoice-runnerSkill
- kpi-dashboard-weeklySkill
- lead-research-dossierSkill
- payment-reconciliationSkill
- pipeline-trackerSkill
- proposal-builderSkill
- stripe-payment-linkSkill
- testimonial-harvesterSkill
- weekly-revenue-reportSkill
- brand-voice-guardianSkill
- case-study-builderSkill
- content-repurposerSkill
- deep-research-briefSkill
- email-nurture-sequenceSkill
- landing-page-copywriterSkill
- linkedin-content-packSkill
- newsletter-assemblerSkill
- seo-blog-writerSkill
- social-listening-reportSkill
- x-thread-builderSkill
- youtube-script-writerSkill
- budget-guardrailsSkill
- ceo-operating-doctrineSkill
- delegation-protocolSkill
- editor-personaSkill
- heartbeat-standupSkill
- hiring-briefSkill
- ops-agent-personaSkill
- researcher-personaSkill
- sales-agent-personaSkill
- support-agent-personaSkill
- weekly-retroSkill
- writer-personaSkill
- calendar-conciergeSkill
- decision-journalSkill
- email-triageSkill
- file-organizerSkill
- habit-trackerSkill
- inbox-zero-sprintSkill
- The first 60 shown.
The file
Files
API Endpoint Tester
Systematic smoke tests with nothing but curl and python3. For every endpoint, four questions get an evidence-backed answer: does it reject strangers (auth), does it work when used right (happy path), does it fail politely when used wrong (errors), and is it fast enough (latency)? The most important test is the one vibe-built apps skip: the request that should be rejected.
When to Use
- New or changed API routes need a confidence check before/after deploy.
- User suspects an endpoint is unprotected ("can anyone call this?").
- Building the results table for a launch checklist or PR.
- Not for: isolating a known bug — use
bug-triage-protocol. Not for whole-site deploy verification — usevercel-deploy-check.
Quick Reference
| Action | Command / Call |
| Status + latency, one line | curl -s -o /dev/null -w "%{http_code} %{time_total}s\n" "$BASE/api/items" |
| Unauthenticated probe | curl -si "$BASE/api/items" | head -1 (expect 401/403, NOT 200) |
| Authenticated GET | curl -s "$BASE/api/items" -H "Authorization: Bearer $TOKEN" |
| POST happy path | curl -si -X POST "$BASE/api/items" -H "Authorization: Bearer $TOKEN" -H "Content-Type: application/json" -d '{"name":"test"}' |
| Malformed-body probe | curl -si -X POST "$BASE/api/items" -H "Authorization: Bearer $TOKEN" -H "Content-Type: application/json" -d '{"name":' (expect 400, not 500) |
| Pretty-print JSON | append | python3 -m json.tool (or | jq .) |
| Latency, 5 runs | for i in 1 2 3 4 5; do curl -s -o /dev/null -w "%{time_total}\n" "$BASE/api/items"; done |
Procedure
- Precheck —
command -v curl python3. SetBASE(prefer a preview/staging URL; confirm explicitly with the user before running POST/DELETE tests against production data). Get a real$TOKEN(browser devtools → Network → copy the Authorization header from a logged-in request). Export both as env vars — never paste tokens into files or the transcript. - Inventory — list endpoints to test: from the code (
grep -rE "app\.(get|post|put|delete)|export async function (GET|POST|PUT|DELETE)" --include="*.ts" -l api/ app/api/ src/ 2>/dev/null), the router directory listing, or the user. For each: method, path, auth required?, sample valid body. - Auth pass (first, always) — hit every protected endpoint with no token, then with garbage (
-H "Authorization: Bearer nonsense"). Expect 401/403 both times. A 200 with real data here is a critical finding — report it immediately, before finishing the sweep. Where multi-user data exists, also try user A's token against user B's resource id — expect 403/404. - Happy path — one valid call per endpoint with
$TOKENand a valid body. Expect 2xx and a sane JSON shape (spot-check fields viapython3 -m json.tool). For POSTs, use obviously-test data ("name":"smoke-test-<date>") and note created ids for cleanup. - Error cases — per write endpoint: malformed JSON (expect 400), missing required field (expect 400 with a useful message), nonexistent id (expect 404). Any 500 on bad input is a fail — servers should never crash on user input.
- Latency — 5 runs per key endpoint (first run is cold start; report it separately). Bar: median under 1s for simple reads; over 3s is a fail worth a
bug-triage-protocolfollow-up. - Cleanup + deliver — delete test rows you created (confirm with the user before any DELETE call). Fill the results table; every FAIL gets the exact repro command so the fix loop starts instantly.
Output Template
## API Smoke Test — <base url> — <date>
Token user: <role/email> Environment: preview | production (confirmed)
| Endpoint | Test | Expected | Got | Latency (median) | Result |
|---|---|---|---|---|---|
| GET /api/items | no token | 401 | 401 | — | PASS |
| GET /api/items | valid token | 200, array | 200 | 0.31s | PASS |
| GET /api/items/:id | other user's id | 404 | 200 ⚠️ | — | FAIL (data leak) |
| POST /api/items | malformed JSON | 400 | 500 | — | FAIL |
Summary: 7 PASS / 2 FAIL
Critical: GET /api/items/:id returns other users' data — fix before anything else (see supabase-migration-writer for RLS).
Repro for each FAIL: <exact curl command>
Cleanup: test rows <ids> deleted ✅Pitfalls
- Testing only with a valid token — the sweep proves the API works but not that it's protected; the unauthenticated probe is the security test. Recovery: auth pass runs first and covers every endpoint, every time.
- Expired token mid-sweep — everything starts returning 401 and looks like mass failure. Recovery: when a previously-passing endpoint flips to 401, re-grab a fresh token and re-run from the first failure, not from scratch.
- Cold start read as slow API — first request 4s, rest 0.3s. Recovery: always run 5 and report median + cold separately; judge on the median.
- Smoke-testing writes against production — test rows in real users' views. Recovery: prefer preview; on prod, only obviously-labeled test data, record every created id, delete them (with confirm) before reporting done.
- JSON "looks fine" but shape is wrong — 200 with
{"items": null}still breaks the frontend. Recovery: assert the shape, e.g.curl -s ... | python3 -c "import json,sys; d=json.load(sys.stdin); assert isinstance(d['items'], list); print('shape ok')".
Verification
- Every protected endpoint probed with no token AND a garbage token (401/403 both)
- Cross-user access attempted where multi-user data exists
- Every write endpoint probed with malformed input; zero 500s
- Latency reported as median-of-5 with cold start noted
- Every FAIL row includes its exact repro command
- Test data cleaned up (user confirmed the deletes); no tokens echoed into the transcript
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

