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

# Get Webhooks

> Get all webhooks under your account.

<Info>This endpoint requires your [private API key](/api-reference/overview#authentication).</Info>


## OpenAPI

````yaml get /webhooks
openapi: 3.0.0
info:
  title: trench API
  description: ''
  version: '1.0'
  contact: {}
servers: []
security: []
tags: []
paths:
  /webhooks:
    get:
      summary: Get all webhooks
      operationId: WebhooksController_getWebhooks
      parameters: []
      responses:
        '200':
          description: >-
            The webhooks have been successfully retrieved. Requires private API
            key in Bearer token.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaginatedWebhookResponse'
      security:
        - bearer: []
components:
  schemas:
    PaginatedWebhookResponse:
      type: object
      properties:
        limit:
          type: number
          description: The limit of the pagination.
          nullable: true
        offset:
          type: number
          description: The offset of the pagination.
          nullable: true
        total:
          type: number
          description: The total number of results. If `null`, the total is unknown.
          nullable: true
        results:
          type: array
          items:
            $ref: '#/components/schemas/Webhook'
      required:
        - limit
        - offset
        - total
        - results
    Webhook:
      type: object
      properties:
        uuid:
          type: string
          description: The UUID of the webhook. Automatically generated.
          example: 123e4567-e89b-12d3-a456-426614174000
        url:
          type: string
          description: The URL that the webhook will send events to.
          example: https://your-webhook-url.com
        enableBatching:
          type: boolean
          description: Whether to enable batching for the webhook.
          example: true
        createdAt:
          format: date-time
          type: string
          description: The date and time the webhook was created.
          example: '2021-01-01T00:00:00.000Z'
        eventTypes:
          description: >-
            The event types that the webhook will send. Use `*` to match all
            event types.
          example:
            - page
            - track
            - identify
            - group
          type: array
          items:
            type: string
        eventNames:
          description: >-
            The event names that the webhook will send. Use `*` to match all
            event names.
          example:
            - UserSignedUp
            - UserLoggedIn
          type: array
          items:
            type: string
        flatten:
          type: boolean
          description: >-
            Whether to flatten the event data. This is useful for downstream
            systems that don't support nested data structures.
          example: true
      required:
        - uuid
        - url
        - enableBatching
        - createdAt
        - eventTypes
        - eventNames
        - flatten

````