---
title: "POST agent_session_failed"
method: POST
path: "agent_session_failed"
---

# POST agent_session_failed

`POST agent_session_failed` (webhook)

Sent when an agent session fails.

## Payload

- WebhookAgentSessionFailed — Sent when an agent session fails.
  - `id` string, required — The unique ID of the event.
  - `object` 'event', required — The object type. Always `event`.
  - `created_at` integer, required — The Unix timestamp, in seconds, when the event was created.
  - `type` 'agent.session.failed', required — The event type. Always `agent.session.failed`.
  - `data` AgentSessionEnvironmentPayloadResource, required
    - `id` string, required — The ID of the session.
    - `environment_id` string — The ID of the environment, when one exists.
    - `environment_type` string, required — The environment type: `none`, `openai_hosted`, or `self_hosted`.

## Acknowledgement `200`

Return a 200 status code to acknowledge receipt of the event. Non-200
status codes will be retried.

---

[API](https://skmtc.dev/openai/apis/openapi.md) · [All operations](https://skmtc.dev/openai/apis/openapi/llms.txt) · [OpenAPI document](https://skmtc.dev/openai/apis/openapi/revisions/2cf225eb2eb4?raw)
