@ellipsis-dev/sdk 0.34.1 → 0.36.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1503,12 +1503,14 @@
1503
1503
  "discriminator": {
1504
1504
  "mapping": {
1505
1505
  "agentMessage": "#/$defs/CodexAgentMessage",
1506
+ "collabAgentToolCall": "#/$defs/CodexCollabAgentToolCall",
1506
1507
  "commandExecution": "#/$defs/CodexCommandExecution",
1507
1508
  "contextCompaction": "#/$defs/CodexContextCompaction",
1508
1509
  "fileChange": "#/$defs/CodexFileChange",
1509
1510
  "mcpToolCall": "#/$defs/CodexMcpToolCall",
1510
1511
  "plan": "#/$defs/CodexPlan",
1511
1512
  "reasoning": "#/$defs/CodexReasoning",
1513
+ "subAgentActivity": "#/$defs/CodexSubAgentActivity",
1512
1514
  "userMessage": "#/$defs/CodexUserMessage",
1513
1515
  "webSearch": "#/$defs/CodexWebSearch"
1514
1516
  },
@@ -1541,6 +1543,12 @@
1541
1543
  },
1542
1544
  {
1543
1545
  "$ref": "#/$defs/CodexContextCompaction"
1546
+ },
1547
+ {
1548
+ "$ref": "#/$defs/CodexSubAgentActivity"
1549
+ },
1550
+ {
1551
+ "$ref": "#/$defs/CodexCollabAgentToolCall"
1544
1552
  }
1545
1553
  ]
1546
1554
  },
@@ -1740,6 +1748,67 @@
1740
1748
  "type": "object",
1741
1749
  "x-ellipsis-preserve-payload": true
1742
1750
  },
