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

# Create a connection webhook

> Register an HTTPS endpoint to receive signed events for connections managed by the caller's partner (HQ) account. The signing `secret` is returned ONCE in this response and never again. Store it securely.



## OpenAPI

````yaml /api-reference/specs/connections.yaml post /connections/v1/webhooks
openapi: 3.1.0
info:
  title: Connections API
  description: >-
    Register and manage webhook subscriptions for the connections your White
    Label (partner) account manages. Receive a signed event whenever one of
    those connections expires and needs to be reconnected.
  version: v1
  contact:
    url: https://docs.zapier.com
servers:
  - url: https://api.zapier.com
    description: Production
security:
  - OAuth: []
tags:
  - name: Connection Webhooks
    description: >-
      Operations for managing per-partner webhook subscriptions for connection
      events
paths:
  /connections/v1/webhooks:
    post:
      tags:
        - Connection Webhooks
      summary: Create a connection webhook
      description: >-
        Register an HTTPS endpoint to receive signed events for connections
        managed by the caller's partner (HQ) account. The signing `secret` is
        returned ONCE in this response and never again. Store it securely.
      operationId: createConnectionWebhook
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ConnectionWebhookCreate'
            examples:
              SubscribeToConnectionExpiryEvents:
                value:
                  event_type: connection.expiry_scheduled
                  callback_url: https://example.com/webhooks/zapier
                summary: Subscribe to connection expiry events
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConnectionWebhookWithSecret'
          description: Created. Includes the signing secret (shown once).
        '400':
          description: Invalid request.
        '409':
          description: An active webhook for this event type already exists.
      callbacks:
        connectionEvent:
          '{$request.body#/callback_url}':
            post:
              description: >-
                When a subscribed event occurs, Zapier sends a signed HTTPS
                `POST` to the `callback_url` registered on this webhook.
                Requests are signed following the [Standard
                Webhooks](https://www.standardwebhooks.com/) specification —
                verify the `webhook-signature` header using the `secret`
                returned once at creation. Respond with any `2xx` status to
                acknowledge; non-`2xx` responses, timeouts, and `429`s are
                retried with backoff.


                Each request carries three headers used for signature
                verification. `webhook-id` is a stable delivery ID for the event
                that stays constant across retries (use it to deduplicate).
                `webhook-timestamp` is the Unix epoch, in seconds, at which the
                event was signed. `webhook-signature` is a space-delimited list
                of `v1,<base64 HMAC-SHA256>` signatures computed over
                `{webhook-id}.{webhook-timestamp}.{body}`.
              summary: Connection event notification
              requestBody:
                content:
                  application/json:
                    schema:
                      $ref: '#/components/schemas/ConnectionWebhookEvent'
                required: true
              responses:
                '200':
                  description: Event acknowledged. Any `2xx` status is accepted.
              method: post
              type: path
            path: '{$request.body#/callback_url}'
      security:
        - OAuth:
            - connection:webhook:write
            - external
components:
  schemas:
    ConnectionWebhookCreate:
      type: object
      description: Input serializer for POST /webhooks.
      properties:
        event_type:
          allOf:
            - $ref: '#/components/schemas/EventTypeEnum'
          description: |-
            The event to subscribe to.

            * `connection.expiry_scheduled` - Expiry Scheduled
        callback_url:
          type: string
          format: uri
          description: HTTPS URL that signed events are POSTed to.
      required:
        - callback_url
        - event_type
    ConnectionWebhookWithSecret:
      type: object
      description: >-
        Output serializer for POST 201. Includes the signing secret (returned
        once only).
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
          description: Unique webhook identifier (UUID).
        event_type:
          allOf:
            - $ref: '#/components/schemas/EventTypeEnum'
          readOnly: true
          description: |-
            The event type this webhook is subscribed to.

            * `connection.expiry_scheduled` - Expiry Scheduled
        callback_url:
          type: string
          format: uri
          readOnly: true
          description: HTTPS URL that signed events are POSTed to.
        is_active:
          type: boolean
          readOnly: true
          description: >-
            Whether the webhook is active. Inactive webhooks do not receive
            events.
        created_at:
          type: string
          format: date-time
          readOnly: true
          description: ISO 8601 timestamp when the webhook was created.
        updated_at:
          type: string
          format: date-time
          readOnly: true
          description: ISO 8601 timestamp when the webhook was last updated.
        secret:
          type: string
          readOnly: true
          description: Standard Webhooks signing secret (whsec_…). Shown once, at creation.
      required:
        - callback_url
        - created_at
        - event_type
        - id
        - is_active
        - secret
        - updated_at
    ConnectionWebhookEvent:
      type: object
      description: Outbound event payload POSTed to ``callback_url`` (documentation only).
      properties:
        type:
          allOf:
            - $ref: '#/components/schemas/TypeEnum'
          description: |-
            The event type. Matches the `event_type` this webhook subscribed to.

            * `connection.expiry_scheduled` - Expiry Scheduled
        expires_at:
          type: string
          format: date-time
          description: ISO 8601 timestamp when the connection is scheduled to expire.
        data:
          allOf:
            - $ref: '#/components/schemas/ConnectionWebhookEventData'
          description: Event-specific details.
      required:
        - data
        - expires_at
        - type
    EventTypeEnum:
      enum:
        - connection.expiry_scheduled
      type: string
      description: '* `connection.expiry_scheduled` - Expiry Scheduled'
    TypeEnum:
      enum:
        - connection.expiry_scheduled
      type: string
      description: '* `connection.expiry_scheduled` - Expiry Scheduled'
    ConnectionWebhookEventData:
      type: object
      description: >-
        The ``data`` object of an outbound connection event (documentation
        only).
      properties:
        connection_id:
          type: string
          description: External (opaque) ID of the connection that triggered the event.
        account_id:
          type: string
          description: External (opaque) ID of the account that owns the connection.
        app:
          type: string
          description: >-
            The integration the connection belongs to, as `app_key@version`
            (e.g. `SlackAPI@1.0.0`).
        title:
          type: string
          description: Human-readable title of the connection.
      required:
        - account_id
        - app
        - connection_id
        - title
  securitySchemes:
    OAuth:
      type: oauth2
      description: OAuth 2.0 authentication.
      flows:
        authorizationCode:
          authorizationUrl: https://zapier.com/oauth/authorize
          tokenUrl: https://zapier.com/oauth/token
          scopes:
            connection:webhook:read: Grants connection:webhook:read access
            external: Scope that gives access to all Public APIs
            connection:webhook:write: Grants connection:webhook:write access
        clientCredentials:
          tokenUrl: https://zapier.com/oauth/token
          scopes:
            connection:webhook:read: Grants connection:webhook:read access
            external: Scope that gives access to all Public APIs
            connection:webhook:write: Grants connection:webhook:write access

````