---
title: "Test Webhook Endpoint"
method: POST
path: "/webhook_endpoints/{webhook_endpoint_id}/test"
---

# Test Webhook Endpoint

`POST /webhook_endpoints/{webhook_endpoint_id}/test`

## Request

- Base URL: `https://api.openai.com/v1`
- URL: `https://api.openai.com/v1/webhook_endpoints/{webhook_endpoint_id}/test`
- Auth: HTTP bearer

Sends a sample event to a webhook endpoint for the authenticated project.

## Path parameters

- `webhook_endpoint_id` string, required

## Request body

- PublicTestEndpointBody
  - `event_type` 'batch.completed' | 'batch.failed' | 'batch.expired' | 'batch.cancelled' | 'response.completed' | 'response.failed' | 'response.cancelled' | 'response.incomplete' | 'eval.run.succeeded' | 'eval.run.failed' | 'eval.run.canceled' | 'fine_tuning.job.succeeded' | 'fine_tuning.job.failed' | 'fine_tuning.job.cancelled' | 'realtime.call.incoming' | 'video.completed' | 'video.failed' | 'agent.environment.ready' | 'agent.environment.failed' | 'agent.environment.suspended' | 'agent.environment.expired' | 'agent.session.created' | 'agent.session.action_required' | 'agent.session.in_progress' | 'agent.session.idle' | 'agent.session.failed' | 'safety.alert.created', required

## Response `200`

Success

- WebhookEndpointTestResultResource
  - `object` 'webhook_endpoint.test', required: The object type, which is always webhook_endpoint.test.
  - `webhook_endpoint_id` string, required: The ID of the webhook endpoint that received the test.
  - `event_type` string, required: The event type sent in the test.
  - `status_code` integer, required: The HTTP status code returned by the endpoint.
  - `success` true, required: Whether the test request completed. Always true for returned results; use status_code to determine the endpoint response.

## Other responses

- `400`: The request parameters are invalid.
- `404`: The webhook endpoint was not found in the authenticated project.
- `500`: The sample event could not be sent to the webhook endpoint.

## Changes

- **2026-10-08** `ff5a4408cabb`: 2 info
  - added the new `agent.environment.expired` enum value to the request property `event_type`
  - added the new `agent.environment.suspended` enum value to the request property `event_type`
- **2026-10-08** `30eea8389a06`: 2 info
  - added the new `agent.environment.failed` enum value to the request property `event_type`
  - added the new `agent.environment.ready` enum value to the request property `event_type`
- **2026-10-06** `487892d3954e`: 3 info
  - added the optional property `error/misalignment/review_target` to the response with the `400` status
  - added the optional property `error/misalignment/review_target` to the response with the `404` status
  - added the optional property `error/misalignment/review_target` to the response with the `500` status
- **2026-10-05** `7f654af7f94f`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/omnistack-sh/apis/openai-api/changes/webhook_endpoints/:webhook_endpoint_id/test/post.md)

---

[API](https://skmtc.dev/omnistack-sh/apis/openai-api.md) - [All operations](https://skmtc.dev/omnistack-sh/apis/openai-api/llms.txt) - [OpenAPI document](https://skmtc.dev/omnistack-sh/apis/openai-api/revisions/0a26f104d35f?raw)