1751
+ "CodexCollabAgentToolCall": {
1752
+ "additionalProperties": true,
1753
+ "properties": {
1754
+ "id": {
1755
+ "title": "Id",
1756
+ "type": "string"
1757
+ },
1758
+ "prompt": {
1759
+ "anyOf": [
1760
+ {
1761
+ "type": "string"
1762
+ },
1763
+ {
1764
+ "type": "null"
1765
+ }
1766
+ ],
1767
+ "default": null,
1768
+ "title": "Prompt"
1769
+ },
1770
+ "receiverThreadIds": {
1771
+ "items": {
1772
+ "type": "string"
1773
+ },
1774
+ "title": "Receiverthreadids",
1775
+ "type": "array"
1776
+ },
1777
+ "senderThreadId": {
1778
+ "title": "Senderthreadid",
1779
+ "type": "string"
1780
+ },
1781
+ "status": {
1782
+ "enum": [
1783
+ "inProgress",
1784
+ "completed",
1785
+ "failed"
1786
+ ],
1787
+ "title": "Status",
1788
+ "type": "string"
1789
+ },
1790
+ "tool": {
1791
+ "title": "Tool",
1792
+ "type": "string"
1793
+ },
1794
+ "type": {
1795
+ "const": "collabAgentToolCall",
1796
+ "default": "collabAgentToolCall",
1797
+ "title": "Type",
1798
+ "type": "string"
1799
+ }
1800
+ },
1801
+ "required": [
1802
+ "id",
1803
+ "receiverThreadIds",
1804
+ "senderThreadId",
1805
+ "status",
1806
+ "tool",
1807
+ "type"
1808
+ ],
1809
+ "title": "CodexCollabAgentToolCall",
1810
+ "type": "object"
1811
+ },
1743
1812
  "CodexCommandExecution": {
1744
1813
  "additionalProperties": true,
1745
1814
  "properties": {
@@ -3070,6 +3139,50 @@
3070
3139
  "type": "object",
3071
3140
  "x-ellipsis-preserve-payload": true
3072
3141
  },
3142
+ "CodexSubAgentActivity": {
3143
+ "additionalProperties": true,
3144
+ "description": "A subagent's spawn or completion, recorded on the spawning thread.",
3145
+ "properties": {
3146
+ "agentPath": {
3147
+ "anyOf": [
3148
+ {
3149
+ "type": "string"
3150
+ },
3151
+ {
3152
+ "type": "null"
3153
+ }
3154
+ ],
3155
+ "default": null,
3156
+ "title": "Agentpath"
3157
+ },
3158
+ "agentThreadId": {
3159
+ "title": "Agentthreadid",
3160
+ "type": "string"
3161
+ },
3162
+ "id": {
3163
+ "title": "Id",
3164
+ "type": "string"
3165
+ },
3166
+ "kind": {
3167
+ "title": "Kind",
3168
+ "type": "string"
3169
+ },
3170
+ "type": {
3171
+ "const": "subAgentActivity",
3172
+ "default": "subAgentActivity",
3173
+ "title": "Type",
3174
+ "type": "string"
3175
+ }
3176
+ },
3177
+ "required": [
3178
+ "agentThreadId",
3179
+ "id",
3180
+ "kind",
3181
+ "type"
3182
+ ],
3183
+ "title": "CodexSubAgentActivity",
3184
+ "type": "object"
3185
+ },
3073
3186
  "CodexTextInput": {
3074
3187
  "additionalProperties": true,
3075
3188
  "properties": {
@@ -3829,7 +3942,7 @@
3829
3942
  "properties": {
3830
3943
  "charged": {
3831
3944
  "default": 0,
3832
- "description": "What Ellipsis charged to credit, in millicents. It is everything except subscription tokens, and it is what the budget caps.",
3945
+ "description": "What Ellipsis charged to credit, in millicents. It is everything except subscription tokens.",
3833
3946
  "title": "Charged",
3834
3947
  "type": "integer"
3835
3948
  },
@@ -3857,7 +3970,7 @@
3857
3970
  },
3858
3971
  "total": {
3859
3972
  "default": 0,
3860
- "description": "Everything it cost, whoever paid, in millicents. It is the sum of llm.all.total, cpu, memory, and fee.",
3973
+ "description": "Everything it cost, whoever paid, in millicents. It is the sum of llm.all.total, cpu, memory, and fee, and it is what the budget caps.",
3861
3974
  "title": "Total",
3862
3975
  "type": "integer"
3863
3976
  }
@@ -4157,7 +4270,8 @@
4157
4270
  "before_start": null,
4158
4271
  "build_base": null,
4159
4272
  "post_clone": null,
4160
- "post_start": null
4273
+ "post_start": null,
4274
+ "validate": null
4161
4275
  }
4162
4276
  },
4163
4277
  "mcp_servers": {
@@ -4210,7 +4324,7 @@
4210
4324
  },
4211
4325
  "EnvironmentHooks": {
4212
4326
  "additionalProperties": false,
4213
- "description": "Environment lifecycle scripts, in order: build_base, after_checkout,\nbefore_start. The first two produce reusable snapshots; before_start runs\nbefore an agent starts or resumes its session. Scripts run as the environment's\nuser in the workspace directory `/sandbox`. A nonzero exit fails the session.\n\nLegacy post_start/post_clone scripts remain supported for existing configs;\nboth run after workspace preparation, before the agent starts or resumes.\nThey cannot be combined with the new lifecycle fields.",
4327
+ "description": "Environment lifecycle scripts, in order: build_base, after_checkout,\nbefore_start, validate. The first two produce reusable snapshots;\nbefore_start runs before an agent starts or resumes its session, and\nvalidate runs last to check that the environment has what the agent needs.\nScripts run as the environment's user in the workspace directory\n`/sandbox`. A nonzero exit fails the session.\n\nLegacy post_start/post_clone scripts remain supported for existing configs;\nboth run after workspace preparation, before the agent starts or resumes.\nThey cannot be combined with the new lifecycle fields.",
4214
4328
  "properties": {
4215
4329
  "after_checkout": {
4216
4330
  "anyOf": [
@@ -4285,6 +4399,22 @@
4285
4399
  "default": null,
4286
4400
  "description": "Legacy session startup script. Use before_start in new configurations.",
4287
4401
  "title": "Post Start"
4402
+ },
4403
+ "validate": {
4404
+ "anyOf": [
4405
+ {
4406
+ "$ref": "#/$defs/EnvironmentScript"
4407
+ },
4408
+ {
4409
+ "type": "string"
4410
+ },
4411
+ {
4412
+ "type": "null"
4413
+ }
4414
+ ],
4415
+ "default": null,
4416
+ "description": "Check that the environment works, for example that required tools are on PATH. Runs last, after before_start, each time a session starts or resumes and each time the environment is built after a change. A nonzero exit fails the session or the build. Not cached.",
4417
+ "title": "Validate"
4288
4418
  }
4289
4419
  },
4290
4420
  "required": [
@@ -4292,7 +4422,8 @@
4292
4422
  "before_start",
4293
4423
  "build_base",
4294
4424
  "post_clone",
4295
- "post_start"
4425
+ "post_start",
4426
+ "validate"
4296
4427
  ],
4297
4428
  "title": "EnvironmentHooks",
4298
4429
  "type": "object"
@@ -4726,30 +4857,500 @@
4726
4857
  "duration_ms": {
4727
4858
  "anyOf": [
4728
4859
  {
4729
- "type": "integer"
4860
+ "type": "integer"
4861
+ },
4862
+ {
4863
+ "type": "null"
4864
+ }
4865
+ ],
4866
+ "default": null,
4867
+ "title": "Duration Ms"
4868
+ },
4869
+ "repositories": {
4870
+ "items": {
4871
+ "type": "string"
4872
+ },
4873
+ "title": "Repositories",
4874
+ "type": "array"
4875
+ }
4876
+ },
4877
+ "required": [
4878
+ "repositories"
4879
+ ],
4880
+ "title": "EnvironmentReadyPayload",
4881
+ "type": "object"
4882
+ },
4883
+ "EnvironmentReadyRecord": {
4884
+ "properties": {
4885
+ "cost": {
4886
+ "anyOf": [
4887
+ {
4888
+ "type": "integer"
4889
+ },
4890
+ {
4891
+ "type": "null"
4892
+ }
4893
+ ],
4894
+ "default": null,
4895
+ "title": "Cost"
4896
+ },
4897
+ "created_at": {
4898
+ "format": "date-time",
4899
+ "title": "Created At",
4900
+ "type": "string"
4901
+ },
4902
+ "duration": {
4903
+ "anyOf": [
4904
+ {
4905
+ "type": "integer"
4906
+ },
4907
+ {
4908
+ "type": "null"
4909
+ }
4910
+ ],
4911
+ "default": null,
4912
+ "title": "Duration"
4913
+ },
4914
+ "feed_seq": {
4915
+ "description": "Position in the session feed and the stream's resume cursor.",
4916
+ "title": "Feed Seq",
4917
+ "type": "integer"
4918
+ },
4919
+ "id": {
4920
+ "description": "Unique identifier of the record.",
4921
+ "title": "Id",
4922
+ "type": "string"
4923
+ },
4924
+ "kind": {
4925
+ "const": "platform",
4926
+ "default": "platform",
4927
+ "title": "Kind",
4928
+ "type": "string"
4929
+ },
4930
+ "model": {
4931
+ "anyOf": [
4932
+ {
4933
+ "type": "string"
4934
+ },
4935
+ {
4936
+ "type": "null"
4937
+ }
4938
+ ],
4939
+ "default": null,
4940
+ "title": "Model"
4941
+ },
4942
+ "payload": {
4943
+ "$ref": "#/$defs/EnvironmentReadyPayload"
4944
+ },
4945
+ "record_format": {
4946
+ "const": "ellipsis_lifecycle@1",
4947
+ "default": "ellipsis_lifecycle@1",
4948
+ "title": "Record Format",
4949
+ "type": "string"
4950
+ },
4951
+ "record_type": {
4952
+ "const": "environment_ready",
4953
+ "default": "environment_ready",
4954
+ "title": "Record Type",
4955
+ "type": "string"
4956
+ },
4957
+ "session_id": {
4958
+ "description": "Session containing this record.",
4959
+ "title": "Session Id",
4960
+ "type": "string"
4961
+ },
4962
+ "session_message_id": {
4963
+ "anyOf": [
4964
+ {
4965
+ "type": "string"
4966
+ },
4967
+ {
4968
+ "type": "null"
4969
+ }
4970
+ ],
4971
+ "default": null,
4972
+ "description": "Message this record receives, delivers, requeues, or echoes.",
4973
+ "title": "Session Message Id"
4974
+ },
4975
+ "source": {
4976
+ "const": "lifecycle",
4977
+ "default": "lifecycle",
4978
+ "title": "Source",
4979
+ "type": "string"
4980
+ },
4981
+ "tokens_info": {
4982
+ "anyOf": [
4983
+ {
4984
+ "$ref": "#/$defs/TokensInfo"
4985
+ },
4986
+ {
4987
+ "type": "null"
4988
+ }
4989
+ ],
4990
+ "default": null
4991
+ },
4992
+ "tools": {
4993
+ "anyOf": [
4994
+ {
4995
+ "items": {
4996
+ "type": "string"
4997
+ },
4998
+ "type": "array"
4999
+ },
5000
+ {
5001
+ "type": "null"
5002
+ }
5003
+ ],
5004
+ "default": null,
5005
+ "title": "Tools"
5006
+ },
5007
+ "turn_id": {
5008
+ "anyOf": [
5009
+ {
5010
+ "type": "string"
5011
+ },
5012
+ {
5013
+ "type": "null"
5014
+ }
5015
+ ],
5016
+ "default": null,
5017
+ "description": "Turn containing this record, when applicable.",
5018
+ "title": "Turn Id"
5019
+ }
5020
+ },
5021
+ "required": [
5022
+ "cost",
5023
+ "created_at",
5024
+ "duration",
5025
+ "feed_seq",
5026
+ "id",
5027
+ "kind",
5028
+ "model",
5029
+ "payload",
5030
+ "record_format",
5031
+ "record_type",
5032
+ "session_id",
5033
+ "session_message_id",
5034
+ "source",
5035
+ "tokens_info",
5036
+ "tools",
5037
+ "turn_id"
5038
+ ],
5039
+ "title": "EnvironmentReadyRecord",
5040
+ "type": "object",
5041
+ "x-ellipsis-preserve-payload": true
5042
+ },
5043
+ "EnvironmentScript": {
5044
+ "additionalProperties": false,
5045
+ "description": "An inline shell script run as the environment's user, with the workspace\ndirectory `/sandbox` as cwd.",
5046
+ "properties": {
5047
+ "run": {
5048
+ "description": "Shell script to run in the workspace directory `/sandbox`.",
5049
+ "minLength": 1,
5050
+ "title": "Run",
5051
+ "type": "string"
5052
+ }
5053
+ },
5054
+ "required": [
5055
+ "run"
5056
+ ],
5057
+ "title": "EnvironmentScript",
5058
+ "type": "object"
5059
+ },
5060
+ "EnvironmentSource": {
5061
+ "description": "How a session's environment was chosen. None (the field is nullable)\nwhen the config carried an inline environment block and no resolution ran \u2014\nan inline environment is not a reference, so there is nothing to record.\n\nNot derivable from the row: `environment_id` says WHICH environment, not\nhow it was chosen, and is null for the built-in basic environment.",
5062
+ "enum": [
5063
+ "request",
5064
+ "agent",
5065
+ "repo_default",
5066
+ "account_default",
5067
+ "platform_default"
5068
+ ],
5069
+ "title": "EnvironmentSource",
5070
+ "type": "string"
5071
+ },
5072
+ "EnvironmentVariable": {
5073
+ "additionalProperties": false,
5074
+ "description": "One environment variable injected into the session's environment.\n\n`value`, when set, is a literal injected as-is \u2014 use it for non-secret\nconfig (LOG_LEVEL, an API base URL). When `value` is omitted the value is\nresolved at run time from the account's secrets store (dashboard\n/ `PUT /v1/secrets`) by `name`, so a secret can be injected without\never putting it in the config file. Either way the variable only reaches\nagents that name it.",
5075
+ "properties": {
5076
+ "name": {
5077
+ "title": "Name",
5078
+ "type": "string"
5079
+ },
5080
+ "value": {
5081
+ "anyOf": [
5082
+ {
5083
+ "type": "string"
5084
+ },
5085
+ {
5086
+ "type": "null"
5087
+ }
5088
+ ],
5089
+ "default": null,
5090
+ "title": "Value"
5091
+ }
5092
+ },
5093
+ "required": [
5094
+ "name",
5095
+ "value"
5096
+ ],
5097
+ "title": "EnvironmentVariable",
5098
+ "type": "object"
5099
+ },
5100
+ "ErrorFrame": {
5101
+ "description": "Terminal error marker, sent before the server closes with code 1011.",
5102
+ "properties": {
5103
+ "message": {
5104
+ "description": "A human-readable error message.",
5105
+ "title": "Message",
5106
+ "type": "string"
5107
+ },
5108
+ "type": {
5109
+ "const": "error",
5110
+ "default": "error",
5111
+ "title": "Type",
5112
+ "type": "string"
5113
+ }
5114
+ },
5115
+ "required": [
5116
+ "message",
5117
+ "type"
5118
+ ],
5119
+ "title": "ErrorFrame",
5120
+ "type": "object"
5121
+ },
5122
+ "GeminiConfig": {
5123
+ "additionalProperties": false,
5124
+ "description": "Native options supported by the current Gemini CLI adapter.",
5125
+ "properties": {
5126
+ "model": {
5127
+ "description": "The model the session runs on: a Gemini id from the models table. Required.",
5128
+ "title": "Model",
5129
+ "type": "string"
5130
+ },
5131
+ "prompt": {
5132
+ "anyOf": [
5133
+ {
5134
+ "type": "string"
5135
+ },
5136
+ {
5137
+ "type": "null"
5138
+ }
5139
+ ],
5140
+ "default": null,
5141
+ "description": "The initial user message, passed verbatim. Omit to start an interactive session with no turn, waiting for a message.",
5142
+ "title": "Prompt"
5143
+ }
5144
+ },
5145
+ "required": [
5146
+ "model",
5147
+ "prompt"
5148
+ ],
5149
+ "title": "GeminiConfig",
5150
+ "type": "object"
5151
+ },
5152
+ "GeminiErrorEvent": {
5153
+ "additionalProperties": true,
5154
+ "properties": {
5155
+ "message": {
5156
+ "title": "Message",
5157
+ "type": "string"
5158
+ },
5159
+ "severity": {
5160
+ "anyOf": [
5161
+ {
5162
+ "type": "string"
5163
+ },
5164
+ {
5165
+ "type": "null"
5166
+ }
5167
+ ],
5168
+ "default": null,
5169
+ "title": "Severity"
5170
+ },
5171
+ "timestamp": {
5172
+ "title": "Timestamp",
5173
+ "type": "string"
5174
+ },
5175
+ "type": {
5176
+ "const": "error",
5177
+ "default": "error",
5178
+ "title": "Type",
5179
+ "type": "string"
5180
+ }
5181
+ },
5182
+ "required": [
5183
+ "message",
5184
+ "timestamp",
5185
+ "type"
5186
+ ],
5187
+ "title": "GeminiErrorEvent",
5188
+ "type": "object"
5189
+ },
5190
+ "GeminiInitEvent": {
5191
+ "additionalProperties": true,
5192
+ "properties": {
5193
+ "model": {
5194
+ "title": "Model",
5195
+ "type": "string"
5196
+ },
5197
+ "session_id": {
5198
+ "title": "Session Id",
5199
+ "type": "string"
5200
+ },
5201
+ "timestamp": {
5202
+ "title": "Timestamp",
5203
+ "type": "string"
5204
+ },
5205
+ "type": {
5206
+ "const": "init",
5207
+ "default": "init",
5208
+ "title": "Type",
5209
+ "type": "string"
5210
+ }
5211
+ },
5212
+ "required": [
5213
+ "model",
5214
+ "session_id",
5215
+ "timestamp",
5216
+ "type"
5217
+ ],
5218
+ "title": "GeminiInitEvent",
5219
+ "type": "object"
5220
+ },
5221
+ "GeminiMessageEvent": {
5222
+ "additionalProperties": true,
5223
+ "properties": {
5224
+ "content": {
5225
+ "title": "Content",
5226
+ "type": "string"
5227
+ },
5228
+ "delta": {
5229
+ "anyOf": [
5230
+ {
5231
+ "type": "boolean"
5232
+ },
5233
+ {
5234
+ "type": "null"
5235
+ }
5236
+ ],
5237
+ "default": null,
5238
+ "title": "Delta"
5239
+ },
5240
+ "role": {
5241
+ "enum": [
5242
+ "user",
5243
+ "assistant"
5244
+ ],
5245
+ "title": "Role",
5246
+ "type": "string"
5247
+ },
5248
+ "timestamp": {
5249
+ "title": "Timestamp",
5250
+ "type": "string"
5251
+ },
5252
+ "type": {
5253
+ "const": "message",
5254
+ "default": "message",
5255
+ "title": "Type",
5256
+ "type": "string"
5257
+ }
5258
+ },
5259
+ "required": [
5260
+ "content",
5261
+ "role",
5262
+ "timestamp",
5263
+ "type"
5264
+ ],
5265
+ "title": "GeminiMessageEvent",
5266
+ "type": "object"
5267
+ },
5268
+ "GeminiModelStats": {
5269
+ "additionalProperties": true,
5270
+ "properties": {
5271
+ "cached": {
5272
+ "default": 0,
5273
+ "title": "Cached",
5274
+ "type": "integer"
5275
+ },
5276
+ "input": {
5277
+ "default": 0,
5278
+ "title": "Input",
5279
+ "type": "integer"
5280
+ },
5281
+ "input_tokens": {
5282
+ "default": 0,
5283
+ "title": "Input Tokens",
5284
+ "type": "integer"
5285
+ },
5286
+ "output_tokens": {
5287
+ "default": 0,
5288
+ "title": "Output Tokens",
5289
+ "type": "integer"
5290
+ },
5291
+ "total_tokens": {
5292
+ "default": 0,
5293
+ "title": "Total Tokens",
5294
+ "type": "integer"
5295
+ }
5296
+ },
5297
+ "required": [],
5298
+ "title": "GeminiModelStats",
5299
+ "type": "object"
5300
+ },
5301
+ "GeminiResultEvent": {
5302
+ "additionalProperties": true,
5303
+ "properties": {
5304
+ "error": {
5305
+ "anyOf": [
5306
+ {
5307
+ "$ref": "#/$defs/GeminiToolError"
5308
+ },
5309
+ {
5310
+ "type": "null"
5311
+ }
5312
+ ],
5313
+ "default": null
5314
+ },
5315
+ "stats": {
5316
+ "anyOf": [
5317
+ {
5318
+ "$ref": "#/$defs/GeminiStreamStats"
4730
5319
  },
4731
5320
  {
4732
5321
  "type": "null"
4733
5322
  }
4734
5323
  ],
4735
- "default": null,
4736
- "title": "Duration Ms"
5324
+ "default": null
4737
5325
  },
4738
- "repositories": {
4739
- "items": {
4740
- "type": "string"
4741
- },
4742
- "title": "Repositories",
4743
- "type": "array"
5326
+ "status": {
5327
+ "enum": [
5328
+ "success",
5329
+ "error"
5330
+ ],
5331
+ "title": "Status",
5332
+ "type": "string"
5333
+ },
5334
+ "timestamp": {
5335
+ "title": "Timestamp",
5336
+ "type": "string"
5337
+ },
5338
+ "type": {
5339
+ "const": "result",
5340
+ "default": "result",
5341
+ "title": "Type",
5342
+ "type": "string"
4744
5343
  }
4745
5344
  },
4746
5345
  "required": [
4747
- "repositories"
5346
+ "status",
5347
+ "timestamp",
5348
+ "type"
4748
5349
  ],
4749
- "title": "EnvironmentReadyPayload",
5350
+ "title": "GeminiResultEvent",
4750
5351
  "type": "object"
4751
5352
  },
4752
- "EnvironmentReadyRecord": {
5353
+ "GeminiSessionRecord": {
4753
5354
  "properties": {
4754
5355
  "cost": {
4755
5356
  "anyOf": [
@@ -4791,8 +5392,8 @@
4791
5392
  "type": "string"
4792
5393
  },
4793
5394
  "kind": {
4794
- "const": "platform",
4795
- "default": "platform",
5395
+ "const": "gemini",
5396
+ "default": "gemini",
4796
5397
  "title": "Kind",
4797
5398
  "type": "string"
4798
5399
  },
@@ -4809,17 +5410,16 @@
4809
5410
  "title": "Model"
4810
5411
  },
4811
5412
  "payload": {
4812
- "$ref": "#/$defs/EnvironmentReadyPayload"
5413
+ "$ref": "#/$defs/GeminiStreamEvent"
4813
5414
  },
4814
5415
  "record_format": {
4815
- "const": "ellipsis_lifecycle@1",
4816
- "default": "ellipsis_lifecycle@1",
5416
+ "const": "gemini_stream_json@1",
5417
+ "default": "gemini_stream_json@1",
4817
5418
  "title": "Record Format",
4818
5419
  "type": "string"
4819
5420
  },
4820
5421
  "record_type": {
4821
- "const": "environment_ready",
4822
- "default": "environment_ready",
5422
+ "description": "Original record type within its format.",
4823
5423
  "title": "Record Type",
4824
5424
  "type": "string"
4825
5425
  },
@@ -4842,8 +5442,8 @@
4842
5442
  "title": "Session Message Id"
4843
5443
  },
4844
5444
  "source": {
4845
- "const": "lifecycle",
4846
- "default": "lifecycle",
5445
+ "const": "gemini",
5446
+ "default": "gemini",
4847
5447
  "title": "Source",
4848
5448
  "type": "string"
4849
5449
  },
@@ -4905,48 +5505,128 @@
4905
5505
  "tools",
4906
5506
  "turn_id"
4907
5507
  ],
4908
- "title": "EnvironmentReadyRecord",
5508
+ "title": "GeminiSessionRecord",
4909
5509
  "type": "object",
4910
5510
  "x-ellipsis-preserve-payload": true
4911
5511
  },
4912
- "EnvironmentScript": {
4913
- "additionalProperties": false,
4914
- "description": "An inline shell script run as the environment's user, with the workspace\ndirectory `/sandbox` as cwd.",
5512
+ "GeminiStreamEvent": {
5513
+ "discriminator": {
5514
+ "mapping": {
5515
+ "error": "#/$defs/GeminiErrorEvent",
5516
+ "init": "#/$defs/GeminiInitEvent",
5517
+ "message": "#/$defs/GeminiMessageEvent",
5518
+ "result": "#/$defs/GeminiResultEvent",
5519
+ "tool_result": "#/$defs/GeminiToolResultEvent",
5520
+ "tool_use": "#/$defs/GeminiToolUseEvent"
5521
+ },
5522
+ "propertyName": "type"
5523
+ },
5524
+ "oneOf": [
5525
+ {
5526
+ "$ref": "#/$defs/GeminiInitEvent"
5527
+ },
5528
+ {
5529
+ "$ref": "#/$defs/GeminiMessageEvent"
5530
+ },
5531
+ {
5532
+ "$ref": "#/$defs/GeminiToolUseEvent"
5533
+ },
5534
+ {
5535
+ "$ref": "#/$defs/GeminiToolResultEvent"
5536
+ },
5537
+ {
5538
+ "$ref": "#/$defs/GeminiErrorEvent"
5539
+ },
5540
+ {
5541
+ "$ref": "#/$defs/GeminiResultEvent"
5542
+ }
5543
+ ]
5544
+ },
5545
+ "GeminiStreamStats": {
5546
+ "additionalProperties": true,
4915
5547
  "properties": {
4916
- "run": {
4917
- "description": "Shell script to run in the workspace directory `/sandbox`.",
4918
- "minLength": 1,
4919
- "title": "Run",
5548
+ "cached": {
5549
+ "default": 0,
5550
+ "title": "Cached",
5551
+ "type": "integer"
5552
+ },
5553
+ "duration_ms": {
5554
+ "default": 0,
5555
+ "title": "Duration Ms",
5556
+ "type": "integer"
5557
+ },
5558
+ "input": {
5559
+ "default": 0,
5560
+ "title": "Input",
5561
+ "type": "integer"
5562
+ },
5563
+ "input_tokens": {
5564
+ "default": 0,
5565
+ "title": "Input Tokens",
5566
+ "type": "integer"
5567
+ },
5568
+ "models": {
5569
+ "additionalProperties": {
5570
+ "$ref": "#/$defs/GeminiModelStats"
5571
+ },
5572
+ "default": {},
5573
+ "title": "Models",
5574
+ "type": "object"
5575
+ },
5576
+ "output_tokens": {
5577
+ "default": 0,
5578
+ "title": "Output Tokens",
5579
+ "type": "integer"
5580
+ },
5581
+ "tool_calls": {
5582
+ "default": 0,
5583
+ "title": "Tool Calls",
5584
+ "type": "integer"
5585
+ },
5586
+ "total_tokens": {
5587
+ "default": 0,
5588
+ "title": "Total Tokens",
5589
+ "type": "integer"
5590
+ }
5591
+ },
5592
+ "required": [],
5593
+ "title": "GeminiStreamStats",
5594
+ "type": "object"
5595
+ },
5596
+ "GeminiToolError": {
5597
+ "additionalProperties": true,
5598
+ "properties": {
5599
+ "message": {
5600
+ "title": "Message",
5601
+ "type": "string"
5602
+ },
5603
+ "type": {
5604
+ "title": "Type",
4920
5605
  "type": "string"
4921
5606
  }
4922
5607
  },
4923
5608
  "required": [
4924
- "run"
5609
+ "message",
5610
+ "type"
4925
5611
  ],
4926
- "title": "EnvironmentScript",
5612
+ "title": "GeminiToolError",
4927
5613
  "type": "object"
4928
5614
  },
4929
- "EnvironmentSource": {
4930
- "description": "How a session's environment was chosen. None (the field is nullable)\nwhen the config carried an inline environment block and no resolution ran \u2014\nan inline environment is not a reference, so there is nothing to record.\n\nNot derivable from the row: `environment_id` says WHICH environment, not\nhow it was chosen, and is null for the built-in basic environment.",
4931
- "enum": [
4932
- "request",
4933
- "agent",
4934
- "repo_default",
4935
- "account_default",
4936
- "platform_default"
4937
- ],
4938
- "title": "EnvironmentSource",
4939
- "type": "string"
4940
- },
4941
- "EnvironmentVariable": {
4942
- "additionalProperties": false,
4943
- "description": "One environment variable injected into the session's environment.\n\n`value`, when set, is a literal injected as-is \u2014 use it for non-secret\nconfig (LOG_LEVEL, an API base URL). When `value` is omitted the value is\nresolved at run time from the account's secrets store (dashboard\n/ `PUT /v1/secrets`) by `name`, so a secret can be injected without\never putting it in the config file. Either way the variable only reaches\nagents that name it.",
5615
+ "GeminiToolResultEvent": {
5616
+ "additionalProperties": true,
4944
5617
  "properties": {
4945
- "name": {
4946
- "title": "Name",
4947
- "type": "string"
5618
+ "error": {
5619
+ "anyOf": [
5620
+ {
5621
+ "$ref": "#/$defs/GeminiToolError"
5622
+ },
5623
+ {
5624
+ "type": "null"
5625
+ }
5626
+ ],
5627
+ "default": null
4948
5628
  },
4949
- "value": {
5629
+ "output": {
4950
5630
  "anyOf": [
4951
5631
  {
4952
5632
  "type": "string"
@@ -4956,36 +5636,75 @@
4956
5636
  }
4957
5637
  ],
4958
5638
  "default": null,
4959
- "title": "Value"
5639
+ "title": "Output"
5640
+ },
5641
+ "status": {
5642
+ "enum": [
5643
+ "success",
5644
+ "error"
5645
+ ],
5646
+ "title": "Status",
5647
+ "type": "string"
5648
+ },
5649
+ "timestamp": {
5650
+ "title": "Timestamp",
5651
+ "type": "string"
5652
+ },
5653
+ "tool_id": {
5654
+ "title": "Tool Id",
5655
+ "type": "string"
5656
+ },
5657
+ "type": {
5658
+ "const": "tool_result",
5659
+ "default": "tool_result",
5660
+ "title": "Type",
5661
+ "type": "string"
4960
5662
  }
4961
5663
  },
4962
5664
  "required": [
4963
- "name",
4964
- "value"
5665
+ "status",
5666
+ "timestamp",
5667
+ "tool_id",
5668
+ "type"
4965
5669
  ],
4966
- "title": "EnvironmentVariable",
5670
+ "title": "GeminiToolResultEvent",
4967
5671
  "type": "object"
4968
5672
  },
4969
- "ErrorFrame": {
4970
- "description": "Terminal error marker, sent before the server closes with code 1011.",
5673
+ "GeminiToolUseEvent": {
5674
+ "additionalProperties": true,
4971
5675
  "properties": {
4972
- "message": {
4973
- "description": "A human-readable error message.",
4974
- "title": "Message",
5676
+ "parameters": {
5677
+ "additionalProperties": true,
5678
+ "default": {},
5679
+ "title": "Parameters",
5680
+ "type": "object"
5681
+ },
5682
+ "timestamp": {
5683
+ "title": "Timestamp",
5684
+ "type": "string"
5685
+ },
5686
+ "tool_id": {
5687
+ "title": "Tool Id",
5688
+ "type": "string"
5689
+ },
5690
+ "tool_name": {
5691
+ "title": "Tool Name",
4975
5692
  "type": "string"
4976
5693
  },
4977
5694
  "type": {
4978
- "const": "error",
4979
- "default": "error",
5695
+ "const": "tool_use",
5696
+ "default": "tool_use",
4980
5697
  "title": "Type",
4981
5698
  "type": "string"
4982
5699
  }
4983
5700
  },
4984
5701
  "required": [
4985
- "message",
5702
+ "timestamp",
5703
+ "tool_id",
5704
+ "tool_name",
4986
5705
  "type"
4987
5706
  ],
4988
- "title": "ErrorFrame",
5707
+ "title": "GeminiToolUseEvent",
4989
5708
  "type": "object"
4990
5709
  },
4991
5710
  "GithubAccountFilter": {
@@ -7987,7 +8706,6 @@
7987
8706
  "defaults",
7988
8707
  "environments",
7989
8708
  "secrets",
7990
- "templates",
7991
8709
  "integrations",
7992
8710
  "reviews",
7993
8711
  "tokens",
@@ -8519,11 +9237,34 @@
8519
9237
  },
8520
9238
  "codex": {
8521
9239
  "type": "null"
9240
+ },
9241
+ "gemini": {
9242
+ "type": "null"
9243
+ }
9244
+ },
9245
+ "required": [
9246
+ "claude_code",
9247
+ "codex",
9248
+ "gemini"
9249
+ ]
9250
+ },
9251
+ {
9252
+ "properties": {
9253
+ "claude_code": {
9254
+ "type": "null"
9255
+ },
9256
+ "codex": {
9257
+ "additionalProperties": true,
9258
+ "type": "object"
9259
+ },
9260
+ "gemini": {
9261
+ "type": "null"
8522
9262
  }
8523
9263
  },
8524
9264
  "required": [
8525
9265
  "claude_code",
8526
- "codex"
9266
+ "codex",
9267
+ "gemini"
8527
9268
  ]
8528
9269
  },
8529
9270
  {
@@ -8532,13 +9273,17 @@
8532
9273
  "type": "null"
8533
9274
  },
8534
9275
  "codex": {
9276
+ "type": "null"
9277
+ },
9278
+ "gemini": {
8535
9279
  "additionalProperties": true,
8536
9280
  "type": "object"
8537
9281
  }
8538
9282
  },
8539
9283
  "required": [
8540
9284
  "claude_code",
8541
- "codex"
9285
+ "codex",
9286
+ "gemini"
8542
9287
  ]
8543
9288
  }
8544
9289
  ]
@@ -8590,7 +9335,7 @@
8590
9335
  }
8591
9336
  ],
8592
9337
  "default": null,
8593
- "description": "Claude Code input and native options. Set exactly one of claude_code or codex."
9338
+ "description": "Claude Code input and native options. Set exactly one of claude_code, codex, or gemini."
8594
9339
  },
8595
9340
  "codex": {
8596
9341
  "anyOf": [
@@ -8602,7 +9347,7 @@
8602
9347
  }
8603
9348
  ],
8604
9349
  "default": null,
8605
- "description": "Codex input and native options. Set exactly one of claude_code or codex."
9350
+ "description": "Codex input and native options. Set exactly one of claude_code, codex, or gemini."
8606
9351
  },
