@compozy/client 0.5.2 → 0.5.4

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.
@@ -360,17 +360,40 @@ export type AgentLimitsPayload = {
360
360
  max_spawn_depth: number;
361
361
  spawn_blocked_reason?: string;
362
362
  };
363
+ export type AgentMCPServerInput = {
364
+ args?: Array<string>;
365
+ auth?: SettingsMCPAuthConfigPayload | null;
366
+ command?: string;
367
+ env?: {
368
+ [key: string]: string;
369
+ };
370
+ name: string;
371
+ reference?: boolean;
372
+ secret_env?: {
373
+ [key: string]: string;
374
+ };
375
+ secret_headers?: {
376
+ [key: string]: string;
377
+ };
378
+ transport?: string;
379
+ url?: string;
380
+ };
363
381
  export type AgentMCPServerJSON = {
364
382
  args?: Array<string>;
365
383
  auth?: SettingsMCPAuthConfigViewPayload | null;
384
+ broken_reference?: boolean;
366
385
  command?: string;
367
386
  env?: {
368
387
  [key: string]: string;
369
388
  };
370
389
  name: string;
390
+ reference?: boolean;
371
391
  secret_env?: {
372
392
  [key: string]: string;
373
393
  };
394
+ secret_headers?: {
395
+ [key: string]: string;
396
+ };
374
397
  transport?: string;
375
398
  url?: string;
376
399
  };
