---
title: "Creates a webhook subscription."
method: POST
path: "/api/v1/orgs/{org}/webhooks"
tags: ["Webhooks"]
---

# Creates a webhook subscription.

`POST /api/v1/orgs/{org}/webhooks`

## Request

- Base URL: `https://api.featureflip.io`
- URL: `https://api.featureflip.io/api/v1/orgs/{org}/webhooks`
- Auth: API key in header `Authorization`

Requires Admin. The response carries the signing secret,
which is never shown again. Supports the `Idempotency-Key` header. A subscription past
the plan's webhook cap is a 403 `plan_limit_reached`.

## Path parameters

- `org` string, required

## Request body

- PublicCreateWebhookSubscriptionRequest: Creates a webhook subscription. `provider` is `GenericHttp`. Omit `eventTypes`, `projectIds` or `environmentIds` (or send an empty list) to receive every event, project or environment. A token restricted to specific projects must list at least one project, all of them within its allowlist.
  - `name` string, nullable, required
  - `url` string, nullable, required
  - `provider` 'GenericHttp', nullable, required: Allowed values: GenericHttp.
  - `eventTypes` string[], nullable
  - `projectIds` string[], nullable
  - `environmentIds` string[], nullable

## Response `201`

Created

- PublicCreateWebhookSubscriptionResponse: The created subscription's id and its signing secret. The secret is shown only here.
  - `id` string, uuid, required
  - `secret` string, nullable, required
  - `warning` string, nullable, required

## Other responses

- `400`: The request is malformed, or it carries an If-Match header, which this endpoint can't evaluate. Send no If-Match, or `*`.
- `401`: Authentication is required, or the supplied API token is invalid or expired.
- `403`: Forbidden
- `404`: Not Found
- `429`: Rate limit exceeded. Retry after the interval indicated by the Retry-After header.

---

[API](https://skmtc.dev/featureflip/apis/management-api.md) · [All operations](https://skmtc.dev/featureflip/apis/management-api/llms.txt) · [OpenAPI document](https://skmtc.dev/featureflip/apis/management-api/revisions/8a77e8581a45?raw)
