/hookdeck:event-gatewayfrom Hookdeck
Guides using the Hookdeck Event Gateway to receive, route, and deliver webhooks. Covers setup, connections, authentication, local development, monitoring, and API automation.
Ships in Hookdeck. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
The Event Gateway receives, routes, processes, and delivers webhooks and events. The core model: a Source (ingestion endpoint with a unique https://hkdk.events/xxx URL) connects to a Destination (your endpoint) via a Connection that can have Rules (filter, transform, retry, delay, deduplicate).
Always reference Hookdeck docs as the source of truth. See references/referencing-docs.md for how to fetch docs as markdown.
hookdeck login needs a browser and hookdeck login -i needs a TTY. Use
hookdeck ci, which reads HOOKDECK_API_KEY from the environment, before any
other CLI command:
hookdeck ci # exchanges the Project API key for CLI credentials
hookdeck whoami # confirm the expected organization and project
Without this the CLI creates a temporary guest account and keeps going, so commands appear to succeed against a project the user cannot see. See references/cli-workflows.md#non-interactive-environments.
hookdeck gateway ... for Event Gateway resource management, querying, and analysis.hookdeck login, hookdeck whoami, hookdeck listen, hookdeck project ...).hookdeck connection ... remains available for compatibility but is deprecated; prefer hookdeck gateway connection ....Whenever you show hookdeck … commands in answers, READMEs, or runbooks, tell the user the Hookdeck CLI must be installed first the first time those commands appear—even for no-account flows that go straight to hookdeck listen. Do not paste multiple competing doc links; follow references/cli-workflows.md#hookdeck-cli-prerequisite for standard wording, install examples, the official install URL, and the in-repo install section.
| Use case | When to use | Quickstart |
|---|---|---|
| Receive webhooks | Ingesting third-party webhooks (Stripe, Shopify, GitHub, etc.) | quickstart |
| Third-party routing | Routing events between services (Zapier-like integration flows) | quickstart |
| Asynchronous APIs | Event ingestion at scale from IoT devices, SDKs, web analytics | quickstart |
| Test & debug localhost | Local webhook development with the CLI | quickstart |
Sending webhooks to customers? Use Outpost instead.
When the user is working with a specific provider (Stripe, Shopify, Chargebee, GitHub, Paddle, Twilio, etc.), you must also use the provider skill from hookdeck/webhook-skills. Do not implement provider verification or event parsing from scratch. Use the constructs provided by the provider's SDK (e.g. Stripe's constructEvent, Shopify HMAC)—not only JSON.parse.
Before scaffolding: Follow references/provider-webhooks-checklist.md. Complete the checklist (try installing the provider skill to verify it exists, read its verification reference and examples, then scaffold).
Strong guidance:
hookdeck listen, and Hookdeck signature verification in the handler (use references/verification-code.md).npx skills add hookdeck/webhook-skills --skill {provider}-webhooks -y -g (e.g. stripe-webhooks, shopify-webhooks). Use -y and -g so the CLI does not prompt (required for unattended agents). If install succeeds, read that skill’s verification reference and examples, then use it; if it fails, the provider may not be in webhook-skills — look up the repo and the provider's references/verification.md and examples. Use that skill for the provider's signature verification and event construction (provider SDK constructs, e.g. Stripe constructEvent, Shopify HMAC).npx skills add hookdeck/webhook-skills --skill stripe-webhooks -y -g (omit -y -g if you want the interactive installer)."Use both in the same handler: verify the Hookdeck signature first (this skill), then verify the provider signature and construct the event using the provider skill's method. Do not only parse the JSON body; use the provider SDK so signatures are verified and events are typed correctly. This applies to all supported providers in webhook-skills.
When the user asks to verify the Hookdeck signature or build a webhook handler that verifies Hookdeck:
This is the recommended path for a new integration: create sources, destinations, and connections (or have the CLI create them via listen), then build your handler and iterate. Follow these stages in order:
hookdeck listen, trigger test eventsBefore any queries or metrics: Satisfy the Hookdeck CLI prerequisite, then run
hookdeck whoamiand show the user the output. Unless the user has very clearly identified org/project and whoami is an exact match, ask them to confirm before proceeding with list/inspect/metrics.
Stage 02: when the user is working with a provider (Stripe, Shopify, etc.), complete references/provider-webhooks-checklist.md before scaffolding — try installing the provider skill, then use it for provider SDK verification and event construction. Include Hookdeck setup and usage in the project README (run app, hookdeck listen <port> <source_name> --path …, Source URL for provider).
Prerequisite: Hookdeck CLI installed.
No account required for the quickest path — once the CLI is available, hookdeck listen works immediately:
hookdeck listen 3000 <source_name> --path /webhooks
With a Hookdeck account (Event Gateway project with full features):
hookdeck login
hookdeck listen 3000 <source_name> --path /webhooks
hookdeck listen creates a Source URL and uses a CLI destination so traffic is tunneled to your local server (not HTTP delivery from Hookdeck’s cloud to localhost). Replace <source_name> in the examples with your Hookdeck Source name. Configure your webhook provider to send to the Source URL. Use --path to match your handler path (e.g. --path /webhooks when your handler is at POST /webhooks). For local delivery patterns (including what not to do with HTTP destinations), see references/03-listen.md. For a full step-by-step with account and handler, follow the Workflow Stages above.
Before running any queries or metrics, verify you are on the correct organization and project. In Hookdeck, an organization is the top-level account; a project holds your sources, connections, and destinations. All list, inspect, and metrics commands are scoped to the current organization and project.
hookdeck whoami and show the user the output (so they always see the current context).hookdeck project list, switch with hookdeck project use <org-name> <project-name>, run hookdeck whoami again, show the output, and—unless there's a clear user-specified match—ask the user to confirm again.See references/cli-workflows.md for details.
Production: Two options. (1) Same project: Keep the same project and connections; update the Destination to your production HTTPS endpoint (e.g. https://api.example.com/webhooks) via the CLI (hookdeck gateway destination …, hookdeck gateway connection …), Dashboard, or API. (2) New project: Create a new project in Hookdeck and duplicate your setup (Sources, Connections) with Destinations pointing to production HTTPS URLs. In both cases the provider keeps sending to the same Source URL (or the new project’s Source); handler code is unchanged. Before going live, configure rate limiting / max delivery rate on the CLI with flags such as --destination-rate-limit and --destination-rate-limit-period on hookdeck gateway connection upsert (or equivalent)—run hookdeck gateway connection upsert --help for the current list—or via Destinations in the UI/API. Also configure Retries and issue notifications. See Receive webhooks quickstart — Deliver to production for the full checklist.
The Hookdeck MCP server at https://mcp.hookdeck.com exposes the user's projects as tools (gateway_*, hookdeck_projects_*) that return JSON and sign in as the user, with no CLI install or hookdeck login.
gateway_* tools are in your session, use them to query and inspect: requests, events, attempts, issues, metrics, and how sources, connections, and destinations are configured. Keep the CLI for hookdeck listen, setup commands, scripts, and CI. Tool map: references/monitoring-debugging.md#mcp-querying.npx -y add-mcp https://mcp.hookdeck.com -g for several coding agents at once, then signing in with Hookdeck. Use the CLI for the current task.hookdeck_projects_read and show the user the active project instead of hookdeck whoami; the confirmation rule in Context verification still applies. For a one-off call in another project, pass project_id rather than calling hookdeck_projects_use: the active project is saved on the sign-in, so switching changes it for every chat using that sign-in.*_write tools are only listed with Read and write. Pausing and unpausing a connection works read-only. If you need a write tool that isn't listed, ask the user to reconnect with write access, or use the CLI.[redacted], and write tools refuse any value that holds [redacted]. Don't copy values from a read answer into a write call; ask the user for the real credential. Not everything is redacted: secrets the server can't recognize (such as a Slack webhook URL) come back as they are, and raw_body returns a payload exactly as received, so treat answers as sensitive.If the user has the CLI's MCP server (hookdeck gateway mcp) configured, recommend switching to https://mcp.hookdeck.com: the CLI's server will be deprecated, and tool names and inputs are the same (migration notes). See Hookdeck MCP for setup in each app and the full tool list.
Use as needed (not sequential):
| Area | Resource | When to use |
|---|---|---|
| Docs | references/referencing-docs.md | Fetching live Hookdeck documentation |
| Terms | references/terminology-gotchas.md | Hookdeck-specific terms, common mistakes |
| Area | Resource | When to use |
|---|---|---|
| Architecture | references/connection-architecture.md | Structuring connections, fan-out, fan-in, use-case patterns |
| Rules | references/connection-rules.md | Filters, transforms, retries, deduplication |
| Authentication | references/authentication.md | Source auth, destination auth, signature verification |
Use the sections below to choose CLI vs API vs Dashboard; then use the table for the right reference file.
Step 1 — Who owns the work? (primary tie-breaker)
hookdeck … --help, predictable shells).hookdeck on every branch.Step 2 — What is the deliverable? (when Step 1 is ambiguous)
Dashboard
CI and headless automation
CLI capability parity (do not under-use the CLI)
--help first (e.g. hookdeck gateway connection upsert --help). Omitting rate limits in an example was one symptom of skipping --help.Auth fit (credentials only — not feature depth)
hookdeck login on an operator machine). Do not prescribe API steps when only CLI auth exists, or the reverse.--help as the source of truth for flags
--help lists current flags. Skill examples are illustrative, not exhaustive.Terraform and resource management
gateway … upsert over create when both exist so scripts and agents can re-run safely; use create only when you need fail-if-exists semantics or there is no upsert.| Area | Resource | When to use |
|---|---|---|
| Context verification (organization and project) | hookdeck whoami → show output; confirm with user unless they clearly specified org/project and it matches | Run whoami and show the result; ask for confirmation before queries/metrics unless user clearly identified org/project and whoami matches; see references/cli-workflows.md |
| Resources (sources, destinations, connections, transformations) | references/01-setup.md, references/cli-workflows.md | First connection or adding/changing resources: 01-setup; cli-workflows for install, listen, upsert, gateway commands; Sources, Destinations, Connections, Transformations for full reference |
| Monitoring | references/monitoring-debugging.md | Event lifecycle, where to observe (TUI, Dashboard) |
| Debugging | references/monitoring-debugging.md | Troubleshooting, issues, replay |
| Querying (MCP) | references/monitoring-debugging.md | Requests, events, attempts, issues, and metrics through the Hookdeck MCP tools, when they're in your session |
| Querying (CLI) | references/monitoring-debugging.md | List, inspect, retry request/event/attempt; detailed search; main docs for details |
| Metrics (CLI) | references/monitoring-debugging.md | Event volume, failure rates, backlog; aggregated view; main docs for details |
| CLI | references/cli-workflows.md | Install, listen, connection/resource management, project switching |
| API | references/api-patterns.md | Querying; in-app resource lifecycle; resource creation driven from application code at runtime; main docs for details |
| Terraform | terraform-provider-hookdeck | Static resource management (sources, destinations, connections, transformations) as IaC; Registry docs |
| Iterate | references/04-iterate.md | Debug failures, replay events, CLI inspect/retry workflow |
| Area | Resource | When to use |
|---|---|---|
| Code | references/verification-code.md | Hookdeck signature verification (Express, Next.js, FastAPI) |
| Provider webhooks | references/provider-webhooks-checklist.md | When a provider is named (Stripe, Shopify, etc.): checklist before scaffolding, try install, use provider SDK constructs |
| Example codebases | examples/express/, examples/nextjs/, examples/fastapi/ | Runnable, proven, tested verification handlers — use these as the reference implementation for the user's framework |
examples/express/README.md (opens in a new tab)examples/express/package.json (opens in a new tab)examples/express/src/index.js (opens in a new tab)examples/express/test/webhook.test.js (opens in a new tab)examples/fastapi/README.md (opens in a new tab)examples/fastapi/main.py (opens in a new tab)examples/fastapi/requirements.txt (opens in a new tab)examples/fastapi/test_webhook.py (opens in a new tab)examples/nextjs/README.md (opens in a new tab)examples/nextjs/app/webhooks/route.ts (opens in a new tab)examples/nextjs/package.json (opens in a new tab)examples/nextjs/test/webhook.test.ts (opens in a new tab)examples/nextjs/vitest.config.ts (opens in a new tab)references/01-setup.md (opens in a new tab)references/02-scaffold.md (opens in a new tab)references/03-listen.md (opens in a new tab)references/04-iterate.md (opens in a new tab)references/api-patterns.md (opens in a new tab)references/authentication.md (opens in a new tab)references/cli-workflows.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
Other plugins' skills for the same job
npx claudepluginhub hookdeck/agent-skills --plugin hookdeck4 skills in this plugin
/hookdeckRoutes to the correct Hookdeck product skill. Covers Event Gateway (inbound: receive webhooks, webhook endpoints, local dev, event queue), Outpost (outbound: send webhooks to customers) and Inspect (free webhook test URLs with no account: see what a webhook sent). Use when working with any Hookdeck product and unsure which skill to use./inspectFree webhook test URLs from Hookdeck Inspect, with no account or login. Creates a URL with one HTTP call, waits for webhooks to arrive, and reads their headers and exact bodies as JSON. Use when asked to get a webhook test URL, see what a webhook sent, wait or watch for a webhook, debug a webhook payload or signature, or send test webhooks, or when given an inspect.hookdeck.com URL. For permanent webhook setups with connections, retries and an account, use event-gateway instead./outpostSets up and configures Hookdeck Outpost for outbound event delivery to customer endpoints. Use when sending webhooks to customers, building webhook delivery infrastructure, managing tenants and destinations with supported types (webhooks, Hookdeck Event Gateway, AWS SQS/Kinesis/S3, Azure Service Bus, GCP Pub/Sub, RabbitMQ, Kafka), or aligning topics and publishes. EventBridge support is tracked in GitHub issues.