1501 1501
1502 - `"environment_connection"`1502 - `"environment_connection"`
1503 1503
1504 - `status: "idle" or "in_progress" or "requires_action" or "failed"`1504 - `spend_control: object { consumed, limit }`
1505
1506 Spending limit and best-effort consumption, in USD cents. The limit is null for an unlimited session. Consumption is null when unavailable.
1507
1508 - `consumed: integer or null`
1509
1510 Best-effort recorded spend floored to whole USD cents, or null when unavailable.
1511
1512 `minimum: 0`
1513
1514 - `limit: integer or null`
1515
1516 The configured positive limit in USD cents, or null when unlimited.
1517
1518 `format: int64`, `minimum: 1`, `maximum: 4503599627370495`
1519
1520 - `status: "idle" or "in_progress" or "requires_action" or 2 more`
1505 1521
1506 The current status of the session.1522 The current status of the session.
1507 1523
1521 1537
1522 The session failed.1538 The session failed.
1523 1539
1540 - `"budget_reached"`
1541
1542 The session is paused because its spending limit was reached.
1543
1524 - `usage: TokenUsage or null`1544 - `usage: TokenUsage or null`
1525 1545
1526 Best-effort token usage for the session, or null if unknown. Recorded usage may change.1546 Best-effort token usage for the session, or null if unknown. Recorded usage may change.
1610 "ttl": "30m"1630 "ttl": "30m"
1611 },1631 },
1612 "review": "none",1632 "review": "none",
1633 "spend_control": {
1634 "limit": 1,
1635 "consumed": 0
1636 },
1613 "metadata": {1637 "metadata": {
1614 "foo": "string"1638 "foo": "string"
1615 },1639 },
1748 1772
1749 A customer-safe error. Non-null only for a failed turn.1773 A customer-safe error. Non-null only for a failed turn.
1750 1774
1751 - `code: "context_length_exceeded" or "max_output_tokens" or "usage_limit_exceeded" or 21 more`1775 - `code: "context_length_exceeded" or "max_output_tokens" or "session_budget_exceeded" or 23 more`
1752 1776
1753 A stable, machine-readable failure category.1777 A stable, machine-readable failure category.
1754 1778
1760 1784
1761 The model reached its output token limit before finishing the response.1785 The model reached its output token limit before finishing the response.
1762 1786
1787 - `"session_budget_exceeded"`
1788
1789 The session has reached its usage budget.
1790
1763 - `"usage_limit_exceeded"`1791 - `"usage_limit_exceeded"`
1764 1792
1765 The organization has reached a usage, plan, or billing limit.1793 The organization has reached a usage, plan, or billing limit.
1808 1836
1809 The request was blocked by the safety systems.1837 The request was blocked by the safety systems.
1810 1838
1839 - `"audio_input_unavailable"`
1840
1841 Audio input is unavailable for the organization.
1842
1811 - `"connection_failed"`1843 - `"connection_failed"`
1812 1844
1813 The request could not connect to the model service.1845 The request could not connect to the model service.
2071 2103
2072 A customer-safe error. Non-null only for a failed turn.2104 A customer-safe error. Non-null only for a failed turn.
2073 2105
2074 - `code: "context_length_exceeded" or "max_output_tokens" or "usage_limit_exceeded" or 21 more`2106 - `code: "context_length_exceeded" or "max_output_tokens" or "session_budget_exceeded" or 23 more`
2075 2107
2076 A stable, machine-readable failure category.2108 A stable, machine-readable failure category.
2077 2109
2083 2115
2084 The model reached its output token limit before finishing the response.2116 The model reached its output token limit before finishing the response.
2085 2117
2118 - `"session_budget_exceeded"`
2119
2120 The session has reached its usage budget.
2121
2086 - `"usage_limit_exceeded"`2122 - `"usage_limit_exceeded"`
2087 2123
2088 The organization has reached a usage, plan, or billing limit.2124 The organization has reached a usage, plan, or billing limit.
2131 2167
2132 The request was blocked by the safety systems.2168 The request was blocked by the safety systems.
2133 2169
2170 - `"audio_input_unavailable"`
2171
2172 Audio input is unavailable for the organization.
2173
2134 - `"connection_failed"`2174 - `"connection_failed"`
2135 2175
2136 The request could not connect to the model service.2176 The request could not connect to the model service.
2394 2434
2395 A customer-safe error. Non-null only for a failed turn.2435 A customer-safe error. Non-null only for a failed turn.
2396 2436
2397 - `code: "context_length_exceeded" or "max_output_tokens" or "usage_limit_exceeded" or 21 more`2437 - `code: "context_length_exceeded" or "max_output_tokens" or "session_budget_exceeded" or 23 more`
2398 2438
2399 A stable, machine-readable failure category.2439 A stable, machine-readable failure category.
2400 2440
2406 2446
2407 The model reached its output token limit before finishing the response.2447 The model reached its output token limit before finishing the response.
2408 2448
2449 - `"session_budget_exceeded"`
2450
2451 The session has reached its usage budget.
2452
2409 - `"usage_limit_exceeded"`2453 - `"usage_limit_exceeded"`
2410 2454
2411 The organization has reached a usage, plan, or billing limit.2455 The organization has reached a usage, plan, or billing limit.
2454 2498
2455 The request was blocked by the safety systems.2499 The request was blocked by the safety systems.
2456 2500
2501 - `"audio_input_unavailable"`
2502
2503 Audio input is unavailable for the organization.
2504
2457 - `"connection_failed"`2505 - `"connection_failed"`
2458 2506
2459 The request could not connect to the model service.2507 The request could not connect to the model service.
2732 2780
2733 A customer-safe error. Non-null only for a failed turn.2781 A customer-safe error. Non-null only for a failed turn.
2734 2782
2735 - `code: "context_length_exceeded" or "max_output_tokens" or "usage_limit_exceeded" or 21 more`2783 - `code: "context_length_exceeded" or "max_output_tokens" or "session_budget_exceeded" or 23 more`
2736 2784
2737 A stable, machine-readable failure category.2785 A stable, machine-readable failure category.
2738 2786
2744 2792
2745 The model reached its output token limit before finishing the response.2793 The model reached its output token limit before finishing the response.
2746 2794
2795 - `"session_budget_exceeded"`
2796
2797 The session has reached its usage budget.
2798
2747 - `"usage_limit_exceeded"`2799 - `"usage_limit_exceeded"`
2748 2800
2749 The organization has reached a usage, plan, or billing limit.2801 The organization has reached a usage, plan, or billing limit.
2792 2844
2793 The request was blocked by the safety systems.2845 The request was blocked by the safety systems.
2794 2846
2847 - `"audio_input_unavailable"`
2848
2849 Audio input is unavailable for the organization.
2850
2795 - `"connection_failed"`2851 - `"connection_failed"`
2796 2852
2797 The request could not connect to the model service.2853 The request could not connect to the model service.
3070 3126
3071 A customer-safe error. Non-null only for a failed turn.3127 A customer-safe error. Non-null only for a failed turn.
3072 3128
3073 - `code: "context_length_exceeded" or "max_output_tokens" or "usage_limit_exceeded" or 21 more`3129 - `code: "context_length_exceeded" or "max_output_tokens" or "session_budget_exceeded" or 23 more`
3074 3130
3075 A stable, machine-readable failure category.3131 A stable, machine-readable failure category.
3076 3132
3082 3138
3083 The model reached its output token limit before finishing the response.3139 The model reached its output token limit before finishing the response.
3084 3140
3141 - `"session_budget_exceeded"`
3142
3143 The session has reached its usage budget.
3144
3085 - `"usage_limit_exceeded"`3145 - `"usage_limit_exceeded"`
3086 3146
3087 The organization has reached a usage, plan, or billing limit.3147 The organization has reached a usage, plan, or billing limit.
3130 3190
3131 The request was blocked by the safety systems.3191 The request was blocked by the safety systems.
3132 3192
3193 - `"audio_input_unavailable"`
3194
3195 Audio input is unavailable for the organization.
3196
3133 - `"connection_failed"`3197 - `"connection_failed"`
3134 3198
3135 The request could not connect to the model service.3199 The request could not connect to the model service.
5433 5497
5434 - `"environment_connection"`5498 - `"environment_connection"`
5435 5499
5436 - `status: "idle" or "in_progress" or "requires_action" or "failed"`5500 - `spend_control: object { consumed, limit }`
5501
5502 Spending limit and best-effort consumption, in USD cents. The limit is null for an unlimited session. Consumption is null when unavailable.
5503
5504 - `consumed: integer or null`
5505
5506 Best-effort recorded spend floored to whole USD cents, or null when unavailable.
5507
5508 `minimum: 0`
5509
5510 - `limit: integer or null`
5511
5512 The configured positive limit in USD cents, or null when unlimited.
5513
5514 `format: int64`, `minimum: 1`, `maximum: 4503599627370495`
5515
5516 - `status: "idle" or "in_progress" or "requires_action" or 2 more`
5437 5517
5438 The current status of the session.5518 The current status of the session.
5439 5519
5453 5533
5454 The session failed.5534 The session failed.
5455 5535
5536 - `"budget_reached"`
5537
5538 The session is paused because its spending limit was reached.
5539
5456 - `usage: TokenUsage or null`5540 - `usage: TokenUsage or null`
5457 5541
5458 Best-effort token usage for the session, or null if unknown. Recorded usage may change.5542 Best-effort token usage for the session, or null if unknown. Recorded usage may change.
5542 "ttl": "30m"5626 "ttl": "30m"
5543 },5627 },
5544 "review": "none",5628 "review": "none",
5629 "spend_control": {
5630 "limit": 1,
5631 "consumed": 0
5632 },
5545 "metadata": {5633 "metadata": {
5546 "foo": "string"5634 "foo": "string"
5547 },5635 },
5626}5714}
5627```5715```
5628 5716
5629<a id="agent.session.in_progress"></a>5717<a id="agent.session.budget_reached"></a>
5630 5718
5631## agent.session.in_progress5719## agent.session.budget_reached
5632 5720
5633Emitted when a session starts processing a turn.5721Emitted when a session pauses because its spending limit was reached.
5634 5722
5635### Schema5723### Schema
5636 5724
5637Schema name: `SessionEventAgentSessionInProgress`5725Schema name: `SessionEventAgentSessionBudgetReached`
5638 5726
5639- `event_id: string`5727- `event_id: string`
5640 5728
5644 5732
5645- `session: AgentSession`5733- `session: AgentSession`
5646 5734
5647 The session that started processing.5735 The paused session.
5648 5736
5649 - `id: string`5737 - `id: string`
5650 5738
6590 6678
6591 - `"environment_connection"`6679 - `"environment_connection"`
6592 6680
6593 - `status: "idle" or "in_progress" or "requires_action" or "failed"`6681 - `spend_control: object { consumed, limit }`
6682
6683 Spending limit and best-effort consumption, in USD cents. The limit is null for an unlimited session. Consumption is null when unavailable.
6684
6685 - `consumed: integer or null`
6686
6687 Best-effort recorded spend floored to whole USD cents, or null when unavailable.
6688
6689 `minimum: 0`
6690
6691 - `limit: integer or null`
6692
6693 The configured positive limit in USD cents, or null when unlimited.
6694
6695 `format: int64`, `minimum: 1`, `maximum: 4503599627370495`
6696
6697 - `status: "idle" or "in_progress" or "requires_action" or 2 more`
6594 6698
6595 The current status of the session.6699 The current status of the session.
6596 6700
6610 6714
6611 The session failed.6715 The session failed.
6612 6716
6717 - `"budget_reached"`
6718
6719 The session is paused because its spending limit was reached.
6720
6613 - `usage: TokenUsage or null`6721 - `usage: TokenUsage or null`
6614 6722
6615 Best-effort token usage for the session, or null if unknown. Recorded usage may change.6723 Best-effort token usage for the session, or null if unknown. Recorded usage may change.
6676 6784
6677 - `"auto_review"`6785 - `"auto_review"`
6678 6786
6679- `type: "agent.session.in_progress" (default: "agent.session.in_progress")`6787- `type: "agent.session.budget_reached" (default: "agent.session.budget_reached")`
6680 6788
6681 The type of the object. Always `agent.session.in_progress`.6789 The type of the object. Always `agent.session.budget_reached`.
6682 6790
6683 - `"agent.session.in_progress"`6791 - `"agent.session.budget_reached"`
6684 6792
6685- `obfuscation: optional string`6793- `obfuscation: optional string`
6686 6794
6692 6800
6693```json6801```json
6694{6802{
6695 "type": "agent.session.in_progress",6803 "type": "agent.session.budget_reached"
6696 "event_id": "event_id",
6697 "session": {
6698 "prompt_cache_options": {
6699 "ttl": "30m"
6700 },
6701 "review": "none",
6702 "metadata": {
6703 "foo": "string"
6704 },
6705 "id": "id",
6706 "object": "agent.session",
6707 "created_at": 0,
6708 "last_active_at": 0,
6709 "status": "idle",
6710 "required_actions": [
6711 {
6712 "type": "mcp_approval_request",
6713 "turn_id": "turn_id",
6714 "request_id": "request_id",
6715 "request": {
6716 "type": "mcp_tool_call",
6717 "server_label": "server_label",
6718 "name": "name",
6719 "arguments": {},
6720 "message": "message"
6721 }
6722 }
6723 ],
6724 "error": "error",
6725 "agent": {
6726 "id": "id",
6727 "name": "name",
6728 "model": "model",
6729 "reasoning": {
6730 "effort": "none",
6731 "summary": "concise"
6732 },
6733 "text": {
6734 "format": {
6735 "type": "text"
6736 },
6737 "verbosity": "low"
6738 },
6739 "service_tier": "auto",
6740 "instructions": "instructions",
6741 "tools": [
6742 {
6743 "type": "function",
6744 "name": "name",
6745 "description": "description",
6746 "parameters": {
6747 "foo": "bar"
6748 },
6749 "defer_loading": true,
6750 "async": true
6751 }
6752 ],
6753 "multi_agent": {
6754 "enabled": true,
6755 "max_concurrent_subagents": 1
6756 },
6757 "compaction": {
6758 "async": true
6759 },
6760 "experimental": {
6761 "time_awareness": true
6762 }
6763 },
6764 "environment": {
6765 "type": "none"
6766 },
6767 "vault_ids": [
6768 "string"
6769 ],
6770 "usage": {
6771 "input_tokens": 0,
6772 "input_tokens_details": {
6773 "cached_tokens": 0
6774 },
6775 "output_tokens": 0,
6776 "output_tokens_details": {
6777 "reasoning_tokens": 0
6778 },
6779 "total_tokens": 0
6780 }
6781 },
6782 "obfuscation": "obfuscation"
6783}6804}
6784```6805```
6785 6806
6786<a id="agent.session.requires_action"></a>6807<a id="agent.session.in_progress"></a>
6787 6808
6788## agent.session.requires_action6809## agent.session.in_progress
6789 6810
6790Emitted when a session is waiting for one or more required actions.6811Emitted when a session starts processing a turn.
6791 6812
6792### Schema6813### Schema
6793 6814
6794Schema name: `SessionEventAgentSessionRequiresAction`6815Schema name: `SessionEventAgentSessionInProgress`
6795 6816
6796- `event_id: string`6817- `event_id: string`
6797 6818
6801 6822
6802- `session: AgentSession`6823- `session: AgentSession`
6803 6824
6804 The session and its current required actions.6825 The session that started processing.
6805 6826
6806 - `id: string`6827 - `id: string`
6807 6828
7747 7768
7748 - `"environment_connection"`7769 - `"environment_connection"`
7749 7770
7750 - `status: "idle" or "in_progress" or "requires_action" or "failed"`7771 - `spend_control: object { consumed, limit }`
7772
7773 Spending limit and best-effort consumption, in USD cents. The limit is null for an unlimited session. Consumption is null when unavailable.
7774
7775 - `consumed: integer or null`
7776
7777 Best-effort recorded spend floored to whole USD cents, or null when unavailable.
7778
7779 `minimum: 0`
7780
7781 - `limit: integer or null`
7782
7783 The configured positive limit in USD cents, or null when unlimited.
7784
7785 `format: int64`, `minimum: 1`, `maximum: 4503599627370495`
7786
7787 - `status: "idle" or "in_progress" or "requires_action" or 2 more`
7751 7788
7752 The current status of the session.7789 The current status of the session.
7753 7790
7767 7804
7768 The session failed.7805 The session failed.
7769 7806
7807 - `"budget_reached"`
7808
7809 The session is paused because its spending limit was reached.
7810
7770 - `usage: TokenUsage or null`7811 - `usage: TokenUsage or null`
7771 7812
7772 Best-effort token usage for the session, or null if unknown. Recorded usage may change.7813 Best-effort token usage for the session, or null if unknown. Recorded usage may change.
7833 7874
7834 - `"auto_review"`7875 - `"auto_review"`
7835 7876
7836- `type: "agent.session.requires_action" (default: "agent.session.requires_action")`7877- `type: "agent.session.in_progress" (default: "agent.session.in_progress")`
7837 7878
7838 The type of the object. Always `agent.session.requires_action`.7879 The type of the object. Always `agent.session.in_progress`.
7839 7880
7840 - `"agent.session.requires_action"`7881 - `"agent.session.in_progress"`
7841 7882
7842- `obfuscation: optional string`7883- `obfuscation: optional string`
7843 7884
7849 7890
7850```json7891```json
7851{7892{
7852 "type": "agent.session.requires_action",7893 "type": "agent.session.in_progress",
7853 "event_id": "event_id",7894 "event_id": "event_id",
7854 "session": {7895 "session": {
7855 "prompt_cache_options": {7896 "prompt_cache_options": {
7856 "ttl": "30m"7897 "ttl": "30m"
7857 },7898 },
7858 "review": "none",7899 "review": "none",
7900 "spend_control": {
7901 "limit": 1,
7902 "consumed": 0
7903 },
7859 "metadata": {7904 "metadata": {
7860 "foo": "string"7905 "foo": "string"
7861 },7906 },
7940}7985}
7941```7986```
7942 7987
7943<a id="agent.session.failed"></a>7988<a id="agent.session.requires_action"></a>
7944 7989
7945## agent.session.failed7990## agent.session.requires_action
7946 7991
7947Emitted when a session fails.7992Emitted when a session is waiting for one or more required actions.
7948 7993
7949### Schema7994### Schema
7950 7995
7951Schema name: `SessionEventAgentSessionFailed`7996Schema name: `SessionEventAgentSessionRequiresAction`
7952 7997
7953- `event_id: string`7998- `event_id: string`
7954 7999
7958 8003
7959- `session: AgentSession`8004- `session: AgentSession`
7960 8005
7961 The failed session.8006 The session and its current required actions.
7962 8007
7963 - `id: string`8008 - `id: string`
7964 8009
8904 8949
8905 - `"environment_connection"`8950 - `"environment_connection"`
8906 8951
8907 - `status: "idle" or "in_progress" or "requires_action" or "failed"`8952 - `spend_control: object { consumed, limit }`
8953
8954 Spending limit and best-effort consumption, in USD cents. The limit is null for an unlimited session. Consumption is null when unavailable.
8955
8956 - `consumed: integer or null`
8957
8958 Best-effort recorded spend floored to whole USD cents, or null when unavailable.
8959
8960 `minimum: 0`
8961
8962 - `limit: integer or null`
8963
8964 The configured positive limit in USD cents, or null when unlimited.
8965
8966 `format: int64`, `minimum: 1`, `maximum: 4503599627370495`
8967
8968 - `status: "idle" or "in_progress" or "requires_action" or 2 more`
8908 8969
8909 The current status of the session.8970 The current status of the session.
8910 8971
8924 8985
8925 The session failed.8986 The session failed.
8926 8987
8988 - `"budget_reached"`
8989
8990 The session is paused because its spending limit was reached.
8991
8927 - `usage: TokenUsage or null`8992 - `usage: TokenUsage or null`
8928 8993
8929 Best-effort token usage for the session, or null if unknown. Recorded usage may change.8994 Best-effort token usage for the session, or null if unknown. Recorded usage may change.
8990 9055
8991 - `"auto_review"`9056 - `"auto_review"`
8992 9057
8993- `type: "agent.session.failed" (default: "agent.session.failed")`9058- `type: "agent.session.requires_action" (default: "agent.session.requires_action")`
8994 9059
8995 The type of the object. Always `agent.session.failed`.9060 The type of the object. Always `agent.session.requires_action`.
8996 9061
8997 - `"agent.session.failed"`9062 - `"agent.session.requires_action"`
8998 9063
8999- `obfuscation: optional string`9064- `obfuscation: optional string`
9000 9065
9006 9071
9007```json9072```json
9008{9073{
9009 "type": "agent.session.failed",9074 "type": "agent.session.requires_action",
9010 "event_id": "event_id",9075 "event_id": "event_id",
9011 "session": {9076 "session": {
9012 "prompt_cache_options": {9077 "prompt_cache_options": {
9013 "ttl": "30m"9078 "ttl": "30m"
9014 },9079 },
9015 "review": "none",9080 "review": "none",
9081 "spend_control": {
9082 "limit": 1,
9083 "consumed": 0
9084 },
9085 "metadata": {
9086 "foo": "string"
9087 },
9088 "id": "id",
9089 "object": "agent.session",
9090 "created_at": 0,
9091 "last_active_at": 0,
9092 "status": "idle",
9093 "required_actions": [
9094 {
9095 "type": "mcp_approval_request",
9096 "turn_id": "turn_id",
9097 "request_id": "request_id",
9098 "request": {
9099 "type": "mcp_tool_call",
9100 "server_label": "server_label",
9101 "name": "name",
9102 "arguments": {},
9103 "message": "message"
9104 }
9105 }
9106 ],
9107 "error": "error",
9108 "agent": {
9109 "id": "id",
9110 "name": "name",
9111 "model": "model",
9112 "reasoning": {
9113 "effort": "none",
9114 "summary": "concise"
9115 },
9116 "text": {
9117 "format": {
9118 "type": "text"
9119 },
9120 "verbosity": "low"
9121 },
9122 "service_tier": "auto",
9123 "instructions": "instructions",
9124 "tools": [
9125 {
9126 "type": "function",
9127 "name": "name",
9128 "description": "description",
9129 "parameters": {
9130 "foo": "bar"
9131 },
9132 "defer_loading": true,
9133 "async": true
9134 }
9135 ],
9136 "multi_agent": {
9137 "enabled": true,
9138 "max_concurrent_subagents": 1
9139 },
9140 "compaction": {
9141 "async": true
9142 },
9143 "experimental": {
9144 "time_awareness": true
9145 }
9146 },
9147 "environment": {
9148 "type": "none"
9149 },
9150 "vault_ids": [
9151 "string"
9152 ],
9153 "usage": {
9154 "input_tokens": 0,
9155 "input_tokens_details": {
9156 "cached_tokens": 0
9157 },
9158 "output_tokens": 0,
9159 "output_tokens_details": {
9160 "reasoning_tokens": 0
9161 },
9162 "total_tokens": 0
9163 }
9164 },
9165 "obfuscation": "obfuscation"
9166}
9167```
9168
9169<a id="agent.session.failed"></a>
9170
9171## agent.session.failed
9172
9173Emitted when a session fails.
9174
9175### Schema
9176
9177Schema name: `SessionEventAgentSessionFailed`
9178
9179- `event_id: string`
9180
9181 The unique ID of the event.
9182
9183 `minLength: 0`
9184
9185- `session: AgentSession`
9186
9187 The failed session.
9188
9189 - `id: string`
9190
9191 The ID of the session.
9192
9193 `minLength: 0`
9194
9195 - `agent: object { id, instructions, model, 8 more }`
9196
9197 The agent running in the session.
9198
9199 - `id: string`
9200
9201 The ID of the agent.
9202
9203 `minLength: 0`
9204
9205 - `instructions: string or null`
9206
9207 Custom instructions appended to the agent's default base instructions.
9208
9209 `minLength: 0`
9210
9211 - `model: string`
9212
9213 The model used by the agent.
9214
9215 `minLength: 0`
9216
9217 - `multi_agent: MultiAgentConfig`
9218
9219 Configuration for creating and coordinating subagents.
9220
9221 - `enabled: boolean`
9222
9223 Whether subagent tools are enabled. Defaults to false.
9224
9225 - `max_concurrent_subagents: integer or null`
9226
9227 Maximum number of subagents that may run concurrently, or null when disabled. Defaults to 6 when enabled.
9228
9229 `format: int64`, `minimum: 1`, `maximum: 4294967295`
9230
9231 - `name: string or null`
9232
9233 The reusable agent's name when the session was created, or null if no name was saved. Later changes to the agent's name do not affect this value.
9234
9235 `minLength: 0`
9236
9237 - `reasoning: AgentReasoning`
9238
9239 The agent's reasoning configuration.
9240
9241 - `effort: "none" or "minimal" or "low" or 4 more or null`
9242
9243 The requested reasoning effort, or `null` when the model selects its own default.
9244
9245 - `"none"`
9246
9247 - `"minimal"`
9248
9249 - `"low"`
9250
9251 - `"medium"`
9252
9253 - `"high"`
9254
9255 - `"xhigh"`
9256
9257 - `"max"`
9258
9259 - `summary: "concise" or "detailed" or "auto" or null`
9260
9261 The requested reasoning summary format, or `null` when summaries are disabled.
9262
9263 - `"concise"`
9264
9265 Returns a concise reasoning summary when supported.
9266
9267 - `"detailed"`
9268
9269 Returns a detailed reasoning summary when supported.
9270
9271 - `"auto"`
9272
9273 Automatically selects the most detailed summary supported by the model.
9274
9275 - `service_tier: "auto" or "default" or "flex" or 3 more`
9276
9277 The effective service-tier policy for model requests. Defaults to `auto`.
9278
9279 - `"auto"`
9280
9281 - `"default"`
9282
9283 - `"flex"`
9284
9285 - `"priority"`
9286
9287 - `"fast"`
9288
9289 - `"ultrafast"`
9290
9291 - `text: AgentText`
9292
9293 Configuration for text generated by the agent.
9294
9295 - `format: TextFormat`
9296
9297 The effective output format. Defaults to ordinary text.
9298
9299 - `Text object { type }`
9300
9301 Generates ordinary text without a structured-output constraint.
9302
9303 - `type: "text" (default: "text")`
9304
9305 The type of the object. Always `text`.
9306
9307 - `"text"`
9308
9309 - `JSONSchema object { schema, type }`
9310
9311 Constrains generated text to a JSON Schema.
9312
9313 - `schema: map[unknown]`
9314
9315 The JSON Schema that generated text must match.
9316
9317 - `type: "json_schema" (default: "json_schema")`
9318
9319 The type of the object. Always `json_schema`.
9320
9321 - `"json_schema"`
9322
9323 - `verbosity: "low" or "medium" or "high"`
9324
9325 The amount of text produced by the agent. Defaults to `medium`.
9326
9327 - `"low"`
9328
9329 - `"medium"`
9330
9331 - `"high"`
9332
9333 - `tools: array of AgentTool`
9334
9335 Tools available to the agent.
9336
9337 `minItems: 0`, `maxItems: 2000`
9338
9339 - `Function object { defer_loading, description, name, 3 more }`
9340
9341 A function defined by the application.
9342
9343 - `defer_loading: boolean`
9344
9345 Whether the function is deferred and discovered through tool search.
9346
9347 - `description: string`
9348
9349 A description of what the function does.
9350
9351 `minLength: 0`
9352
9353 - `name: string`
9354
9355 The name of the function.
9356
9357 `minLength: 0`
9358
9359 - `parameters: map[unknown]`
9360
9361 A JSON Schema object describing the function's arguments.
9362
9363 - `type: "function" (default: "function")`
9364
9365 The type of the object. Always `function`.
9366
9367 - `"function"`
9368
9369 - `async: optional boolean`
9370
9371 Whether the agent continues without waiting for the function result.
9372
9373 - `ProgrammaticToolCalling object { enabled, type }`
9374
9375 Enables calling tools from model-generated code.
9376
9377 - `enabled: boolean`
9378
9379 Whether tools can be called from model-generated code.
9380
9381 - `type: "programmatic_tool_calling" (default: "programmatic_tool_calling")`
9382
9383 The type of the object. Always `programmatic_tool_calling`.
9384
9385 - `"programmatic_tool_calling"`
9386
9387 - `Mcp object { allowed_tools, connection_origin, credential_id, 5 more }`
9388
9389 Tools provided by a remote MCP server.
9390
9391 - `allowed_tools: array of string or null`
9392
9393 The MCP tools the agent may call.
9394
9395 `minItems: 0`, `maxItems: 2000`
9396
9397 - `connection_origin: "service" or "environment"`
9398
9399 Where outbound MCP HTTP connections originate.
9400
9401 - `"service"`
9402
9403 - `"environment"`
9404
9405 - `credential_id: string or null`
9406
9407 The attached vault credential selected for this MCP server, if any. Optional when exactly one attached credential matches the server URL.
9408
9409 `minLength: 0`
9410
9411 - `request_metadata: map[unknown]`
9412
9413 Metadata included with requests to this MCP server.
9414
9415 - `required: boolean`
9416
9417 Whether this MCP server must initialize before the first turn.
9418
9419 - `server_label: string`
9420
9421 A label used to identify the MCP server in tool calls.
9422
9423 `minLength: 0`
9424
9425 - `transport: McpTransport`
9426
9427 The transport used to connect to the MCP server.
9428
9429 - `HTTP object { server_url, type }`
9430
9431 Connects to an MCP server over HTTP.
9432
9433 - `server_url: string`
9434
9435 The URL of the MCP server.
9436
9437 `minLength: 0`
9438
9439 - `type: "http" (default: "http")`
9440
9441 The type of the object. Always `http`.
9442
9443 - `"http"`
9444
9445 - `Stdio object { args, command, cwd, 2 more }`
9446
9447 Starts an MCP server as a local process.
9448
9449 - `args: array of string`
9450
9451 Arguments passed to the MCP server command.
9452
9453 `minItems: 0`, `maxItems: 2000`
9454
9455 - `command: string`
9456
9457 The command used to start the MCP server.
9458
9459 `minLength: 0`
9460
9461 - `cwd: string`
9462
9463 The working directory used to start the MCP server.
9464
9465 `minLength: 0`
9466
9467 - `env_vars: array of string`
9468
9469 Environment variable names inherited from the execution environment.
9470
9471 `minItems: 0`, `maxItems: 2000`
9472
9473 - `type: "stdio" (default: "stdio")`
9474
9475 The type of the object. Always `stdio`.
9476
9477 - `"stdio"`
9478
9479 - `type: "mcp" (default: "mcp")`
9480
9481 The type of the object. Always `mcp`.
9482
9483 - `"mcp"`
9484
9485 - `WebSearch object { allowed_domains, context_size, location, 2 more }`
9486
9487 Web search.
9488
9489 - `allowed_domains: array of string or null`
9490
9491 Allowed search domains, or `null` when the search is unrestricted.
9492
9493 `minItems: 0`, `maxItems: 2000`
9494
9495 - `context_size: "low" or "medium" or "high"`
9496
9497 The amount of search context made available to the model. Defaults to `medium`.
9498
9499 - `"low"`
9500
9501 - `"medium"`
9502
9503 - `"high"`
9504
9505 - `location: object { city, country, region, timezone } or null`
9506
9507 Approximate location used to localize search results, if provided.
9508
9509 - `city: string or null`
9510
9511 The city name.
9512
9513 `minLength: 0`
9514
9515 - `country: string or null`
9516
9517 The two-letter ISO country code, such as `US`.
9518
9519 `minLength: 0`
9520
9521 - `region: string or null`
9522
9523 The region or state name.
9524
9525 `minLength: 0`
9526
9527 - `timezone: string or null`
9528
9529 The IANA timezone, such as `America/Los_Angeles`.
9530
9531 `minLength: 0`
9532
9533 - `mode: "disabled" or "cached" or "live"`
9534
9535 The source used for web search results.
9536
9537 - `"disabled"`
9538
9539 - `"cached"`
9540
9541 - `"live"`
9542
9543 - `type: "web_search" (default: "web_search")`
9544
9545 The type of the object. Always `web_search`.
9546
9547 - `"web_search"`
9548
9549 - `ComputerUse object { include_screenshots, type }`
9550
9551 Browser use in an OpenAI-hosted session.
9552
9553 - `include_screenshots: boolean`
9554
9555 Whether computer tool outputs include screenshots.
9556
9557 - `type: "computer_use" (default: "computer_use")`
9558
9559 The type of the object. Always `computer_use`.
9560
9561 - `"computer_use"`
9562
9563 - `Automations object { type }`
9564
9565 Lets the agent manage its own scheduled wakeups.
9566
9567 - `type: "automations" (default: "automations")`
9568
9569 The type of the object. Always `automations`.
9570
9571 - `"automations"`
9572
9573 - `compaction: optional object { async }`
9574
9575 The effective context compaction settings.
9576
9577 - `async: boolean`
9578
9579 Whether context is compacted in the background. Defaults to false.
9580
9581 - `experimental: optional object { time_awareness }`
9582
9583 The effective experimental settings for the agent.
9584
9585 - `time_awareness: boolean`
9586
9587 Whether the model receives periodic current-time reminders.
9588
9589 - `created_at: integer`
9590
9591 The Unix timestamp, in seconds, when the session was created.
9592
9593 `format: int64`
9594
9595 - `environment: Environment`
9596
9597 The execution environment for the session.
9598
9599 - `None object { type }`
9600
9601 The session talks to CCA without selecting or provisioning an execution environment.
9602
9603 - `type: "none" (default: "none")`
9604
9605 The type of the object. Always `none`.
9606
9607 - `"none"`
9608
9609 - `OpenAIHosted object { id, capability_directories, desktop, 7 more }`
9610
9611 An environment hosted by OpenAI.
9612
9613 - `id: string`
9614
9615 The public ID of the environment.
9616
9617 `minLength: 0`
9618
9619 - `capability_directories: array of string`
9620
9621 Directories that contain capabilities exposed to the agent.
9622
9623 `minItems: 0`, `maxItems: 2000`
9624
9625 - `desktop: object { enabled }`
9626
9627 The effective desktop configuration.
9628
9629 - `enabled: boolean`
9630
9631 Whether the environment provisions a desktop and browser proxy.
9632
9633 - `files: array of HostedEnvironmentFile`
9634
9635 Files available in the environment, excluding their contents.
9636
9637 `minItems: 0`, `maxItems: 50`
9638
9639 - `HostedEnvironmentFileID object { id, file_id, path, 2 more }`
9640
9641 A file copied from the OpenAI Files API.
9642
9643 - `id: string`
9644
9645 The session-scoped ID of the file in the execution environment.
9646
9647 `minLength: 0`
9648
9649 - `file_id: string`
9650
9651 The ID of the uploaded file.
9652
9653 `minLength: 0`
9654
9655 - `path: string`
9656
9657 The file's absolute path inside the environment.
9658
9659 `minLength: 0`
9660
9661 - `size_bytes: integer`
9662
9663 The decoded file size in bytes.
9664
9665 `format: int64`, `minimum: 0`
9666
9667 - `type: "file_id" (default: "file_id")`
9668
9669 The type of the object. Always `file_id`.
9670
9671 - `"file_id"`
9672
9673 - `Inline object { id, path, size_bytes, type }`
9674
9675 A file supplied inline when the session was created.
9676
9677 - `id: string`
9678
9679 The session-scoped ID of the file in the execution environment.
9680
9681 `minLength: 0`
9682
9683 - `path: string`
9684
9685 The file's absolute path inside the environment.
9686
9687 `minLength: 0`
9688
9689 - `size_bytes: integer`
9690
9691 The decoded file size in bytes.
9692
9693 `format: int64`, `minimum: 0`
9694
9695 - `type: "inline" (default: "inline")`
9696
9697 The type of the object. Always `inline`.
9698
9699 - `"inline"`
9700
9701 - `network: object { access, allowed_domains }`
9702
9703 The effective network access policy for the environment.
9704
9705 - `access: "enabled" or "disabled" or "restricted"`
9706
9707 The environment's network access mode.
9708
9709 - `"enabled"`
9710
9711 Allows unrestricted network access.
9712
9713 - `"disabled"`
9714
9715 Disables network access.
9716
9717 - `"restricted"`
9718
9719 Applies the configured domain restrictions.
9720
9721 - `allowed_domains: array of string`
9722
9723 Domains the environment may access when network access is restricted.
9724
9725 `minItems: 0`, `maxItems: 2000`
9726
9727 - `packages: object { npm, python, system }`
9728
9729 Packages installed in the environment.
9730
9731 - `npm: array of string`
9732
9733 npm packages installed globally in the environment.
9734
9735 `minItems: 0`, `maxItems: 16384`
9736
9737 - `python: array of string`
9738
9739 Python packages installed in the environment.
9740
9741 `minItems: 0`, `maxItems: 16384`
9742
9743 - `system: array of string`
9744
9745 System packages installed in the environment.
9746
9747 `minItems: 0`, `maxItems: 16384`
9748
9749 - `plugins: array of HostedPlugin`
9750
9751 Plugins installed in the environment, excluding their archive contents.
9752
9753 `minItems: 0`, `maxItems: 2000`
9754
9755 - `description: string`
9756
9757 The installed plugin description.
9758
9759 `minLength: 0`
9760
9761 - `name: string`
9762
9763 The installed plugin name.
9764
9765 `minLength: 0`
9766
9767 - `type: "inline" (default: "inline")`
9768
9769 The type of the object. Always `inline`.
9770
9771 - `"inline"`
9772
9773 - `skills: array of HostedSkill`
9774
9775 Skills installed in the environment, excluding their archive contents.
9776
9777 `minItems: 0`, `maxItems: 2000`
9778
9779 - `HostedSkillReference object { description, name, skill_id, 2 more }`
9780
9781 A skill installed from the Skills API.
9782
9783 - `description: string`
9784
9785 The installed skill description.
9786
9787 `minLength: 0`
9788
9789 - `name: string`
9790
9791 The installed skill name.
9792
9793 `minLength: 0`
9794
9795 - `skill_id: string`
9796
9797 The referenced skill ID.
9798
9799 `minLength: 0`
9800
9801 - `type: "skill_reference" (default: "skill_reference")`
9802
9803 The type of the object. Always `skill_reference`.
9804
9805 - `"skill_reference"`
9806
9807 - `version: string`
9808
9809 The concrete skill version installed for this session.
9810
9811 `minLength: 0`
9812
9813 - `Inline object { description, name, type }`
9814
9815 A skill installed from an inline ZIP archive.
9816
9817 - `description: string`
9818
9819 The installed skill description.
9820
9821 `minLength: 0`
9822
9823 - `name: string`
9824
9825 The installed skill name.
9826
9827 `minLength: 0`
9828
9829 - `type: "inline" (default: "inline")`
9830
9831 The type of the object. Always `inline`.
9832
9833 - `"inline"`
9834
9835 - `type: "openai_hosted" (default: "openai_hosted")`
9836
9837 The type of the object. Always `openai_hosted`.
9838
9839 - `"openai_hosted"`
9840
9841 - `container_size: optional "small" or "medium" or "large" or null`
9842
9843 The effective CPU and memory tier, or null when unknown or outside the public tiers.
9844
9845 - `"small"`
9846
9847 - `"medium"`
9848
9849 - `"large"`
9850
9851 - `SelfHosted object { id, capability_directories, remote_url, 2 more }`
9852
9853 An environment hosted by the application.
9854
9855 - `id: string`
9856
9857 The public ID of the environment.
9858
9859 `minLength: 0`
9860
9861 - `capability_directories: array of string`
9862
9863 Directories that contain capabilities exposed to the agent.
9864
9865 `minItems: 0`, `maxItems: 2000`
9866
9867 - `remote_url: string`
9868
9869 Pass this URL unchanged to `codex exec-server --remote` when connecting this environment.
9870
9871 `minLength: 0`
9872
9873 - `type: "self_hosted" (default: "self_hosted")`
9874
9875 The type of the object. Always `self_hosted`.
9876
9877 - `"self_hosted"`
9878
9879 - `workspace_directory: string`
9880
9881 The absolute project directory inside the environment. Defaults to `/workspace`.
9882
9883 `minLength: 0`
9884
9885 - `error: string or null`
9886
9887 The error that caused the session to fail, if any.
9888
9889 `minLength: 0`
9890
9891 - `last_active_at: integer`
9892
9893 The Unix timestamp, in seconds, when the session was last active.
9894
9895 `format: int64`
9896
9897 - `metadata: map[string]`
9898
9899 Custom string key-value pairs attached to the session.
9900
9901 - `object: "agent.session" (default: "agent.session")`
9902
9903 The object type. Always `agent.session`.
9904
9905 - `"agent.session"`
9906
9907 - `required_actions: array of McpApprovalRequest { request, request_id, turn_id, type } or ComputerUseApprovalRequest { request, request_id, turn_id, type } or FunctionCall { arguments, call_id, name, 2 more } or EnvironmentConnection { environment_id, type }`
9908
9909 Actions that must be completed before the session can continue.
9910
9911 `minItems: 0`, `maxItems: 2000`
9912
9913 - `McpApprovalRequest object { request, request_id, turn_id, type }`
9914
9915 Respond to an MCP tool-call approval request.
9916
9917 - `request: object { arguments, message, name, 2 more }`
9918
9919 Information for presenting an MCP approval.
9920
9921 - `arguments: unknown`
9922
9923 The tool arguments as JSON, or null when CCA does not provide them.
9924
9925 - `message: string`
9926
9927 `minLength: 0`
9928
9929 - `name: string or null`
9930
9931 The tool name, or null when CCA does not provide it.
9932
9933 `minLength: 0`
9934
9935 - `server_label: string`
9936
9937 `minLength: 0`
9938
9939 - `type: "mcp_tool_call" (default: "mcp_tool_call")`
9940
9941 The type of the object. Always `mcp_tool_call`.
9942
9943 - `"mcp_tool_call"`
9944
9945 - `request_id: string`
9946
9947 The opaque approval ID to echo when responding.
9948
9949 `minLength: 0`
9950
9951 - `turn_id: string`
9952
9953 The turn that requested approval.
9954
9955 `minLength: 0`
9956
9957 - `type: "mcp_approval_request" (default: "mcp_approval_request")`
9958
9959 The type of the object. Always `mcp_approval_request`.
9960
9961 - `"mcp_approval_request"`
9962
9963 - `ComputerUseApprovalRequest object { request, request_id, turn_id, type }`
9964
9965 Respond to a computer-use request.
9966
9967 - `request: BrowserAuthentication { credential_origin, fields, options, 2 more } or BrowserOriginAccess { origin, reason, type }`
9968
9969 The information needed to render the request.
9970
9971 - `BrowserAuthentication object { credential_origin, fields, options, 2 more }`
9972
9973 A registered form awaiting the application's response.
9974
9975 - `credential_origin: string or null`
9976
9977 The registered form or frame origin where values will be entered.
9978
9979 `minLength: 0`
9980
9981 - `fields: array of object { id, label, required, type }`
9982
9983 Controls to render. All submitted values are sensitive.
9984
9985 `minItems: 0`, `maxItems: 2000`
9986
9987 - `id: string`
9988
9989 The field ID to submit as field_id in a fields entry.
9990
9991 `minLength: 0`
9992
9993 - `label: string`
9994
9995 The label to display beside the control.
9996
9997 `minLength: 0`
9998
9999 - `required: boolean`
10000
10001 Whether this control requires a nonempty value.
10002
10003 - `type: string`
10004
10005 The rendering type, such as email, password, or text.
10006
10007 `minLength: 0`
10008
10009 - `options: array of object { id, field_ids, label }`
10010
10011 Sign-in methods. Empty for a plain form.
10012
10013 `minItems: 0`, `maxItems: 2000`
10014
10015 - `id: string`
10016
10017 The option ID to submit as selected_option.
10018
10019 `minLength: 0`
10020
10021 - `field_ids: array of string`
10022
10023 IDs from the registered fields that this method accepts.
10024
10025 `minItems: 0`, `maxItems: 2000`
10026
10027 - `label: string`
10028
10029 The method label to display.
10030
10031 `minLength: 0`
10032
10033 - `reason: string or null`
10034
10035 Why the agent needs the user to sign in.
10036
10037 `minLength: 0`
10038
10039 - `type: "browser_authentication" (default: "browser_authentication")`
10040
10041 The type of the object. Always `browser_authentication`.
10042
10043 - `"browser_authentication"`
10044
10045 - `BrowserOriginAccess object { origin, reason, type }`
10046
10047 A browser origin awaiting the application's approval decision.
10048
10049 - `origin: string`
10050
10051 The origin the browser needs permission to access.
10052
10053 `minLength: 0`
10054
10055 - `reason: string or null`
10056
10057 The browser's explanation for this request, or null when unavailable.
10058
10059 `minLength: 0`
10060
10061 - `type: "browser_origin_access" (default: "browser_origin_access")`
10062
10063 The type of the object. Always `browser_origin_access`.
10064
10065 - `"browser_origin_access"`
10066
10067 - `request_id: string`
10068
10069 The registered request ID to echo when responding.
10070
10071 `minLength: 0`
10072
10073 - `turn_id: string`
10074
10075 The turn that requested approval.
10076
10077 `minLength: 0`
10078
10079 - `type: "computer_use_approval_request" (default: "computer_use_approval_request")`
10080
10081 The type of the object. Always `computer_use_approval_request`.
10082
10083 - `"computer_use_approval_request"`
10084
10085 - `FunctionCall object { arguments, call_id, name, 2 more }`
10086
10087 Run a function tool and submit its result.
10088
10089 - `arguments: unknown`
10090
10091 The arguments supplied by the model.
10092
10093 - `call_id: string`
10094
10095 The ID to include when submitting the function result.
10096
10097 `minLength: 0`
10098
10099 - `name: string`
10100
10101 The function name.
10102
10103 `minLength: 0`
10104
10105 - `turn_id: string`
10106
10107 The ID of the turn that requested the function call.
10108
10109 `minLength: 0`
10110
10111 - `type: "function_call" (default: "function_call")`
10112
10113 The type of the object. Always `function_call`.
10114
10115 - `"function_call"`
10116
10117 - `EnvironmentConnection object { environment_id, type }`
10118
10119 Reconnect a session environment.
10120
10121 - `environment_id: string`
10122
10123 The ID of the environment to reconnect.
10124
10125 `minLength: 0`
10126
10127 - `type: "environment_connection" (default: "environment_connection")`
10128
10129 The type of the object. Always `environment_connection`.
10130
10131 - `"environment_connection"`
10132
10133 - `spend_control: object { consumed, limit }`
10134
10135 Spending limit and best-effort consumption, in USD cents. The limit is null for an unlimited session. Consumption is null when unavailable.
10136
10137 - `consumed: integer or null`
10138
10139 Best-effort recorded spend floored to whole USD cents, or null when unavailable.
10140
10141 `minimum: 0`
10142
10143 - `limit: integer or null`
10144
10145 The configured positive limit in USD cents, or null when unlimited.
10146
10147 `format: int64`, `minimum: 1`, `maximum: 4503599627370495`
10148
10149 - `status: "idle" or "in_progress" or "requires_action" or 2 more`
10150
10151 The current status of the session.
10152
10153 - `"idle"`
10154
10155 The session has no turn in progress and is ready for input. A hosted environment may still be provisioning.
10156
10157 - `"in_progress"`
10158
10159 The session is processing a turn.
10160
10161 - `"requires_action"`
10162
10163 The session is waiting for one or more required actions.
10164
10165 - `"failed"`
10166
10167 The session failed.
10168
10169 - `"budget_reached"`
10170
10171 The session is paused because its spending limit was reached.
10172
10173 - `usage: TokenUsage or null`
10174
10175 Best-effort token usage for the session, or null if unknown. Recorded usage may change.
10176
10177 - `input_tokens: integer`
10178
10179 The number of input tokens used by the agent.
10180
10181 `format: int64`
10182
10183 - `input_tokens_details: object { cached_tokens }`
10184
10185 A breakdown of the agent's input token usage.
10186
10187 - `cached_tokens: integer`
10188
10189 The number of input tokens retrieved from the prompt cache.
10190
10191 `format: int64`
10192
10193 - `output_tokens: integer`
10194
10195 The number of output tokens generated by the agent.
10196
10197 `format: int64`
10198
10199 - `output_tokens_details: object { reasoning_tokens }`
10200
10201 A breakdown of the agent's output token usage.
10202
10203 - `reasoning_tokens: integer`
10204
10205 The number of output tokens used for reasoning.
10206
10207 `format: int64`
10208
10209 - `total_tokens: integer`
10210
10211 The total number of input and output tokens used by the agent.
10212
10213 `format: int64`
10214
10215 - `vault_ids: array of string`
10216
10217 The IDs of vaults made available to the session.
10218
10219 `minItems: 0`, `maxItems: 2000`
10220
10221 - `prompt_cache_options: optional object { ttl } or null`
10222
10223 Default prompt cache lifetime for turns in this session, when configured.
10224
10225 - `ttl: "30m" or "12h"`
10226
10227 - `"30m"`
10228
10229 - `"12h"`
10230
10231 - `review: optional "none" or "auto_review"`
10232
10233 Review applied to eligible actions in this session. Omitted when review is none and automatic review is not enabled. Omission means none.
10234
10235 - `"none"`
10236
10237 - `"auto_review"`
10238
10239- `type: "agent.session.failed" (default: "agent.session.failed")`
10240
10241 The type of the object. Always `agent.session.failed`.
10242
10243 - `"agent.session.failed"`
10244
10245- `obfuscation: optional string`
10246
10247 Random alphanumeric padding. Present when stream obfuscation is enabled.
10248
10249 `minLength: 0`
10250
10251### Example
10252
10253```json
10254{
10255 "type": "agent.session.failed",
10256 "event_id": "event_id",
10257 "session": {
10258 "prompt_cache_options": {
10259 "ttl": "30m"
10260 },
10261 "review": "none",
10262 "spend_control": {
10263 "limit": 1,
10264 "consumed": 0
10265 },
9016 "metadata": {10266 "metadata": {
9017 "foo": "string"10267 "foo": "string"
9018 },10268 },