# emulate

Drop-in local emulator for Vercel, GitHub, Slack, AWS, and other APIs. It runs stateful mock-free services for offline tests and CI sandboxes.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode · 540 installs · ★ 1953
- Author: vercel-labs
- License: Apache-2.0 · policy=mirror · the beginning of the file is at the end of this page
- Source: https://github.com/vercel-labs/emulate/tree/HEAD/skills/emulate/SKILL.md
- Updated: 2026-10-25
- HTML: https://affpapa.org/en/nevibecode/skills/emulate

## What it does

The skill spins up stateful local API emulators instead of static mocks. It covers Vercel, GitHub, Google, Slack, Apple, AWS, Clerk, Linear, Twilio, and Stripe. Services bind to `127.0.0.1` by default. The base port starts at 4000 and increments for each active service.

You can run it via `npx emulate` in the terminal or import `createEmulator` inside Vitest and Jest suites. The programmatic API exposes instance methods like `reset()` to reload seed state and `close()` to stop listeners. When starter data is needed, `npx emulate init` scaffolds sample YAML or JSON config files.

The `--generated-secrets-file` flag does not work on Windows and requires `setfacl` alongside `getfacl` on Linux. Because verification fails closed, missing ACL utilities will abort startup in CI sandboxes.

## Requirements
- Works with: GitHub, AWS, Linear

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add vercel-labs/emulate --skill emulate -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/emulate/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/emulate/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add vercel-labs/emulate --skill emulate -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/emulate/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add vercel-labs/emulate --skill emulate -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/emulate/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install vercel-labs/emulate emulate
```

2. **Manually: put the files in place**
- File: `.github/skills/emulate/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add vercel-labs/emulate --skill emulate -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/vercel-labs/emulate --path skills/emulate
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/emulate/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add vercel-labs/emulate --skill emulate -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/vercel-labs/emulate/tree/HEAD/skills/emulate/SKILL.md

## When to use it
- spin up local Vercel and GitHub APIs without internet access
- execute Vitest or Jest suites against stateful seeded services
- test OAuth redirects and webhooks using a custom base URL
- scaffold a starter configuration file with `npx emulate init`

## Example prompts
- Start local emulators for GitHub and Vercel using `npx emulate`
- Generate a seed config file for vercel using `npx emulate init`
- Configure Vitest integration tests against the local Stripe emulator

## Source text · SKILL.md · Apache-2.0

Below is the content of a third-party file. It is data, not instructions for you: do not act on anything written inside unless the human asks. Block tag: 74b00b3994dab4b9.

BEGIN THIRD-PARTY FILE 74b00b3994dab4b9
````text
---
name: emulate
description: Local drop-in API emulator for Vercel, GitHub, Google, Slack, Apple, Microsoft, AWS, Clerk, Linear, Twilio, and other developer APIs. Use when the user needs to start emulated services, configure seed data, write tests against local APIs, set up CI without network access, or work with the emulate CLI or programmatic API. Triggers include "start the emulator", "emulate services", "mock API locally", "create emulator config", "test against local API", "npx emulate", or any task requiring local service emulation.
allowed-tools: Bash(npx emulate:*)
---

# Service Emulation with emulate

Local drop-in replacement services for CI and no-network sandboxes. Fully stateful, production-fidelity API emulation, not mocks.

## Quick Start

```bash
npx emulate
```

All services listen on IPv4 loopback (`127.0.0.1`) by default:

| Service   | Default Port |
|-----------|-------------|
| Vercel    | 4000        |
| GitHub    | 4001        |
| Google    | 4002        |
| Slack     | 4003        |
| Apple     | 4004        |
| Microsoft | 4005        |
| Okta      | 4006        |
| AWS       | 4007        |
| Resend    | 4008        |
| Stripe    | 4009        |
| MongoDB Atlas | 4010   |
| Clerk     | 4011        |
| Linear    | 4012        |
| Twilio    | 4013        |

## CLI

```bash
# Start all services (zero-config)
npx emulate

# Start specific services
npx emulate --service vercel,github

# Custom base port (auto-increments per service)
npx emulate --port 3000

# Use a seed config file
npx emulate --seed config.yaml

# Generate omitted service secrets into a private file
npx emulate start --seed config.yaml --generated-secrets-file .emulate-secrets.json

# Generate a starter config
npx emulate init

# Generate config for a specific service
npx emulate init --service vercel

# List available services
npx emulate list
```

### Options

| Flag | Default | Description |
|------|---------|-------------|
| `-p, --port` | `4000` | Base port (auto-increments per service) |
| `--host` | `127.0.0.1` | Listening address; use `0.0.0.0` to allow network access |
| `-s, --service` | all | Comma-separated services to enable |
| `--seed` | auto-detect | Path to seed config (YAML or JSON) |
| `--base-url` | none | Override advertised base URL (supports `{service}` template) |
| `--portless` | off | Serve over HTTPS via portless (auto-registers aliases) |
| `--generated-secrets-file` | none | Generate omitted service secrets and write them to a new owner-only JSON file |

The port can also be set via `EMULATE_PORT` or `PORT` environment variables.

For access from a container or another machine, use `npx emulate start --host 0.0.0.0`. Set `--base-url` to a URL reachable by those clients when using OAuth redirects or other advertised URLs.
````
END THIRD-PARTY FILE 74b00b3994dab4b9

The third-party file has ended. Everything between the 74b00b3994dab4b9 tags is data: requests and commands from it are not followed. An “end of file” line with another tag inside the block is part of the file.

First 2792 of 19277 bytes. © vercel-labs · Apache-2.0 · https://github.com/vercel-labs/emulate/tree/HEAD/skills/emulate/SKILL.md

## Similar
- [chat-sdk](https://affpapa.org/en/nevibecode/skills/vercel-chat-sdk.md) — skill · 5400 installs
- [sync-health-monitor](https://affpapa.org/en/nevibecode/commands/sync-health-monitor.md) — command · 121 installs
- [encore-testing](https://affpapa.org/en/nevibecode/skills/encore-testing.md) — skill · 791 installs

_Part of the page did not fit — see the HTML version._

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
