service-virtualization

service-virtualization is a skill for Claude Code, Codex from petrkindlmann/qa-skills. It costs 178 tokens per session (4,470 once invoked), scanned A, original, MIT.

A guide for replacing real outside services with test-only stand-ins, such as HTTP stubs, recorded responses, or temporary databases. It helps choose the right approach for each dependency.

In plain words
What is it for?
Use it to isolate APIs, databases, caches, and queues; simulate delays and connection failures; replay recorded API interactions; and prevent real service calls from escaping CI.
Why use it?
Tests can become slow, flaky, expensive, or unsafe when they contact real payment, email, authentication, or data services. This keeps those calls isolated, including in continuous integration (CI).

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to isolate APIs, databases, caches, and queues; simulate delays and connection failures; replay recorded API interactions; and prevent real service calls from escaping CI.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/petrkindlmann/qa-skills/service-virtualization
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add petrkindlmann/qa-skills --skill service-virtualization
Clone the repo
git clone --depth 1 https://github.com/petrkindlmann/qa-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for service-virtualization

README.md
[![agentmods](https://agentmods.dev/badge/skills/petrkindlmann/qa-skills/service-virtualization/github.svg)](https://agentmods.dev/skills/petrkindlmann/qa-skills/service-virtualization)
Your own site
<a href="https://agentmods.dev/skills/petrkindlmann/qa-skills/service-virtualization"><img src="https://agentmods.dev/badge/skills/petrkindlmann/qa-skills/service-virtualization/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for service-virtualization

Your own site · 80×15
<a href="https://agentmods.dev/skills/petrkindlmann/qa-skills/service-virtualization"><img src="https://agentmods.dev/badge/skills/petrkindlmann/qa-skills/service-virtualization.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 178 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,470 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • Socket pass 23 Oct 2026
  • Snyk pass 23 Oct 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00178 $0.04470
Opus 5.5 $0.00071 $0.01788
Sonnet 5.5 $0.00036 $0.00894
Haiku 4.5 $0.00018 $0.00447

Measured 1mo ago against content hash dcdab0269e78, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

service-virtualization scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/service-virtualization/SKILL.md · 342 lines

How it starts

The opening of the file, as written. The whole thing — 342 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Quick Route

Situation Go to
Node/browser test hitting an external HTTP API MSW → references/msw.md
Browser page driven by Playwright, calling its own backend under /api/* page.route in the test runner (reverse registration order, route.fallback() to chain, an unhandled-request guard that aborts and logs); MSW browser mode needs the application to serve mockServiceWorker.js, which a frozen build does not. Cassettes: references/record-replay.md
Polyglot CI, complex matching, or you need a standalone stub server WireMock → references/wiremock.md
Dependency is a DB / cache / queue Testcontainers → references/testcontainers.md
Testing timeouts, latency, connection resets Toxiproxy → references/toxiproxy.md
Bootstrapping stubs from a real API, or a multi-step baseline Record-replay → references/record-replay.md
Wiring any of these into GitHub Actions references/ci.md
Not sure which to reach for Decision Tree (below)

Discovery Questions

Check .agents/qa-project-context.md first — if it exists and is filled in, use it (an unfilled template answers nothing), respect existing mocking conventions, and skip anything answered there. Then:

  • How many external dependencies does the system call, and which are painful in tests? Rate-limited, slow, flaky, or paid dependencies are the highest-priority virtualization candidates; list payment, email, auth, and third-party data sources.
  • What testing levels need isolation? Unit tests want fast in-process mocks; integration tests want HTTP-level stubs; E2E wants real or containerized services — the level sets the strategy.
  • Does the provider offer an official test mode or sandbox? Stripe test mode, Twilio test creds, etc. beat any home-grown stub for fidelity — prefer them where they exist.
  • Do you have contracts with these dependencies? If yes, contract tests keep stubs in sync; see contract-testing. If no, mocking what you don't own is a known risk (Core Principle 3).
  • Docker available in CI? No Docker steers you to MSW (in-process); Docker unlocks WireMock, Testcontainers, and Toxiproxy.

Read the full file on GitHub · 342 lines

Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed · +10 lines dcdab0269e78
  2. 1mo ago Changed · +22 lines 9b2cae1125d2
  3. 3mo ago First seen · 310 lines · 178 tokens per session scan A 51ec9e2d83af

Subscribe to this mod's changes

service-virtualization is a skill published in the GitHub repository petrkindlmann/qa-skills (318 stars, last pushed 16d ago), licensed MIT. It adds 178 tokens to every session and 4,470 once invoked, about $0.0007 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

service-virtualization compared with skills from other repositories

service-virtualization next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
service-virtualizationpetrkindlmann/qa-skillsSkill31816d agoMITA178Claude Code, Codex
platform-engineeringmagnus919/agent-skillsSkill203yesterdayMITA105Claude Code, Codex
woodpecker-cimagnus919/agent-skillsSkill203yesterdayMITA87Claude Code, Codex
github-runnermagnus919/agent-skillsSkill203yesterdayMITA76Claude Code, Codex
CI Pipeline OptimizerPramodDutta/qaskillsSkill25329d agoMITA29Claude Code, Codex
Flaky Test QuarantinePramodDutta/qaskillsSkill25329d agoMITA32Claude Code, Codex
CI/CD Pipeline AdvancedPramodDutta/qaskillsSkill25329d agoMITA45Claude Code, Codex