@belonguniverseai/react-sdk 0.6.19 → 0.6.21

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.
Files changed (90) hide show
  1. package/dist/api/client.d.ts +83 -5
  2. package/dist/api/questions.d.ts +2 -6
  3. package/dist/component/{abnfDiagram-N423BO3Z-p8pf1oUu.js → abnfDiagram-N423BO3Z-DZRUOUZQ.js} +4 -4
  4. package/dist/component/{arc-CDN3jDNB.js → arc-B4biduil.js} +2 -2
  5. package/dist/component/{architectureDiagram-T3A2C74G-Dd8FlfDW.js → architectureDiagram-T3A2C74G-q8voStNN.js} +3 -3
  6. package/dist/component/{blockDiagram-VBNYF7ZC-CUgNh_GL.js → blockDiagram-VBNYF7ZC-C0TDyTgw.js} +4 -4
  7. package/dist/component/{c4Diagram-5PPSVZJV-CSjftNi_.js → c4Diagram-5PPSVZJV-rxRyd6rh.js} +3 -3
  8. package/dist/component/{channel-RXp4rUai.js → channel-CUruDJSx.js} +2 -2
  9. package/dist/component/{chunk-2GRJ4B5K-Conm-Udw.js → chunk-2GRJ4B5K-Kff5Fvbi.js} +2 -2
  10. package/dist/component/{chunk-2Q5K7J3B-BJVcNqca.js → chunk-2Q5K7J3B-BT3ZD31a.js} +2 -2
  11. package/dist/component/{chunk-5RXB4S5H-ClnvuSUP.js → chunk-5RXB4S5H-CYZ36tQD.js} +5 -5
  12. package/dist/component/{chunk-5VM5RSS4-CZSg676A.js → chunk-5VM5RSS4-BweQRk7u.js} +2 -2
  13. package/dist/component/{chunk-6Q2QTUOP-d6e2hDQ3.js → chunk-6Q2QTUOP-DHcoXRhe.js} +2 -2
  14. package/dist/component/{chunk-GF5L2VYU-DMNXiX_5.js → chunk-GF5L2VYU-DtE5ljCc.js} +6 -6
  15. package/dist/component/{chunk-JWPE2WC7-Be-HKBKg.js → chunk-JWPE2WC7-ClHq4gN2.js} +2 -2
  16. package/dist/component/{chunk-KBJHAD2P-CSs5ejAq.js → chunk-KBJHAD2P-BeCfHf5W.js} +2 -2
  17. package/dist/component/{chunk-RYQCIY6F-BM0CmhLz.js → chunk-RYQCIY6F-CuAngwHt.js} +2 -2
  18. package/dist/component/{chunk-XXDRQBXY-Xj8K5wzT.js → chunk-XXDRQBXY-D9c0CJyR.js} +2 -2
  19. package/dist/component/{classDiagram-JCYQIIEL-DTZI6cPh.js → classDiagram-JCYQIIEL-DdzIbKj1.js} +3 -3
  20. package/dist/component/{classDiagram-v2-OCEON4UE-DTZI6cPh.js → classDiagram-v2-OCEON4UE-DdzIbKj1.js} +3 -3
  21. package/dist/component/{cose-bilkent-JH36ORCC-DaY5o18F.js → cose-bilkent-JH36ORCC-hME9BYGm.js} +2 -2
  22. package/dist/component/{cynefinDiagram-MW4NZA55-DoTeA4Ye.js → cynefinDiagram-MW4NZA55-BiceKBPh.js} +3 -3
  23. package/dist/component/{dagre-VZM6K2ZE-CF3eWDN_.js → dagre-VZM6K2ZE-DiPOLAUX.js} +3 -3
  24. package/dist/component/{diagram-7IWD3JNH-D4CVwoPP.js → diagram-7IWD3JNH-BSDWgxjs.js} +4 -4
  25. package/dist/component/{diagram-B4RE2ZJO-DTk-yH1g.js → diagram-B4RE2ZJO-BdpGOPaT.js} +3 -3
  26. package/dist/component/{diagram-LBJQPF4R-C82NaEDn.js → diagram-LBJQPF4R-B0V6_5ih.js} +3 -3
  27. package/dist/component/{diagram-Q27KOJAE-DVbW2GPm.js → diagram-Q27KOJAE-CYDb40TJ.js} +4 -4
  28. package/dist/component/{diagram-UB23O5K3-fLwqL8Hl.js → diagram-UB23O5K3-DgwjRdl5.js} +3 -3
  29. package/dist/component/{ebnfDiagram-BXEA7PRR-BLEKzcRB.js → ebnfDiagram-BXEA7PRR-D-C7SWec.js} +4 -4
  30. package/dist/component/{erDiagram-JOGREHBK-D9srj1qV.js → erDiagram-JOGREHBK-DLJCjcXM.js} +5 -5
  31. package/dist/component/{flowDiagram-UKHOOZJN-CeyLyzYo.js → flowDiagram-UKHOOZJN-BZfBucKB.js} +7 -7
  32. package/dist/component/{ganttDiagram-PKOTCBZU-D_wnN-8z.js → ganttDiagram-PKOTCBZU-CxTHmusv.js} +3 -3
  33. package/dist/component/{gitGraphDiagram-DS77QQ5N-PeHi2KIR.js → gitGraphDiagram-DS77QQ5N-B_dWXxMf.js} +4 -4
  34. package/dist/component/{highlighted-body-OFNGDK62-CuSKYiPW.js → highlighted-body-OFNGDK62-CQ1ZdhQ-.js} +2 -2
  35. package/dist/component/{index-Dips44uG.js → index-i49DPVb4.js} +960 -464
  36. package/dist/component/index.js +2 -2
  37. package/dist/component/{infoDiagram-6WML65LV-CGnUeTPG.js → infoDiagram-6WML65LV-P4GO-aVw.js} +2 -2
  38. package/dist/component/{ishikawaDiagram-WSZJBQD7-DhbZTdB_.js → ishikawaDiagram-WSZJBQD7-BMXMrxKI.js} +2 -2
  39. package/dist/component/{journeyDiagram-NVQOT4AX-DbAZyk3F.js → journeyDiagram-NVQOT4AX-DPdTmxkF.js} +5 -5
  40. package/dist/component/{kanban-definition-27J2QSJJ-CPIUg4vz.js → kanban-definition-27J2QSJJ-sYw64NrE.js} +3 -3
  41. package/dist/component/{linear-CpcRfWUV.js → linear-DYjDg3gl.js} +2 -2
  42. package/dist/component/{mermaid-GHXKKRXX-CnsSyJhK.js → mermaid-GHXKKRXX-DfdCmrs3.js} +31367 -29801
  43. package/dist/component/{mindmap-definition-FAOFIHXS-RIm66-oB.js → mindmap-definition-FAOFIHXS-UkAbrucA.js} +4 -4
  44. package/dist/component/{pegDiagram-VL7TDLO6-C6uB8Ash.js → pegDiagram-VL7TDLO6-BGab1it6.js} +4 -4
  45. package/dist/component/{pieDiagram-7S7Q4E2Y-6m7QqfK3.js → pieDiagram-7S7Q4E2Y-BnY70Pr-.js} +4 -4
  46. package/dist/component/{quadrantDiagram-CIZ2JOQS-Dge2oJ5y.js → quadrantDiagram-CIZ2JOQS-Cv1bjdQb.js} +3 -3
  47. package/dist/component/{railroadDiagram-AXF67PYL-DWfg1byS.js → railroadDiagram-AXF67PYL-DJhLbGB_.js} +4 -4
  48. package/dist/component/{requirementDiagram-LRYGKXZP-C_mrqai9.js → requirementDiagram-LRYGKXZP-CLW3CgbU.js} +4 -4
  49. package/dist/component/{sankeyDiagram-W5VNT64P-D1MhEv2a.js → sankeyDiagram-W5VNT64P-vnapx0yf.js} +2 -2
  50. package/dist/component/{sequenceDiagram-SI44F4Z6-mn9it5es.js → sequenceDiagram-SI44F4Z6-I43iQsY0.js} +4 -4
  51. package/dist/component/{sizeCapture-X5ZJPWSS-Do_vnkJp.js → sizeCapture-X5ZJPWSS-D9LGwwwC.js} +2 -2
  52. package/dist/component/{stateDiagram-OKZ733FA-Pru5Vhsh.js → stateDiagram-OKZ733FA-BXejMYGk.js} +3 -3
  53. package/dist/component/{stateDiagram-v2-UEYNNEHI-BvRl8AHY.js → stateDiagram-v2-UEYNNEHI-BP05TJSl.js} +3 -3
  54. package/dist/component/{swimlanes-SLNWSIFB-CfaY_lmO.js → swimlanes-SLNWSIFB-CfmDVYhs.js} +4 -4
  55. package/dist/component/{swimlanesDiagram-ULZ7WXOC-BFIfCk31.js → swimlanesDiagram-ULZ7WXOC-DfjQBUfV.js} +3 -3
  56. package/dist/component/{timeline-definition-Z64GVDOM-BFU8eZDJ.js → timeline-definition-Z64GVDOM-C0BwzTs3.js} +3 -3
  57. package/dist/component/{vennDiagram-T6HMQDX7-C475K8TJ.js → vennDiagram-T6HMQDX7-CRf8sGBL.js} +2 -2
  58. package/dist/component/{wardleyDiagram-T6FBY63Y-DZEN3DyJ.js → wardleyDiagram-T6FBY63Y-C2h7TQ4a.js} +3 -3
  59. package/dist/component/{xychartDiagram-ELKLHX3M-B6MDNNoT.js → xychartDiagram-ELKLHX3M-CBcAwmdF.js} +3 -3
  60. package/dist/components/ui/badge.d.ts +1 -1
  61. package/dist/embed/copy.d.ts +1 -0
  62. package/dist/embed/dev-mode.d.ts +5 -7
  63. package/dist/embed/locale.d.ts +1 -1
  64. package/dist/embed/voice/line-run-reader.d.ts +8 -0
  65. package/dist/embed/voice-call.d.ts +4 -0
  66. package/dist/i18n/messages/en.d.ts +13 -5
  67. package/dist/i18n/messages/it.d.ts +3 -0
  68. package/dist/i18n/messages/surfaces/aiElements.d.ts +52 -0
  69. package/dist/i18n/messages/surfaces/app.d.ts +18 -0
  70. package/dist/i18n/messages/surfaces/connectors.d.ts +235 -0
  71. package/dist/i18n/messages/surfaces/embedMisc.d.ts +45 -0
  72. package/dist/i18n/messages/surfaces/feedback.d.ts +9 -0
  73. package/dist/i18n/messages/surfaces/files.d.ts +37 -0
  74. package/dist/i18n/messages/surfaces/header.d.ts +28 -0
  75. package/dist/i18n/messages/surfaces/login.d.ts +8 -0
  76. package/dist/i18n/messages/surfaces/plan.d.ts +17 -0
  77. package/dist/i18n/messages/surfaces/prompts.d.ts +43 -0
  78. package/dist/i18n/messages/surfaces/scheduled.d.ts +108 -0
  79. package/dist/i18n/messages/surfaces/sessions.d.ts +23 -0
  80. package/dist/i18n/messages/surfaces/stats.d.ts +18 -0
  81. package/dist/i18n/messages/surfaces/stream.d.ts +145 -5
  82. package/dist/i18n/messages/surfaces/usage.d.ts +26 -0
  83. package/dist/i18n/messages/surfaces/workspace.d.ts +10 -0
  84. package/dist/stream/ai-sdk-part-renderers.d.ts +7 -1
  85. package/dist/stream/belong-chat-transport.d.ts +5 -0
  86. package/dist/stream/belong-data-parts.d.ts +7 -3
  87. package/dist/stream/message-continuation.d.ts +29 -0
  88. package/dist/stream/run-line-progress.d.ts +1 -0
  89. package/dist/types/public.d.ts +1 -1
  90. package/package.json +1 -1
