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

# Send test event

> Send a synthetic ``ping`` event to the endpoint **synchronously** and return the first attempt's result. Bypasses the retry queue — this is for verifying URL reachability, signature verification, and customer-side handler wiring during integration. Subscribed event types are not consulted; the test event is delivered regardless of ``event_types``.



## OpenAPI

````yaml /openapi/openapi-integrations.json post /integrations/api/v1/webhooks/endpoints/{endpoint_id}/test/
openapi: 3.1.0
info:
  title: Integrations API
  version: 1.0.0
  description: >
    Webhook endpoint management and delivery tracking.


    ## Authentication


    All endpoints require an API key passed via the `X-API-Key` HTTP header,
    unless otherwise noted.


    ```

    X-API-Key: csb_<body>_<checksum>

    ```


    Generate API keys in **Settings > API Keys** in your dashboard, or via the
    Account API.

    Session-based (cookie) authentication is also accepted for browser-based
    access.


    ## Rate Limits


    | Tier        | Requests / minute | Requests / day |

    |-------------|-------------------|----------------|

    | Default     | 300               | 10,000         |

    | Custom      | Contact us        | Contact us     |


    Rate-limit headers are included on every response so callers can
    self-throttle without

    hitting our 429s ("informed governor"):


    - `RateLimit-Policy` — every active window, e.g. `300;w=60, 10000;w=86400`

    - `RateLimit-Limit` — quota for the **most-restrictive** currently-active
    window

    - `RateLimit-Remaining` — requests left in that window

    - `RateLimit-Reset` — seconds until that window resets (relative; clock-skew
    safe)


    Legacy `X-RateLimit-*` aliases are also emitted for back-compat.
    `X-RateLimit-Reset`

    keeps the absolute Unix-timestamp shape to avoid breaking existing
    consumers.


    When rate-limited, you receive `429 Too Many Requests` with a
    `retry_after_seconds` field

    in the error envelope and a `Retry-After` header.


    ## Pagination


    List endpoints return paginated results in this envelope:


    ```json

    {
      "data": [...],
      "pagination": {
        "page": 1,
        "page_size": 25,
        "total_count": 342,
        "total_pages": 14,
        "has_next": true,
        "has_previous": false
      }
    }

    ```


    Use `?page=2&page_size=50` query parameters. Maximum page size is 100.


    ## Error Responses


    All errors conform to [RFC 9457 Problem
    Details](https://www.rfc-editor.org/rfc/rfc9457)

    with `Content-Type: application/problem+json`:


    ```json

    {
      "type": "https://closient.com/docs/errors/not_found",
      "title": "Not Found",
      "status": 404,
      "detail": "The requested resource was not found.",
      "error_code": "not_found",
      "retryable": false,
      "timestamp": "2026-03-31T12:00:00+00:00"
    }

    ```


    Common error codes: `unauthorized` (401), `forbidden` (403), `not_found`
    (404),

    `validation_error` (422), `rate_limited` (429), `internal_error` (500).
  termsOfService: https://www.closient.com/terms/
servers:
  - url: https://www.closient.com
security: []
tags:
  - name: Webhook Endpoints
    description: Register and manage webhook delivery endpoints.
  - name: Webhook Deliveries
    description: Track and replay webhook delivery attempts.
externalDocs:
  description: Closient Documentation
  url: https://docs.closient.com
paths:
  /integrations/api/v1/webhooks/endpoints/{endpoint_id}/test/:
    post:
      tags:
        - Webhook Endpoints
      summary: Send test event
      description: >-
        Send a synthetic ``ping`` event to the endpoint **synchronously** and
        return the first attempt's result. Bypasses the retry queue — this is
        for verifying URL reachability, signature verification, and
        customer-side handler wiring during integration. Subscribed event types
        are not consulted; the test event is delivered regardless of
        ``event_types``.
      operationId: apps_integrations_webhooks_api_test_endpoint_view
      parameters:
        - in: path
          name: endpoint_id
          schema:
            description: >-
              UUID of the webhook endpoint. Returned as the ``id`` field on
              every endpoint response.
            format: shortuuid
            maxLength: 22
            minLength: 22
            pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$
            title: Endpoint Id
            type: string
          required: true
          description: >-
            UUID of the webhook endpoint. Returned as the ``id`` field on every
            endpoint response.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TestResultSchema'
      security:
        - APIKeyHeaderAuth: []
        - OAuthTokenAuth: []
        - SessionAuth: []
components:
  schemas:
    TestResultSchema:
      description: |-
        Result of a synchronous test or replay delivery.

        Returned by ``POST /webhooks/endpoints/{endpoint_id}/test/`` (sends a
        synthetic ``ping`` event) and ``POST /webhooks/deliveries/{id}/replay/``
        (re-queues a dead-lettered delivery and waits for the first attempt to
        finish before responding). Subsequent retries — if any — happen
        asynchronously and surface in the deliveries list.
      examples:
        - delivery_id: e6f7a8b9-0123-4567-abcd-ef8901234567
          http_status_code: 200
          response_body: '{"received": true}'
          status: delivered
      properties:
        delivery_id:
          description: >-
            UUID of the delivery record that was created or replayed. Use this
            to look the attempt up in the deliveries list.
          title: Delivery Id
          type: string
        status:
          $ref: '#/components/schemas/DeliveryStatusEnum'
          description: >-
            Lifecycle state of the delivery attempt. ``pending`` deliveries are
            awaiting their next retry; ``delivered`` is terminal-success;
            ``failed`` is mid-retry-backoff; ``rate_limited`` is a 429 response
            (retried separately so 429s don't inflate failure rates);
            ``dead_letter`` is terminal-failure after retries are exhausted and
            must be replayed via the deliveries-replay endpoint to attempt
            again.
        http_status_code:
          anyOf:
            - maximum: 599
              minimum: 100
              type: integer
            - type: 'null'
          description: >-
            HTTP status code returned by the customer endpoint on the most
            recent attempt. ``null`` while the delivery is enqueued but has not
            been attempted yet, or when the request errored before a response
            was received (DNS / TLS / connect timeout).
          title: Http Status Code
        response_body:
          anyOf:
            - maxLength: 256
              type: string
            - type: 'null'
          description: >-
            First 256 characters of the customer endpoint's response body for
            the test attempt, or ``null`` if the request errored before a
            response was received.
          title: Response Body
      required:
        - delivery_id
        - status
      title: TestResultSchema
      type: object
    DeliveryStatusEnum:
      description: >-
        Lifecycle status of a single
        :class:`~apps.integrations.models.WebhookDelivery`.


        Mirrors :class:`apps.integrations.models.WebhookDelivery.Status` (and

        the standalone :class:`apps.integrations.models.DeliveryStatus`,

        which carry identical values).


        State transitions::

            pending ──► delivered            (2xx response, terminal success)
            pending ──► failed ──► pending   (retried with backoff)
            pending ──► rate_limited ──► pending  (429 response, retried)
            failed  ──► dead_letter          (max attempts exceeded, terminal)

        ``rate_limited`` is reported separately from ``failed`` so customers

        can dashboard 429s without inflating their failure rate. ``dead_letter``

        deliveries can be re-queued via ``POST
        /webhooks/deliveries/{id}/replay/``.
      enum:
        - pending
        - delivered
        - failed
        - rate_limited
        - dead_letter
      title: DeliveryStatusEnum
      type: string
  securitySchemes:
    APIKeyHeaderAuth:
      type: apiKey
      in: header
      name: X-API-Key
    OAuthTokenAuth:
      type: http
      scheme: bearer
    SessionAuth:
      type: apiKey
      in: cookie
      name: sessionid

````