8607
9352
  "conversation": {
8608
9353
  "$ref": "#/$defs/SessionConversation",
@@ -8689,6 +9434,18 @@
8689
9434
  "description": "The typed external event that started the session; null for direct and scheduled starts.",
8690
9435
  "title": "Event"
8691
9436
  },
9437
+ "gemini": {
9438
+ "anyOf": [
9439
+ {
9440
+ "$ref": "#/$defs/GeminiConfig"
9441
+ },
9442
+ {
9443
+ "type": "null"
9444
+ }
9445
+ ],
9446
+ "default": null,
9447
+ "description": "Gemini CLI input and native options. Set exactly one of claude_code, codex, or gemini."
9448
+ },
8692
9449
  "git": {
8693
9450
  "anyOf": [
8694
9451
  {
@@ -8814,6 +9571,7 @@
8814
9571
  "created_at",
8815
9572
  "environment",
8816
9573
  "event",
9574
+ "gemini",
8817
9575
  "git",
8818
9576
  "handler",
8819
9577
  "id",
@@ -9117,11 +9875,34 @@
9117
9875
  },
9118
9876
  "codex": {
9119
9877
  "type": "null"
9878
+ },
9879
+ "gemini": {
9880
+ "type": "null"
9881
+ }
9882
+ },
9883
+ "required": [
9884
+ "claude_code",
9885
+ "codex",
9886
+ "gemini"
9887
+ ]
9888
+ },
9889
+ {
9890
+ "properties": {
9891
+ "claude_code": {
9892
+ "type": "null"
9893
+ },
9894
+ "codex": {
9895
+ "additionalProperties": true,
9896
+ "type": "object"
9897
+ },
9898
+ "gemini": {
9899
+ "type": "null"
9120
9900
  }
9121
9901
  },
9122
9902
  "required": [
9123
9903
  "claude_code",
9124
- "codex"
9904
+ "codex",
9905
+ "gemini"
9125
9906
  ]
9126
9907
  },
