> ## Documentation Index
> Fetch the complete documentation index at: https://developers.respondent.io/llms.txt
> Use this file to discover all available pages before exploring further.

> Register a webhook URL to receive real-time event notifications. Each team can have **one active webhook**, which receives all events; registering a new one deactivates the previous webhook. Failed deliveries are retried up to 5 times at 10-minute intervals.

# Create webhook

## Webhook behavior

<CardGroup cols={2}>
  <Card title="Retry policy" icon="rotate">
    Failed deliveries are retried **up to 5 times** at 10-minute intervals. Your endpoint must respond within 3 seconds.
  </Card>

  <Card title="Event types" icon="bell">
    Use [Retrieve Event Types](/webhooks/retrieve-webhook-event-types) to see all available events, then [Simulate](/webhooks/simulate-webhook-event) to test your handler.
  </Card>
</CardGroup>


## OpenAPI

````yaml post /v1/webhooks
openapi: 3.0.0
info:
  title: Partner API
  description: Public API for partner integrations
  version: '1.0'
  contact: {}
servers:
  - url: https://api-staging.respondent.io
security: []
tags: []
paths:
  /v1/webhooks:
    post:
      tags:
        - webhooks
      summary: Create webhook
      description: >-
        Each team can have a single active webhook url, which we send all events
        to.

        (A team may have multiple sets of API credentials; they all share the
        same webhook.)

        To change the url, send another post request with the new url —

        this deactivates the previous webhook and creates a new one.


        Webhook retries are live — partners must return a 2xx status code within
        3 seconds;

        otherwise, we'll retry up to 5 times in 10-minute intervals.
      operationId: WebhooksController_create
      parameters:
        - name: x-api-key
          in: header
          required: true
          schema:
            type: string
        - name: x-api-secret
          in: header
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateWebhookDto'
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WebhookDto'
components:
  schemas:
    CreateWebhookDto:
      type: object
      properties:
        url:
          type: string
          description: The URL to send the webhook payload to.
      required:
        - url
    WebhookDto:
      type: object
      properties:
        id:
          type: string
          format: ObjectId
        url:
          type: string
          description: The URL to send the webhook payload to.
        privateKey:
          type: string
          description: The secret key to be used to sign the webhook payload.
        teamId:
          type: string
          format: ObjectId
        organizationId:
          type: string
          format: ObjectId
      required:
        - id
        - url
        - privateKey

````