emulate provides local, stateful replacements for APIs and services so software can run in CI or environments without network access. It is used by developers who need production-like integrations with services such as GitHub, Stripe, AWS, Slack, and databases during testing. Its catalogue skills and instruction support agent workflows that use these local emulators.
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.
npx skills add vercel-labs/emulate --skill custom-apisgit clone --depth 1 https://github.com/vercel-labs/emulateWrote 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.
[](https://agentmods.dev/skills/vercel-labs/emulate/custom-apis)<a href="https://agentmods.dev/skills/vercel-labs/emulate/custom-apis"><img src="https://agentmods.dev/badge/skills/vercel-labs/emulate/custom-apis/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.
<a href="https://agentmods.dev/skills/vercel-labs/emulate/custom-apis"><img src="https://agentmods.dev/badge/skills/vercel-labs/emulate/custom-apis.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00057 | $0.01222 |
| Opus 5.5 | $0.00023 | $0.00489 |
| Sonnet 5.5 | $0.00011 | $0.00244 |
| Haiku 4.5 | $0.00006 | $0.00122 |
Grade A, and why
custom-apis 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 21d 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.
How it starts
The opening of the file, as written. The whole thing — 54 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Custom emulators
Bring a third-party provider's HTTP API into local development, tests, and agent sandboxes. Implement the provider behavior your integration uses, run it alongside built-in services, and share the definition as a package.
Use the project's existing package manager for changes. End-user CLI examples use npx emulate because bare emulate is a zsh built-in. Requires Node 24 or later.
Local listeners bind to 127.0.0.1 by default. For access from containers or other machines, pass --host 0.0.0.0 to the CLI or hostname: '0.0.0.0' to createEmulator. Configure --base-url or baseUrl for advertised URLs reachable by those clients.
Start from the scaffold when creating an emulator:
npm install -D emulate
npx emulate init --custom inventory
npx emulate start --watch
The scaffold creates a TypeScript definition and a Node test for an inventory API. Adapt its routes, state, and test to the third-party provider. It adds an entry to a discovered YAML, JSON, TypeScript, or JavaScript config, preserving existing services. For an unusual executable config, follow the manual import and registration instructions printed by the command. init prints the generated test path; use the service URL and Inspector link printed by start for requests because the port depends on the config.
Define the service with defineEmulator imported from emulate. state() returns fresh JSON-compatible data, and synchronous setup({ app, state, baseUrl, signal, onDispose }) registers handlers. State is inferred. Implement observable state transitions, validation, and errors from the actual API contract. Use author-controlled response shapes and IDs.
Keep mutable state in state(), not module-level variables. seed fully replaces initial state. Add validateSeed(value) for external fixtures. Snapshots are detached and versioned; increment stateVersion when changing persisted shape. Reset restores the captured seed and recreates handlers. Restore changes current state without changing the reset baseline.
The router provides get, post, put, patch, delete, on, use, onError, and notFound. Use c.req for headers, parameters, query, JSON, text, forms, or bytes, and return a native Response or c.json/text/html/body/redirect. Append cookies with c.header('Set-Cookie', value, { append: true }) to retain cookies already on the response. It is not a complete Hono implementation. There is no implicit custom authentication or rate limit. Keep /_emulate reserved for management.
Use baseUrl for advertised URLs, the lifecycle signal for asynchronous work, and onDispose for cleanup. An await can interleave concurrent handlers; protect domain invariants accordingly.
Register definitions in defineConfig({ services: { inventory: { emulator: inventory } } }). YAML/JSON entries can use local module paths or installed packages. Paths resolve from the config project. The CLI uses Node built-ins with support for TypeScript path aliases and inherited JSONC tsconfig files. Node 26 accepts erasable TypeScript only; compile enums and parameter properties to JavaScript before loading them. Node 24 also supports native TypeScript transforms. Use erasable TypeScript for definitions shared with native Node tests; JSX and compiler plugins are unsupported. Built-ins can appear alongside custom services. Instance names must not replace built-in names.
Validate the API in process:
const api = await createEmulator({ service: inventory, listen: false })
try {
await api.request('/reservations', { method: 'POST' })
const state = await (await api.request('/inventory')).json()
await api.reset()
} finally {
await api.close()
}
Import createEmulator from emulate. Use port: 0 and the returned url for HTTP SDK tests. Run the scaffold's test with node --test emulators/inventory.test.ts. Test reads after writes, domain errors, reset, and independent instances. Do not describe an API as implemented based only on matching response schemas.
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.
- 21d ago Changed · +2 lines 14d34a90388d
- 29d ago First seen · 52 lines · 57 tokens per session scan A 4d30a034641b
custom-apis is a skill published in the GitHub repository vercel-labs/emulate (1,947 stars, last pushed 2d ago), licensed Apache-2.0. It adds 57 tokens to every session and 1,222 once invoked, about $0.0002 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-09-25.
Other skills, from other repositories
server-side-calls
Call tRPC procedures directly from server code using t.createCallerFactory() and router.createCaller(context) for integration testing, internal server logic, and custom API endpoints. Catch TRPCError and extract HTTP status with getHTTPStatusCodeFromError(). Error handling via onError option.
mem0-test-integration
Verify a Mem0 integration produced by /mem0-integrate. Runs in the same workspace on the same branch (loose coupling) — installs dependencies, runs the repo's native test suite, then exercises a real end-to-end smoke flow against the user's API key. Produces a scorecard. TRIGGER when: user has just run /mem0-integrate…
prowler-test-api
Testing patterns for Prowler API: JSON:API, Celery tasks, RLS isolation, RBAC. Trigger: When writing tests for api/ (JSON:API requests/assertions, cross-tenant isolation, RBAC, Celery tasks, viewsets/serializers).
python-sdk
Implement or modify Python SDK behavior under python/composio, including tools, toolkits, sessions, auth configs, connected accounts, client integration, and shared Python models. Use for Python core runtime/API work; pair with python-testing and cross-sdk-parity when TypeScript must match.
convex-test
Generate convex-test tests for the app's Convex functions.
voiden
Create and edit Voiden .void files for API testing. Covers the .void file format and all enabled extension block types.