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

# Test Webhook

> Send a test event to your configured webhook URL to verify delivery. `type: event` sends a real v2 envelope (`type: webhook.test`), signed exactly like a live event — X-Classet-Signature, X-Classet-Signature-V2 and X-Classet-Timestamp when a signing secret is set — so it exercises your signature verification too. `type: results` sends the legacy unsigned test payload to the results URL.

Send a test event to one of your configured webhook URLs to verify delivery is working.

* `type: "event"` sends a real v2 envelope with `type: "webhook.test"` to your event webhook URL. It is signed exactly like a live event: when a signing secret is set it carries `X-Classet-Signature`, `X-Classet-Signature-V2` and `X-Classet-Timestamp`. Use it to check your signature verification as well as reachability.
* `type: "results"` sends the legacy unsigned test payload to your results webhook URL.

```bash cURL theme={null}
curl -X POST https://api.classet.ai/v2/webhooks/test \
  -H "X-API-KEY: your-api-key" \
  -H "Content-Type: application/json" \
  -d '{ "type": "event" }'
```

```json 200 theme={null}
{
  "message": "Test webhook sent",
  "webhook_url": "https://your-server.com/webhooks/events",
  "response_status": 204
}
```

The body your endpoint receives for `type: "event"`:

```json theme={null}
{
  "event_id": "5b8f0c1e-2d3a-4c5b-9e6f-7a8b9c0d1e2f",
  "type": "webhook.test",
  "created_at": "2026-11-03T16:00:00.000Z",
  "org_id": "your-org-id",
  "api_version": "v2",
  "data": {
    "message": "Test webhook from Classet v2 API (event)",
    "org_id": "your-org-id"
  }
}
```

> [!NOTE]
>
> A test only succeeds when your endpoint returns a 2xx. Any other status comes back as a `400` naming the status your endpoint returned. Verify the signature over the raw request body; see [Verifying v2 events](/docs/guides/webhooks.md#replay-protection-v2-events).


## OpenAPI

````yaml POST /v2/webhooks/test
openapi: 3.1.0
info:
  title: Classet API
  version: 2.0.3
  description: >-
    AI-powered recruiting and phone screening API.


    **API key scopes.** `read` covers every GET; any other method needs `write`
    (403 `insufficient_scope`); starting or stopping an interview also needs
    `interviews:send`. A branch-limited key sees and writes only jobs in its
    branches (not jobs with no branch) and their candidates, applications and
    calls; anything outside is a 404. An organization-group key is read-only
    across every organization in its group. Branch-limited and group keys cannot
    use organization configuration (scripts, knowledge, webhooks, message
    automations, agent settings, AI generation, organization): 403
    `restricted_key_unsupported`. `GET /v2/me` reports what the calling key can
    do.
servers:
  - url: https://api.classet.ai
    description: Production
  - url: http://localhost:8081
    description: Local development
security:
  - ApiKeyAuth: []
paths:
  /v2/webhooks/test:
    post:
      tags:
        - Webhooks
      summary: Send a test webhook
      description: >-
        Send a test event to your configured webhook URL to verify delivery.
        `type: event` sends a real v2 envelope (`type: webhook.test`), signed
        exactly like a live event — X-Classet-Signature, X-Classet-Signature-V2
        and X-Classet-Timestamp when a signing secret is set — so it exercises
        your signature verification too. `type: results` sends the legacy
        unsigned test payload to the results URL.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                type:
                  type: string
                  enum:
                    - event
                    - results
                  default: event
                  description: Which webhook to test. Either `"event"` or `"results"`.
      responses:
        '200':
          description: Test sent
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                  webhook_url:
                    type: string
                    nullable: true
                  response_status:
                    type: integer
                    description: >-
                      HTTP status your endpoint returned. Always 2xx — a non-2xx
                      is reported as a 400.
                required:
                  - message
                  - webhook_url
                  - response_status
        '400':
          description: No webhook configured
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Resource not found
                  code:
                    type: string
                    enum:
                      - not_found
                      - validation_error
                      - unauthorized
                      - forbidden
                      - insufficient_scope
                      - restricted_key_unsupported
                      - branch_out_of_scope
                      - key_misconfigured
                      - quota_exceeded
                      - rate_limited
                      - rate_limit_unavailable
                      - conflict
                      - idempotency_key_reuse
                      - candidate_opted_out
                      - recently_contacted
                      - request_in_progress
                      - unprocessable
                      - bad_request
                      - payload_too_large
                      - internal_error
                      - service_unavailable
                    example: not_found
                    description: Stable machine-readable error code.
                  request_id:
                    type: string
                    example: 9f2c1d7e-4a3b-4c8d-9e0f-1a2b3c4d5e6f
                    description: >-
                      Request ID, also echoed in the X-Request-Id response
                      header. Include it when reporting issues.
                required:
                  - error
        '500':
          description: Server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Resource not found
                  code:
                    type: string
                    enum:
                      - not_found
                      - validation_error
                      - unauthorized
                      - forbidden
                      - insufficient_scope
                      - restricted_key_unsupported
                      - branch_out_of_scope
                      - key_misconfigured
                      - quota_exceeded
                      - rate_limited
                      - rate_limit_unavailable
                      - conflict
                      - idempotency_key_reuse
                      - candidate_opted_out
                      - recently_contacted
                      - request_in_progress
                      - unprocessable
                      - bad_request
                      - payload_too_large
                      - internal_error
                      - service_unavailable
                    example: not_found
                    description: Stable machine-readable error code.
                  request_id:
                    type: string
                    example: 9f2c1d7e-4a3b-4c8d-9e0f-1a2b3c4d5e6f
                    description: >-
                      Request ID, also echoed in the X-Request-Id response
                      header. Include it when reporting issues.
                required:
                  - error
        '503':
          description: External mutations are not enabled
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Resource not found
                  code:
                    type: string
                    enum:
                      - not_found
                      - validation_error
                      - unauthorized
                      - forbidden
                      - insufficient_scope
                      - restricted_key_unsupported
                      - branch_out_of_scope
                      - key_misconfigured
                      - quota_exceeded
                      - rate_limited
                      - rate_limit_unavailable
                      - conflict
                      - idempotency_key_reuse
                      - candidate_opted_out
                      - recently_contacted
                      - request_in_progress
                      - unprocessable
                      - bad_request
                      - payload_too_large
                      - internal_error
                      - service_unavailable
                    example: not_found
                    description: Stable machine-readable error code.
                  request_id:
                    type: string
                    example: 9f2c1d7e-4a3b-4c8d-9e0f-1a2b3c4d5e6f
                    description: >-
                      Request ID, also echoed in the X-Request-Id response
                      header. Include it when reporting issues.
                required:
                  - error
      security:
        - ApiKeyAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-KEY
      description: Your Classet API key. Create and rotate keys in Settings → API.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.