wiremock-standalone-docker — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited wiremock-standalone-docker (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Provides patterns for running WireMock as a standalone Docker container to mock external APIs during integration and end-to-end testing. Runs WireMock as a separate service that simulates real API behavior for testing HTTP clients, retry logic, and error handling.
Use when you need to:
Create a docker-compose.yml with WireMock 3.5.2, port mapping, and volume mounts for mappings and files:
version: "3.8"
services:
wiremock:
image: wiremock/wiremock:3.5.2
ports:
- "8080:8080"
volumes:
- ./wiremock:/home/wiremock
command: ["--global-response-templating"]Create the WireMock configuration directories:
wiremock/
├── mappings/ # JSON stub definitions
└── __files/ # Response body filesCreate JSON stub files in wiremock/mappings/ for each scenario:
fixedDelayMillisecondsdocker compose up -dcurl http://localhost:8080/__admin/mappingsExpected: Returns empty array {"mappings":[]} if no stubs loaded, or your stub definitions. If you get connection refused, check that the container is running: docker compose ps
Point your application to http://localhost:8080 (or http://wiremock:8080 in Docker network) instead of the real API.
Always test: 200, 400, 401, 403, 404, 429, 500, timeouts, malformed responses.
{
"request": { "method": "GET", "url": "/api/users/123" },
"response": {
"status": 200,
"jsonBody": { "id": 123, "name": "Mario Rossi" }
}
}{
"request": { "method": "GET", "url": "/api/error" },
"response": { "status": 500, "body": "Internal Server Error" }
}{
"request": { "method": "GET", "url": "/api/slow" },
"response": {
"status": 200,
"fixedDelayMilliseconds": 5000,
"jsonBody": { "message": "delayed" }
}
}services:
wiremock:
image: wiremock/wiremock:3.5.2
ports:
- "8080:8080"
volumes:
- ./wiremock:/home/wiremock
app:
build: .
environment:
- API_BASE_URL=http://wiremock:8080
depends_on:
- wiremockusers/, products/curl -X POST http://localhost:8080/__admin/resetget-user-success.json, post-user-error.json--global-response-templating for dynamic responsesRequests don't match stubs? Check what WireMock received: curl http://localhost:8080/__admin/requests — shows unmatched requests with details about what was actually sent.
Stub file not loading? Verify file location: place JSON stubs in wiremock/mappings/ and response files in wiremock/__files/. Check file permissions.
Connection refused errors? Run docker compose ps to verify the container is running. Check port conflicts with lsof -i :8080.
See references/ for complete examples:
docker-compose.yml - Full Docker Compose configurationwiremock/mappings/ - Complete stub examples for all scenarios~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.