@get-bb/plugin-sdk 0.5.29 → 0.5.30

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.
@@ -96,6 +96,7 @@ type PluginRpcCallArgs<Method extends PluginRpcMethodContract> = null extends Pl
96
96
  type PluginRpcResult<Method extends PluginRpcMethodContract> = StandardSchemaV1InferOutput<Method["output"]>;
97
97
 
98
98
  declare const appSettingsSchema: z$1.ZodObject<{
99
+ allowFastServiceTier: z$1.ZodBoolean;
99
100
  defaultMachineAccess: z$1.ZodNullable<z$1.ZodString>;
100
101
  defaultProviderId: z$1.ZodNullable<z$1.ZodString>;
101
102
  machineGitCredentialsEnabled: z$1.ZodBoolean;
@@ -114,6 +115,7 @@ declare const appSettingsSchema: z$1.ZodObject<{
114
115
  }, z$1.core.$strict>;
115
116
  type AppSettings = z$1.infer<typeof appSettingsSchema>;
116
117
  declare const appSettingsUpdateSchema: z$1.ZodUnion<readonly [z$1.ZodObject<{
118
+ allowFastServiceTier: z$1.ZodOptional<z$1.ZodBoolean>;
117
119
  defaultMachineAccess: z$1.ZodNullable<z$1.ZodString>;
118
120
  defaultProviderId: z$1.ZodNullable<z$1.ZodString>;
119
121
  machineGitCredentialsEnabled: z$1.ZodBoolean;
@@ -131,6 +133,7 @@ declare const appSettingsUpdateSchema: z$1.ZodUnion<readonly [z$1.ZodObject<{
131
133
  streamerMode: z$1.ZodBoolean;
132
134
  telemetryEnabled: z$1.ZodOptional<z$1.ZodBoolean>;
133
135
  }, z$1.core.$strict>, z$1.ZodObject<{
136
+ allowFastServiceTier: z$1.ZodOptional<z$1.ZodBoolean>;
134
137
  defaultMachineAccess: z$1.ZodNullable<z$1.ZodString>;
135
138
  defaultProviderId: z$1.ZodNullable<z$1.ZodString>;
136
139
  machineGitCredentialsEnabled: z$1.ZodBoolean;
@@ -338,6 +341,7 @@ type AppThemeSelection = z$1.infer<typeof appThemeSelectionSchema>;
338
341
  declare const changedMessageSchema: z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
339
342
  changes: z$1.ZodReadonly<z$1.ZodArray<z$1.ZodEnum<{
340
343
  "archived-changed": "archived-changed";
344
+ "draft-changed": "draft-changed";
341
345
  "environment-changed": "environment-changed";
342
346
  "events-appended": "events-appended";
343
347
  "history-rewritten": "history-rewritten";
@@ -3039,11 +3043,45 @@ declare const threadEventSchema: z$1.ZodPipe<z$1.ZodUnknown, z$1.ZodUnion<readon
3039
3043
  }>>;
3040
3044
  systemMessageSubject: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
3041
3045
  kind: z$1.ZodLiteral<"thread">;
3046
+ outcomes: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
3047
+ interruption: z$1.ZodOptional<z$1.ZodObject<{
3048
+ cause: z$1.ZodOptional<z$1.ZodLiteral<"host-connection-lost">>;
3049
+ reason: z$1.ZodEnum<{
3050
+ "host-daemon-restarted": "host-daemon-restarted";
3051
+ "host-removed": "host-removed";
3052
+ "manual-stop": "manual-stop";
3053
+ "provider-turn-idle": "provider-turn-idle";
3054
+ }>;
3055
+ }, z$1.core.$strip>>;
3056
+ status: z$1.ZodEnum<{
3057
+ completed: "completed";
3058
+ failed: "failed";
3059
+ interrupted: "interrupted";
3060
+ }>;
3061
+ threadId: z$1.ZodString;
3062
+ }, z$1.core.$strip>>>;
3042
3063
  threadId: z$1.ZodString;
3043
3064
  threadName: z$1.ZodString;
3044
3065
  }, z$1.core.$strip>, z$1.ZodObject<{
3045
3066
  count: z$1.ZodNumber;
3046
3067
  kind: z$1.ZodLiteral<"thread-batch">;
3068
+ outcomes: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
3069
+ interruption: z$1.ZodOptional<z$1.ZodObject<{
3070
+ cause: z$1.ZodOptional<z$1.ZodLiteral<"host-connection-lost">>;
3071
+ reason: z$1.ZodEnum<{
3072
+ "host-daemon-restarted": "host-daemon-restarted";
3073
+ "host-removed": "host-removed";
3074
+ "manual-stop": "manual-stop";
3075
+ "provider-turn-idle": "provider-turn-idle";
3076
+ }>;
3077
+ }, z$1.core.$strip>>;
3078
+ status: z$1.ZodEnum<{
3079
+ completed: "completed";
3080
+ failed: "failed";
3081
+ interrupted: "interrupted";
3082
+ }>;
3083
+ threadId: z$1.ZodString;
3084
+ }, z$1.core.$strip>>>;
3047
3085
  }, z$1.core.$strip>, z$1.ZodObject<{
3048
3086
  kind: z$1.ZodLiteral<"tool-call">;
3049
3087
  suppress: z$1.ZodBoolean;
@@ -10141,6 +10179,7 @@ declare const systemConfigResponseSchema: z$1.ZodObject<{
10141
10179
  timelineWindowEventBudget: z$1.ZodNumber;
10142
10180
  }, z$1.core.$strip>;
10143
10181
  generalSettings: z$1.ZodObject<{
10182
+ allowFastServiceTier: z$1.ZodBoolean;
10144
10183
  defaultMachineAccess: z$1.ZodNullable<z$1.ZodString>;
10145
10184
  defaultProviderId: z$1.ZodNullable<z$1.ZodString>;
10146
10185
  machineGitCredentialsEnabled: z$1.ZodBoolean;
@@ -10872,11 +10911,45 @@ declare const timelineConversationRowSchema: z$1.ZodDiscriminatedUnion<[z$1.ZodO
10872
10911
  }>;
10873
10912
  systemMessageSubject: z$1.ZodNullable<z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
10874
10913
  kind: z$1.ZodLiteral<"thread">;
10914
+ outcomes: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
10915
+ interruption: z$1.ZodOptional<z$1.ZodObject<{
10916
+ cause: z$1.ZodOptional<z$1.ZodLiteral<"host-connection-lost">>;
10917
+ reason: z$1.ZodEnum<{
10918
+ "host-daemon-restarted": "host-daemon-restarted";
10919
+ "host-removed": "host-removed";
10920
+ "manual-stop": "manual-stop";
10921
+ "provider-turn-idle": "provider-turn-idle";
10922
+ }>;
10923
+ }, z$1.core.$strip>>;
10924
+ status: z$1.ZodEnum<{
10925
+ completed: "completed";
10926
+ failed: "failed";
10927
+ interrupted: "interrupted";
10928
+ }>;
10929
+ threadId: z$1.ZodString;
10930
+ }, z$1.core.$strip>>>;
10875
10931
  threadId: z$1.ZodString;
10876
10932
  threadName: z$1.ZodString;
10877
10933
  }, z$1.core.$strip>, z$1.ZodObject<{
10878
10934
  count: z$1.ZodNumber;
10879
10935
  kind: z$1.ZodLiteral<"thread-batch">;
10936
+ outcomes: z$1.ZodOptional<z$1.ZodArray<z$1.ZodObject<{
10937
+ interruption: z$1.ZodOptional<z$1.ZodObject<{
10938
+ cause: z$1.ZodOptional<z$1.ZodLiteral<"host-connection-lost">>;
10939
+ reason: z$1.ZodEnum<{
10940
+ "host-daemon-restarted": "host-daemon-restarted";
10941
+ "host-removed": "host-removed";
10942
+ "manual-stop": "manual-stop";
10943
+ "provider-turn-idle": "provider-turn-idle";
10944
+ }>;
10945
+ }, z$1.core.$strip>>;
10946
+ status: z$1.ZodEnum<{
10947
+ completed: "completed";
10948
+ failed: "failed";
10949
+ interrupted: "interrupted";
10950
+ }>;
10951
+ threadId: z$1.ZodString;
10952
+ }, z$1.core.$strip>>>;
10880
10953
  }, z$1.core.$strip>, z$1.ZodObject<{
10881
10954
  kind: z$1.ZodLiteral<"tool-call">;
10882
10955
  suppress: z$1.ZodBoolean;
@@ -11909,6 +11982,7 @@ declare const createExecutionInputSourcesSchema: z$1.ZodObject<{
11909
11982
  }, z$1.core.$strict>;
11910
11983
  type CreateExecutionInputSources = z$1.infer<typeof createExecutionInputSourcesSchema>;
11911
11984
  declare const createThreadRequestSchema: z$1.ZodObject<{
11985
+ draft: z$1.ZodOptional<z$1.ZodBoolean>;
11912
11986
  environment: z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
11913
11987
  environmentId: z$1.ZodString;
11914
11988
  type: z$1.ZodLiteral<"reuse">;
@@ -12943,6 +13017,91 @@ declare const createQueuedMessageRequestSchema: z$1.ZodObject<{
12943
13017
  }>>;
12944
13018
  }, z$1.core.$strip>;
12945
13019
  type CreateQueuedMessageRequest = z$1.infer<typeof createQueuedMessageRequestSchema>;
13020
+ declare const updateThreadDraftRequestSchema: z$1.ZodObject<{
13021
+ input: z$1.ZodArray<z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
13022
+ mentions: z$1.ZodDefault<z$1.ZodArray<z$1.ZodObject<{
13023
+ end: z$1.ZodNumber;
13024
+ resource: z$1.ZodPipe<z$1.ZodTransform<unknown, unknown>, z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
13025
+ kind: z$1.ZodLiteral<"thread">;
13026
+ label: z$1.ZodString;
13027
+ projectId: z$1.ZodOptional<z$1.ZodString>;
13028
+ threadId: z$1.ZodString;
13029
+ }, z$1.core.$strip>, z$1.ZodObject<{
13030
+ kind: z$1.ZodLiteral<"project">;
13031
+ label: z$1.ZodString;
13032
+ projectId: z$1.ZodString;
13033
+ }, z$1.core.$strip>, z$1.ZodObject<{
13034
+ kind: z$1.ZodLiteral<"section">;
13035
+ label: z$1.ZodString;
13036
+ sectionId: z$1.ZodString;
13037
+ }, z$1.core.$strip>, z$1.ZodObject<{
13038
+ entryKind: z$1.ZodEnum<{
13039
+ directory: "directory";
13040
+ file: "file";
13041
+ }>;
13042
+ kind: z$1.ZodLiteral<"path">;
13043
+ label: z$1.ZodString;
13044
+ path: z$1.ZodString;
13045
+ source: z$1.ZodEnum<{
13046
+ "thread-storage": "thread-storage";
13047
+ workspace: "workspace";
13048
+ }>;
13049
+ }, z$1.core.$strip>, z$1.ZodObject<{
13050
+ argumentHint: z$1.ZodNullable<z$1.ZodString>;
13051
+ kind: z$1.ZodLiteral<"command">;
13052
+ label: z$1.ZodString;
13053
+ name: z$1.ZodString;
13054
+ origin: z$1.ZodEnum<{
13055
+ builtin: "builtin";
13056
+ project: "project";
13057
+ user: "user";
13058
+ }>;
13059
+ source: z$1.ZodEnum<{
13060
+ command: "command";
13061
+ skill: "skill";
13062
+ }>;
13063
+ trigger: z$1.ZodEnum<{
13064
+ "/": "/";
13065
+ $: "$";
13066
+ }>;
13067
+ }, z$1.core.$strip>, z$1.ZodObject<{
13068
+ icon: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodString>>;
13069
+ itemId: z$1.ZodString;
13070
+ kind: z$1.ZodLiteral<"plugin">;
13071
+ label: z$1.ZodString;
13072
+ pluginId: z$1.ZodString;
13073
+ }, z$1.core.$strip>], "kind">>;
13074
+ start: z$1.ZodNumber;
13075
+ }, z$1.core.$strip>>>;
13076
+ text: z$1.ZodString;
13077
+ type: z$1.ZodLiteral<"text">;
13078
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13079
+ "agent-only": "agent-only";
13080
+ }>>;
13081
+ }, z$1.core.$strip>, z$1.ZodObject<{
13082
+ type: z$1.ZodLiteral<"image">;
13083
+ url: z$1.ZodString;
13084
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13085
+ "agent-only": "agent-only";
13086
+ }>>;
13087
+ }, z$1.core.$strip>, z$1.ZodObject<{
13088
+ path: z$1.ZodString;
13089
+ type: z$1.ZodLiteral<"localImage">;
13090
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13091
+ "agent-only": "agent-only";
13092
+ }>>;
13093
+ }, z$1.core.$strip>, z$1.ZodObject<{
13094
+ mimeType: z$1.ZodOptional<z$1.ZodString>;
13095
+ name: z$1.ZodOptional<z$1.ZodString>;
13096
+ path: z$1.ZodString;
13097
+ sizeBytes: z$1.ZodOptional<z$1.ZodNumber>;
13098
+ type: z$1.ZodLiteral<"localFile">;
13099
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13100
+ "agent-only": "agent-only";
13101
+ }>>;
13102
+ }, z$1.core.$strip>], "type">>;
13103
+ }, z$1.core.$strict>;
13104
+ type UpdateThreadDraftRequest = z$1.infer<typeof updateThreadDraftRequestSchema>;
12946
13105
  declare const updateQueuedMessageRequestSchema: z$1.ZodObject<{
12947
13106
  expectedUpdatedAt: z$1.ZodNumber;
12948
13107
  input: z$1.ZodArray<z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
@@ -13491,6 +13650,88 @@ declare const threadResponseSchema: z$1.ZodObject<{
13491
13650
  canSpawnChild: z$1.ZodBoolean;
13492
13651
  createdAt: z$1.ZodNumber;
13493
13652
  deletedAt: z$1.ZodNullable<z$1.ZodNumber>;
13653
+ draft: z$1.ZodNullable<z$1.ZodArray<z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
13654
+ mentions: z$1.ZodDefault<z$1.ZodArray<z$1.ZodObject<{
13655
+ end: z$1.ZodNumber;
13656
+ resource: z$1.ZodPipe<z$1.ZodTransform<unknown, unknown>, z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
13657
+ kind: z$1.ZodLiteral<"thread">;
13658
+ label: z$1.ZodString;
13659
+ projectId: z$1.ZodOptional<z$1.ZodString>;
13660
+ threadId: z$1.ZodString;
13661
+ }, z$1.core.$strip>, z$1.ZodObject<{
13662
+ kind: z$1.ZodLiteral<"project">;
13663
+ label: z$1.ZodString;
13664
+ projectId: z$1.ZodString;
13665
+ }, z$1.core.$strip>, z$1.ZodObject<{
13666
+ kind: z$1.ZodLiteral<"section">;
13667
+ label: z$1.ZodString;
13668
+ sectionId: z$1.ZodString;
13669
+ }, z$1.core.$strip>, z$1.ZodObject<{
13670
+ entryKind: z$1.ZodEnum<{
13671
+ directory: "directory";
13672
+ file: "file";
13673
+ }>;
13674
+ kind: z$1.ZodLiteral<"path">;
13675
+ label: z$1.ZodString;
13676
+ path: z$1.ZodString;
13677
+ source: z$1.ZodEnum<{
13678
+ "thread-storage": "thread-storage";
13679
+ workspace: "workspace";
13680
+ }>;
13681
+ }, z$1.core.$strip>, z$1.ZodObject<{
13682
+ argumentHint: z$1.ZodNullable<z$1.ZodString>;
13683
+ kind: z$1.ZodLiteral<"command">;
13684
+ label: z$1.ZodString;
13685
+ name: z$1.ZodString;
13686
+ origin: z$1.ZodEnum<{
13687
+ builtin: "builtin";
13688
+ project: "project";
13689
+ user: "user";
13690
+ }>;
13691
+ source: z$1.ZodEnum<{
13692
+ command: "command";
13693
+ skill: "skill";
13694
+ }>;
13695
+ trigger: z$1.ZodEnum<{
13696
+ "/": "/";
13697
+ $: "$";
13698
+ }>;
13699
+ }, z$1.core.$strip>, z$1.ZodObject<{
13700
+ icon: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodString>>;
13701
+ itemId: z$1.ZodString;
13702
+ kind: z$1.ZodLiteral<"plugin">;
13703
+ label: z$1.ZodString;
13704
+ pluginId: z$1.ZodString;
13705
+ }, z$1.core.$strip>], "kind">>;
13706
+ start: z$1.ZodNumber;
13707
+ }, z$1.core.$strip>>>;
13708
+ text: z$1.ZodString;
13709
+ type: z$1.ZodLiteral<"text">;
13710
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13711
+ "agent-only": "agent-only";
13712
+ }>>;
13713
+ }, z$1.core.$strip>, z$1.ZodObject<{
13714
+ type: z$1.ZodLiteral<"image">;
13715
+ url: z$1.ZodString;
13716
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13717
+ "agent-only": "agent-only";
13718
+ }>>;
13719
+ }, z$1.core.$strip>, z$1.ZodObject<{
13720
+ path: z$1.ZodString;
13721
+ type: z$1.ZodLiteral<"localImage">;
13722
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13723
+ "agent-only": "agent-only";
13724
+ }>>;
13725
+ }, z$1.core.$strip>, z$1.ZodObject<{
13726
+ mimeType: z$1.ZodOptional<z$1.ZodString>;
13727
+ name: z$1.ZodOptional<z$1.ZodString>;
13728
+ path: z$1.ZodString;
13729
+ sizeBytes: z$1.ZodOptional<z$1.ZodNumber>;
13730
+ type: z$1.ZodLiteral<"localFile">;
13731
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13732
+ "agent-only": "agent-only";
13733
+ }>>;
13734
+ }, z$1.core.$strip>], "type">>>;
13494
13735
  environmentId: z$1.ZodNullable<z$1.ZodString>;