9127
9908
  {
@@ -9130,13 +9911,17 @@
9130
9911
  "type": "null"
9131
9912
  },
9132
9913
  "codex": {
9914
+ "type": "null"
9915
+ },
9916
+ "gemini": {
9133
9917
  "additionalProperties": true,
9134
9918
  "type": "object"
9135
9919
  }
9136
9920
  },
9137
9921
  "required": [
9138
9922
  "claude_code",
9139
- "codex"
9923
+ "codex",
9924
+ "gemini"
9140
9925
  ]
9141
9926
  }
9142
9927
  ]
@@ -9163,7 +9948,7 @@
9163
9948
  }
9164
9949
  ],
9165
9950
  "default": null,
9166
- "description": "Claude Code input and native options. Set exactly one of claude_code or codex."
9951
+ "description": "Claude Code input and native options. Set exactly one of claude_code, codex, or gemini."
9167
9952
  },
9168
9953
  "codex": {
9169
9954
  "anyOf": [
@@ -9175,7 +9960,7 @@
9175
9960
  }
9176
9961
  ],
9177
9962
  "default": null,
9178
- "description": "Codex input and native options. Set exactly one of claude_code or codex."
9963
+ "description": "Codex input and native options. Set exactly one of claude_code, codex, or gemini."
9179
9964
  },
