agentleFS
dmzoneilldmzoneill/skills/api-smoke-test/SKILL.md

api-smoke-test

Skill2 starsChanged 19 days agoApache-2.0View on GitHub

Run smoke tests against API endpoints to verify availability and performance. Use after deploy_to_ephemeral, release_to_prod, or when debugging API connectivity.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Verify API availability and performance.

    line 8

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

API Smoke Test

Verify API availability and performance. Validates deploy_to_ephemeral and release_to_prod.

Inputs

InputTypeDefaultPurpose
base_urlstringrequiredBase URL (e.g., https://api.example.com)
environmentstringstagestage, production, ephemeral
auth_tokenstring""Bearer token for auth endpoints
fail_on_slowboolfalseFail if response > threshold

Workflow

1. Load Persona

  • persona_load("developer")

2. Check Known Issues

  • check_known_issues("curl", "")
  • check_known_issues("api", "")

3. TLS Check

  • openssl_s_client(host="{{ base_url }}") — verify TLS
  • Parse: "verify return code: 0" → ok, extract TLS version

4. HTTP Endpoint Checks

  • curl_get(url="{{ base_url }}/") — root
  • curl_get(url="{{ base_url }}/health") — health
  • curl_head(url="{{ base_url }}/")
  • curl_headers(url="{{ base_url }}/")
  • curl_timing(url="{{ base_url }}/") — latency
  • curl_post(url="{{ base_url }}/api/v1/ping") — if endpoint exists
  • curl_put(url="{{ base_url }}/api/v1/ping") — if endpoint exists
  • curl_delete(url="{{ base_url }}/api/v1/ping") — if endpoint exists

5. Parse Results

  • HTTP status 200–499 → pass
  • Timing: total > 2s → slow
  • Count passed/total endpoints

6. Failure Learning

  • "could not resolve" → learn_tool_fix("curl_get", "could not resolve", "DNS resolution failed", "Verify hostname and DNS")
  • "connection refused" → service not running
  • "no route to host" → vpn_connect() for internal APIs

7. Memory

  • memory_session_log("API smoke test on {{ base_url }}", "environment={{ environment }}, passed=X/Y")

Error Recovery

ErrorAction
"could not resolve"Verify hostname, DNS
"connection refused"Check API service running
"no route to host"vpn_connect() for internal APIs

Output

Report: endpoint results table (passed/total), TLS version, response timing (total, connect, slow flag), response headers, known issues. If failures: suggest skill_run("debug_prod", ...).

Chains To

  • debug_prod, create_jira_issue, investigate_alert

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.