---
title: "webhooks create"
description: "Create a webhook endpoint"
canonical: "https://pgbeam.com/docs/cli/webhooks/create"
last-updated: "2026-10-29T19:01:20.000Z"
---

# webhooks create

> Create a webhook endpoint

URL: https://pgbeam.com/docs/cli/webhooks/create

{/* Auto-generated from CLI commands. Do not edit. Run `pnpm generate:cli-docs` to regenerate. */}

Create a webhook endpoint for the linked project. PgBeam delivers event and audit notifications to the given URL using the selected format. Subscribe to specific event types with `--event` (repeatable or comma-separated); omit it to receive all events.

## Usage

```bash
pgbeam webhooks create [url] [flags]
```

## Options

| Option                  | Description                                                                                                          | Required | Default |
| ----------------------- | -------------------------------------------------------------------------------------------------------------------- | -------- | ------- |
| `<url>`                 | Destination URL for webhook deliveries. If omitted, you will be prompted.                                            | No       | -       |
| `--format <value>`      | Delivery format: json, splunk_hec, datadog, or elastic.                                                              | No       | `json`  |
| `--event <value>`       | Event type(s) to subscribe to. Comma-separated. Omit to receive all events.                                          | No       | -       |
| `--secret <value>`      | Shared secret used to sign webhook payloads. Visible in shell history and the process list; prefer `--secret-stdin`. | No       | -       |
| `--secret-stdin`        | Read the signing secret from stdin. One trailing newline is removed.                                                 | No       | `false` |
| `--description <value>` | Human-readable description for the webhook endpoint.                                                                 | No       | -       |
| `--disabled`            | Create the webhook in a disabled state.                                                                              | No       | `false` |

> **Global options**
>
> All [global options](/docs/cli/global-options) (`--token`, `--profile`,
> `--project`, `--org`, `--json`, `--no-color`, `--no-trunc`, `--debug`) are
> also available on this command.

## Examples

```bash
# Create a webhook interactively
pgbeam webhooks create

# Create a webhook for a URL
pgbeam webhooks create https://example.com/hook

# Create a Datadog webhook for specific events
pgbeam webhooks create https://example.com/hook --format datadog --event query_blocked,canary_tripped

# Create a disabled webhook with a signing secret read from stdin
printf %s "$SECRET" | pgbeam webhooks create https://example.com/hook --secret-stdin --disabled
```

## Output

Prints a success message with the new webhook ID and its URL. With `--json`, returns the full webhook object from the API.