9180
9965
  "conversation": {
9181
9966
  "$ref": "#/$defs/SessionConversationConfig",
@@ -9203,7 +9988,8 @@
9203
9988
  "before_start": null,
9204
9989
  "build_base": null,
9205
9990
  "post_clone": null,
9206
- "post_start": null
9991
+ "post_start": null,
9992
+ "validate": null
9207
9993
  },
9208
9994
  "mcp_servers": [],
9209
9995
  "repositories": [],
@@ -9211,6 +9997,18 @@
9211
9997
  },
9212
9998
  "title": "Environment"
9213
9999
  },
10000
+ "gemini": {
10001
+ "anyOf": [
10002
+ {
10003
+ "$ref": "#/$defs/GeminiConfig"
10004
+ },
10005
+ {
10006
+ "type": "null"
10007
+ }
10008
+ ],
10009
+ "default": null,
10010
+ "description": "Gemini CLI input and native options. Set exactly one of claude_code, codex, or gemini."
10011
+ },
9214
10012
  "metadata": {
9215
10013
  "additionalProperties": {
9216
10014
  "type": "string"
@@ -9256,6 +10054,7 @@
9256
10054
  "codex",
9257
10055
  "conversation",
9258
10056
  "environment",
10057
+ "gemini",
9259
10058
  "metadata",
9260
10059
  "output",
9261
10060
  "permissions",
@@ -9331,7 +10130,8 @@
9331
10130
  "before_start": null,
9332
10131
  "build_base": null,
9333
10132
  "post_clone": null,
9334
- "post_start": null
10133
+ "post_start": null,
10134
+ "validate": null
9335
10135
  }
9336
10136
  },
