Skip to content
For the complete documentation index, see llms.txt. Markdown versions of documentation pages are available by appending .md to the page URL.
Primary navigation

Webhooks

Create Webhook Endpoint
webhooks.create(**kwargs) -> WebhookEndpointWithSecret { id, created_at, event_types, 6 more }
POST/webhook_endpoints
Delete Webhook Endpoint
webhooks.delete(webhook_endpoint_id) -> DeletedWebhookEndpoint { id, deleted, object }
DELETE/webhook_endpoints/{webhook_endpoint_id}
List Webhook Endpoints
webhooks.list(**kwargs) -> CursorPage<WebhookEndpoint { id, created_at, event_types, 5 more } >
GET/webhook_endpoints
Retrieve Webhook Endpoint
webhooks.retrieve(webhook_endpoint_id) -> WebhookEndpoint { id, created_at, event_types, 5 more }
GET/webhook_endpoints/{webhook_endpoint_id}
Rotate Webhook Endpoint Signing Secret
webhooks.rotate_secret(webhook_endpoint_id, **kwargs) -> WebhookEndpointWithSecret { id, created_at, event_types, 6 more }
POST/webhook_endpoints/{webhook_endpoint_id}/rotate_secret
Test Webhook Endpoint
webhooks.test_(webhook_endpoint_id, **kwargs) -> WebhookEndpointTestResult { event_type, object, status_code, 2 more }
POST/webhook_endpoints/{webhook_endpoint_id}/test
Unwrap
webhooks.unwrap() -> void
Function
Update Webhook Endpoint
webhooks.update(webhook_endpoint_id, **kwargs) -> WebhookEndpoint { id, created_at, event_types, 5 more }
POST/webhook_endpoints/{webhook_endpoint_id}
ModelsExpand Collapse
class AgentEnvironmentExpiredWebhookEvent { id, created_at, data, 2 more }

Sent when an agent environment expires and can no longer resume from a snapshot.

class AgentEnvironmentFailedWebhookEvent { id, created_at, data, 2 more }

Sent when setup fails for a prewarmed OpenAI-hosted environment before it is attached to a session.

class AgentEnvironmentReadyWebhookEvent { id, created_at, data, 2 more }

Sent when a prewarmed OpenAI-hosted environment finishes setup before being attached to a session.

class AgentEnvironmentSuspendedWebhookEvent { id, created_at, data, 2 more }

Sent when an agent environment is suspended and can resume from a snapshot.

class AgentSessionActionRequiredWebhookEvent { id, created_at, data, 2 more }

Sent when an agent session requires an action. Retrieve the session for action details.

class AgentSessionCreatedWebhookEvent { id, created_at, data, 2 more }

Sent when an agent session is created.

class AgentSessionFailedWebhookEvent { id, created_at, data, 2 more }

Sent when an agent session fails.

class AgentSessionIdleWebhookEvent { id, created_at, data, 2 more }

Sent when an agent session becomes idle.

class AgentSessionInProgressWebhookEvent { id, created_at, data, 2 more }

Sent when an agent session enters the in-progress state.

class BatchCancelledWebhookEvent { id, created_at, data, 2 more }

Sent when a batch API request has been cancelled.

class BatchCompletedWebhookEvent { id, created_at, data, 2 more }

Sent when a batch API request has been completed.

class BatchExpiredWebhookEvent { id, created_at, data, 2 more }

Sent when a batch API request has expired.

class BatchFailedWebhookEvent { id, created_at, data, 2 more }

Sent when a batch API request has failed.

class DeletedWebhookEndpoint { id, deleted, object }
class EvalRunCanceledWebhookEvent { id, created_at, data, 2 more }

Sent when an eval run has been canceled.

class EvalRunFailedWebhookEvent { id, created_at, data, 2 more }

Sent when an eval run has failed.

class EvalRunSucceededWebhookEvent { id, created_at, data, 2 more }

Sent when an eval run has succeeded.

class FineTuningJobCancelledWebhookEvent { id, created_at, data, 2 more }

Sent when a fine-tuning job has been cancelled.

class FineTuningJobFailedWebhookEvent { id, created_at, data, 2 more }

Sent when a fine-tuning job has failed.

class FineTuningJobSucceededWebhookEvent { id, created_at, data, 2 more }

Sent when a fine-tuning job has succeeded.

class LiveCallIncomingWebhookEvent { id, created_at, data, 2 more }

Deprecated: use live.transport.incoming. Retained for existing subscriptions during migration; new subscriptions to this event are not allowed. Sent when an incoming API SIP session is available for Live acceptance. The same pending session can also emit realtime.call.incoming; the first successful Realtime or Live accept endpoint selects the runtime surface.

class LiveTransportIncomingWebhookEvent { id, created_at, data, 2 more }

Sent when an incoming API SIP session is available for Live acceptance. The same pending session can also emit realtime.call.incoming; the first successful Realtime or Live accept endpoint selects the runtime surface.

class RealtimeCallIncomingWebhookEvent { id, created_at, data, 2 more }

Sent when an incoming API SIP session is available for Realtime acceptance. The same pending session can also emit live.transport.incoming; the first successful Realtime or Live accept endpoint selects the runtime surface.

class ResponseCancelledWebhookEvent { id, created_at, data, 2 more }

Sent when a background response has been cancelled.

class ResponseCompletedWebhookEvent { id, created_at, data, 2 more }

Sent when a background response has been completed.

class ResponseFailedWebhookEvent { id, created_at, data, 2 more }

Sent when a background response has failed.

class ResponseIncompleteWebhookEvent { id, created_at, data, 2 more }

Sent when a background response has been interrupted.

class SafetyAlertCreatedWebhookEvent { id, created_at, data, 2 more }

Sent when an approved safety alert is available for an API project.

class SafetyDeactivationIssuedWebhookEvent { id, created_at, data, 2 more }

Sent when a deactivation is issued for a safety identifier in your organization.

class SafetyOrgAlertCreatedWebhookEvent { id, created_at, data, 2 more }

Sent when an approved safety alert is available for an enterprise workspace.

class SafetyWarningIssuedWebhookEvent { id, created_at, data, 2 more }

Sent when a warning is issued for a safety identifier in your organization.

class WebhookEndpoint { id, created_at, event_types, 5 more }
class WebhookEndpointList { data, first_id, has_more, 2 more }
class WebhookEndpointTestResult { event_type, object, status_code, 2 more }
class WebhookEndpointWithSecret { id, created_at, event_types, 6 more }
class WebhookEventTypeList { data, object }

WebhooksEvent Types

List Webhook Event Types
webhooks.event_types.list() -> WebhookEventTypeList { data, object }
GET/webhook_event_types