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

# Get Webhook Deliveries

> Get recent delivery attempts for a specific webhook. Requires API key with webhook:read.



## OpenAPI

````yaml /api-reference/openapi.json get /v1/webhooks/{webhookId}/deliveries
openapi: 3.1.0
info:
  title: Migma.ai API (v1)
  description: >-
    API for managing brands, contacts, email generation, sending, and
    integrations.
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.migma.ai
    description: Production
security:
  - apiKeyAuth: []
tags:
  - name: Projects/Brands
    description: Manage projects (brands) and import from websites
  - name: Contacts
    description: Manage your contacts, segments, tags, and topics
  - name: Segments
    description: Create and manage dynamic contact segments
  - name: Tags
    description: Organize contacts with tags
  - name: Topics
    description: Manage subscription topics and preferences
  - name: Emails
    description: Generate, send, and export emails
  - name: Email Validation
    description: Validate email content for compatibility and deliverability
  - name: Email Previews
    description: Preview emails across devices and email clients
  - name: Domains
    description: Manage sending domains and verification
  - name: Webhooks
    description: Manage webhook endpoints for real-time event notifications
  - name: Events
    description: Record customer events and conversions
  - name: Integrations
    description: Third-party platform integrations
  - name: Campaigns
    description: Create, schedule, send, and manage email campaigns
  - name: Project Editing
    description: Edit project assets, logos, images, and knowledge base entries
paths:
  /v1/webhooks/{webhookId}/deliveries:
    get:
      tags:
        - Webhooks
      summary: Get Webhook Deliveries
      description: >-
        Get recent delivery attempts for a specific webhook. Requires API key
        with webhook:read.
      operationId: GetWebhookDeliveries
      parameters:
        - name: webhookId
          in: path
          description: Webhook ID (MongoDB ObjectId)
          required: true
          schema:
            type: string
            pattern: ^[0-9a-fA-F]{24}$
        - name: limit
          in: query
          description: Maximum number of deliveries to return (max 100)
          required: false
          schema:
            type: integer
            default: 50
            maximum: 100
      responses:
        '200':
          description: Webhook deliveries
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiResponseWebhookDeliveries'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
      x-codeSamples:
        - lang: javascript
          label: Node.js SDK
          source: >-
            import Migma from 'migma';


            const migma = new Migma('YOUR_API_KEY');


            const { data, error } = await
            migma.webhooks.getDeliveries('WEBHOOK_ID');
components:
  schemas:
    ApiResponseWebhookDeliveries:
      allOf:
        - $ref: '#/components/schemas/ApiResponse'
        - type: object
          properties:
            data:
              type: object
              properties:
                deliveries:
                  type: array
                  items:
                    $ref: '#/components/schemas/WebhookDelivery'
                total:
                  type: integer
    ApiResponse:
      type: object
      properties:
        success:
          type: boolean
        data:
          nullable: true
        error:
          type: string
          nullable: true
      required:
        - success
    WebhookDelivery:
      type: object
      properties:
        id:
          type: string
          description: Delivery ID
        eventId:
          type: string
          description: Event ID (for idempotency)
        eventType:
          type: string
          description: Event type
        status:
          type: string
          enum:
            - pending
            - sending
            - success
            - failed
            - retry
          description: Delivery status
        attempts:
          type: integer
          description: Number of delivery attempts
        lastAttemptAt:
          type: string
          format: date-time
          description: Last attempt timestamp
        response:
          type: object
          properties:
            statusCode:
              type: integer
              description: HTTP status code
            error:
              type: string
              description: Error message if failed
        createdAt:
          type: string
          format: date-time
          description: Creation timestamp
    ApiError:
      type: object
      properties:
        success:
          type: boolean
          default: false
        error:
          type: string
        code:
          type: string
          description: >-
            Machine-readable error code (e.g., IDEMPOTENCY_CONFLICT,
            DOMAIN_CLAIMABLE).
        data:
          type: object
          description: >-
            Additional structured context for the error, such as the affected
            domain.
          additionalProperties: true
      required:
        - success
        - error
  responses:
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
      description: >-
        API key authentication. Use 'Authorization: Bearer YOUR_API_KEY' where
        YOUR_API_KEY is obtained from the Migma dashboard under Settings →
        Developers → API Keys.

````