13495
13736
  id: z$1.ZodString;
13496
13737
  lastReadAt: z$1.ZodNullable<z$1.ZodNumber>;
@@ -13550,6 +13791,88 @@ declare const threadWithIncludesResponseSchema: z$1.ZodObject<{
13550
13791
  canSpawnChild: z$1.ZodBoolean;
13551
13792
  createdAt: z$1.ZodNumber;
13552
13793
  deletedAt: z$1.ZodNullable<z$1.ZodNumber>;
13794
+ draft: z$1.ZodNullable<z$1.ZodArray<z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
13795
+ mentions: z$1.ZodDefault<z$1.ZodArray<z$1.ZodObject<{
13796
+ end: z$1.ZodNumber;
13797
+ resource: z$1.ZodPipe<z$1.ZodTransform<unknown, unknown>, z$1.ZodDiscriminatedUnion<[z$1.ZodObject<{
13798
+ kind: z$1.ZodLiteral<"thread">;
13799
+ label: z$1.ZodString;
13800
+ projectId: z$1.ZodOptional<z$1.ZodString>;
13801
+ threadId: z$1.ZodString;
13802
+ }, z$1.core.$strip>, z$1.ZodObject<{
13803
+ kind: z$1.ZodLiteral<"project">;
13804
+ label: z$1.ZodString;
13805
+ projectId: z$1.ZodString;
13806
+ }, z$1.core.$strip>, z$1.ZodObject<{
13807
+ kind: z$1.ZodLiteral<"section">;
13808
+ label: z$1.ZodString;
13809
+ sectionId: z$1.ZodString;
13810
+ }, z$1.core.$strip>, z$1.ZodObject<{
13811
+ entryKind: z$1.ZodEnum<{
13812
+ directory: "directory";
13813
+ file: "file";
13814
+ }>;
13815
+ kind: z$1.ZodLiteral<"path">;
13816
+ label: z$1.ZodString;
13817
+ path: z$1.ZodString;
13818
+ source: z$1.ZodEnum<{
13819
+ "thread-storage": "thread-storage";
13820
+ workspace: "workspace";
13821
+ }>;
13822
+ }, z$1.core.$strip>, z$1.ZodObject<{
13823
+ argumentHint: z$1.ZodNullable<z$1.ZodString>;
13824
+ kind: z$1.ZodLiteral<"command">;
13825
+ label: z$1.ZodString;
13826
+ name: z$1.ZodString;
13827
+ origin: z$1.ZodEnum<{
13828
+ builtin: "builtin";
13829
+ project: "project";
13830
+ user: "user";
13831
+ }>;
13832
+ source: z$1.ZodEnum<{
13833
+ command: "command";
13834
+ skill: "skill";
13835
+ }>;
13836
+ trigger: z$1.ZodEnum<{
13837
+ "/": "/";
13838
+ $: "$";
13839
+ }>;
13840
+ }, z$1.core.$strip>, z$1.ZodObject<{
13841
+ icon: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodString>>;
13842
+ itemId: z$1.ZodString;
13843
+ kind: z$1.ZodLiteral<"plugin">;
13844
+ label: z$1.ZodString;
13845
+ pluginId: z$1.ZodString;
13846
+ }, z$1.core.$strip>], "kind">>;
13847
+ start: z$1.ZodNumber;
13848
+ }, z$1.core.$strip>>>;
13849
+ text: z$1.ZodString;
13850
+ type: z$1.ZodLiteral<"text">;
13851
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13852
+ "agent-only": "agent-only";
13853
+ }>>;
13854
+ }, z$1.core.$strip>, z$1.ZodObject<{
13855
+ type: z$1.ZodLiteral<"image">;
13856
+ url: z$1.ZodString;
13857
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13858
+ "agent-only": "agent-only";
13859
+ }>>;
13860
+ }, z$1.core.$strip>, z$1.ZodObject<{
13861
+ path: z$1.ZodString;
13862
+ type: z$1.ZodLiteral<"localImage">;
13863
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13864
+ "agent-only": "agent-only";
13865
+ }>>;
13866
+ }, z$1.core.$strip>, z$1.ZodObject<{
13867
+ mimeType: z$1.ZodOptional<z$1.ZodString>;
13868
+ name: z$1.ZodOptional<z$1.ZodString>;
13869
+ path: z$1.ZodString;
13870
+ sizeBytes: z$1.ZodOptional<z$1.ZodNumber>;
13871
+ type: z$1.ZodLiteral<"localFile">;
13872
+ visibility: z$1.ZodOptional<z$1.ZodEnum<{
13873
+ "agent-only": "agent-only";
13874
+ }>>;
13875
+ }, z$1.core.$strip>], "type">>>;
13553
13876
  environment: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodObject<{
13554
13877
  baseBranch: z$1.ZodNullable<z$1.ZodString>;
13555
13878
  branchName: z$1.ZodNullable<z$1.ZodString>;
@@ -14149,6 +14472,7 @@ declare const threadQueuedMessageListResponseSchema: z$1.ZodArray<z$1.ZodObject<
14149
14472
  type ThreadQueuedMessageListResponse = z$1.infer<typeof threadQueuedMessageListResponseSchema>;
14150
14473
  declare const threadChildSummaryResponseSchema: z$1.ZodObject<{
14151
14474
  nonDeletedChildCount: z$1.ZodNumber;
14475
+ unarchivedDescendantCount: z$1.ZodNumber;
14152
14476
  }, z$1.core.$strip>;
14153
14477
  type ThreadChildSummaryResponse = z$1.infer<typeof threadChildSummaryResponseSchema>;
14154
14478
  declare const deleteThreadRequestSchema: z$1.ZodObject<{
@@ -16480,6 +16804,9 @@ interface ThreadForkArgs extends Omit<ForkThreadRequest, "origin" | "visibility"
16480
16804
  interface ThreadUpdateArgs extends UpdateThreadRequest {
16481
16805
  threadId: string;
16482
16806
  }
16807
+ interface ThreadUpdateDraftArgs extends UpdateThreadDraftRequest {
16808
+ threadId: string;
16809
+ }
16483
16810
  interface ThreadPluginMetadataArgs {
16484
16811
  pluginId: string;
16485
16812
  signal?: AbortSignal;
@@ -16763,6 +17090,12 @@ interface ThreadsArea {
16763
17090
  unarchive(args: ThreadActionArgs): Promise<ThreadUnarchiveResult>;
16764
17091
  unpin(args: ThreadActionArgs): Promise<ThreadMutationResult>;
16765
17092
  update(args: ThreadUpdateArgs): Promise<ThreadMutationResult>;
17093
+ /**
17094
+ * Replace the thread's saved, unsent draft message. An empty `input` clears
17095
+ * it. On a `pending` thread the draft also becomes the thread's fallback
17096
+ * title. Sending a message does not clear the draft; clear it explicitly.
17097
+ */
17098
+ updateDraft(args: ThreadUpdateDraftArgs): Promise<ThreadMutationResult>;
16766
17099
  wait(args: ThreadWaitArgs): Promise<ThreadWaitResult>;
16767
17100
  }
16768
17101
 
@@ -146,6 +146,88 @@ declare const threadResponseSchema: z.ZodObject<{
146
146
  canSpawnChild: z.ZodBoolean;
147
147
  createdAt: z.ZodNumber;
148
148
  deletedAt: z.ZodNullable<z.ZodNumber>;
149
+ draft: z.ZodNullable<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
150
+ mentions: z.ZodDefault<z.ZodArray<z.ZodObject<{
151
+ end: z.ZodNumber;
152
+ resource: z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodDiscriminatedUnion<[z.ZodObject<{
153
+ kind: z.ZodLiteral<"thread">;
154
+ label: z.ZodString;
155
+ projectId: z.ZodOptional<z.ZodString>;
156
+ threadId: z.ZodString;
157
+ }, z.core.$strip>, z.ZodObject<{
158
+ kind: z.ZodLiteral<"project">;
159
+ label: z.ZodString;
160
+ projectId: z.ZodString;
161
+ }, z.core.$strip>, z.ZodObject<{
162
+ kind: z.ZodLiteral<"section">;
163
+ label: z.ZodString;
164
+ sectionId: z.ZodString;
165
+ }, z.core.$strip>, z.ZodObject<{
166
+ entryKind: z.ZodEnum<{
167
+ directory: "directory";
168
+ file: "file";
169
+ }>;
170
+ kind: z.ZodLiteral<"path">;
171
+ label: z.ZodString;
172
+ path: z.ZodString;
173
+ source: z.ZodEnum<{
174
+ "thread-storage": "thread-storage";
175
+ workspace: "workspace";
176
+ }>;
177
+ }, z.core.$strip>, z.ZodObject<{
178
+ argumentHint: z.ZodNullable<z.ZodString>;
179
+ kind: z.ZodLiteral<"command">;
180
+ label: z.ZodString;
181
+ name: z.ZodString;
182
+ origin: z.ZodEnum<{
183
+ builtin: "builtin";
184
+ project: "project";
185
+ user: "user";
186
+ }>;
187
+ source: z.ZodEnum<{
188
+ command: "command";
189
+ skill: "skill";
190
+ }>;
191
+ trigger: z.ZodEnum<{
192
+ "/": "/";
193
+ $: "$";
194
+ }>;
195
+ }, z.core.$strip>, z.ZodObject<{
196
+ icon: z.ZodOptional<z.ZodNullable<z.ZodString>>;
197
+ itemId: z.ZodString;
198
+ kind: z.ZodLiteral<"plugin">;
199
+ label: z.ZodString;
200
+ pluginId: z.ZodString;
201
+ }, z.core.$strip>], "kind">>;
202
+ start: z.ZodNumber;
203
+ }, z.core.$strip>>>;
204
+ text: z.ZodString;
205
+ type: z.ZodLiteral<"text">;
206
+ visibility: z.ZodOptional<z.ZodEnum<{
207
+ "agent-only": "agent-only";
208
+ }>>;
209
+ }, z.core.$strip>, z.ZodObject<{
210
+ type: z.ZodLiteral<"image">;
211
+ url: z.ZodString;
212
+ visibility: z.ZodOptional<z.ZodEnum<{
213
+ "agent-only": "agent-only";
214
+ }>>;
215
+ }, z.core.$strip>, z.ZodObject<{
216
+ path: z.ZodString;
217
+ type: z.ZodLiteral<"localImage">;
218
+ visibility: z.ZodOptional<z.ZodEnum<{
219
+ "agent-only": "agent-only";
220
+ }>>;
221
+ }, z.core.$strip>, z.ZodObject<{
222
+ mimeType: z.ZodOptional<z.ZodString>;
223
+ name: z.ZodOptional<z.ZodString>;
224
+ path: z.ZodString;
225
+ sizeBytes: z.ZodOptional<z.ZodNumber>;
226
+ type: z.ZodLiteral<"localFile">;
227
+ visibility: z.ZodOptional<z.ZodEnum<{
228
+ "agent-only": "agent-only";
229
+ }>>;
230
+ }, z.core.$strip>], "type">>>;
149
231
  environmentId: z.ZodNullable<z.ZodString>;
150
232
  id: z.ZodString;
151
233
  lastReadAt: z.ZodNullable<z.ZodNumber>;
@@ -484,6 +484,88 @@ declare const threadResponseSchema: z.ZodObject<{
484
484
  canSpawnChild: z.ZodBoolean;
485
485
  createdAt: z.ZodNumber;
486
486
  deletedAt: z.ZodNullable<z.ZodNumber>;
487
+ draft: z.ZodNullable<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
488
+ mentions: z.ZodDefault<z.ZodArray<z.ZodObject<{
489
+ end: z.ZodNumber;
490
+ resource: z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodDiscriminatedUnion<[z.ZodObject<{
491
+ kind: z.ZodLiteral<"thread">;
492
+ label: z.ZodString;
493
+ projectId: z.ZodOptional<z.ZodString>;
494
+ threadId: z.ZodString;
495
+ }, z.core.$strip>, z.ZodObject<{
496
+ kind: z.ZodLiteral<"project">;
497
+ label: z.ZodString;
498
+ projectId: z.ZodString;
499
+ }, z.core.$strip>, z.ZodObject<{
500
+ kind: z.ZodLiteral<"section">;
501
+ label: z.ZodString;
502
+ sectionId: z.ZodString;
503
+ }, z.core.$strip>, z.ZodObject<{
504
+ entryKind: z.ZodEnum<{
505
+ directory: "directory";
506
+ file: "file";
507
+ }>;
508
+ kind: z.ZodLiteral<"path">;
509
+ label: z.ZodString;
510
+ path: z.ZodString;
511
+ source: z.ZodEnum<{
512
+ "thread-storage": "thread-storage";
513
+ workspace: "workspace";
514
+ }>;
515
+ }, z.core.$strip>, z.ZodObject<{
516
+ argumentHint: z.ZodNullable<z.ZodString>;
517
+ kind: z.ZodLiteral<"command">;
518
+ label: z.ZodString;
519
+ name: z.ZodString;
520
+ origin: z.ZodEnum<{
521
+ builtin: "builtin";
522
+ project: "project";
523
+ user: "user";
524
+ }>;
525
+ source: z.ZodEnum<{
526
+ command: "command";
527
+ skill: "skill";
528
+ }>;
529
+ trigger: z.ZodEnum<{
530
+ "/": "/";
531
+ $: "$";
532
+ }>;
533
+ }, z.core.$strip>, z.ZodObject<{
534
+ icon: z.ZodOptional<z.ZodNullable<z.ZodString>>;
535
+ itemId: z.ZodString;
536
+ kind: z.ZodLiteral<"plugin">;
537
+ label: z.ZodString;
538
+ pluginId: z.ZodString;
539
+ }, z.core.$strip>], "kind">>;
540
+ start: z.ZodNumber;
541
+ }, z.core.$strip>>>;
542
+ text: z.ZodString;
543
+ type: z.ZodLiteral<"text">;
544
+ visibility: z.ZodOptional<z.ZodEnum<{
545
+ "agent-only": "agent-only";
546
+ }>>;
547
+ }, z.core.$strip>, z.ZodObject<{
548
+ type: z.ZodLiteral<"image">;
549
+ url: z.ZodString;
550
+ visibility: z.ZodOptional<z.ZodEnum<{
551
+ "agent-only": "agent-only";
552
+ }>>;
553
+ }, z.core.$strip>, z.ZodObject<{
554
+ path: z.ZodString;
555
+ type: z.ZodLiteral<"localImage">;
556
+ visibility: z.ZodOptional<z.ZodEnum<{
557
+ "agent-only": "agent-only";
558
+ }>>;
559
+ }, z.core.$strip>, z.ZodObject<{
560
+ mimeType: z.ZodOptional<z.ZodString>;
561
+ name: z.ZodOptional<z.ZodString>;
562
+ path: z.ZodString;
563
+ sizeBytes: z.ZodOptional<z.ZodNumber>;
564
+ type: z.ZodLiteral<"localFile">;
565
+ visibility: z.ZodOptional<z.ZodEnum<{
566
+ "agent-only": "agent-only";
567
+ }>>;
568
+ }, z.core.$strip>], "type">>>;
487
569
  environmentId: z.ZodNullable<z.ZodString>;
488
570
  id: z.ZodString;
489
571
  lastReadAt: z.ZodNullable<z.ZodNumber>;
@@ -3594,11 +3594,45 @@ declare const threadEventSchema: z.ZodPipe<z.ZodUnknown, z.ZodUnion<readonly [z.
3594
3594
  }>>;
3595
3595
  systemMessageSubject: z.ZodOptional<z.ZodNullable<z.ZodDiscriminatedUnion<[z.ZodObject<{
3596
3596
  kind: z.ZodLiteral<"thread">;
3597
+ outcomes: z.ZodOptional<z.ZodArray<z.ZodObject<{
3598
+ interruption: z.ZodOptional<z.ZodObject<{
3599
+ cause: z.ZodOptional<z.ZodLiteral<"host-connection-lost">>;
3600
+ reason: z.ZodEnum<{
3601
+ "host-daemon-restarted": "host-daemon-restarted";
3602
+ "host-removed": "host-removed";
3603
+ "manual-stop": "manual-stop";
3604
+ "provider-turn-idle": "provider-turn-idle";
3605
+ }>;
3606
+ }, z.core.$strip>>;
3607
+ status: z.ZodEnum<{
3608
+ completed: "completed";
3609
+ failed: "failed";
3610
+ interrupted: "interrupted";
3611
+ }>;
3612
+ threadId: z.ZodString;
3613
+ }, z.core.$strip>>>;
3597
3614
  threadId: z.ZodString;
3598
3615
  threadName: z.ZodString;
3599
3616
  }, z.core.$strip>, z.ZodObject<{
3600
3617
  count: z.ZodNumber;
3601
3618
  kind: z.ZodLiteral<"thread-batch">;
3619
+ outcomes: z.ZodOptional<z.ZodArray<z.ZodObject<{
3620
+ interruption: z.ZodOptional<z.ZodObject<{
3621
+ cause: z.ZodOptional<z.ZodLiteral<"host-connection-lost">>;
3622
+ reason: z.ZodEnum<{
3623
+ "host-daemon-restarted": "host-daemon-restarted";
3624
+ "host-removed": "host-removed";
3625
+ "manual-stop": "manual-stop";
3626
+ "provider-turn-idle": "provider-turn-idle";
3627
+ }>;
3628
+ }, z.core.$strip>>;
3629
+ status: z.ZodEnum<{
3630
+ completed: "completed";
3631
+ failed: "failed";
3632
+ interrupted: "interrupted";
3633
+ }>;
3634
+ threadId: z.ZodString;
3635
+ }, z.core.$strip>>>;
3602
3636
  }, z.core.$strip>, z.ZodObject<{
3603
3637
  kind: z.ZodLiteral<"tool-call">;
3604
3638
  suppress: z.ZodBoolean;