@@ -14,19 +14,26 @@ export declare const streamEn: {
14
14
  readonly skillChip: "Skill: {{name}}";
15
15
  readonly failedSuffix: " — failed";
16
16
  readonly approvalRequired: "Approval required";
17
+ readonly approvalRequest: "Approval request";
18
+ readonly alwaysAllowCommands: "Always allow running commands";
19
+ readonly alwaysAllowNavigation: "Always allow opening pages";
17
20
  readonly approve: "Approve";
18
21
  readonly requestChanges: "Request changes";
19
22
  readonly reject: "Reject";
20
23
  readonly approving: "Approving…";
21
24
  readonly rejecting: "Rejecting…";
22
25
  readonly sending: "Sending…";
23
- readonly decisionApproved: "approved";
24
- readonly decisionRejected: "rejected";
25
- readonly decisionAmendRequested: "amend requested";
26
- readonly expired: "expired";
27
- readonly alreadyResolved: "already resolved";
26
+ readonly decisionApproved: "Approved";
27
+ readonly decisionRejected: "Rejected";
28
+ readonly decisionAmendRequested: "Changes requested";
29
+ readonly expired: "Expired";
30
+ readonly alreadyResolved: "Already resolved";
28
31
  readonly alwaysAllowTool: "Always allow {{toolName}}";
29
32
  readonly alwaysAllowAction: "Always allow this action";
33
+ readonly approvalOpenPage: "Open this page";
34
+ readonly approvalRunCommand: "Run this command";
35
+ readonly expiredHint: "The wait timed out, so nothing ran";
36
+ readonly alreadyResolvedHint: "Answered somewhere else";
30
37
  readonly submitError: "That didn't go through — {{message}}. Try again.";
31
38
  readonly errorServerAnswered: "the server answered {{status}}";
32
39
  readonly errorRequestUnreachable: "the request didn't reach the server";
@@ -111,6 +118,7 @@ export declare const streamEn: {
111
118
  readonly reconnecting: "Reconnecting to Simetrik…";
112
119
  };
113
120
  readonly reconnectingBadge: "reconnecting";
121
+ readonly incompleteTask: "Paused — unfinished";
114
122
  readonly resumingAfterPause: "Taking longer than expected — picking it back up…";
115
123
  readonly open: "Open";
116
124
  readonly reconnectRateLimited: "{{provider}} is busy — trying again automatically in {{seconds}}s.";
@@ -125,6 +133,9 @@ export declare const streamEs: {
125
133
  skillChip: string;
126
134
  failedSuffix: string;
127
135
  approvalRequired: string;
136
+ approvalRequest: string;
137
+ alwaysAllowCommands: string;
138
+ alwaysAllowNavigation: string;
128
139
  approve: string;
129
140
  requestChanges: string;
130
141
  reject: string;
@@ -138,6 +149,10 @@ export declare const streamEs: {
138
149
  alreadyResolved: string;
139
150
  alwaysAllowTool: string;
140
151
  alwaysAllowAction: string;
152
+ approvalOpenPage: string;
153
+ approvalRunCommand: string;
154
+ expiredHint: string;
155
+ alreadyResolvedHint: string;
141
156
  submitError: string;
142
157
  errorServerAnswered: string;
143
158
  errorRequestUnreachable: string;
@@ -219,6 +234,7 @@ export declare const streamEs: {
219
234
  reconnecting: string;
220
235
  };
221
236
  reconnectingBadge: string;
237
+ incompleteTask: string;
222
238
  resumingAfterPause: string;
223
239
  open: string;
224
240
  reconnectRateLimited: string;
@@ -233,6 +249,9 @@ export declare const streamPt: {
233
249
  skillChip: string;
234
250
  failedSuffix: string;
235
251
  approvalRequired: string;
252
+ approvalRequest: string;
253
+ alwaysAllowCommands: string;
254
+ alwaysAllowNavigation: string;
236
255
  approve: string;
237
256
  requestChanges: string;
238
257
  reject: string;
@@ -246,6 +265,10 @@ export declare const streamPt: {
246
265
  alreadyResolved: string;
247
266
  alwaysAllowTool: string;
248
267
  alwaysAllowAction: string;
268
+ approvalOpenPage: string;
269
+ approvalRunCommand: string;
270
+ expiredHint: string;
271
+ alreadyResolvedHint: string;
249
272
  submitError: string;
250
273
  errorServerAnswered: string;
251
274
  errorRequestUnreachable: string;
@@ -327,6 +350,123 @@ export declare const streamPt: {
327
350
  reconnecting: string;
328
351
  };
329
352
  reconnectingBadge: string;
353
+ incompleteTask: string;
354
+ resumingAfterPause: string;
355
+ open: string;
356
+ reconnectRateLimited: string;
357
+ reconnectRateLimitedStill: string;
358
+ };
359
+ };
360
+ export declare const streamIt: {
361
+ stream: {
362
+ toolExecutionError: string;
363
+ copyOutput: string;
364
+ terminalOutput: string;
365
+ skillChip: string;
366
+ failedSuffix: string;
367
+ approvalRequired: string;
368
+ approvalRequest: string;
369
+ alwaysAllowCommands: string;
370
+ alwaysAllowNavigation: string;
371
+ approve: string;
372
+ requestChanges: string;
373
+ reject: string;
374
+ approving: string;
375
+ rejecting: string;
376
+ sending: string;
377
+ decisionApproved: string;
378
+ decisionRejected: string;
379
+ decisionAmendRequested: string;
380
+ expired: string;
381
+ alreadyResolved: string;
382
+ alwaysAllowTool: string;
383
+ alwaysAllowAction: string;
384
+ approvalOpenPage: string;
385
+ approvalRunCommand: string;
386
+ expiredHint: string;
387
+ alreadyResolvedHint: string;
388
+ submitError: string;
389
+ errorServerAnswered: string;
390
+ errorRequestUnreachable: string;
391
+ alreadyAnswered: string;
392
+ questionPending: string;
393
+ questionSkipped: string;
394
+ questionClosed: string;
395
+ questionDetached: string;
396
+ questionCancelled: string;
397
+ youReplied: string;
398
+ submit: string;
399
+ questionOf: string;
400
+ previousQuestion: string;
401
+ nextQuestion: string;
402
+ close: string;
403
+ somethingElse: string;
404
+ typeYourAnswer: string;
405
+ skip: string;
406
+ selectedCount_one: string;
407
+ selectedCount_other: string;
408
+ answer: string;
409
+ next: string;
410
+ questionDetachedHint: string;
411
+ toolShellRunning: string;
412
+ toolShellDone: string;
413
+ toolShellFailed: string;
414
+ toolShellDetail: string;
415
+ toolApprovalRunning: string;
416
+ toolApprovalDone: string;
417
+ toolApprovalFailed: string;
418
+ toolApprovalDetail: string;
419
+ toolGenericRunning: string;
420
+ toolGenericDone: string;
421
+ toolGenericFailed: string;
422
+ toolGenericDetail: string;
423
+ toolRememberRunning: string;
424
+ toolRememberDone: string;
425
+ toolRememberFailed: string;
426
+ toolRememberDetail: string;
427
+ toolForgetRunning: string;
428
+ toolForgetDone: string;
429
+ toolForgetFailed: string;
430
+ toolForgetDetail: string;
431
+ browserSnapshot: string;
432
+ browserRead: string;
433
+ browserClick: string;
434
+ browserType: string;
435
+ browserNavigate: string;
436
+ browserSelfTest: string;
437
+ browserResolveResource: string;
438
+ browserAwaitProcessed: string;
439
+ browserAssertCreated: string;
440
+ browserRefreshView: string;
441
+ failedBadge: string;
442
+ actionReadFile: string;
443
+ actionWroteFile: string;
444
+ actionPublishedArtifact: string;
445
+ actionLookedUpSkill: string;
446
+ actionSubTask: string;
447
+ actionMadePlan: string;
448
+ actionCheckedRules: string;
449
+ actionScheduledTask: string;
450
+ actionAskedQuestion: string;
451
+ actionGeneric: string;
452
+ executingTasks: string;
453
+ workedSteps_one: string;
454
+ workedSteps_other: string;
455
+ subagentRunning: string;
456
+ subagentDone: string;
457
+ subagentDoneSteps_one: string;
458
+ subagentDoneSteps_other: string;
459
+ subagentFailed: string;
460
+ subagentTimedOut: string;
461
+ subagentVia: string;
462
+ cliAuthStop: {
463
+ noGrant: string;
464
+ reconnectFailed: string;
465
+ cliAuthRequired: string;
466
+ reconnecting: string;
467
+ };
468
+ reconnectingBadge: string;
469
+ incompleteTask: string;
330
470
  resumingAfterPause: string;
331
471
  open: string;
332
472
  reconnectRateLimited: string;
@@ -77,3 +77,29 @@ export declare const usagePt: {
77
77
  };
78
78
  };
79
79
  };
80
+ export declare const usageIt: {
81
+ usage: {
82
+ tooltip: string;
83
+ windowTooltip: string;
84
+ context: string;
85
+ tokens: string;
86
+ inOut: string;
87
+ turnsThisSessionOne: string;
88
+ turnsThisSessionOther: string;
89
+ panel: {
90
+ title: string;
91
+ segments: {
92
+ messages: string;
93
+ system_prompt: string;
94
+ tools: string;
95
+ skills: string;
96
+ memory: string;
97
+ };
98
+ freeSpace: string;
99
+ estimateNote: string;
100
+ sessionTokens: string;
101
+ cacheLine: string;
102
+ autoCompact: string;
103
+ };
104
+ };
105
+ };
@@ -30,3 +30,13 @@ export declare const workspacePt: {
30
30
  planTitle: string;
31
31
  };
32
32
  };
33
+ export declare const workspaceIt: {
34
+ workspace: {
35
+ newItem: string;
36
+ close: string;
37
+ download: string;
38
+ shownByBelong: string;
39
+ openedByYou: string;
40
+ planTitle: string;
41
+ };
42
+ };
@@ -1,3 +1,4 @@
1
+ import { MessageContinuation } from './message-continuation.ts';
1
2
  import { BelongDataParts, BelongUIMessage, SandboxCommandData, SubagentData, ToolCallData } from './belong-data-parts.ts';
2
3
  /** One tool call in an activity run, paired (for shell) with its same-id output. */
3
4
  export type ToolActivityItem = {
@@ -51,6 +52,11 @@ export type PartRendererProps = {
51
52
  */
52
53
  readonly onExecutePlan?: (() => void) | undefined;
53
54
  readonly onContinueConnector?: ((connectorId: string, name: string) => Promise<void>) | undefined;
55
+ /**
56
+ * Follows the turn an approval card's decision started (an agent-raised plan
57
+ * card's 200 names it). Absent = the card resolves and follows nothing.
58
+ */
59
+ readonly onFollowContinuation?: ((continuation: MessageContinuation) => void) | undefined;
54
60
  /**
55
61
  * The part belongs to a restored-history message (`metadata.fromHistory`,
56
62
  * stamped by `loadSessionHistory`). The dispatch renderers (navigation,
@@ -66,7 +72,7 @@ export type PartRendererProps = {
66
72
  * `BelongDataParts` (above) plus the SDK's built-in `text` and
67
73
  * `reasoning` parts.
68
74
  */
69
- export declare const PartRenderer: ({ part, onExecutePlan, historical, onContinueConnector, }: PartRendererProps) => import("react").JSX.Element | null;
75
+ export declare const PartRenderer: ({ part, onExecutePlan, historical, onContinueConnector, onFollowContinuation, }: PartRendererProps) => import("react").JSX.Element | null;
70
76
  export type RenderGroup = {
71
77
  readonly kind: "part";
72
78
  readonly part: BelongMessagePart;
@@ -195,6 +195,8 @@ export declare const wireStreamPartSchema: z.ZodDiscriminatedUnion<[z.ZodObject<
195
195
  throttled: "throttled";
196
196
  }>;
197
197
  message: z.ZodOptional<z.ZodString>;
198
+ outcome: z.ZodOptional<z.ZodString>;
199
+ terminationReason: z.ZodOptional<z.ZodString>;
198
200
  retryable: z.ZodOptional<z.ZodBoolean>;
199
201
  }, z.core.$strip>;
200
202
  }, z.core.$strip>, z.ZodObject<{
@@ -372,6 +374,9 @@ export declare class BelongChatTransport implements ChatTransport<BelongUIMessag
372
374
  get sessionId(): string | null;
373
375
  /** The construction-captured workspace (see #workspaceExternalId). */
374
376
  get workspaceExternalId(): string | null;
377
+ /** Includes an outstanding SSE handshake and the transport's retry loop,
378
+ * which can own the Session before useChat reports `streaming`. */
379
+ get hasLiveStream(): boolean;
375
380
  /** Drop the cached session so the next `sendMessages` creates a new one. */
376
381
  reset(): void;
377
382
  /**
@@ -45,9 +45,10 @@ export type ApprovalRequestData = {
45
45
  readonly reason: string;
46
46
  readonly state: ApprovalState;
47
47
  /**
48
- * Optional tool name for the "Always allow" consent checkbox label.
49
- * When absent: "Always allow this action".
50
- * When present: "Always allow <toolName>".
48
+ * Optional tool name — the key of the consent row "Always allow" inserts.
49
+ * The dock labels the checkbox by what that consent covers (running
50
+ * commands / opening pages for the tool codes it knows, the identifier
51
+ * otherwise); when absent: "Always allow this action".
51
52
  * Added by the backend in a parallel branch — may be absent on older wire
52
53
  * messages; render the generic label when undefined.
53
54
  */
@@ -211,6 +212,9 @@ export type ArtifactData = {
211
212
  };
212
213
  export type StatusData = {
213
214
  readonly status: RunStatusKind;
215
+ /** Additive wire metadata: old docks still understand the failed terminal. */
216
+ readonly outcome?: string | undefined;
217
+ readonly terminationReason?: string | undefined;
214
218
  readonly message?: string | undefined;
215
219
  /**
216
220
  * Resume promise on a "failed" status: the backend verified the session
@@ -0,0 +1,29 @@
1
+ import { BelongUIMessage } from './belong-data-parts.ts';
2
+ export type MessageContinuation = {
3
+ readonly messageId: string;
4
+ readonly taskId: string;
5
+ readonly runId: string;
6
+ readonly text: string;
7
+ };
8
+ /**
9
+ * The continuation a 200 body names, if any (§4). A body that drifted still
10
+ * means the resolution was ACCEPTED — only the continuation is lost, so this
11
+ * never throws and never turns a success into a failure.
12
+ */
13
+ export declare const readContinuation: (body: unknown) => MessageContinuation | undefined;
14
+ /**
15
+ * The continuation a resolved response names, if any. The body read itself
16
+ * cannot fail the caller either: the resolution already succeeded.
17
+ */
18
+ export declare const readResponseContinuation: (res: {
19
+ readonly json: () => Promise<unknown>;
20
+ }) => Promise<MessageContinuation | undefined>;
21
+ /**
22
+ * The continuation's user message, appended locally so the transcript shows
23
+ * what the server just sent on the user's behalf. Same shape the history loader
24
+ * produces for a user turn, keyed by the SERVER message id, so the next history
25
+ * merge (`mergeRestoredHistory`) recognises it as the same turn instead of
26
+ * doubling it. Idempotent: a second continuation for the same message (a
27
+ * retried POST) appends nothing.
28
+ */
29
+ export declare const appendContinuationMessage: (messages: readonly BelongUIMessage[], continuation: MessageContinuation) => BelongUIMessage[];
@@ -31,6 +31,7 @@ export type RunLineProgressEvent = {
31
31
  readonly kind: "terminal";
32
32
  readonly runId: string;
33
33
  readonly status: Exclude<RunStatusKind, "continuing">;
34
+ readonly outcome?: string;
34
35
  };
35
36
  /**
36
37
  * Report one run event for `sessionId`. Silently does nothing when no agent
@@ -106,7 +106,7 @@ export type PartialBelongTheme = {
106
106
  /** Built-in theme presets selectable via `belong.applyPreset(name)`. */
107
107
  export type PresetName = "belong" | "simetrik" | "custom";
108
108
  /** UI languages the dock ships. `setLocale` / `init({ locale })` accept these. */
109
- export type BelongLocale = "en" | "es" | "pt";
109
+ export type BelongLocale = "en" | "es" | "pt" | "it";
110
110
  export type BelongInitInput = {
111
111
  /** Belong cloud base URL, e.g. `https://api.belong.host` or `http://localhost:8787`. */
112
112
  readonly apiBaseUrl: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@belonguniverseai/react-sdk",
3
- "version": "0.6.19",
3
+ "version": "0.6.21",
4
4
  "description": "Belong — embeddable React AI assistant dock. Mount <BelongWidget> in your app tree with getToken dependency-injection auth.",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",