---
title: "Create webhook"
method: POST
path: "/v1/webhook"
tags: ["Webhook"]
---

# Create webhook

`POST /v1/webhook`

Creates a new webhook with event subscriptions. The signing secret is only returned in this response.

## Request body

- CreateWebhookInput — Input for creating a webhook
  - `url` string, uri, required — Webhook URL
  - `description` string, nullable — Webhook description
  - `headers` object — Request headers (e.g. authorization tokens)
  - `events` string[], required — Event types to subscribe to (at least one required)

## Response `201`

The created webhook with signing secret

- object
  - `data` CreateWebhookResponse, required — Webhook with its subscribed event types
    - `id` string, uuid, required — Webhook ID
    - `description` string, nullable, required — Webhook description
    - `url` string, required — Webhook URL
    - `headers` object, required — Request headers
    - `events` string[], required — Event types this webhook is subscribed to
    - `createdAt` string, required — Creation timestamp
    - `updatedAt` string, required — Last update timestamp

## Other responses

- `401` — Unauthorized
- `500` — Internal Server Error

---

[API](https://skmtc.net/roarkhq/apis/roark-analytics-api.md) · [All operations](https://skmtc.net/roarkhq/apis/roark-analytics-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/roarkhq/roark-analytics-api/revisions/83528d3618ef/schema)
