api-integration
/api-integration
Execute user-defined API calls during test runs, from the project's integration/ catalog. Use whenever a test step needs an HTTP call: verify via API that a UI action persisted, check an endpoint's response, or seed test data through a service. Triggers on spec steps starting with "api:", or requests like "verify via API", "call the endpoint", "check the response". The agent executes ONLY requests the user has defined in a *_api.json catalog (searched recursively under integration/) — it never composes its own HTTP requests.
- Author
- mhmdelgazzar ↗
- Repository
- agentex ↗
- Licence
- MIT
- Last repository change
- 26.10.2026
Assessment and security
- Files in this package
- 5
- Scripts
- 2
- HTML comments
- 0
- URLs in SKILL.md
- 1
No signals detected. Repository changed on 26.10.2026, without references to retired models or APIs.
MIT, open: use and modify while retaining author attribution.
- 2 scripts in this package. Review them before installing, as Claude may execute them.
Scripts: scripts/run_api.js, scripts/run_api.test.js
What it does and when to use it
Execute user-defined API calls during test runs, from the project's integration/ catalog. Use whenever a test step needs an HTTP call: verify via API that a UI action persisted, check an endpoint's response, or seed test data through a service. Triggers on spec steps starting with "api:", or requests like "verify via API", "call the endpoint", "check the response". The agent executes ONLY requests the user has defined in a *_api.json catalog (searched recursively under integration/) — it never composes its own HTTP requests.
Triggers from the description
Original author description
Execute user-defined API calls during test runs, from the project's integration/ catalog. Use whenever a test step needs an HTTP call: verify via API that a UI action persisted, check an endpoint's response, or seed test data through a service. Triggers on spec steps starting with "api:", or requests like "verify via API", "call the endpoint", "check the response". The agent executes ONLY requests the user has defined in a *_api.json catalog (searched recursively under integration/) — it never composes its own HTTP requests.
How it works
- Role
- The catalog — the ONLY requests you may execute
- Step syntax in test specs
- Where the target comes from
- Safety rules (also enforced by the runner)
- Evidence
- Preflight
SKILL.md preview
---
name: api-integration
description: >
Execute user-defined API calls during test runs, from the project's integration/ catalog.
Use whenever a test step needs an HTTP call: verify via API that a UI action persisted,
check an endpoint's response, or seed test data through a service. Triggers on spec steps
starting with "api:", or requests like "verify via API", "call the endpoint", "check the
response". The agent executes ONLY requests the user has defined in a *_api.json catalog
(searched recursively under integration/) — it never composes its own HTTP requests.
---
# API Integration — cataloged API steps
## Role
You execute the API call a test step asks for, strictly from the project's `integration/*_api.json`
catalog. You never compose your own HTTP request or call an endpoint outside the catalog.
Lets test scenarios call APIs **by name**, from definitions the user wrote. Execution is done
by the bundled runner script (deterministic, enforces the safety rules in code):
```
node ${CLAUDE_PLUGIN_ROOT}/skills/api-integration/scripts/run_api.js \
--entry <file-name>.<request-name> --param key=value [--param ...] \
[--expect-status 200] [--expect-field <dot.path>] [--expect-equals <dot.path>=<value>] \
[--env <environment-name>] --log <SESSION_DIR>/logs/<scenario>-<entry>.log
```
It loads the catalog, validates params, resolves env vars, performs the request, writes the
evidence log, checks expectations, and prints one JSON line:
`{"result":"PASS|FAIL|BLOCKED", ...}` (exit 0/1/2). Read
**`${CLAUDE_PLUGIN_ROOT}/skills/api-integration/references/api-requests.md`** for the catalog
format, curl fallback (if node/script fails), and assertion details — including
`--no-auth`, `--expect-contains`, `--omit`, typed `$param` body nodes and `auth.tokenStore`
(a token captured by the suite wizard).
## The catalog — the ONLY requests you may execute
Definitions live in the **consumer project** under **`./integration/`** (`<service>_api.json`),
searched recursively — hand-written catalogs typically sit flat at `integration/`, while
catalogs generated by `swagger-import` are co-located with their suite under
`integration/api_test_suites/<service>/`. Either location works; `run_api.js` finds the file
by matching the catalog's internal `"name"`, not by path. `node_modules/` and dot-directories
are not searched. Two files declaring the same `"name"` is **BLOCKED** (both files are listed)
— catalog names must be unique across `integration/`.
- If the folder/file is missing when a step needs it, scaffold from
`${CLAUDE_PLUGIN_ROOT}/skills/api-integration/templates/sample_api.json` (never overwrite),
then ask the user to define their entries.
- **Hard rule:** a step naming a request not defined in the catalog is **BLOCKED** — report
which definition is missing. Never improvise a request.
## Step syntax in test specs
```
api: <file-name>.<request-name>(param=value, ...) → <expectation>
```
Example: `api: sample-api.get-todo(id=1) → expect HTTP 200 and title present`
## Where the target comes from
A catalog's optional top-level `"target"` decides (full rules in the reference):
- **`"catalog"`** — only the catalog's own `baseUrl` refs and `auth`; the environment's `api`
block is ignored for it, base URL and token both. Every `swagger-import`ed catalog carries
it. An unset ref is BLOCKED; it never falls back to the environment's host.
- **`"environment"`** — the **`environments/<env>.json` `api` block** of the active
environment (`--env <name>`, omitted = the project's `defaultEnvironment`):
`{ "baseUrl": "https://…", "token": { "envSecret": "API_TOKEN" } }`. The token reference is
resolved from `.env` — never a value in JSON. Set it on a hand-written catalog whose
`baseUrl` uses another variable but should still follow `--env`.
- **No `target`** — the environment's `api` block applies **only** when the catalog's
`baseUrl` is absent/empty or exactly `"${API_BASE_URL}"` (the project default); any other
`baseUrl` (e.g. `"${PETSTORE_BASE_URL}"`) keeps its own `baseUrl` and `auth`, and the
environment token is never sent to it.
- Any other value → BLOCKED, naming the catalog and the allowed values.
When the environment has no `api` block, the catalog's own `baseUrl` refs and `auth` are used
(legacy fallback) — old projects keep working untouched. An unknown `--env` is BLOCKED
whatever the target.
## Safety rules (also enforced by the runner)
- Writes (POST/PUT/DELETE) run if cataloged — the catalog is the authorization.
- Secrets stay in env — catalog files hold env-var *names* (`tokenEnv`); never print values.
- Missing param/env → BLOCKED (sequential: ask the user instead).
## Evidence
Runner writes status + headers + body to the `--log` path (under the session's `logs/`).
Expectation mismatch = **FAIL** defect with that log as evidence, reported in the standard
defect format.
## Preflight
The runner needs only Node (already required by the plugin). For the curl fallback, preflight
per the reference.
Files in this package (5)
- SKILL.md 5 KB
- references/api-requests.md 10 KB
- scripts/run_api.js 20 KB
- scripts/run_api.test.js 41 KB
- templates/sample_api.json 1 KB
Versions
| Repository | Score | Licence |
|---|---|---|
| This page · mhmdelgazzar/agentex | 100 | MIT |
| facebook/agentic-tools | 100 | MIT |
| AutumnsGrove/Lattice | 100 | AGPL-3.0 |
| srstomp/pokayokay | 100 | MIT |
| ajyadav013/claude-kit | 100 | MIT |
| ajyadav013/claude-kit | 100 | MIT |
| seb1n/awesome-ai-agent-skills | 100 | MIT |
| shurikentrade/shuriken-skills | 100 | MIT |
| LambdaTest/agent-skills | 95 | MIT |
Database snapshot: 13.11.2026 · package version 61e54ac738af (SHA-256 digest of the entire package)
Downloads in the last 30 days: 0 · ranking
Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.
Similar skills
- 100db-integration
Execute user-defined database queries during test runs, from the project's integration/ catalog (SQL Server via sqlcmd). Use whenever a test step needs a DB check: verify a row was created/updated by a UI action, check column values, or seed test data. Triggers on spec steps… - 100api-response-cacher
Configure api response cacher operations. Auto-activating skill for API Integration. Triggers on: api response cacher, api response cacher Part of the API Integration skill category. Use when working with APIs or building integrations. Trigger with phrases like "api response… - 90add-api-endpoint
Use when a ticket asks to add or extend an HTTP/API endpoint — a new route, handler, or RPC method — with request validation and a defined response. Invoke for "add a POST /things endpoint", "expose a list API", or "add a field to the X response". - 100swagger-import
Generate an API catalog + suite of test cases (integration/api_test_suites/<service>/) from a Swagger 2.0 or OpenAPI 3.x JSON document. Use for /import-swagger, or requests like "import this swagger doc", "generate endpoint tests from this OpenAPI spec", or the guided wizard… - 100api-endpoint
Rules for HTTP API endpoints. Use when adding or changing any endpoint (route, request or response shape, status codes), especially login and ones that read or change other users' data. - 100integration-test-generator
Generate integration test generator operations. Auto-activating skill for API Integration. Triggers on: integration test generator, integration test generator Part of the API Integration skill category. Use when writing or running tests. Trigger with phrases like "integration…