9337
10137
  "id": {
@@ -10000,6 +10800,9 @@
10000
10800
  {
10001
10801
  "$ref": "#/$defs/CodexAppServerSessionRecord"
10002
10802
  },
10803
+ {
10804
+ "$ref": "#/$defs/GeminiSessionRecord"
10805
+ },
10003
10806
  {
10004
10807
  "$ref": "#/$defs/PlatformSessionRecord"
10005
10808
  },
@@ -10407,12 +11210,6 @@
10407
11210
  "title": "Messages",
10408
11211
  "type": "array"
10409
11212
  },
10410
- "protocol": {
10411
- "default": 7,
10412
- "description": "Echoes the protocol version the server is serving.",
10413
- "title": "Protocol",
10414
- "type": "integer"
10415
- },
10416
11213
  "session": {
10417
11214
  "$ref": "#/$defs/Session",
10418
11215
  "description": "The session's current state."
@@ -10427,7 +11224,6 @@
10427
11224
  "required": [
10428
11225
  "earliest_feed_seq",
10429
11226
  "messages",
10430
- "protocol",
10431
11227
  "session",
10432
11228
  "type"
10433
11229
  ],
@@ -11356,7 +12152,7 @@
11356
12152
  }
11357
12153
  },
11358
12154
  "$schema": "https://json-schema.org/draft/2020-12/schema",
11359
- "description": "One server-to-client frame of the Ellipsis session stream protocol v7 (WS /v1/sessions/{id}/stream?protocol=7). Clients MUST ignore frames with unknown `type` values \u2014 additive frames are not a protocol break.",
12155
+ "description": "One server-to-client frame of the Ellipsis session stream (WS /v1/sessions/{id}/stream). Clients ignore frames with unknown `type` values.",
11360
12156
  "oneOf": [
11361
12157
  {
11362
12158
  "$ref": "#/$defs/SnapshotFrame"