@@ -985,7 +1008,7 @@ export type BulkForceTaskRunResponse = {
985
1008
  export type BusyInputState = {
986
1009
  default_mode: string;
987
1010
  steer_capability: "steer_ext" | "concurrent_prompt" | "none";
988
- steer_delivery?: "injected" | "pending_injection" | "interrupt_fallback";
1011
+ steer_delivery?: "injected" | "pending_injection" | "pending_boundary" | "after_turn" | "interrupt_fallback";
989
1012
  };
990
1013
  export type CancelTaskRequest = {
991
1014
  metadata?: unknown;
@@ -1003,6 +1026,28 @@ export type CatalogMeta = {
1003
1026
  keywords?: Array<string>;
1004
1027
  use_when?: string;
1005
1028
  };
1029
+ export type ChangeBasePayload = {
1030
+ merge_base_sha: string;
1031
+ ref: string;
1032
+ source: string;
1033
+ };
1034
+ export type ChangeBaseRefPayload = {
1035
+ is_default?: boolean;
1036
+ kind: string;
1037
+ ref: string;
1038
+ source?: string;
1039
+ };
1040
+ export type ChangeHeadPayload = {
1041
+ branch: string;
1042
+ sha: string;
1043
+ };
1044
+ export type ChangePatchPayload = {
1045
+ fingerprint: string;
1046
+ patch?: string;
1047
+ path: string;
1048
+ sensitive?: boolean;
1049
+ too_large?: boolean;
1050
+ };
1006
1051
  export type ChangeSet = {
1007
1052
  client_ids?: Array<string>;
1008
1053
  desktop_ids?: Array<string>;
@@ -1012,6 +1057,16 @@ export type ChangeSet = {
1012
1057
  stack_ungrouped?: Array<string>;
1013
1058
  window_ids?: Array<string>;
1014
1059
  };
1060
+ export type ChangeSidePayload = {
1061
+ sensitive?: boolean;
1062
+ text?: string | null;
1063
+ };
1064
+ export type ChangeTotalsPayload = {
1065
+ additions: number;
1066
+ deletions: number;
1067
+ files: number;
1068
+ partial?: boolean;
1069
+ };
1015
1070
  export type Chip = {
1016
1071
  count?: number | null;
1017
1072
  fallback?: string;
@@ -1421,10 +1476,11 @@ export type CreateAgentPayload = {
1421
1476
  display_name?: string | null;
1422
1477
  fallback_chain?: Array<AgentFallbackRoutePayload>;
1423
1478
  /**
1424
- * Agent kind: on_demand (default) or always_on; fixed at creation. stays_on is the deprecated v0.5.0 spelling of always_on and is removed in v0.5.2.
1479
+ * Agent kind: on_demand (default) or always_on; fixed at creation.
1425
1480
  */
1426
- kind?: "on_demand" | "always_on" | "stays_on";
1481
+ kind?: "on_demand" | "always_on";
1427
1482
  label?: string;
1483
+ mcp_servers?: Array<AgentMCPServerInput>;
1428
1484
  model?: string;
1429
1485
  name: string;
1430
1486
  permission_rules?: Array<AgentPermissionRulePayload>;
@@ -1711,9 +1767,9 @@ export type DuplicateAgentOverrides = {
1711
1767
  description?: string | null;
1712
1768
  display_name?: string | null;
1713
1769
  /**
1714
- * Agent kind: on_demand (default) or always_on; fixed at creation. stays_on is the deprecated v0.5.0 spelling of always_on and is removed in v0.5.2.
1770
+ * Agent kind: on_demand (default) or always_on; fixed at creation.
1715
1771
  */
1716
- kind?: "on_demand" | "always_on" | "stays_on";
1772
+ kind?: "on_demand" | "always_on";
1717
1773
  model?: string;
1718
1774
  permission_rules?: Array<AgentPermissionRulePayload>;
1719
1775
  permissions?: "deny-all" | "approve-reads" | "approve-edits" | "auto" | "approve-all";
@@ -1732,9 +1788,9 @@ export type DuplicateAgentOverrides = {
1732
1788
  };
1733
1789
  export type DuplicateAgentRequest = {
1734
1790
  /**
1735
- * Agent kind: on_demand (default) or always_on; fixed at creation. stays_on is the deprecated v0.5.0 spelling of always_on and is removed in v0.5.2.
1791
+ * Agent kind: on_demand (default) or always_on; fixed at creation.
1736
1792
  */
1737
- kind?: "on_demand" | "always_on" | "stays_on";
1793
+ kind?: "on_demand" | "always_on";
1738
1794
  name: string;
1739
1795
  overrides?: DuplicateAgentOverrides | null;
1740
1796
  scope?: "workspace" | "global";
@@ -2080,6 +2136,103 @@ export type FanoutRollup = {
2080
2136
  node_id: string;
2081
2137
  total: number;
2082
2138
  };
2139
+ export type FileChangePayload = {
2140
+ additions: number;
2141
+ binary?: boolean;
2142
+ deletions: number;
2143
+ fingerprint: string;
2144
+ generated?: boolean;
2145
+ old_path?: string;
2146
+ path: string;
2147
+ sensitive?: boolean;
2148
+ status: string;
2149
+ };
2150
+ export type FileContentResponse = {
2151
+ image_base64?: string;
2152
+ image_mime?: string;
2153
+ kind: string;
2154
+ language?: string;
2155
+ path: string;
2156
+ revision?: string;
2157
+ root: FileRootPayload;
2158
+ sensitive?: boolean;
2159
+ size: number;
2160
+ text?: string | null;
2161
+ truncated: boolean;
2162
+ };
2163
+ export type FileEntriesResponse = {
2164
+ entries: Array<FileEntryPayload>;
2165
+ path: string;
2166
+ root: FileRootPayload;
2167
+ status_unavailable?: boolean;
2168
+ truncated: boolean;
2169
+ };
2170
+ export type FileEntryPayload = {
2171
+ contains_changes?: boolean;
2172
+ git_status?: string;
2173
+ ignored?: boolean;
2174
+ kind: string;
2175
+ name: string;
2176
+ path: string;
2177
+ sensitive?: boolean;
2178
+ size?: number;
2179
+ symlink?: boolean;
2180
+ };
2181
+ export type FileFindMatch = {
2182
+ kind: string;
2183
+ match_ranges: Array<Array<number>>;
2184
+ path: string;
2185
+ score: number;
2186
+ sensitive?: boolean;
2187
+ };
2188
+ export type FileFindResponse = {
2189
+ index_truncated: boolean;
2190
+ indexed_files: number;
2191
+ query: string;
2192
+ results: Array<FileFindMatch>;
2193
+ root: FileRootPayload;
2194
+ };
2195
+ export type FileRootPayload = {
2196
+ branch?: string;
2197
+ kind: string;
2198
+ name: string;
2199
+ workspace_id: string;
2200
+ worktree_id?: string;
2201
+ };
2202
+ export type FileSearchFile = {
2203
+ matches: Array<FileSearchMatch>;
2204
+ path: string;
2205
+ truncated_matches?: boolean;
2206
+ };
2207
+ export type FileSearchMatch = {
2208
+ column: number;
2209
+ line: number;
2210
+ ranges: Array<Array<number>>;
2211
+ text: string;
2212
+ text_offset: number;
2213
+ };
2214
+ export type FileSearchQuery = {
2215
+ case_sensitive: boolean;
2216
+ exclude: Array<string>;
2217
+ include: Array<string>;
2218
+ pattern: string;
2219
+ regex: boolean;
2220
+ whole_word: boolean;
2221
+ };
2222
+ export type FileSearchResponse = {
2223
+ engine: string;
2224
+ files: Array<FileSearchFile>;
2225
+ query: FileSearchQuery;
2226
+ root: FileRootPayload;
2227
+ sensitive_excluded: number;
2228
+ timed_out: boolean;
2229
+ totals: FileSearchTotals;
2230
+ truncated: boolean;
2231
+ };
2232
+ export type FileSearchTotals = {
2233
+ files: number;
2234
+ matches: number;
2235
+ };
2083
2236
  export type FireLimitConfig = {
2084
2237
  max: number;
2085
2238
  window: string;
@@ -2899,7 +3052,7 @@ export type HeartbeatWakeByPathRequest = {
2899
3052
  dry_run?: boolean;
2900
3053
  idempotency_key?: string;
2901
3054
  session_id: string;
2902
- source: "scheduler" | "manual" | "harness_reentry";
3055
+ source: "timer" | "instance_check" | "scheduler" | "manual" | "harness_reentry";
2903
3056
  workspace_id?: string;
2904
3057
  };
2905
3058
  export type HeartbeatWakeDecisionPayload = {
@@ -2907,8 +3060,8 @@ export type HeartbeatWakeDecisionPayload = {
2907
3060
  diagnostics?: Array<AuthoredContextDiagnosticPayload>;
2908
3061
  policy_digest?: string;
2909
3062
  policy_snapshot_id?: string;
2910
- reason: "source_poll_in_flight" | "wake_sent" | "heartbeat_disabled" | "heartbeat_invalid" | "heartbeat_no_policy" | "heartbeat_rate_limited" | "heartbeat_no_eligible_session" | "cooldown_active" | "quiet_window" | "session_not_found" | "session_unhealthy" | "session_not_attachable" | "session_prompt_active" | "session_prompt_active_race" | "synthetic_prompt_failed" | "wake_coalesced";
2911
- result: "sent" | "skipped" | "coalesced" | "rate_limited" | "failed";
3063
+ reason: "quiet" | "reported" | "cancelled" | "digest_empty" | "digest_unchanged" | "policy_disabled" | "definition_not_always_on" | "definition_missing" | "no_slot" | "hook_cancelled" | "duplicate_suppressed" | "triage_unsupported" | "triage_output_invalid" | "triage_timeout" | "triage_interrupted" | "triage_config_unavailable" | "triage_failed" | "source_poll_in_flight" | "wake_sent" | "heartbeat_disabled" | "heartbeat_invalid" | "heartbeat_no_policy" | "heartbeat_rate_limited" | "heartbeat_no_eligible_session" | "cooldown_active" | "quiet_window" | "session_not_found" | "session_unhealthy" | "session_not_attachable" | "session_prompt_active" | "session_prompt_active_race" | "synthetic_prompt_failed" | "wake_coalesced";
3064
+ result: "quiet" | "cancelled" | "reported" | "sent" | "skipped" | "coalesced" | "rate_limited" | "failed";
2912
3065
  synthetic_prompt_id?: string;
2913
3066
  wake_event_id?: string;
2914
3067
  };
@@ -2919,10 +3072,10 @@ export type HeartbeatWakeEventPayload = {
2919
3072
  expires_at: string;
2920
3073
  id: string;
2921
3074
  policy_snapshot_id?: string;
2922
- reason: "source_poll_in_flight" | "wake_sent" | "heartbeat_disabled" | "heartbeat_invalid" | "heartbeat_no_policy" | "heartbeat_rate_limited" | "heartbeat_no_eligible_session" | "cooldown_active" | "quiet_window" | "session_not_found" | "session_unhealthy" | "session_not_attachable" | "session_prompt_active" | "session_prompt_active_race" | "synthetic_prompt_failed" | "wake_coalesced";
2923
- result: "sent" | "skipped" | "coalesced" | "rate_limited" | "failed";
3075
+ reason: "quiet" | "reported" | "cancelled" | "digest_empty" | "digest_unchanged" | "policy_disabled" | "definition_not_always_on" | "definition_missing" | "no_slot" | "hook_cancelled" | "duplicate_suppressed" | "triage_unsupported" | "triage_output_invalid" | "triage_timeout" | "triage_interrupted" | "triage_config_unavailable" | "triage_failed" | "source_poll_in_flight" | "wake_sent" | "heartbeat_disabled" | "heartbeat_invalid" | "heartbeat_no_policy" | "heartbeat_rate_limited" | "heartbeat_no_eligible_session" | "cooldown_active" | "quiet_window" | "session_not_found" | "session_unhealthy" | "session_not_attachable" | "session_prompt_active" | "session_prompt_active_race" | "synthetic_prompt_failed" | "wake_coalesced";
3076
+ result: "quiet" | "cancelled" | "reported" | "sent" | "skipped" | "coalesced" | "rate_limited" | "failed";
2924
3077
  session_id?: string;
2925
- source: "scheduler" | "manual" | "harness_reentry";
3078
+ source: "timer" | "instance_check" | "scheduler" | "manual" | "harness_reentry";
2926
3079
  synthetic_prompt_id?: string;
2927
3080
  workspace_id?: string;
2928
3081
  };
@@ -2932,8 +3085,8 @@ export type HeartbeatWakeResponse = {
2932
3085
  export type HeartbeatWakeStatePayload = {
2933
3086
  agent_name?: string;
2934
3087
  coalesced_count: number;
2935
- last_reason?: "source_poll_in_flight" | "wake_sent" | "heartbeat_disabled" | "heartbeat_invalid" | "heartbeat_no_policy" | "heartbeat_rate_limited" | "heartbeat_no_eligible_session" | "cooldown_active" | "quiet_window" | "session_not_found" | "session_unhealthy" | "session_not_attachable" | "session_prompt_active" | "session_prompt_active_race" | "synthetic_prompt_failed" | "wake_coalesced";
2936
- last_result: "sent" | "skipped" | "coalesced" | "rate_limited" | "failed";
3088
+ last_reason?: "quiet" | "reported" | "cancelled" | "digest_empty" | "digest_unchanged" | "policy_disabled" | "definition_not_always_on" | "definition_missing" | "no_slot" | "hook_cancelled" | "duplicate_suppressed" | "triage_unsupported" | "triage_output_invalid" | "triage_timeout" | "triage_interrupted" | "triage_config_unavailable" | "triage_failed" | "source_poll_in_flight" | "wake_sent" | "heartbeat_disabled" | "heartbeat_invalid" | "heartbeat_no_policy" | "heartbeat_rate_limited" | "heartbeat_no_eligible_session" | "cooldown_active" | "quiet_window" | "session_not_found" | "session_unhealthy" | "session_not_attachable" | "session_prompt_active" | "session_prompt_active_race" | "synthetic_prompt_failed" | "wake_coalesced";
3089
+ last_result: "quiet" | "cancelled" | "reported" | "sent" | "skipped" | "coalesced" | "rate_limited" | "failed";
2937
3090
  last_wake_at?: string | null;
2938
3091
  next_allowed_at?: string | null;
2939
3092
  policy_snapshot_id?: string;
@@ -4740,6 +4893,7 @@ export type ProviderUsageTarget = {
4740
4893
  account: ProviderUsageAccount | null;
4741
4894
  balances: Array<ProviderUsageBalance>;
4742
4895
  checked_at: string | null;
4896
+ collector_id?: string;
4743
4897
  confidence: string;
4744
4898
  error: ProviderUsageError | null;
4745
4899
  measured_at: string | null;
@@ -4798,6 +4952,7 @@ export type PutSettingsHookRequest = {
4798
4952
  };
4799
4953
  export type PutSettingsMCPServerRequest = {
4800
4954
  preserve_env?: Array<string>;
4955
+ preserve_headers?: boolean;
4801
4956
  preserve_secrets?: SettingsMCPSecretPreservationPayload | null;
4802
4957
  secret_values?: SettingsMCPSecretValuesPayload | null;
4803
4958
  server: SettingsMCPServerPayload;
@@ -5465,6 +5620,8 @@ export type SendPromptResultPayload = {
5465
5620
  entry_id?: string;
5466
5621
  estimated_send_at?: string | null;
5467
5622
  goal?: GoalCommandResult | null;
5623
+ held_instance_id?: string;
5624
+ held_reason?: string;
5468
5625
  idempotency_key: string;
5469
5626
  message_id: string;
5470
5627
  mode?: string;
@@ -5476,7 +5633,7 @@ export type SendPromptResultPayload = {
5476
5633
  replayed: boolean;
5477
5634
  reply_watch?: ReplyWatchRefPayload | null;
5478
5635
  status: string;
5479
- steer_delivery?: "injected" | "pending_injection" | "interrupt_fallback";
5636
+ steer_delivery?: "injected" | "pending_injection" | "pending_boundary" | "after_turn" | "interrupt_fallback";
5480
5637
  target_session_id?: string;
5481
5638
  target_workspace_id?: string;
5482
5639
  turn_id?: string;
@@ -5585,6 +5742,35 @@ export type SessionCatalogResponse = {
5585
5742
  page: SessionCatalogPagePayload;
5586
5743
  sessions: Array<SessionPayload>;
5587
5744
  };
5745
+ export type SessionChangeBasesResponse = {
5746
+ default: ChangeBaseRefPayload | null;
5747
+ refs: Array<ChangeBaseRefPayload>;
5748
+ resolvable: boolean;
5749
+ truncated: boolean;
5750
+ };
5751
+ export type SessionChangeContentsResponse = {
5752
+ fingerprint: string;
5753
+ new?: ChangeSidePayload | null;
5754
+ old?: ChangeSidePayload | null;
5755
+ old_path?: string;
5756
+ path: string;
5757
+ revision: string;
5758
+ };
5759
+ export type SessionChangePatchesResponse = {
5760
+ patches: Array<ChangePatchPayload>;
5761
+ revision: string;
5762
+ };
5763
+ export type SessionChangesResponse = {
5764
+ base: ChangeBasePayload;
5765
+ files: Array<FileChangePayload>;
5766
+ head: ChangeHeadPayload;
5767
+ pull_request?: SessionPullRequestPayload | null;
5768
+ revision: string;
5769
+ root: FileRootPayload;
5770
+ scope: string;
5771
+ totals: ChangeTotalsPayload;
5772
+ truncated: boolean;
5773
+ };
5588
5774
  export type SessionChildrenPayload = {
5589
5775
  done: number;
5590
5776
  in_review: number;
@@ -5937,6 +6123,8 @@ export type SessionInputPayload = {
5937
6123
  delivery: string;
5938
6124
  enqueued_at: string;
5939
6125
  held: boolean;
6126
+ held_instance_id?: string;
6127
+ held_reason?: string;
5940
6128
  id: string;
5941
6129
  idempotency_key?: string;
5942
6130
  mentions?: Array<SessionInputMentionPayload>;
@@ -5950,7 +6138,7 @@ export type SessionInputPayload = {
5950
6138
  session_id: string;
5951
6139
  skill_invocations?: Array<SessionSkillInvocationPayload>;
5952
6140
  status: "queued" | "dispatching" | "sent" | "failed" | "canceled";
5953
- steer_delivery?: "injected" | "pending_injection" | "interrupt_fallback";
6141
+ steer_delivery?: "injected" | "pending_injection" | "pending_boundary" | "after_turn" | "interrupt_fallback";
5954
6142
  target_turn_id?: string;
5955
6143
  text: string;
5956
6144
  };
@@ -6824,6 +7012,7 @@ export type SettingsMCPServerItemPayload = {
6824
7012
  catalog_version?: string;
6825
7013
  command?: string;
6826
7014
  env_keys?: Array<string>;
7015
+ headers_configured?: boolean;
6827
7016
  name: string;
6828
7017
  override?: SettingsMCPExtensionOverridePayload | null;
6829
7018
  owner?: string;
@@ -7469,7 +7658,7 @@ export type SettingsWindowManagerSnapPayload = {
7469
7658
  };
7470
7659
  export type SignalSourceState = {
7471
7660
  error?: string;
7472
- kind: "agent_progress" | "tool_running" | "active_child" | "loop_run" | "task_lease" | "scheduled_wait" | "awaiting_reply" | "active_monitor" | "held_permission";
7661
+ kind: "agent_progress" | "tool_running" | "active_child" | "loop_run" | "task_lease" | "scheduled_wait" | "awaiting_reply" | "active_monitor" | "held_permission" | "held_input";
7473
7662
  ref?: string;
7474
7663
  state: string;
7475
7664
  };
@@ -9602,7 +9791,9 @@ export type WorkCandidates = {
9602
9791
  supports_pr_discovery: boolean;
9603
9792
  };
9604
9793
  export type WorkSignal = {
9605
- kind: "agent_progress" | "tool_running" | "active_child" | "loop_run" | "task_lease" | "scheduled_wait" | "awaiting_reply" | "active_monitor" | "held_permission";
9794
+ held_instance_id?: string;
9795
+ held_reason?: string;
9796
+ kind: "agent_progress" | "tool_running" | "active_child" | "loop_run" | "task_lease" | "scheduled_wait" | "awaiting_reply" | "active_monitor" | "held_permission" | "held_input";
9606
9797
  ref?: string;
9607
9798
  since: string;
9608
9799
  };
@@ -9878,6 +10069,72 @@ export type WorktreesResponse = {
9878
10069
  repo: WorktreeRepoPayload;
9879
10070
  worktrees: Array<WorktreePayload>;
9880
10071
  };
10072
+ export type AgentMCPServerInputWritable = {
10073
+ args?: Array<string>;
10074
+ auth?: SettingsMCPAuthConfigPayload | null;
10075
+ command?: string;
10076
+ env?: {
10077
+ [key: string]: string;
10078
+ };
10079
+ name: string;
10080
+ reference?: boolean;
10081
+ secret_env?: {
10082
+ [key: string]: string;
10083
+ };
10084
+ secret_env_values?: {
10085
+ [key: string]: string;
10086
+ };
10087
+ secret_header_values?: {
10088
+ [key: string]: string;
10089
+ };
10090
+ secret_headers?: {
10091
+ [key: string]: string;
10092
+ };
10093
+ transport?: string;
10094
+ url?: string;
10095
+ };
10096
+ export type CreateAgentPayloadWritable = {
10097
+ acp_options?: Array<AgentACPOptionSelection>;
10098
+ appearance?: {
10099
+ [key: string]: unknown;
10100
+ };
10101
+ category_path?: Array<string>;
10102
+ command?: string;
10103
+ deny_tools?: Array<string>;
10104
+ description?: string | null;
10105
+ display_name?: string | null;
10106
+ fallback_chain?: Array<AgentFallbackRoutePayload>;
10107
+ /**
10108
+ * Agent kind: on_demand (default) or always_on; fixed at creation.
10109
+ */
10110
+ kind?: "on_demand" | "always_on";
10111
+ label?: string;
10112
+ mcp_servers?: Array<AgentMCPServerInputWritable>;
10113
+ model?: string;
10114
+ name: string;
10115
+ permission_rules?: Array<AgentPermissionRulePayload>;
10116
+ permissions?: "deny-all" | "approve-reads" | "approve-edits" | "auto" | "approve-all";
10117
+ prompt: string;
10118
+ provider?: string;
10119
+ reasoning_effort?: string;
10120
+ resolved_appearance?: {
10121
+ [key: string]: unknown;
10122
+ };
10123
+ session_approval?: string;
10124
+ session_env?: {
10125
+ [key: string]: SessionEnvBindingPayload;
10126
+ };
10127
+ skills?: CreateAgentSkillsConfig | null;
10128
+ speed?: "normal" | "fast";
10129
+ tools?: Array<string>;
10130
+ toolsets?: Array<string>;
10131
+ workspace_access?: string;
10132
+ };
10133
+ export type CreateAgentRequestWritable = {
10134
+ agent: CreateAgentPayloadWritable;
10135
+ scope: "workspace" | "global";
10136
+ workspace?: string;
10137
+ };
9881
10138
  export type InstallExtensionRequestWritable = {
9882
10139
  allow_unverified?: boolean;
9883
10140
  asset?: string;
@@ -9905,6 +10162,11 @@ export type InstallExtensionRequestWritable = {
9905
10162
  */
9906
10163
  workspace_id?: string;
9907
10164
  };
10165
+ export type UpdateAgentRequestWritable = {
10166
+ agent: CreateAgentPayloadWritable;
10167
+ expected_digest: string;
10168
+ workspace?: string;
10169
+ };
9908
10170
  export type UpdateExtensionRequestWritable = {
9909
10171
  allow_unverified?: boolean;
9910
10172
  check_only?: boolean;
@@ -11894,7 +12156,7 @@ export type CreateAgentData = {
11894
12156
  /**
11895
12157
  * JSON request body
11896
12158
  */
11897
- body: CreateAgentRequest;
12159
+ body: CreateAgentRequestWritable;
11898
12160
  path?: never;
11899
12161
  query?: {
11900
12162
  /**
@@ -12280,7 +12542,7 @@ export type UpdateAgentData = {
12280
12542
  /**
12281
12543
  * JSON request body
12282
12544
  */
12283
- body: UpdateAgentRequest;
12545
+ body: UpdateAgentRequestWritable;
12284
12546
  path: {
12285
12547
  /**
12286
12548
  * Agent name
@@ -27666,6 +27928,278 @@ export type DismissAutomationSuggestionResponses = {
27666
27928
  200: AutomationSuggestionResponse;
27667
27929
  };
27668
27930
  export type DismissAutomationSuggestionResponse = DismissAutomationSuggestionResponses[keyof DismissAutomationSuggestionResponses];
27931
+ export type ReadFileContentData = {
27932
+ body?: never;
27933
+ path: {
27934
+ /**
27935
+ * Workspace id
27936
+ */
27937
+ workspace_id: string;
27938
+ };
27939
+ query: {
27940
+ /**
27941
+ * Optional worktree id
27942
+ */
27943
+ worktree_id?: string;
27944
+ /**
27945
+ * Root-relative path
27946
+ */
27947
+ path: string;
27948
+ /**
27949
+ * Reveal sensitive content; forbidden to app tokens
27950
+ */
27951
+ reveal?: boolean;
27952
+ /**
27953
+ * Read one profile's rows by name
27954
+ */
27955
+ profile?: string;
27956
+ /**
27957
+ * Read the owner-labeled all-profiles aggregate
27958
+ */
27959
+ all_profiles?: boolean;
27960
+ };
27961
+ url: "/api/workspaces/{workspace_id}/files/content";
27962
+ };
27963
+ export type ReadFileContentErrors = {
27964
+ /**
27965
+ * File operation failed
27966
+ */
27967
+ 400: ErrorPayload;
27968
+ /**
27969
+ * File operation failed
27970
+ */
27971
+ 403: ErrorPayload;
27972
+ /**
27973
+ * File operation failed
27974
+ */
27975
+ 404: ErrorPayload;
27976
+ /**
27977
+ * File operation failed
27978
+ */
27979
+ 409: ErrorPayload;
27980
+ /**
27981
+ * File operation failed
27982
+ */
27983
+ 422: ErrorPayload;
27984
+ /**
27985
+ * File operation failed
27986
+ */
27987
+ 500: ErrorPayload;
27988
+ };
27989
+ export type ReadFileContentError = ReadFileContentErrors[keyof ReadFileContentErrors];
27990
+ export type ReadFileContentResponses = {
27991
+ /**
27992
+ * OK
27993
+ */
27994
+ 200: FileContentResponse;
27995
+ };
27996
+ export type ReadFileContentResponse = ReadFileContentResponses[keyof ReadFileContentResponses];
27997
+ export type ListFileEntriesData = {
27998
+ body?: never;
27999
+ path: {
28000
+ /**
28001
+ * Workspace id
28002
+ */
28003
+ workspace_id: string;
28004
+ };
28005
+ query?: {
28006
+ /**
28007
+ * Optional worktree id
28008
+ */
28009
+ worktree_id?: string;
28010
+ /**
28011
+ * Root-relative path
28012
+ */
28013
+ path?: string;
28014
+ /**
28015
+ * Include ignored entries
28016
+ */
28017
+ show_ignored?: boolean;
28018
+ /**
28019
+ * Read one profile's rows by name
28020
+ */
28021
+ profile?: string;
28022
+ /**
28023
+ * Read the owner-labeled all-profiles aggregate
28024
+ */
28025
+ all_profiles?: boolean;
28026
+ };
28027
+ url: "/api/workspaces/{workspace_id}/files/entries";
28028
+ };
28029
+ export type ListFileEntriesErrors = {
28030
+ /**
28031
+ * File operation failed
28032
+ */
28033
+ 400: ErrorPayload;
28034
+ /**
28035
+ * File operation failed
28036
+ */
28037
+ 403: ErrorPayload;
28038
+ /**
28039
+ * File operation failed
28040
+ */
28041
+ 404: ErrorPayload;
28042
+ /**
28043
+ * File operation failed
28044
+ */
28045
+ 409: ErrorPayload;
28046
+ /**
28047
+ * File operation failed
28048
+ */
28049
+ 422: ErrorPayload;
28050
+ /**
28051
+ * File operation failed
28052
+ */
28053
+ 500: ErrorPayload;
28054
+ };
28055
+ export type ListFileEntriesError = ListFileEntriesErrors[keyof ListFileEntriesErrors];
28056
+ export type ListFileEntriesResponses = {
28057
+ /**
28058
+ * OK
28059
+ */
28060
+ 200: FileEntriesResponse;
28061
+ };
28062
+ export type ListFileEntriesResponse = ListFileEntriesResponses[keyof ListFileEntriesResponses];
28063
+ export type FindFilesData = {
28064
+ body?: never;
28065
+ path: {
28066
+ /**
28067
+ * Workspace id
28068
+ */
28069
+ workspace_id: string;
28070
+ };
28071
+ query: {
28072
+ /**
28073
+ * Optional worktree id
28074
+ */
28075
+ worktree_id?: string;
28076
+ /**
28077
+ * Search query
28078
+ */
28079
+ q: string;
28080
+ /**
28081
+ * Result limit; defaults and clamps to 50
28082
+ */
28083
+ limit?: number;
28084
+ /**
28085
+ * Read one profile's rows by name
28086
+ */
28087
+ profile?: string;
28088
+ /**
28089
+ * Read the owner-labeled all-profiles aggregate
28090
+ */
28091
+ all_profiles?: boolean;
28092
+ };
28093
+ url: "/api/workspaces/{workspace_id}/files/find";
28094
+ };
28095
+ export type FindFilesErrors = {
28096
+ /**
28097
+ * Search failed
28098
+ */
28099
+ 400: ErrorPayload;
28100
+ /**
28101
+ * Search failed
28102
+ */
28103
+ 403: ErrorPayload;
28104
+ /**
28105
+ * Search failed
28106
+ */
28107
+ 404: ErrorPayload;
28108
+ /**
28109
+ * Search failed
28110
+ */
28111
+ 409: ErrorPayload;
28112
+ /**
28113
+ * Search failed
28114
+ */
28115
+ 500: ErrorPayload;
28116
+ };
28117
+ export type FindFilesError = FindFilesErrors[keyof FindFilesErrors];
28118
+ export type FindFilesResponses = {
28119
+ /**
28120
+ * OK
28121
+ */
28122
+ 200: FileFindResponse;
28123
+ };
28124
+ export type FindFilesResponse = FindFilesResponses[keyof FindFilesResponses];
28125
+ export type SearchFileContentsData = {
28126
+ body?: never;
28127
+ path: {
28128
+ /**
28129
+ * Workspace id
28130
+ */
28131
+ workspace_id: string;
28132
+ };
28133
+ query: {
28134
+ /**
28135
+ * Optional worktree id
28136
+ */
28137
+ worktree_id?: string;
28138
+ /**
28139
+ * Search query
28140
+ */
28141
+ q: string;
28142
+ /**
28143
+ * Use POSIX ERE
28144
+ */
28145
+ regex?: boolean;
28146
+ /**
28147
+ * Match case
28148
+ */
28149
+ case_sensitive?: boolean;
28150
+ /**
28151
+ * Match whole words
28152
+ */
28153
+ whole_word?: boolean;
28154
+ /**
28155
+ * Root-relative globs; repeat at most ten times
28156
+ */
28157
+ include?: Array<string>;
28158
+ /**
28159
+ * Root-relative globs; repeat at most ten times
28160
+ */
28161
+ exclude?: Array<string>;
28162
+ /**
28163
+ * Read one profile's rows by name
28164
+ */
28165
+ profile?: string;
28166
+ /**
28167
+ * Read the owner-labeled all-profiles aggregate
28168
+ */
28169
+ all_profiles?: boolean;
28170
+ };
28171
+ url: "/api/workspaces/{workspace_id}/files/search";
28172
+ };
28173
+ export type SearchFileContentsErrors = {
28174
+ /**
28175
+ * Search failed
28176
+ */
28177
+ 400: ErrorPayload;
28178
+ /**
28179
+ * Search failed
28180
+ */
28181
+ 403: ErrorPayload;
28182
+ /**
28183
+ * Search failed
28184
+ */
28185
+ 404: ErrorPayload;
28186
+ /**
28187
+ * Search failed
28188
+ */
28189
+ 409: ErrorPayload;
28190
+ /**
28191
+ * Search failed
28192
+ */
28193
+ 500: ErrorPayload;
28194
+ };
28195
+ export type SearchFileContentsError = SearchFileContentsErrors[keyof SearchFileContentsErrors];
28196
+ export type SearchFileContentsResponses = {
28197
+ /**
28198
+ * OK
28199
+ */
28200
+ 200: FileSearchResponse;
28201
+ };
28202
+ export type SearchFileContentsResponse = SearchFileContentsResponses[keyof SearchFileContentsResponses];
27669
28203
  export type GetHookRunsData = {
27670
28204
  body?: never;
27671
28205
  path: {
@@ -30860,6 +31394,318 @@ export type ReadSessionAttachmentBytesResponses = {
30860
31394
  200: Blob | File;
30861
31395
  };
30862
31396
  export type ReadSessionAttachmentBytesResponse = ReadSessionAttachmentBytesResponses[keyof ReadSessionAttachmentBytesResponses];
31397
+ export type GetSessionChangesData = {
31398
+ body?: never;
31399
+ path: {
31400
+ /**
31401
+ * Workspace id
31402
+ */
31403
+ workspace_id: string;
31404
+ /**
31405
+ * Session id
31406
+ */
31407
+ session_id: string;
31408
+ };
31409
+ query?: {
31410
+ /**
31411
+ * Changes scope
31412
+ */
31413
+ scope?: "branch" | "uncommitted";
31414
+ /**
31415
+ * Optional base ref
31416
+ */
31417
+ base?: string;
31418
+ /**
31419
+ * Read one profile's rows by name
31420
+ */
31421
+ profile?: string;
31422
+ /**
31423
+ * Read the owner-labeled all-profiles aggregate
31424
+ */
31425
+ all_profiles?: boolean;
31426
+ };
31427
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/changes";
31428
+ };
31429
+ export type GetSessionChangesErrors = {
31430
+ /**
31431
+ * Changes operation failed
31432
+ */
31433
+ 400: ErrorPayload;
31434
+ /**
31435
+ * Changes operation failed
31436
+ */
31437
+ 403: ErrorPayload;
31438
+ /**
31439
+ * Changes operation failed
31440
+ */
31441
+ 404: ErrorPayload;
31442
+ /**
31443
+ * Changes operation failed
31444
+ */
31445
+ 409: ErrorPayload;
31446
+ /**
31447
+ * Changes operation failed
31448
+ */
31449
+ 413: ErrorPayload;
31450
+ /**
31451
+ * Changes operation failed
31452
+ */
31453
+ 422: ErrorPayload;
31454
+ /**
31455
+ * Changes operation failed
31456
+ */
31457
+ 500: ErrorPayload;
31458
+ };
31459
+ export type GetSessionChangesError = GetSessionChangesErrors[keyof GetSessionChangesErrors];
31460
+ export type GetSessionChangesResponses = {
31461
+ /**
31462
+ * OK
31463
+ */
31464
+ 200: SessionChangesResponse;
31465
+ };
31466
+ export type GetSessionChangesResponse = GetSessionChangesResponses[keyof GetSessionChangesResponses];
31467
+ export type ListSessionChangeBasesData = {
31468
+ body?: never;
31469
+ path: {
31470
+ /**
31471
+ * Workspace id
31472
+ */
31473
+ workspace_id: string;
31474
+ /**
31475
+ * Session id
31476
+ */
31477
+ session_id: string;
31478
+ };
31479
+ query?: {
31480
+ /**
31481
+ * Substring ref filter
31482
+ */
31483
+ q?: string;
31484
+ /**
31485
+ * Default 200, maximum 500
31486
+ */
31487
+ limit?: number;
31488
+ /**
31489
+ * Read one profile's rows by name
31490
+ */
31491
+ profile?: string;
31492
+ /**
31493
+ * Read the owner-labeled all-profiles aggregate
31494
+ */
31495
+ all_profiles?: boolean;
31496
+ };
31497
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/changes/bases";
31498
+ };
31499
+ export type ListSessionChangeBasesErrors = {
31500
+ /**
31501
+ * Changes operation failed
31502
+ */
31503
+ 400: ErrorPayload;
31504
+ /**
31505
+ * Changes operation failed
31506
+ */
31507
+ 403: ErrorPayload;
31508
+ /**
31509
+ * Changes operation failed
31510
+ */
31511
+ 404: ErrorPayload;
31512
+ /**
31513
+ * Changes operation failed
31514
+ */
31515
+ 409: ErrorPayload;
31516
+ /**
31517
+ * Changes operation failed
31518
+ */
31519
+ 413: ErrorPayload;
31520
+ /**
31521
+ * Changes operation failed
31522
+ */
31523
+ 422: ErrorPayload;
31524
+ /**
31525
+ * Changes operation failed
31526
+ */
31527
+ 500: ErrorPayload;
31528
+ };
31529
+ export type ListSessionChangeBasesError = ListSessionChangeBasesErrors[keyof ListSessionChangeBasesErrors];
31530
+ export type ListSessionChangeBasesResponses = {
31531
+ /**
31532
+ * OK
31533
+ */
31534
+ 200: SessionChangeBasesResponse;
31535
+ };
31536
+ export type ListSessionChangeBasesResponse = ListSessionChangeBasesResponses[keyof ListSessionChangeBasesResponses];
31537
+ export type GetSessionChangeContentsData = {
31538
+ body?: never;
31539
+ path: {
31540
+ /**
31541
+ * Workspace id
31542
+ */
31543
+ workspace_id: string;
31544
+ /**
31545
+ * Session id
31546
+ */
31547
+ session_id: string;
31548
+ };
31549
+ query: {
31550
+ /**
31551
+ * Changes scope
31552
+ */
31553
+ scope?: "branch" | "uncommitted";
31554
+ /**
31555
+ * Optional base ref
31556
+ */
31557
+ base?: string;
31558
+ /**
31559
+ * Summary revision fence
31560
+ */
31561
+ revision: string;
31562
+ /**
31563
+ * Root-relative path
31564
+ */
31565
+ path: string;
31566
+ /**
31567
+ * Aligned old path for renames
31568
+ */
31569
+ old_path?: string;
31570
+ /**
31571
+ * Reveal sensitive contents; forbidden to app tokens
31572
+ */
31573
+ reveal?: boolean;
31574
+ /**
31575
+ * Read one profile's rows by name
31576
+ */
31577
+ profile?: string;
31578
+ /**
31579
+ * Read the owner-labeled all-profiles aggregate
31580
+ */
31581
+ all_profiles?: boolean;
31582
+ };
31583
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/changes/contents";
31584
+ };
31585
+ export type GetSessionChangeContentsErrors = {
31586
+ /**
31587
+ * Changes operation failed
31588
+ */
31589
+ 400: ErrorPayload;
31590
+ /**
31591
+ * Changes operation failed
31592
+ */
31593
+ 403: ErrorPayload;
31594
+ /**
31595
+ * Changes operation failed
31596
+ */
31597
+ 404: ErrorPayload;
31598
+ /**
31599
+ * Changes operation failed
31600
+ */
31601
+ 409: ErrorPayload;
31602
+ /**
31603
+ * Changes operation failed
31604
+ */
31605
+ 413: ErrorPayload;
31606
+ /**
31607
+ * Changes operation failed
31608
+ */
31609
+ 422: ErrorPayload;
31610
+ /**
31611
+ * Changes operation failed
31612
+ */
31613
+ 500: ErrorPayload;
31614
+ };
31615
+ export type GetSessionChangeContentsError = GetSessionChangeContentsErrors[keyof GetSessionChangeContentsErrors];
31616
+ export type GetSessionChangeContentsResponses = {
31617
+ /**
31618
+ * OK
31619
+ */
31620
+ 200: SessionChangeContentsResponse;
31621
+ };
31622
+ export type GetSessionChangeContentsResponse = GetSessionChangeContentsResponses[keyof GetSessionChangeContentsResponses];
31623
+ export type GetSessionChangePatchesData = {
31624
+ body?: never;
31625
+ path: {
31626
+ /**
31627
+ * Workspace id
31628
+ */
31629
+ workspace_id: string;
31630
+ /**
31631
+ * Session id
31632
+ */
31633
+ session_id: string;
31634
+ };
31635
+ query: {
31636
+ /**
31637
+ * Changes scope
31638
+ */
31639
+ scope?: "branch" | "uncommitted";
31640
+ /**
31641
+ * Optional base ref
31642
+ */
31643
+ base?: string;
31644
+ /**
31645
+ * Summary revision fence
31646
+ */
31647
+ revision: string;
31648
+ /**
31649
+ * Root-relative path
31650
+ */
31651
+ path: Array<string>;
31652
+ /**
31653
+ * Aligned old path for renames
31654
+ */
31655
+ old_path?: Array<string>;
31656
+ /**
31657
+ * Reveal sensitive contents; forbidden to app tokens
31658
+ */
31659
+ reveal?: boolean;
31660
+ /**
31661
+ * Read one profile's rows by name
31662
+ */
31663
+ profile?: string;
31664
+ /**
31665
+ * Read the owner-labeled all-profiles aggregate
31666
+ */
31667
+ all_profiles?: boolean;
31668
+ };
31669
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/changes/patches";
31670
+ };
31671
+ export type GetSessionChangePatchesErrors = {
31672
+ /**
31673
+ * Changes operation failed
31674
+ */
31675
+ 400: ErrorPayload;
31676
+ /**
31677
+ * Changes operation failed
31678
+ */
31679
+ 403: ErrorPayload;
31680
+ /**
31681
+ * Changes operation failed
31682
+ */
31683
+ 404: ErrorPayload;
31684
+ /**
31685
+ * Changes operation failed
31686
+ */
31687
+ 409: ErrorPayload;
31688
+ /**
31689
+ * Changes operation failed
31690
+ */
31691
+ 413: ErrorPayload;
31692
+ /**
31693
+ * Changes operation failed
31694
+ */
31695
+ 422: ErrorPayload;
31696
+ /**
31697
+ * Changes operation failed
31698
+ */
31699
+ 500: ErrorPayload;
31700
+ };
31701
+ export type GetSessionChangePatchesError = GetSessionChangePatchesErrors[keyof GetSessionChangePatchesErrors];
31702
+ export type GetSessionChangePatchesResponses = {
31703
+ /**
31704
+ * OK
31705
+ */
31706
+ 200: SessionChangePatchesResponse;
31707
+ };
31708
+ export type GetSessionChangePatchesResponse = GetSessionChangePatchesResponses[keyof GetSessionChangePatchesResponses];
30863
31709
  export type ListSessionClarificationsData = {
30864
31710
  body?: never;
30865
31711
  path: {
@@ -31023,9 +31869,219 @@ export type GetSessionCommandsData = {
31023
31869
  */
31024
31870
  all_profiles?: boolean;
31025
31871
  };
31026
- url: "/api/workspaces/{workspace_id}/sessions/{session_id}/commands";
31872
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/commands";
31873
+ };
31874
+ export type GetSessionCommandsErrors = {
31875
+ /**
31876
+ * Session not found
31877
+ */
31878
+ 404: ErrorPayload;
31879
+ /**
31880
+ * Internal server error
31881
+ */
31882
+ 500: ErrorPayload;
31883
+ /**
31884
+ * Command catalog unavailable
31885
+ */
31886
+ 503: ErrorPayload;
31887
+ };
31888
+ export type GetSessionCommandsError = GetSessionCommandsErrors[keyof GetSessionCommandsErrors];
31889
+ export type GetSessionCommandsResponses = {
31890
+ /**
31891
+ * OK
31892
+ */
31893
+ 200: SessionCommandsResponse;
31894
+ };
31895
+ export type GetSessionCommandsResponse = GetSessionCommandsResponses[keyof GetSessionCommandsResponses];
31896
+ export type CompactSessionData = {
31897
+ /**
31898
+ * JSON request body
31899
+ */
31900
+ body: SessionCompactRequest;
31901
+ path: {
31902
+ /**
31903
+ * Workspace id
31904
+ */
31905
+ workspace_id: string;
31906
+ /**
31907
+ * Session id
31908
+ */
31909
+ session_id: string;
31910
+ };
31911
+ query?: {
31912
+ /**
31913
+ * Act as this profile by name
31914
+ */
31915
+ profile?: string;
31916
+ };
31917
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/compact";
31918
+ };
31919
+ export type CompactSessionErrors = {
31920
+ /**
31921
+ * session_not_promptable
31922
+ */
31923
+ 400: ErrorPayload;
31924
+ /**
31925
+ * Session not found
31926
+ */
31927
+ 404: ErrorPayload;
31928
+ /**
31929
+ * session_busy or compaction_unsupported
31930
+ */
31931
+ 409: ErrorPayload;
31932
+ /**
31933
+ * Internal server error
31934
+ */
31935
+ 500: ErrorPayload;
31936
+ };
31937
+ export type CompactSessionError = CompactSessionErrors[keyof CompactSessionErrors];
31938
+ export type CompactSessionResponses = {
31939
+ /**
31940
+ * Compaction accepted
31941
+ */
31942
+ 202: SessionCompactResponse;
31943
+ };
31944
+ export type CompactSessionResponse = CompactSessionResponses[keyof CompactSessionResponses];
31945
+ export type ContinueSessionData = {
31946
+ /**
31947
+ * JSON request body
31948
+ */
31949
+ body: ContinueSessionRequest;
31950
+ path: {
31951
+ /**
31952
+ * Workspace id
31953
+ */
31954
+ workspace_id: string;
31955
+ /**
31956
+ * Source session id
31957
+ */
31958
+ session_id: string;
31959
+ };
31960
+ query?: {
31961
+ /**
31962
+ * Act as this profile by name
31963
+ */
31964
+ profile?: string;
31965
+ };
31966
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/continue";
31967
+ };
31968
+ export type ContinueSessionErrors = {
31969
+ /**
31970
+ * Invalid continue request
31971
+ */
31972
+ 400: SessionDeriveErrorPayload;
31973
+ /**
31974
+ * Session or agent not found
31975
+ */
31976
+ 404: SessionDeriveErrorPayload;
31977
+ /**
31978
+ * Session cannot be continued
31979
+ */
31980
+ 409: SessionDeriveErrorPayload;
31981
+ /**
31982
+ * Runtime or authentication failure; when the new session was already created the error carries child_session_id and a retry with the same idempotency_key returns it
31983
+ */
31984
+ 422: SessionDeriveErrorPayload;
31985
+ /**
31986
+ * Internal server error
31987
+ */
31988
+ 500: SessionDeriveErrorPayload;
31989
+ /**
31990
+ * New-work admission is unavailable while the daemon is draining
31991
+ */
31992
+ 503: SessionDeriveErrorPayload;
31993
+ };
31994
+ export type ContinueSessionError = ContinueSessionErrors[keyof ContinueSessionErrors];
31995
+ export type ContinueSessionResponses = {
31996
+ /**
31997
+ * Recorded outcome replayed
31998
+ */
31999
+ 200: SessionDeriveResponse;
32000
+ /**
32001
+ * Created
32002
+ */
32003
+ 201: SessionDeriveResponse;
32004
+ };
32005
+ export type ContinueSessionResponse = ContinueSessionResponses[keyof ContinueSessionResponses];
32006
+ export type PreviewSessionDeriveData = {
32007
+ body?: never;
32008
+ path: {
32009
+ /**
32010
+ * Workspace id
32011
+ */
32012
+ workspace_id: string;
32013
+ /**
32014
+ * Source session id
32015
+ */
32016
+ session_id: string;
32017
+ };
32018
+ query?: {
32019
+ /**
32020
+ * Durable user message to cut through (fork from here)
32021
+ */
32022
+ message_id?: string;
32023
+ /**
32024
+ * Read one profile's rows by name
32025
+ */
32026
+ profile?: string;
32027
+ /**
32028
+ * Read the owner-labeled all-profiles aggregate
32029
+ */
32030
+ all_profiles?: boolean;
32031
+ };
32032
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/derive/preview";
32033
+ };
32034
+ export type PreviewSessionDeriveErrors = {
32035
+ /**
32036
+ * Session cannot be continued or forked
32037
+ */
32038
+ 400: ErrorPayload;
32039
+ /**
32040
+ * Session or message not found
32041
+ */
32042
+ 404: ErrorPayload;
32043
+ /**
32044
+ * Session is archived
32045
+ */
32046
+ 409: ErrorPayload;
32047
+ /**
32048
+ * Internal server error
32049
+ */
32050
+ 500: ErrorPayload;
32051
+ };
32052
+ export type PreviewSessionDeriveError = PreviewSessionDeriveErrors[keyof PreviewSessionDeriveErrors];
32053
+ export type PreviewSessionDeriveResponses = {
32054
+ /**
32055
+ * OK
32056
+ */
32057
+ 200: SessionDerivePreviewResponse;
32058
+ };
32059
+ export type PreviewSessionDeriveResponse = PreviewSessionDeriveResponses[keyof PreviewSessionDeriveResponses];
32060
+ export type ListSessionDescendantsData = {
32061
+ body?: never;
32062
+ path: {
32063
+ /**
32064
+ * Workspace id
32065
+ */
32066
+ workspace_id: string;
32067
+ /**
32068
+ * Session id
32069
+ */
32070
+ session_id: string;
32071
+ };
32072
+ query?: {
32073
+ /**
32074
+ * Read one profile's rows by name
32075
+ */
32076
+ profile?: string;
32077
+ /**
32078
+ * Read the owner-labeled all-profiles aggregate
32079
+ */
32080
+ all_profiles?: boolean;
32081
+ };
32082
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/descendants";
31027
32083
  };
31028
- export type GetSessionCommandsErrors = {
32084
+ export type ListSessionDescendantsErrors = {
31029
32085
  /**
31030
32086
  * Session not found
31031
32087
  */
@@ -31035,23 +32091,20 @@ export type GetSessionCommandsErrors = {
31035
32091
  */
31036
32092
  500: ErrorPayload;
31037
32093
  /**
31038
- * Command catalog unavailable
32094
+ * Service unavailable - dependent service missing
31039
32095
  */
31040
32096
  503: ErrorPayload;
31041
32097
  };
31042
- export type GetSessionCommandsError = GetSessionCommandsErrors[keyof GetSessionCommandsErrors];
31043
- export type GetSessionCommandsResponses = {
32098
+ export type ListSessionDescendantsError = ListSessionDescendantsErrors[keyof ListSessionDescendantsErrors];
32099
+ export type ListSessionDescendantsResponses = {
31044
32100
  /**
31045
32101
  * OK
31046
32102
  */
31047
- 200: SessionCommandsResponse;
32103
+ 200: SessionsResponse;
31048
32104
  };
31049
- export type GetSessionCommandsResponse = GetSessionCommandsResponses[keyof GetSessionCommandsResponses];
31050
- export type CompactSessionData = {
31051
- /**
31052
- * JSON request body
31053
- */
31054
- body: SessionCompactRequest;
32105
+ export type ListSessionDescendantsResponse = ListSessionDescendantsResponses[keyof ListSessionDescendantsResponses];
32106
+ export type ListSessionEventsData = {
32107
+ body?: never;
31055
32108
  path: {
31056
32109
  /**
31057
32110
  * Workspace id
@@ -31064,100 +32117,125 @@ export type CompactSessionData = {
31064
32117
  };
31065
32118
  query?: {
31066
32119
  /**
31067
- * Act as this profile by name
32120
+ * Only events emitted since this timestamp
32121
+ */
32122
+ since?: string;
32123
+ /**
32124
+ * Maximum number of records to return; defaults to the newest 200 and is capped at 1000
32125
+ */
32126
+ limit?: number;
32127
+ /**
32128
+ * Only return events after this sequence number
32129
+ */
32130
+ after_sequence?: number;
32131
+ /**
32132
+ * Event type
32133
+ */
32134
+ type?: string;
32135
+ /**
32136
+ * Agent name
32137
+ */
32138
+ agent_name?: string;
32139
+ /**
32140
+ * Turn id
32141
+ */
32142
+ turn_id?: string;
32143
+ /**
32144
+ * Select active, archived, or all events
32145
+ */
32146
+ archive?: "active" | "archived" | "all";
32147
+ /**
32148
+ * Read one profile's rows by name
31068
32149
  */
31069
32150
  profile?: string;
32151
+ /**
32152
+ * Read the owner-labeled all-profiles aggregate
32153
+ */
32154
+ all_profiles?: boolean;
31070
32155
  };
31071
- url: "/api/workspaces/{workspace_id}/sessions/{session_id}/compact";
32156
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/events";
31072
32157
  };
31073
- export type CompactSessionErrors = {
32158
+ export type ListSessionEventsErrors = {
31074
32159
  /**
31075
- * session_not_promptable
32160
+ * Invalid filter
31076
32161
  */
31077
32162
  400: ErrorPayload;
31078
32163
  /**
31079
32164
  * Session not found
31080
32165
  */
31081
32166
  404: ErrorPayload;
31082
- /**
31083
- * session_busy or compaction_unsupported
31084
- */
31085
- 409: ErrorPayload;
31086
32167
  /**
31087
32168
  * Internal server error
31088
32169
  */
31089
32170
  500: ErrorPayload;
31090
32171
  };
31091
- export type CompactSessionError = CompactSessionErrors[keyof CompactSessionErrors];
31092
- export type CompactSessionResponses = {
32172
+ export type ListSessionEventsError = ListSessionEventsErrors[keyof ListSessionEventsErrors];
32173
+ export type ListSessionEventsResponses = {
31093
32174
  /**
31094
- * Compaction accepted
32175
+ * OK
31095
32176
  */
31096
- 202: SessionCompactResponse;
32177
+ 200: SessionEventsResponse;
31097
32178
  };
31098
- export type CompactSessionResponse = CompactSessionResponses[keyof CompactSessionResponses];
31099
- export type ContinueSessionData = {
31100
- /**
31101
- * JSON request body
31102
- */
31103
- body: ContinueSessionRequest;
32179
+ export type ListSessionEventsResponse = ListSessionEventsResponses[keyof ListSessionEventsResponses];
32180
+ export type SearchSessionFilesData = {
32181
+ body?: never;
31104
32182
  path: {
31105
32183
  /**
31106
32184
  * Workspace id
31107
32185
  */
31108
32186
  workspace_id: string;
31109
32187
  /**
31110
- * Source session id
32188
+ * Session id
31111
32189
  */
31112
32190
  session_id: string;
31113
32191
  };
31114
32192
  query?: {
31115
32193
  /**
31116
- * Act as this profile by name
32194
+ * Search text; empty returns the shallowest entries
32195
+ */
32196
+ q?: string;
32197
+ /**
32198
+ * Maximum entries returned
32199
+ */
32200
+ limit?: number;
32201
+ /**
32202
+ * Read one profile's rows by name
31117
32203
  */
31118
32204
  profile?: string;
32205
+ /**
32206
+ * Read the owner-labeled all-profiles aggregate
32207
+ */
32208
+ all_profiles?: boolean;
31119
32209
  };
31120
- url: "/api/workspaces/{workspace_id}/sessions/{session_id}/continue";
32210
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/files";
31121
32211
  };
31122
- export type ContinueSessionErrors = {
31123
- /**
31124
- * Invalid continue request
31125
- */
31126
- 400: SessionDeriveErrorPayload;
32212
+ export type SearchSessionFilesErrors = {
31127
32213
  /**
31128
- * Session or agent not found
32214
+ * Invalid limit
31129
32215
  */
31130
- 404: SessionDeriveErrorPayload;
32216
+ 400: ErrorPayload;
31131
32217
  /**
31132
- * Session cannot be continued
32218
+ * Session not found
31133
32219
  */
31134
- 409: SessionDeriveErrorPayload;
32220
+ 404: ErrorPayload;
31135
32221
  /**
31136
- * Runtime or authentication failure; when the new session was already created the error carries child_session_id and a retry with the same idempotency_key returns it
32222
+ * Session working directory no longer exists
31137
32223
  */
31138
- 422: SessionDeriveErrorPayload;
32224
+ 409: ErrorPayload;
31139
32225
  /**
31140
32226
  * Internal server error
31141
32227
  */
31142
- 500: SessionDeriveErrorPayload;
31143
- /**
31144
- * New-work admission is unavailable while the daemon is draining
31145
- */
31146
- 503: SessionDeriveErrorPayload;
32228
+ 500: ErrorPayload;
31147
32229
  };
31148
- export type ContinueSessionError = ContinueSessionErrors[keyof ContinueSessionErrors];
31149
- export type ContinueSessionResponses = {
31150
- /**
31151
- * Recorded outcome replayed
31152
- */
31153
- 200: SessionDeriveResponse;
32230
+ export type SearchSessionFilesError = SearchSessionFilesErrors[keyof SearchSessionFilesErrors];
32231
+ export type SearchSessionFilesResponses = {
31154
32232
  /**
31155
- * Created
32233
+ * OK
31156
32234
  */
31157
- 201: SessionDeriveResponse;
32235
+ 200: SessionFilesResponse;
31158
32236
  };
31159
- export type ContinueSessionResponse = ContinueSessionResponses[keyof ContinueSessionResponses];
31160
- export type PreviewSessionDeriveData = {
32237
+ export type SearchSessionFilesResponse = SearchSessionFilesResponses[keyof SearchSessionFilesResponses];
32238
+ export type ReadSessionFileContentData = {
31161
32239
  body?: never;
31162
32240
  path: {
31163
32241
  /**
@@ -31165,15 +32243,19 @@ export type PreviewSessionDeriveData = {
31165
32243
  */
31166
32244
  workspace_id: string;
31167
32245
  /**
31168
- * Source session id
32246
+ * Session id
31169
32247
  */
31170
32248
  session_id: string;
31171
32249
  };
31172
- query?: {
32250
+ query: {
31173
32251
  /**
31174
- * Durable user message to cut through (fork from here)
32252
+ * Root-relative path
31175
32253
  */
31176
- message_id?: string;
32254
+ path: string;
32255
+ /**
32256
+ * Reveal sensitive content; forbidden to app tokens
32257
+ */
32258
+ reveal?: boolean;
31177
32259
  /**
31178
32260
  * Read one profile's rows by name
31179
32261
  */
@@ -31183,35 +32265,43 @@ export type PreviewSessionDeriveData = {
31183
32265
  */
31184
32266
  all_profiles?: boolean;
31185
32267
  };
31186
- url: "/api/workspaces/{workspace_id}/sessions/{session_id}/derive/preview";
32268
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/files/content";
31187
32269
  };
31188
- export type PreviewSessionDeriveErrors = {
32270
+ export type ReadSessionFileContentErrors = {
31189
32271
  /**
31190
- * Session cannot be continued or forked
32272
+ * File operation failed
31191
32273
  */
31192
32274
  400: ErrorPayload;
31193
32275
  /**
31194
- * Session or message not found
32276
+ * File operation failed
32277
+ */
32278
+ 403: ErrorPayload;
32279
+ /**
32280
+ * File operation failed
31195
32281
  */
31196
32282
  404: ErrorPayload;
31197
32283
  /**
31198
- * Session is archived
32284
+ * File operation failed
31199
32285
  */
31200
32286
  409: ErrorPayload;
31201
32287
  /**
31202
- * Internal server error
32288
+ * File operation failed
32289
+ */
32290
+ 422: ErrorPayload;
32291
+ /**
32292
+ * File operation failed
31203
32293
  */
31204
32294
  500: ErrorPayload;
31205
32295
  };
31206
- export type PreviewSessionDeriveError = PreviewSessionDeriveErrors[keyof PreviewSessionDeriveErrors];
31207
- export type PreviewSessionDeriveResponses = {
32296
+ export type ReadSessionFileContentError = ReadSessionFileContentErrors[keyof ReadSessionFileContentErrors];
32297
+ export type ReadSessionFileContentResponses = {
31208
32298
  /**
31209
32299
  * OK
31210
32300
  */
31211
- 200: SessionDerivePreviewResponse;
32301
+ 200: FileContentResponse;
31212
32302
  };
31213
- export type PreviewSessionDeriveResponse = PreviewSessionDeriveResponses[keyof PreviewSessionDeriveResponses];
31214
- export type ListSessionDescendantsData = {
32303
+ export type ReadSessionFileContentResponse = ReadSessionFileContentResponses[keyof ReadSessionFileContentResponses];
32304
+ export type ListSessionFileEntriesData = {
31215
32305
  body?: never;
31216
32306
  path: {
31217
32307
  /**
@@ -31224,6 +32314,14 @@ export type ListSessionDescendantsData = {
31224
32314
  session_id: string;
31225
32315
  };
31226
32316
  query?: {
32317
+ /**
32318
+ * Root-relative path
32319
+ */
32320
+ path?: string;
32321
+ /**
32322
+ * Include ignored entries
32323
+ */
32324
+ show_ignored?: boolean;
31227
32325
  /**
31228
32326
  * Read one profile's rows by name
31229
32327
  */
@@ -31233,31 +32331,43 @@ export type ListSessionDescendantsData = {
31233
32331
  */
31234
32332
  all_profiles?: boolean;
31235
32333
  };
31236
- url: "/api/workspaces/{workspace_id}/sessions/{session_id}/descendants";
32334
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/files/entries";
31237
32335
  };
31238
- export type ListSessionDescendantsErrors = {
32336
+ export type ListSessionFileEntriesErrors = {
31239
32337
  /**
31240
- * Session not found
32338
+ * File operation failed
32339
+ */
32340
+ 400: ErrorPayload;
32341
+ /**
32342
+ * File operation failed
32343
+ */
32344
+ 403: ErrorPayload;
32345
+ /**
32346
+ * File operation failed
31241
32347
  */
31242
32348
  404: ErrorPayload;
31243
32349
  /**
31244
- * Internal server error
32350
+ * File operation failed
31245
32351
  */
31246
- 500: ErrorPayload;
32352
+ 409: ErrorPayload;
31247
32353
  /**
31248
- * Service unavailable - dependent service missing
32354
+ * File operation failed
31249
32355
  */
31250
- 503: ErrorPayload;
32356
+ 422: ErrorPayload;
32357
+ /**
32358
+ * File operation failed
32359
+ */
32360
+ 500: ErrorPayload;
31251
32361
  };
31252
- export type ListSessionDescendantsError = ListSessionDescendantsErrors[keyof ListSessionDescendantsErrors];
31253
- export type ListSessionDescendantsResponses = {
32362
+ export type ListSessionFileEntriesError = ListSessionFileEntriesErrors[keyof ListSessionFileEntriesErrors];
32363
+ export type ListSessionFileEntriesResponses = {
31254
32364
  /**
31255
32365
  * OK
31256
32366
  */
31257
- 200: SessionsResponse;
32367
+ 200: FileEntriesResponse;
31258
32368
  };
31259
- export type ListSessionDescendantsResponse = ListSessionDescendantsResponses[keyof ListSessionDescendantsResponses];
31260
- export type ListSessionEventsData = {
32369
+ export type ListSessionFileEntriesResponse = ListSessionFileEntriesResponses[keyof ListSessionFileEntriesResponses];
32370
+ export type FindSessionFilesData = {
31261
32371
  body?: never;
31262
32372
  path: {
31263
32373
  /**
@@ -31269,35 +32379,15 @@ export type ListSessionEventsData = {
31269
32379
  */
31270
32380
  session_id: string;
31271
32381
  };
31272
- query?: {
32382
+ query: {
31273
32383
  /**
31274
- * Only events emitted since this timestamp
32384
+ * Search query
31275
32385
  */
31276
- since?: string;
32386
+ q: string;
31277
32387
  /**
31278
- * Maximum number of records to return; defaults to the newest 200 and is capped at 1000
32388
+ * Result limit; defaults and clamps to 50
31279
32389
  */
31280
32390
  limit?: number;
31281
- /**
31282
- * Only return events after this sequence number
31283
- */
31284
- after_sequence?: number;
31285
- /**
31286
- * Event type
31287
- */
31288
- type?: string;
31289
- /**
31290
- * Agent name
31291
- */
31292
- agent_name?: string;
31293
- /**
31294
- * Turn id
31295
- */
31296
- turn_id?: string;
31297
- /**
31298
- * Select active, archived, or all events
31299
- */
31300
- archive?: "active" | "archived" | "all";
31301
32391
  /**
31302
32392
  * Read one profile's rows by name
31303
32393
  */
@@ -31307,31 +32397,39 @@ export type ListSessionEventsData = {
31307
32397
  */
31308
32398
  all_profiles?: boolean;
31309
32399
  };
31310
- url: "/api/workspaces/{workspace_id}/sessions/{session_id}/events";
32400
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/files/find";
31311
32401
  };
31312
- export type ListSessionEventsErrors = {
32402
+ export type FindSessionFilesErrors = {
31313
32403
  /**
31314
- * Invalid filter
32404
+ * Search failed
31315
32405
  */
31316
32406
  400: ErrorPayload;
31317
32407
  /**
31318
- * Session not found
32408
+ * Search failed
32409
+ */
32410
+ 403: ErrorPayload;
32411
+ /**
32412
+ * Search failed
31319
32413
  */
31320
32414
  404: ErrorPayload;
31321
32415
  /**
31322
- * Internal server error
32416
+ * Search failed
32417
+ */
32418
+ 409: ErrorPayload;
32419
+ /**
32420
+ * Search failed
31323
32421
  */
31324
32422
  500: ErrorPayload;
31325
32423
  };
31326
- export type ListSessionEventsError = ListSessionEventsErrors[keyof ListSessionEventsErrors];
31327
- export type ListSessionEventsResponses = {
32424
+ export type FindSessionFilesError = FindSessionFilesErrors[keyof FindSessionFilesErrors];
32425
+ export type FindSessionFilesResponses = {
31328
32426
  /**
31329
32427
  * OK
31330
32428
  */
31331
- 200: SessionEventsResponse;
32429
+ 200: FileFindResponse;
31332
32430
  };
31333
- export type ListSessionEventsResponse = ListSessionEventsResponses[keyof ListSessionEventsResponses];
31334
- export type SearchSessionFilesData = {
32431
+ export type FindSessionFilesResponse = FindSessionFilesResponses[keyof FindSessionFilesResponses];
32432
+ export type SearchSessionFileContentsData = {
31335
32433
  body?: never;
31336
32434
  path: {
31337
32435
  /**
@@ -31343,15 +32441,31 @@ export type SearchSessionFilesData = {
31343
32441
  */
31344
32442
  session_id: string;
31345
32443
  };
31346
- query?: {
32444
+ query: {
31347
32445
  /**
31348
- * Search text; empty returns the shallowest entries
32446
+ * Search query
31349
32447
  */
31350
- q?: string;
32448
+ q: string;
31351
32449
  /**
31352
- * Maximum entries returned
32450
+ * Use POSIX ERE
31353
32451
  */
31354
- limit?: number;
32452
+ regex?: boolean;
32453
+ /**
32454
+ * Match case
32455
+ */
32456
+ case_sensitive?: boolean;
32457
+ /**
32458
+ * Match whole words
32459
+ */
32460
+ whole_word?: boolean;
32461
+ /**
32462
+ * Root-relative globs; repeat at most ten times
32463
+ */
32464
+ include?: Array<string>;
32465
+ /**
32466
+ * Root-relative globs; repeat at most ten times
32467
+ */
32468
+ exclude?: Array<string>;
31355
32469
  /**
31356
32470
  * Read one profile's rows by name
31357
32471
  */
@@ -31361,34 +32475,38 @@ export type SearchSessionFilesData = {
31361
32475
  */
31362
32476
  all_profiles?: boolean;
31363
32477
  };
31364
- url: "/api/workspaces/{workspace_id}/sessions/{session_id}/files";
32478
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/files/search";
31365
32479
  };
31366
- export type SearchSessionFilesErrors = {
32480
+ export type SearchSessionFileContentsErrors = {
31367
32481
  /**
31368
- * Invalid limit
32482
+ * Search failed
31369
32483
  */
31370
32484
  400: ErrorPayload;
31371
32485
  /**
31372
- * Session not found
32486
+ * Search failed
32487
+ */
32488
+ 403: ErrorPayload;
32489
+ /**
32490
+ * Search failed
31373
32491
  */
31374
32492
  404: ErrorPayload;
31375
32493
  /**
31376
- * Session working directory no longer exists
32494
+ * Search failed
31377
32495
  */
31378
32496
  409: ErrorPayload;
31379
32497
  /**
31380
- * Internal server error
32498
+ * Search failed
31381
32499
  */
31382
32500
  500: ErrorPayload;
31383
32501
  };
31384
- export type SearchSessionFilesError = SearchSessionFilesErrors[keyof SearchSessionFilesErrors];
31385
- export type SearchSessionFilesResponses = {
32502
+ export type SearchSessionFileContentsError = SearchSessionFileContentsErrors[keyof SearchSessionFileContentsErrors];
32503
+ export type SearchSessionFileContentsResponses = {
31386
32504
  /**
31387
32505
  * OK
31388
32506
  */
31389
- 200: SessionFilesResponse;
32507
+ 200: FileSearchResponse;
31390
32508
  };
31391
- export type SearchSessionFilesResponse = SearchSessionFilesResponses[keyof SearchSessionFilesResponses];
32509
+ export type SearchSessionFileContentsResponse = SearchSessionFileContentsResponses[keyof SearchSessionFileContentsResponses];
31392
32510
  export type ForkSessionData = {
31393
32511
  /**
31394
32512
  * JSON request body
@@ -35357,7 +36475,7 @@ export type ReadToolArtifactData = {
35357
36475
  body?: never;
35358
36476
  path: {
35359
36477
  /**
35360
- * Durable workspace id
36478
+ * Durable workspace id or @user
35361
36479
  */
35362
36480
  workspace_id: string;
35363
36481
  /**
@@ -35374,6 +36492,10 @@ export type ReadToolArtifactData = {
35374
36492
  * Page size in bytes; defaults to and is capped at 65536
35375
36493
  */
35376
36494
  limit?: number;
36495
+ /**
36496
+ * Act as this profile by name
36497
+ */
36498
+ profile?: string;
35377
36499
  };
35378
36500
  url: "/api/workspaces/{workspace_id}/tool-artifacts/{artifact_id}";
35379
36501
  };
@@ -35383,7 +36505,7 @@ export type ReadToolArtifactErrors = {
35383
36505
  */
35384
36506
  400: ToolErrorResponse;
35385
36507
  /**
35386
- * Artifact not found in the resolved workspace
36508
+ * Artifact not found in the resolved workspace or User scope and profile
35387
36509
  */
35388
36510
  404: ToolErrorResponse;
35389
36511
  /**