@base44-preview/sdk 0.8.48-pr.286.7d59d14 → 0.8.48-pr.286.d14ea24

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.
@@ -4,4 +4,4 @@ export { PlatformSocketError } from "./errors.js";
4
4
  export type { PlatformSocketErrorCode } from "./errors.types.js";
5
5
  export type { PlatformClientOptions } from "./client.types.js";
6
6
  export type { BuilderModule, BuilderInitOptions, BuilderSession, PlatformSubscription, SubscriptionOptions } from "./modules/builder.types.js";
7
- export type { AppUpdate, ChatMessage, ToolCall, QueueItem, QueueUpdate, TaskUpdate, ImageReady, Directive, PlatformEventMap, PlatformEvent, Joined } from "./modules/builder.events.types.js";
7
+ export type { AppUpdate, ChatMessage, ToolCall, ToolDisplayProjection, ToolQuestionOption, ToolQuestion, ToolQuestionArguments, ToolSecretField, ToolSecretArguments, ToolPackageOperation, ToolPackageArguments, ToolPlanUpdate, ToolPlanArguments, ToolMediaArguments, ToolQuestionAnswer, ToolQuestionInput, ToolOutcome, QueueItem, QueueUpdate, TaskUpdate, ImageReady, Directive, PlatformEventMap, PlatformEvent, Joined } from "./modules/builder.events.types.js";
@@ -1,4 +1,109 @@
1
- /** Public progress of an existing builder tool; arguments and results are withheld. */
1
+ /** A reviewed file, execution, or entity activity summary. */
2
+ export interface ToolDisplayProjection {
3
+ /** Changed file paths for a file operation. Source bodies and diffs are never included. */
4
+ file_paths?: string[];
5
+ /** Whether a file write intentionally used empty content. */
6
+ content_empty?: boolean;
7
+ /** Reviewed execution activity summary. Commands and execution output are never included. */
8
+ summary?: string;
9
+ /** Whether a reviewed execution action changed entity data. */
10
+ writes_entities?: boolean;
11
+ /** Entity type affected by an entity operation. Records and query values are never included. */
12
+ entity_name?: string;
13
+ /** Number of records affected when supplied by the producer. */
14
+ record_count?: number;
15
+ }
16
+ /** A reviewed selectable answer to a builder question. */
17
+ export interface ToolQuestionOption {
18
+ /** Visible option label. */
19
+ label: string;
20
+ }
21
+ /** A reviewed builder question. Image/HTML source and private design context are excluded. */
22
+ export interface ToolQuestion {
23
+ /** Visible question text. */
24
+ question?: string;
25
+ /** Existing question category. */
26
+ type?: string;
27
+ /** Optional visible supporting text. */
28
+ description?: string;
29
+ /** Whether more than one answer may be selected. */
30
+ multi_select?: boolean;
31
+ /** Optional existing plan section identifier. */
32
+ covers?: string;
33
+ /** Reviewed selectable options. */
34
+ options?: ToolQuestionOption[];
35
+ }
36
+ /** Reviewed question arguments, serialized in `ToolCall.arguments_string`. */
37
+ export interface ToolQuestionArguments {
38
+ /** Questions presented by a clarifying-question tool. */
39
+ questions: ToolQuestion[];
40
+ }
41
+ /** A requested secret field. The secret value is never sent over the socket. */
42
+ export interface ToolSecretField {
43
+ /** Requested secret name. */
44
+ secretName: string;
45
+ /** Optional explanation of where to obtain it. */
46
+ description?: string;
47
+ }
48
+ /** Reviewed secret-form arguments, serialized in `ToolCall.arguments_string`. */
49
+ export interface ToolSecretArguments {
50
+ /** Requested secret fields. */
51
+ secrets_schema: ToolSecretField[];
52
+ }
53
+ /** A reviewed package operation. Versions and package-manager output are excluded. */
54
+ export interface ToolPackageOperation {
55
+ /** Package name. */
56
+ name: string;
57
+ /** Requested package operation. */
58
+ action?: string;
59
+ }
60
+ /** Reviewed package arguments, serialized in `ToolCall.arguments_string`. */
61
+ export interface ToolPackageArguments {
62
+ /** Requested package operations. */
63
+ packages: ToolPackageOperation[];
64
+ }
65
+ /** A reviewed add-only builder plan update. */
66
+ export interface ToolPlanUpdate {
67
+ /** Existing update action. */
68
+ action?: string;
69
+ /** Plan section key. */
70
+ section?: string;
71
+ /** Optional user-facing section label. */
72
+ section_label?: string;
73
+ /** Reviewed plan point. */
74
+ text?: string;
75
+ }
76
+ /** Reviewed plan arguments, serialized in `ToolCall.arguments_string`. */
77
+ export interface ToolPlanArguments {
78
+ /** Plan updates in their emitted order. */
79
+ updates?: ToolPlanUpdate[];
80
+ /** Base plan sections the builder considers sufficiently specified. */
81
+ sections_with_enough?: string[];
82
+ }
83
+ /** Reviewed generated-media arguments, serialized in `ToolCall.arguments_string`. */
84
+ export interface ToolMediaArguments {
85
+ /** Visible media label. */
86
+ label?: string;
87
+ /** Requested image or video aspect ratio. */
88
+ aspect_ratio?: string;
89
+ }
90
+ /** A reviewed answer to a clarifying question. Secret-form input is never included. */
91
+ export interface ToolQuestionAnswer {
92
+ /** Zero-based question index. */
93
+ question_index?: number;
94
+ /** Labels selected by the user. */
95
+ selected_labels?: string[];
96
+ /** User-provided free-text answer. Structural filtering does not redact prose. */
97
+ custom_text?: string;
98
+ }
99
+ /** Reviewed clarifying-question input. */
100
+ export interface ToolQuestionInput {
101
+ /** Answers supplied to the question card. */
102
+ answers: ToolQuestionAnswer[];
103
+ }
104
+ /** Fixed reviewed completion text. Raw tool results and errors are never included. */
105
+ export type ToolOutcome = "Secret configuration completed." | "Package installation completed." | "Plan updated.";
106
+ /** Public progress of an existing builder tool. */
2
107
  export interface ToolCall {
3
108
  /** Stable tool call identifier, when included in the update. */
4
109
  id?: string;
@@ -8,11 +113,27 @@ export interface ToolCall {
8
113
  status?: "running" | "success" | "error" | "stopped" | "waiting_for_user_input";
9
114
  /** Whether the tool needs a user response through the partner backend. */
10
115
  requires_user_input?: boolean;
116
+ /** Whether the builder auto-approved the reviewed operation. */
117
+ auto_approved?: boolean | null;
118
+ /** Whether the reviewed mutation was applied. */
119
+ mutation_applied?: boolean | null;
11
120
  /** Existing serialized interaction category; no raw interaction payload. */
12
121
  waiting_on?: {
13
122
  /** Kind of response expected. */
14
123
  kind?: "approval" | "choice" | "input" | null;
15
- };
124
+ } | null;
125
+ /**
126
+ * JSON containing one reviewed argument shape: ToolQuestionArguments,
127
+ * ToolSecretArguments, ToolPackageArguments, ToolPlanArguments, or ToolMediaArguments.
128
+ * It is omitted for all other tools and malformed/partial streaming arguments.
129
+ */
130
+ arguments_string?: string;
131
+ /** Reviewed activity metadata for file, execution, or entity tools. */
132
+ display_projection?: ToolDisplayProjection;
133
+ /** Reviewed clarifying-question answers only. */
134
+ user_input?: ToolQuestionInput;
135
+ /** Fixed reviewed success outcome only. */
136
+ results?: ToolOutcome;
16
137
  }
17
138
  /** Public message replacement. Omitted properties are not synthesized by the SDK. */
18
139
  export interface ChatMessage {
@@ -24,7 +145,7 @@ export interface ChatMessage {
24
145
  content?: string | null;
25
146
  /** Attached file URLs. */
26
147
  file_urls?: string[] | null;
27
- /** Public tool progress, without arguments or results. */
148
+ /** Public tool progress with optional reviewed interaction details. */
28
149
  tool_calls?: ToolCall[] | null;
29
150
  /** Message timestamp, without author identity. */
30
151
  metadata?: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@base44-preview/sdk",
3
- "version": "0.8.48-pr.286.7d59d14",
3
+ "version": "0.8.48-pr.286.d14ea24",
4
4
  "description": "JavaScript SDK for Base44 API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",