@arbidocs/sdk 0.4.167 → 0.4.169
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.
- package/README.md +19 -14
- package/dist/{browser-DDZsy7dn.d.cts → browser-3s6asEn1.d.cts} +2051 -211
- package/dist/{browser-DDZsy7dn.d.ts → browser-jyiyv5Wh.d.ts} +2051 -211
- package/dist/browser.cjs +2169 -339
- package/dist/browser.cjs.map +1 -1
- package/dist/browser.d.cts +3 -2
- package/dist/browser.d.ts +3 -2
- package/dist/browser.js +2127 -341
- package/dist/browser.js.map +1 -1
- package/dist/index.cjs +2172 -342
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +7 -6
- package/dist/index.d.ts +7 -6
- package/dist/index.js +2130 -344
- package/dist/index.js.map +1 -1
- package/dist/sse-types-BbR7JG5o.d.cts +69 -0
- package/dist/sse-types-BbR7JG5o.d.ts +69 -0
- package/dist/testing.cjs +816 -0
- package/dist/testing.cjs.map +1 -0
- package/dist/testing.d.cts +293 -0
- package/dist/testing.d.ts +293 -0
- package/dist/testing.js +792 -0
- package/dist/testing.js.map +1 -0
- package/package.json +10 -2
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as _arbidocs_client from '@arbidocs/client';
|
|
2
|
-
import {
|
|
2
|
+
import { SessionPersistence, ArbiClient, LoginResult, WebSocketServerMessage, WsAuthResultMessage, WsTaskUpdateMessage, components, KeyPair, CallPeer, SessionStateStorage, RegisterParams, RegisterResult, LoginParams, SessionManager, LoginProfile } from '@arbidocs/client';
|
|
3
|
+
import { S as SSEStreamStartData, j as ResponseOutputItemAddedEvent, k as ResponseOutputItemDoneEvent, g as ResponseContentPartAddedEvent, c as ArbiErrorEvent, f as MessageQueuedEvent, o as UserMessageEvent, e as MessageMetadataPayload$1, U as UserInputRequestEvent, P as ProbeAnswerEvent, D as DeferredInterjectionEvent, A as AgentControlStateEvent, d as ArtifactEvent, M as MailDraftSSEEvent, n as ResponseUsage, T as TokenBudgetContext, b as AgentStepEvent } from './sse-types-BbR7JG5o.cjs';
|
|
3
4
|
|
|
4
5
|
/**
|
|
5
6
|
* Core error types and throwing error utilities.
|
|
@@ -194,7 +195,7 @@ interface ConfigStore {
|
|
|
194
195
|
* that omit this leave 401 retry disabled (the middleware falls back
|
|
195
196
|
* to its built-in IndexedDB adapter, which only works in browsers).
|
|
196
197
|
*/
|
|
197
|
-
|
|
198
|
+
getSessionPersistence?(): SessionPersistence;
|
|
198
199
|
}
|
|
199
200
|
|
|
200
201
|
/**
|
|
@@ -332,41 +333,6 @@ declare function resolveAuth(store: ConfigStore): Promise<AuthContext>;
|
|
|
332
333
|
*/
|
|
333
334
|
declare function resolveWorkspace(store: ConfigStore, workspaceOpt?: string): Promise<WorkspaceContext>;
|
|
334
335
|
|
|
335
|
-
/**
|
|
336
|
-
* SSE event types — re-exported from the auto-generated OpenAPI schema.
|
|
337
|
-
*
|
|
338
|
-
* Consumers should import these from '@arbidocs/sdk' (or '/browser')
|
|
339
|
-
* rather than reaching into '@arbidocs/client' directly.
|
|
340
|
-
*/
|
|
341
|
-
|
|
342
|
-
type ResponseCreatedEvent = components['schemas']['ResponseCreatedEvent'];
|
|
343
|
-
type ResponseCompletedEvent = components['schemas']['ResponseCompletedEvent'];
|
|
344
|
-
type ResponseFailedEvent = components['schemas']['ResponseFailedEvent'];
|
|
345
|
-
type ResponseOutputTextDeltaEvent = components['schemas']['ResponseOutputTextDeltaEvent'];
|
|
346
|
-
type ResponseOutputTextDoneEvent = components['schemas']['ResponseOutputTextDoneEvent'];
|
|
347
|
-
type ResponseOutputItemAddedEvent = components['schemas']['ResponseOutputItemAddedEvent'];
|
|
348
|
-
type ResponseOutputItemDoneEvent = components['schemas']['ResponseOutputItemDoneEvent'];
|
|
349
|
-
type ResponseContentPartAddedEvent = components['schemas']['ResponseContentPartAddedEvent'];
|
|
350
|
-
type AgentStepEvent = components['schemas']['AgentStepEvent'];
|
|
351
|
-
type AgentStepDeltaEvent = components['schemas']['AgentStepDeltaEvent'];
|
|
352
|
-
type UserInputRequestEvent = components['schemas']['UserInputRequestEvent'];
|
|
353
|
-
type ProbeAnswerEvent = components['schemas']['ProbeAnswerEvent'];
|
|
354
|
-
type DeferredInterjectionEvent = components['schemas']['DeferredInterjectionEvent'];
|
|
355
|
-
type AgentControlStateEvent = components['schemas']['AgentControlStateEvent'];
|
|
356
|
-
type ArtifactEvent = components['schemas']['ArtifactEvent'];
|
|
357
|
-
type MailDraftSSEEvent = components['schemas']['MailDraftSSEEvent'];
|
|
358
|
-
type UserMessageEvent = components['schemas']['UserMessageEvent'];
|
|
359
|
-
type MessageQueuedEvent = components['schemas']['MessageQueuedEvent'];
|
|
360
|
-
type MessageMetadataPayload$1 = components['schemas']['MessageMetadataPayload'];
|
|
361
|
-
type ArbiErrorEvent = components['schemas']['ArbiErrorEvent'];
|
|
362
|
-
type ResponseUsage = components['schemas']['ResponseUsage'];
|
|
363
|
-
type OutputTokensDetails = components['schemas']['OutputTokensDetails'];
|
|
364
|
-
type TokenBudgetContext = components['schemas']['TokenBudgetContext'];
|
|
365
|
-
/** Convenience type — what onStreamStart callbacks receive. */
|
|
366
|
-
type SSEStreamStartData = {
|
|
367
|
-
assistant_message_ext_id: string;
|
|
368
|
-
};
|
|
369
|
-
|
|
370
336
|
/**
|
|
371
337
|
* Server-Sent Events (SSE) parsing utilities.
|
|
372
338
|
*
|
|
@@ -963,6 +929,7 @@ declare function listDocuments(arbi: ArbiClient, workspaceExtId?: string | null)
|
|
|
963
929
|
status?: string | null | undefined;
|
|
964
930
|
error_message?: string | null | undefined;
|
|
965
931
|
failed_stage?: string | null | undefined;
|
|
932
|
+
status_seq: number;
|
|
966
933
|
n_pages?: number | null | undefined;
|
|
967
934
|
n_chunks?: number | null | undefined;
|
|
968
935
|
tokens?: number | null | undefined;
|
|
@@ -1090,6 +1057,7 @@ declare function getDocuments(arbi: ArbiClient, externalIds: string[]): Promise<
|
|
|
1090
1057
|
status?: string | null | undefined;
|
|
1091
1058
|
error_message?: string | null | undefined;
|
|
1092
1059
|
failed_stage?: string | null | undefined;
|
|
1060
|
+
status_seq: number;
|
|
1093
1061
|
n_pages?: number | null | undefined;
|
|
1094
1062
|
n_chunks?: number | null | undefined;
|
|
1095
1063
|
tokens?: number | null | undefined;
|
|
@@ -1205,6 +1173,7 @@ declare function updateDocuments(arbi: ArbiClient, documents: DocUpdateRequest$1
|
|
|
1205
1173
|
status?: string | null | undefined;
|
|
1206
1174
|
error_message?: string | null | undefined;
|
|
1207
1175
|
failed_stage?: string | null | undefined;
|
|
1176
|
+
status_seq: number;
|
|
1208
1177
|
n_pages?: number | null | undefined;
|
|
1209
1178
|
n_chunks?: number | null | undefined;
|
|
1210
1179
|
tokens?: number | null | undefined;
|
|
@@ -1905,7 +1874,7 @@ declare function listWorkspaces(arbi: ArbiClient): Promise<{
|
|
|
1905
1874
|
encryption_public_key: string;
|
|
1906
1875
|
is_sso: boolean;
|
|
1907
1876
|
is_identity_verified: boolean;
|
|
1908
|
-
temporary_access_only
|
|
1877
|
+
temporary_access_only: boolean;
|
|
1909
1878
|
};
|
|
1910
1879
|
role: components["schemas"]["WorkspaceRole"];
|
|
1911
1880
|
joined_at: string;
|
|
@@ -1963,7 +1932,7 @@ declare function createWorkspace(arbi: ArbiClient, name: string, encryptedWorksp
|
|
|
1963
1932
|
encryption_public_key: string;
|
|
1964
1933
|
is_sso: boolean;
|
|
1965
1934
|
is_identity_verified: boolean;
|
|
1966
|
-
temporary_access_only
|
|
1935
|
+
temporary_access_only: boolean;
|
|
1967
1936
|
};
|
|
1968
1937
|
role: components["schemas"]["WorkspaceRole"];
|
|
1969
1938
|
joined_at: string;
|
|
@@ -2015,7 +1984,7 @@ declare function updateWorkspace(arbi: ArbiClient, body: WorkspaceUpdateRequest$
|
|
|
2015
1984
|
encryption_public_key: string;
|
|
2016
1985
|
is_sso: boolean;
|
|
2017
1986
|
is_identity_verified: boolean;
|
|
2018
|
-
temporary_access_only
|
|
1987
|
+
temporary_access_only: boolean;
|
|
2019
1988
|
};
|
|
2020
1989
|
role: components["schemas"]["WorkspaceRole"];
|
|
2021
1990
|
joined_at: string;
|
|
@@ -2049,7 +2018,7 @@ declare function listWorkspaceUsers(arbi: ArbiClient): Promise<{
|
|
|
2049
2018
|
encryption_public_key: string;
|
|
2050
2019
|
is_sso: boolean;
|
|
2051
2020
|
is_identity_verified: boolean;
|
|
2052
|
-
temporary_access_only
|
|
2021
|
+
temporary_access_only: boolean;
|
|
2053
2022
|
};
|
|
2054
2023
|
role: components["schemas"]["WorkspaceRole"];
|
|
2055
2024
|
joined_at: string;
|
|
@@ -2060,6 +2029,18 @@ declare function listWorkspaceUsers(arbi: ArbiClient): Promise<{
|
|
|
2060
2029
|
is_temporary: boolean;
|
|
2061
2030
|
access_expires_at?: string | null | undefined;
|
|
2062
2031
|
}[]>;
|
|
2032
|
+
/**
|
|
2033
|
+
* How long an external recipient's grant lasts unless the request says otherwise: the server's
|
|
2034
|
+
* default, and its maximum (24 hours). It applies to external recipients only; everyone else's
|
|
2035
|
+
* grant is permanent or session-scoped.
|
|
2036
|
+
*/
|
|
2037
|
+
declare const EXTERNAL_ACCESS_SECONDS = 86400;
|
|
2038
|
+
/** An add-members request; `access_duration_seconds` defaults to {@link EXTERNAL_ACCESS_SECONDS}. */
|
|
2039
|
+
type AddWorkspaceMembersRequest = Omit<components['schemas']['AddWorkspaceUsersRequest'], 'access_duration_seconds'> & {
|
|
2040
|
+
access_duration_seconds?: number;
|
|
2041
|
+
};
|
|
2042
|
+
/** The `POST /v1/workspace/users` body for a request, with the server's default duration filled in. */
|
|
2043
|
+
declare function addWorkspaceMembersBody(request: AddWorkspaceMembersRequest): components['schemas']['AddWorkspaceUsersRequest'];
|
|
2063
2044
|
/**
|
|
2064
2045
|
* `POST /v1/workspace/users` with the whole request: members of the open workspace (or of
|
|
2065
2046
|
* `workspace_ext_id` with its key sealed to the caller's session), a temporary session-scoped grant
|
|
@@ -2067,7 +2048,7 @@ declare function listWorkspaceUsers(arbi: ArbiClient): Promise<{
|
|
|
2067
2048
|
* share of one resource (`resource_type`, `resource_ext_id`, `confirm_share`). Resolves with the
|
|
2068
2049
|
* memberships added.
|
|
2069
2050
|
*/
|
|
2070
|
-
declare function addWorkspaceMembers(arbi: ArbiClient, request:
|
|
2051
|
+
declare function addWorkspaceMembers(arbi: ArbiClient, request: AddWorkspaceMembersRequest): Promise<{
|
|
2071
2052
|
user: {
|
|
2072
2053
|
external_id: string;
|
|
2073
2054
|
parent_ext_id?: string | null | undefined;
|
|
@@ -2078,7 +2059,7 @@ declare function addWorkspaceMembers(arbi: ArbiClient, request: components['sche
|
|
|
2078
2059
|
encryption_public_key: string;
|
|
2079
2060
|
is_sso: boolean;
|
|
2080
2061
|
is_identity_verified: boolean;
|
|
2081
|
-
temporary_access_only
|
|
2062
|
+
temporary_access_only: boolean;
|
|
2082
2063
|
};
|
|
2083
2064
|
role: components["schemas"]["WorkspaceRole"];
|
|
2084
2065
|
joined_at: string;
|
|
@@ -2107,7 +2088,7 @@ confirmInvite?: boolean): Promise<{
|
|
|
2107
2088
|
encryption_public_key: string;
|
|
2108
2089
|
is_sso: boolean;
|
|
2109
2090
|
is_identity_verified: boolean;
|
|
2110
|
-
temporary_access_only
|
|
2091
|
+
temporary_access_only: boolean;
|
|
2111
2092
|
};
|
|
2112
2093
|
role: components["schemas"]["WorkspaceRole"];
|
|
2113
2094
|
joined_at: string;
|
|
@@ -2144,7 +2125,7 @@ declare function grantTemporaryWorkspaceAccess(arbi: ArbiClient, params: {
|
|
|
2144
2125
|
encryption_public_key: string;
|
|
2145
2126
|
is_sso: boolean;
|
|
2146
2127
|
is_identity_verified: boolean;
|
|
2147
|
-
temporary_access_only
|
|
2128
|
+
temporary_access_only: boolean;
|
|
2148
2129
|
};
|
|
2149
2130
|
role: components["schemas"]["WorkspaceRole"];
|
|
2150
2131
|
joined_at: string;
|
|
@@ -2168,7 +2149,7 @@ declare function setUserRole(arbi: ArbiClient, userIds: string[], role: 'owner'
|
|
|
2168
2149
|
encryption_public_key: string;
|
|
2169
2150
|
is_sso: boolean;
|
|
2170
2151
|
is_identity_verified: boolean;
|
|
2171
|
-
temporary_access_only
|
|
2152
|
+
temporary_access_only: boolean;
|
|
2172
2153
|
};
|
|
2173
2154
|
role: components["schemas"]["WorkspaceRole"];
|
|
2174
2155
|
joined_at: string;
|
|
@@ -2234,23 +2215,91 @@ declare function getWorkspaceActivity(arbi: ArbiClient, workspaceExtId: string,
|
|
|
2234
2215
|
* e.g. so a sync into it can read it.
|
|
2235
2216
|
*/
|
|
2236
2217
|
declare function primeWorkspaceKey(arbi: ArbiClient, workspaceExtId: string, sessionSealedKey: string): Promise<void>;
|
|
2218
|
+
type TransferScope = components['schemas']['TransferScope'];
|
|
2219
|
+
type TransferKind = components['schemas']['TransferKind'];
|
|
2220
|
+
type TransferMode = components['schemas']['TransferMode'];
|
|
2221
|
+
type TransferPlan = components['schemas']['TransferPlanResponse'];
|
|
2222
|
+
type TransferStatus = components['schemas']['TransferStatusResponse'];
|
|
2223
|
+
type TransferConflictPolicy = components['schemas']['ConflictPolicy'];
|
|
2224
|
+
type WorkspaceExport = components['schemas']['WorkspaceExportResponse'];
|
|
2225
|
+
/** What a scope of the current workspace would take (counts, warnings), before running it. */
|
|
2226
|
+
declare function planWorkspaceTransfer(arbi: ArbiClient, scope: TransferScope, mode: TransferMode): Promise<TransferPlan>;
|
|
2227
|
+
/**
|
|
2228
|
+
* Start copying or moving a scope of the current workspace into another (a background job).
|
|
2229
|
+
* `targetWorkspaceKey`: the target's key sealed to this server session.
|
|
2230
|
+
*/
|
|
2231
|
+
declare function startWorkspaceTransfer(arbi: ArbiClient, params: {
|
|
2232
|
+
scope: TransferScope;
|
|
2233
|
+
mode: TransferMode;
|
|
2234
|
+
targetWorkspaceId: string;
|
|
2235
|
+
targetWorkspaceKey: string;
|
|
2236
|
+
onConflict?: TransferConflictPolicy;
|
|
2237
|
+
}): Promise<TransferStatus>;
|
|
2238
|
+
/** Resume a stopped job (nothing is copied twice). */
|
|
2239
|
+
declare function resumeWorkspaceTransfer(arbi: ArbiClient, transferId: string, targetWorkspaceKey: string): Promise<TransferStatus>;
|
|
2240
|
+
declare function cancelWorkspaceTransfer(arbi: ArbiClient, transferId: string): Promise<{
|
|
2241
|
+
external_id: string;
|
|
2242
|
+
mode: components["schemas"]["TransferMode"];
|
|
2243
|
+
status: components["schemas"]["TransferStatus"];
|
|
2244
|
+
phase: components["schemas"]["TransferPhase"];
|
|
2245
|
+
source_workspace_ext_id?: string | null | undefined;
|
|
2246
|
+
target_workspace_ext_id?: string | null | undefined;
|
|
2247
|
+
total: number;
|
|
2248
|
+
processed: number;
|
|
2249
|
+
counts: {
|
|
2250
|
+
[x: string]: unknown;
|
|
2251
|
+
};
|
|
2252
|
+
error?: string | null | undefined;
|
|
2253
|
+
created_at: string;
|
|
2254
|
+
finished_at?: string | null | undefined;
|
|
2255
|
+
issues: {
|
|
2256
|
+
kind: string;
|
|
2257
|
+
source_ext_id: string;
|
|
2258
|
+
target_ext_id?: string | null | undefined;
|
|
2259
|
+
status: components["schemas"]["TransferItemStatus"];
|
|
2260
|
+
message?: string | null | undefined;
|
|
2261
|
+
}[];
|
|
2262
|
+
}>;
|
|
2263
|
+
/** One job's progress. */
|
|
2264
|
+
declare function getWorkspaceTransfer(arbi: ArbiClient, transferId: string): Promise<TransferStatus>;
|
|
2265
|
+
/** The caller's recent jobs out of the current workspace. */
|
|
2266
|
+
declare function listWorkspaceTransfers(arbi: ArbiClient): Promise<TransferStatus[]>;
|
|
2267
|
+
/** A scope's data for a download: its files (with versions and markup) and one JSON per kind. */
|
|
2268
|
+
declare function exportWorkspaceData(arbi: ArbiClient, scope: TransferScope): Promise<WorkspaceExport>;
|
|
2237
2269
|
|
|
2270
|
+
type workspaces_AddWorkspaceMembersRequest = AddWorkspaceMembersRequest;
|
|
2271
|
+
declare const workspaces_EXTERNAL_ACCESS_SECONDS: typeof EXTERNAL_ACCESS_SECONDS;
|
|
2272
|
+
type workspaces_TransferConflictPolicy = TransferConflictPolicy;
|
|
2273
|
+
type workspaces_TransferKind = TransferKind;
|
|
2274
|
+
type workspaces_TransferMode = TransferMode;
|
|
2275
|
+
type workspaces_TransferPlan = TransferPlan;
|
|
2276
|
+
type workspaces_TransferScope = TransferScope;
|
|
2277
|
+
type workspaces_TransferStatus = TransferStatus;
|
|
2238
2278
|
type workspaces_WorkspaceActivityOptions = WorkspaceActivityOptions;
|
|
2279
|
+
type workspaces_WorkspaceExport = WorkspaceExport;
|
|
2239
2280
|
declare const workspaces_addWorkspaceMembers: typeof addWorkspaceMembers;
|
|
2281
|
+
declare const workspaces_addWorkspaceMembersBody: typeof addWorkspaceMembersBody;
|
|
2240
2282
|
declare const workspaces_addWorkspaceUsers: typeof addWorkspaceUsers;
|
|
2283
|
+
declare const workspaces_cancelWorkspaceTransfer: typeof cancelWorkspaceTransfer;
|
|
2241
2284
|
declare const workspaces_copyDocuments: typeof copyDocuments;
|
|
2242
2285
|
declare const workspaces_createWorkspace: typeof createWorkspace;
|
|
2243
2286
|
declare const workspaces_deleteWorkspaces: typeof deleteWorkspaces;
|
|
2287
|
+
declare const workspaces_exportWorkspaceData: typeof exportWorkspaceData;
|
|
2244
2288
|
declare const workspaces_getWorkspaceActivity: typeof getWorkspaceActivity;
|
|
2289
|
+
declare const workspaces_getWorkspaceTransfer: typeof getWorkspaceTransfer;
|
|
2245
2290
|
declare const workspaces_grantTemporaryWorkspaceAccess: typeof grantTemporaryWorkspaceAccess;
|
|
2291
|
+
declare const workspaces_listWorkspaceTransfers: typeof listWorkspaceTransfers;
|
|
2246
2292
|
declare const workspaces_listWorkspaceUsers: typeof listWorkspaceUsers;
|
|
2247
2293
|
declare const workspaces_listWorkspaces: typeof listWorkspaces;
|
|
2294
|
+
declare const workspaces_planWorkspaceTransfer: typeof planWorkspaceTransfer;
|
|
2248
2295
|
declare const workspaces_primeWorkspaceKey: typeof primeWorkspaceKey;
|
|
2249
2296
|
declare const workspaces_removeWorkspaceUsers: typeof removeWorkspaceUsers;
|
|
2297
|
+
declare const workspaces_resumeWorkspaceTransfer: typeof resumeWorkspaceTransfer;
|
|
2250
2298
|
declare const workspaces_setUserRole: typeof setUserRole;
|
|
2299
|
+
declare const workspaces_startWorkspaceTransfer: typeof startWorkspaceTransfer;
|
|
2251
2300
|
declare const workspaces_updateWorkspace: typeof updateWorkspace;
|
|
2252
2301
|
declare namespace workspaces {
|
|
2253
|
-
export { type workspaces_WorkspaceActivityOptions as WorkspaceActivityOptions, workspaces_addWorkspaceMembers as addWorkspaceMembers, workspaces_addWorkspaceUsers as addWorkspaceUsers, workspaces_copyDocuments as copyDocuments, workspaces_createWorkspace as createWorkspace, workspaces_deleteWorkspaces as deleteWorkspaces, workspaces_getWorkspaceActivity as getWorkspaceActivity, workspaces_grantTemporaryWorkspaceAccess as grantTemporaryWorkspaceAccess, workspaces_listWorkspaceUsers as listWorkspaceUsers, workspaces_listWorkspaces as listWorkspaces, workspaces_primeWorkspaceKey as primeWorkspaceKey, workspaces_removeWorkspaceUsers as removeWorkspaceUsers, workspaces_setUserRole as setUserRole, workspaces_updateWorkspace as updateWorkspace };
|
|
2302
|
+
export { type workspaces_AddWorkspaceMembersRequest as AddWorkspaceMembersRequest, workspaces_EXTERNAL_ACCESS_SECONDS as EXTERNAL_ACCESS_SECONDS, type workspaces_TransferConflictPolicy as TransferConflictPolicy, type workspaces_TransferKind as TransferKind, type workspaces_TransferMode as TransferMode, type workspaces_TransferPlan as TransferPlan, type workspaces_TransferScope as TransferScope, type workspaces_TransferStatus as TransferStatus, type workspaces_WorkspaceActivityOptions as WorkspaceActivityOptions, type workspaces_WorkspaceExport as WorkspaceExport, workspaces_addWorkspaceMembers as addWorkspaceMembers, workspaces_addWorkspaceMembersBody as addWorkspaceMembersBody, workspaces_addWorkspaceUsers as addWorkspaceUsers, workspaces_cancelWorkspaceTransfer as cancelWorkspaceTransfer, workspaces_copyDocuments as copyDocuments, workspaces_createWorkspace as createWorkspace, workspaces_deleteWorkspaces as deleteWorkspaces, workspaces_exportWorkspaceData as exportWorkspaceData, workspaces_getWorkspaceActivity as getWorkspaceActivity, workspaces_getWorkspaceTransfer as getWorkspaceTransfer, workspaces_grantTemporaryWorkspaceAccess as grantTemporaryWorkspaceAccess, workspaces_listWorkspaceTransfers as listWorkspaceTransfers, workspaces_listWorkspaceUsers as listWorkspaceUsers, workspaces_listWorkspaces as listWorkspaces, workspaces_planWorkspaceTransfer as planWorkspaceTransfer, workspaces_primeWorkspaceKey as primeWorkspaceKey, workspaces_removeWorkspaceUsers as removeWorkspaceUsers, workspaces_resumeWorkspaceTransfer as resumeWorkspaceTransfer, workspaces_setUserRole as setUserRole, workspaces_startWorkspaceTransfer as startWorkspaceTransfer, workspaces_updateWorkspace as updateWorkspace };
|
|
2254
2303
|
}
|
|
2255
2304
|
|
|
2256
2305
|
/**
|
|
@@ -3047,16 +3096,14 @@ declare namespace conversations {
|
|
|
3047
3096
|
}
|
|
3048
3097
|
|
|
3049
3098
|
/**
|
|
3050
|
-
*
|
|
3051
|
-
*
|
|
3052
|
-
* retrieve: Uses the typed SDK route POST /v1/assistant/retrieve.
|
|
3053
|
-
* Returns matching chunks without LLM generation.
|
|
3099
|
+
* The one request builder for an assistant turn (`POST /v1/assistant/query`).
|
|
3054
3100
|
*
|
|
3055
|
-
*
|
|
3056
|
-
*
|
|
3101
|
+
* Every client that asks the assistant — the web chat, the agent sidebar, the Word add-in, the
|
|
3102
|
+
* image generator, the CLI and the TUI — builds its body here, so the tools a turn carries and the
|
|
3103
|
+
* fields it sets cannot drift between them.
|
|
3057
3104
|
*/
|
|
3058
3105
|
|
|
3059
|
-
type MessageInput$
|
|
3106
|
+
type MessageInput$2 = components['schemas']['MessageInput'];
|
|
3060
3107
|
declare function buildRetrievalChunkTool(docIds: string[], searchMode?: 'semantic' | 'keyword' | 'hybrid'): components['schemas']['RetrievalChunkTool'];
|
|
3061
3108
|
declare function buildRetrievalFullContextTool(docIds: string[]): components['schemas']['RetrievalFullContextTool'];
|
|
3062
3109
|
/**
|
|
@@ -3066,6 +3113,93 @@ declare function buildRetrievalFullContextTool(docIds: string[]): components['sc
|
|
|
3066
3113
|
*/
|
|
3067
3114
|
declare function buildFactsContextTool(factIds: string[]): components['schemas']['FactsContextTool'];
|
|
3068
3115
|
declare function buildRetrievalTocTool(docIds: string[]): components['schemas']['RetrievalTOCTool'];
|
|
3116
|
+
/** What a turn asks, and with what. */
|
|
3117
|
+
interface TurnRequest {
|
|
3118
|
+
/** The prompt as the person wrote it. */
|
|
3119
|
+
question: string;
|
|
3120
|
+
workspaceId: string;
|
|
3121
|
+
/**
|
|
3122
|
+
* The chat's documents. Absent: the turn carries no document tools (an agent run brings its
|
|
3123
|
+
* own); present (even empty): retrieval over them, plus the pinned one in full.
|
|
3124
|
+
*/
|
|
3125
|
+
docIds?: string[];
|
|
3126
|
+
/**
|
|
3127
|
+
* The pinned document: read in full rather than searched, when it is one of `docIds`. One at a
|
|
3128
|
+
* time — a pinned document's whole text goes into the agent's prompt.
|
|
3129
|
+
*/
|
|
3130
|
+
pinnedDocumentId?: string | null;
|
|
3131
|
+
/** The chat's facts, sent with every message (the server reads only the newest list). */
|
|
3132
|
+
factIds?: string[];
|
|
3133
|
+
/**
|
|
3134
|
+
* A launch's own tools (a workflow step, image references): they replace the document tools.
|
|
3135
|
+
* The chat's facts still ride along: the agent runs in this chat.
|
|
3136
|
+
*/
|
|
3137
|
+
tools?: MessageInput$2['tools'];
|
|
3138
|
+
/** Delegate the turn to the personal agent (PA mode). */
|
|
3139
|
+
personalAgent?: boolean;
|
|
3140
|
+
/**
|
|
3141
|
+
* The document open beside the chat (drafting): named, never sent. The assistant reads it on
|
|
3142
|
+
* demand and edits it in place.
|
|
3143
|
+
*/
|
|
3144
|
+
activeArtifactExtId?: string | null;
|
|
3145
|
+
/** The message this turn replies to. */
|
|
3146
|
+
previousResponseId?: string | null;
|
|
3147
|
+
/** An existing conversation with no previous response yet (a task's empty thread). */
|
|
3148
|
+
conversationId?: string;
|
|
3149
|
+
/** Run through this owned agent. */
|
|
3150
|
+
agentId?: string;
|
|
3151
|
+
/** The config (model) to answer with. */
|
|
3152
|
+
model?: string | null;
|
|
3153
|
+
/** Structured @mentions in the question. */
|
|
3154
|
+
mentions?: MessageInput$2['mentions'];
|
|
3155
|
+
/** The mode a NEW conversation starts in. */
|
|
3156
|
+
assistantMode?: MessageInput$2['assistant_mode'];
|
|
3157
|
+
}
|
|
3158
|
+
/** How a chat's documents split between full context and retrieval. */
|
|
3159
|
+
interface FullContextSelection {
|
|
3160
|
+
/** The document read in full (the pinned one), if any. */
|
|
3161
|
+
fullContextDocId: string | null;
|
|
3162
|
+
/** The documents searched. */
|
|
3163
|
+
chunkRetrievalDocIds: string[];
|
|
3164
|
+
}
|
|
3165
|
+
/**
|
|
3166
|
+
* Split a chat's documents between full context and retrieval. Only a pinned document is read in
|
|
3167
|
+
* full, and only while it is one of the chat's documents; everything else is searched.
|
|
3168
|
+
*/
|
|
3169
|
+
declare function selectFullContextDocument(docIds: string[], pinnedDocumentId: string | null | undefined): FullContextSelection;
|
|
3170
|
+
/** The retrieval tools for a selection. */
|
|
3171
|
+
declare function buildDocumentTools(selection: FullContextSelection): {
|
|
3172
|
+
retrieval_chunk: {
|
|
3173
|
+
name: "retrieval_chunk";
|
|
3174
|
+
description: string;
|
|
3175
|
+
tool_args: components["schemas"]["RetrievalChunkToolArgs"];
|
|
3176
|
+
tool_responses: {
|
|
3177
|
+
[key: string]: components["schemas"]["Chunk"][];
|
|
3178
|
+
};
|
|
3179
|
+
};
|
|
3180
|
+
retrieval_full_context: {
|
|
3181
|
+
name: "retrieval_full_context";
|
|
3182
|
+
description: string;
|
|
3183
|
+
tool_args: components["schemas"]["RetrievalFullContextToolArgs"];
|
|
3184
|
+
tool_responses: {
|
|
3185
|
+
[key: string]: components["schemas"]["Chunk"][];
|
|
3186
|
+
};
|
|
3187
|
+
};
|
|
3188
|
+
};
|
|
3189
|
+
/** The body of `POST /v1/assistant/query` for a turn. */
|
|
3190
|
+
declare function buildTurnRequest(request: TurnRequest): MessageInput$2;
|
|
3191
|
+
|
|
3192
|
+
/**
|
|
3193
|
+
* Assistant operations — retrieve (search-only) and query (with LLM).
|
|
3194
|
+
*
|
|
3195
|
+
* retrieve: Uses the typed SDK route POST /v1/assistant/retrieve.
|
|
3196
|
+
* Returns matching chunks without LLM generation.
|
|
3197
|
+
*
|
|
3198
|
+
* queryAssistant: Returns the raw Response for SSE streaming.
|
|
3199
|
+
* Uses raw fetch because the SDK client doesn't support streaming responses.
|
|
3200
|
+
*/
|
|
3201
|
+
|
|
3202
|
+
type MessageInput$1 = components['schemas']['MessageInput'];
|
|
3069
3203
|
/**
|
|
3070
3204
|
* The most document ids one retrieve sends. An empty list searches the whole workspace (the
|
|
3071
3205
|
* server resolves it), so a caller sends ids only for a narrowed scope, and a scope above this
|
|
@@ -3140,41 +3274,55 @@ interface SearchChunk {
|
|
|
3140
3274
|
* best score (a rerank score that is not positive does not count).
|
|
3141
3275
|
*/
|
|
3142
3276
|
declare function searchChunks(result: RetrieveResult | null | undefined): SearchChunk[];
|
|
3143
|
-
interface AssistantQueryOptions extends AuthHeaders {
|
|
3144
|
-
agentId?: string;
|
|
3145
|
-
activeArtifactExtId?: string;
|
|
3146
|
-
workspaceId: string;
|
|
3147
|
-
question: string;
|
|
3148
|
-
docIds: string[];
|
|
3149
|
-
previousResponseId?: string | null;
|
|
3150
|
-
/** Attach the first answer to an existing empty task/thread. */
|
|
3151
|
-
conversationId?: string;
|
|
3152
|
-
assistantMode?: MessageInput$1['assistant_mode'];
|
|
3153
|
-
model?: string;
|
|
3154
|
-
/**
|
|
3155
|
-
* Structured @mentions in `question`. A person mention shares the conversation and
|
|
3156
|
-
* notifies them; an assistant mention is what runs the assistant in a `mentioned`
|
|
3157
|
-
* conversation.
|
|
3158
|
-
*/
|
|
3159
|
-
mentions?: MessageInput$1['mentions'];
|
|
3277
|
+
interface AssistantQueryOptions extends AuthHeaders, TurnRequest {
|
|
3160
3278
|
/** Aborts the request and the stream (stop generating). */
|
|
3161
3279
|
signal?: AbortSignal;
|
|
3162
3280
|
}
|
|
3163
3281
|
/**
|
|
3164
|
-
* Send a
|
|
3165
|
-
*
|
|
3282
|
+
* Send a turn to the assistant. Returns the raw Response so the caller can stream or buffer as
|
|
3283
|
+
* needed; throws with the server's reason when it refuses (`authenticatedFetch`).
|
|
3166
3284
|
*
|
|
3167
|
-
* Uses raw fetch (not the SDK client) because we need the streaming
|
|
3168
|
-
*
|
|
3285
|
+
* Uses raw fetch (not the SDK client) because we need the streaming Response body — the SDK
|
|
3286
|
+
* client consumes the body to parse JSON.
|
|
3169
3287
|
*/
|
|
3170
3288
|
declare function queryAssistant(options: AssistantQueryOptions): Promise<Response>;
|
|
3289
|
+
/** The project's AI usage is used up (a `QUOTA_EXCEEDED` refusal or stream error). */
|
|
3290
|
+
interface QuotaExceeded {
|
|
3291
|
+
spend: number;
|
|
3292
|
+
budget: number;
|
|
3293
|
+
projectExtId: string | null;
|
|
3294
|
+
message?: string;
|
|
3295
|
+
}
|
|
3296
|
+
/** The server refused a turn before streaming it, in words a person can read. */
|
|
3297
|
+
declare class AssistantTurnRefused extends ArbiApiError {
|
|
3298
|
+
/** Set when the refusal is the project's used-up AI usage. */
|
|
3299
|
+
readonly quota: QuotaExceeded | null;
|
|
3300
|
+
constructor(message: string, status: number, quota?: QuotaExceeded | null);
|
|
3301
|
+
}
|
|
3302
|
+
/** The session's token has expired and could not be renewed. */
|
|
3303
|
+
declare const SESSION_EXPIRED_MESSAGE = "Token has expired. Please log in again.";
|
|
3304
|
+
/** A `QUOTA_EXCEEDED` detail (a 402 body or an `arbi.error` frame), read as {@link QuotaExceeded}. */
|
|
3305
|
+
declare function quotaExceededFrom(detail: unknown): QuotaExceeded | null;
|
|
3306
|
+
/** A stream error that is LiteLLM's ExceededBudget, read as {@link QuotaExceeded} (in £). */
|
|
3307
|
+
declare function quotaFromStreamError(error: unknown): QuotaExceeded | null;
|
|
3308
|
+
/**
|
|
3309
|
+
* Open a turn's stream (`POST /v1/assistant/query` with a built body). A 401 throws the
|
|
3310
|
+
* `ArbiApiError` the session recovery renews the token on; any other refusal throws
|
|
3311
|
+
* {@link AssistantTurnRefused}.
|
|
3312
|
+
*/
|
|
3313
|
+
declare function openTurnStream(auth: AuthHeaders, body: MessageInput$1, signal?: AbortSignal): Promise<Response>;
|
|
3314
|
+
/**
|
|
3315
|
+
* Open a running turn's stream (`GET /v1/assistant/run/{id}/stream`): it replays the frames so far,
|
|
3316
|
+
* then tails the live ones until the run ends. A 404 means the run is no longer active.
|
|
3317
|
+
*/
|
|
3318
|
+
declare function openRunStream(auth: AuthHeaders, responseId: string, signal?: AbortSignal): Promise<Response>;
|
|
3171
3319
|
/**
|
|
3172
3320
|
* Interject into a running agent turn with input — answer its ask_user question,
|
|
3173
3321
|
* or (as raw text) send a steering interjection or a run-control command
|
|
3174
3322
|
* (`/pause`, `/resume`, `/report`). The backend classifies the text; the
|
|
3175
3323
|
* assistant_message_ext_id identifies which streaming turn to interject into.
|
|
3176
3324
|
*/
|
|
3177
|
-
declare function
|
|
3325
|
+
declare function interject(arbi: ArbiClient, assistantMessageExtId: string, answer: string): Promise<unknown>;
|
|
3178
3326
|
/** A single user-invocable skill as exposed by ``GET /v1/assistant/skills``.
|
|
3179
3327
|
* Re-exported with the schema-generated shape so callers don't have to
|
|
3180
3328
|
* reach into ``components['schemas']`` themselves. */
|
|
@@ -3231,6 +3379,11 @@ type CommandDescriptor = components['schemas']['CommandDescriptorResponse'];
|
|
|
3231
3379
|
* user-authored skills).
|
|
3232
3380
|
*/
|
|
3233
3381
|
declare function listCommands(arbi: ArbiClient): Promise<CommandDescriptor[]>;
|
|
3382
|
+
/**
|
|
3383
|
+
* Transcribe a voice recording (`POST /v1/assistant/transcribe`): the words spoken, as text (empty
|
|
3384
|
+
* when no speech was found).
|
|
3385
|
+
*/
|
|
3386
|
+
declare function transcribe(arbi: ArbiClient, audio: Blob): Promise<string>;
|
|
3234
3387
|
/** Parsed slash-command shape, regardless of frontend. */
|
|
3235
3388
|
interface ParsedSlashCommand {
|
|
3236
3389
|
/** The lowercased token immediately after ``/``. */
|
|
@@ -3281,37 +3434,42 @@ declare function filterSkills<T extends {
|
|
|
3281
3434
|
slug?: string;
|
|
3282
3435
|
name: string;
|
|
3283
3436
|
}>(items: ReadonlyArray<T>, query: string, pinned?: ReadonlyArray<string>): T[];
|
|
3284
|
-
/**
|
|
3285
|
-
declare function
|
|
3437
|
+
/** Stop a run on the server (closing its stream alone leaves it running). */
|
|
3438
|
+
declare function cancelRun(auth: AuthHeaders, responseId: string): Promise<void>;
|
|
3286
3439
|
|
|
3287
3440
|
type assistant_AssistantQueryOptions = AssistantQueryOptions;
|
|
3441
|
+
type assistant_AssistantTurnRefused = AssistantTurnRefused;
|
|
3442
|
+
declare const assistant_AssistantTurnRefused: typeof AssistantTurnRefused;
|
|
3288
3443
|
type assistant_Chunk = Chunk;
|
|
3289
3444
|
type assistant_ChunkMetadata = ChunkMetadata;
|
|
3290
3445
|
type assistant_CommandDescriptor = CommandDescriptor;
|
|
3291
3446
|
declare const assistant_MAX_RETRIEVE_DOC_IDS: typeof MAX_RETRIEVE_DOC_IDS;
|
|
3292
3447
|
type assistant_ParsedSlashCommand = ParsedSlashCommand;
|
|
3448
|
+
type assistant_QuotaExceeded = QuotaExceeded;
|
|
3293
3449
|
type assistant_RetrieveOptions = RetrieveOptions;
|
|
3294
3450
|
type assistant_RetrieveResult = RetrieveResult;
|
|
3451
|
+
declare const assistant_SESSION_EXPIRED_MESSAGE: typeof SESSION_EXPIRED_MESSAGE;
|
|
3295
3452
|
type assistant_SearchChunk = SearchChunk;
|
|
3296
3453
|
type assistant_SkillSummary = SkillSummary;
|
|
3297
|
-
declare const
|
|
3298
|
-
declare const assistant_buildRetrievalChunkTool: typeof buildRetrievalChunkTool;
|
|
3299
|
-
declare const assistant_buildRetrievalFullContextTool: typeof buildRetrievalFullContextTool;
|
|
3300
|
-
declare const assistant_buildRetrievalTocTool: typeof buildRetrievalTocTool;
|
|
3301
|
-
declare const assistant_cancelAssistantRun: typeof cancelAssistantRun;
|
|
3454
|
+
declare const assistant_cancelRun: typeof cancelRun;
|
|
3302
3455
|
declare const assistant_filterSkills: typeof filterSkills;
|
|
3456
|
+
declare const assistant_interject: typeof interject;
|
|
3303
3457
|
declare const assistant_isSharedSkill: typeof isSharedSkill;
|
|
3304
3458
|
declare const assistant_listCommands: typeof listCommands;
|
|
3305
3459
|
declare const assistant_listSkills: typeof listSkills;
|
|
3460
|
+
declare const assistant_openRunStream: typeof openRunStream;
|
|
3461
|
+
declare const assistant_openTurnStream: typeof openTurnStream;
|
|
3306
3462
|
declare const assistant_parseSlashCommand: typeof parseSlashCommand;
|
|
3307
3463
|
declare const assistant_parseSlashTokenInProgress: typeof parseSlashTokenInProgress;
|
|
3308
3464
|
declare const assistant_queryAssistant: typeof queryAssistant;
|
|
3309
|
-
declare const
|
|
3465
|
+
declare const assistant_quotaExceededFrom: typeof quotaExceededFrom;
|
|
3466
|
+
declare const assistant_quotaFromStreamError: typeof quotaFromStreamError;
|
|
3310
3467
|
declare const assistant_retrieve: typeof retrieve;
|
|
3311
3468
|
declare const assistant_searchChunks: typeof searchChunks;
|
|
3469
|
+
declare const assistant_transcribe: typeof transcribe;
|
|
3312
3470
|
declare const assistant_uploadSkill: typeof uploadSkill;
|
|
3313
3471
|
declare namespace assistant {
|
|
3314
|
-
export { type assistant_AssistantQueryOptions as AssistantQueryOptions, type assistant_Chunk as Chunk, type assistant_ChunkMetadata as ChunkMetadata, type assistant_CommandDescriptor as CommandDescriptor, assistant_MAX_RETRIEVE_DOC_IDS as MAX_RETRIEVE_DOC_IDS, type assistant_ParsedSlashCommand as ParsedSlashCommand, type assistant_RetrieveOptions as RetrieveOptions, type assistant_RetrieveResult as RetrieveResult, type assistant_SearchChunk as SearchChunk, type assistant_SkillSummary as SkillSummary,
|
|
3472
|
+
export { type assistant_AssistantQueryOptions as AssistantQueryOptions, assistant_AssistantTurnRefused as AssistantTurnRefused, type assistant_Chunk as Chunk, type assistant_ChunkMetadata as ChunkMetadata, type assistant_CommandDescriptor as CommandDescriptor, assistant_MAX_RETRIEVE_DOC_IDS as MAX_RETRIEVE_DOC_IDS, type assistant_ParsedSlashCommand as ParsedSlashCommand, type assistant_QuotaExceeded as QuotaExceeded, type assistant_RetrieveOptions as RetrieveOptions, type assistant_RetrieveResult as RetrieveResult, assistant_SESSION_EXPIRED_MESSAGE as SESSION_EXPIRED_MESSAGE, type assistant_SearchChunk as SearchChunk, type assistant_SkillSummary as SkillSummary, assistant_cancelRun as cancelRun, assistant_filterSkills as filterSkills, assistant_interject as interject, assistant_isSharedSkill as isSharedSkill, assistant_listCommands as listCommands, assistant_listSkills as listSkills, assistant_openRunStream as openRunStream, assistant_openTurnStream as openTurnStream, assistant_parseSlashCommand as parseSlashCommand, assistant_parseSlashTokenInProgress as parseSlashTokenInProgress, assistant_queryAssistant as queryAssistant, assistant_quotaExceededFrom as quotaExceededFrom, assistant_quotaFromStreamError as quotaFromStreamError, assistant_retrieve as retrieve, assistant_searchChunks as searchChunks, assistant_transcribe as transcribe, assistant_uploadSkill as uploadSkill };
|
|
3315
3473
|
}
|
|
3316
3474
|
|
|
3317
3475
|
/**
|
|
@@ -3334,6 +3492,8 @@ interface SubmitBackgroundQueryOptions extends AuthHeaders {
|
|
|
3334
3492
|
conversationId?: string;
|
|
3335
3493
|
mentions?: MessageInput['mentions'];
|
|
3336
3494
|
activeArtifactExtId?: string;
|
|
3495
|
+
/** Also read the documents in full (`retrieval_full_context`) beside their passages. Default true. */
|
|
3496
|
+
fullContext?: boolean;
|
|
3337
3497
|
}
|
|
3338
3498
|
/**
|
|
3339
3499
|
* Submit a query for background processing.
|
|
@@ -7166,12 +7326,382 @@ declare namespace calendar {
|
|
|
7166
7326
|
export { calendar_ACCOUNT_VENDOR as ACCOUNT_VENDOR, type calendar_AccountSyncResult as AccountSyncResult, type calendar_AttendeeRead as AttendeeRead, type calendar_BookingConfirmation as BookingConfirmation, type calendar_BookingPage as BookingPage, type calendar_BookingPageWriteBody as BookingPageWriteBody, type calendar_BookingRequestBody as BookingRequestBody, type calendar_CalDavConnectBody as CalDavConnectBody, type calendar_CalDavProfile as CalDavProfile, type calendar_CalendarAccount as CalendarAccount, type calendar_CalendarAccountKind as CalendarAccountKind, type calendar_CalendarCreate as CalendarCreate, type calendar_CalendarCreateBody as CalendarCreateBody, type calendar_CalendarEvent as CalendarEvent, type calendar_CalendarKeys as CalendarKeys, type calendar_CalendarRead as CalendarRead, type calendar_CalendarSettings as CalendarSettings, type calendar_CalendarSettingsBody as CalendarSettingsBody, type calendar_CalendarUpdate as CalendarUpdate, type calendar_CalendarWindow as CalendarWindow, type calendar_DateTimeSpec as DateTimeSpec, type calendar_EditScope as EditScope, type calendar_EventCreate as EventCreate, type calendar_EventCreateBody as EventCreateBody, type calendar_EventPatchBody as EventPatchBody, type calendar_EventWrite as EventWrite, type calendar_FindTimeParams as FindTimeParams, type calendar_FreeBusyEntry as FreeBusyEntry, type calendar_HolidayCountry as HolidayCountry, type calendar_ImportResult as ImportResult, type calendar_InvitationRead as InvitationRead, type calendar_ListEventsParams as ListEventsParams, type calendar_OAuthAccountKind as OAuthAccountKind, type calendar_OverlayItem as OverlayItem, type calendar_OverlayLayerName as OverlayLayerName, type calendar_PersonKey as PersonKey, calendar_PublicBookingError as PublicBookingError, type calendar_PublicBookingPage as PublicBookingPage, type calendar_ResourceCreate as ResourceCreate, type calendar_RespondParams as RespondParams, type calendar_RespondPartstat as RespondPartstat, type calendar_RoomCreateBody as RoomCreateBody, type calendar_RoomQuery as RoomQuery, type calendar_RoomRead as RoomRead, type calendar_ScopedTarget as ScopedTarget, type calendar_ShareRead as ShareRead, type calendar_ShareRole as ShareRole, type calendar_SubscribeParams as SubscribeParams, type calendar_TimeSuggestion as TimeSuggestion, type calendar_WeeklyHoursSpec as WeeklyHoursSpec, calendar_addHolidayCalendar as addHolidayCalendar, calendar_bookPublicSlot as bookPublicSlot, calendar_cancelPublicBooking as cancelPublicBooking, calendar_connectCalDavAccount as connectCalDavAccount, calendar_connectOAuthAccount as connectOAuthAccount, calendar_createCalendar as createCalendar, calendar_createEvent as createEvent, calendar_createRoom as createRoom, calendar_decideCounter as decideCounter, calendar_deleteBookingPage as deleteBookingPage, calendar_deleteCalendar as deleteCalendar, calendar_deleteEvent as deleteEvent, calendar_disconnectAccount as disconnectAccount, calendar_ensureCalendarUnlocked as ensureCalendarUnlocked, calendar_eventIcs as eventIcs, calendar_exportCalendarIcs as exportCalendarIcs, calendar_findTime as findTime, calendar_getCalendarSettings as getCalendarSettings, calendar_getEvent as getEvent, calendar_getFreeBusy as getFreeBusy, calendar_getPublicBookingPage as getPublicBookingPage, calendar_importCalendarIcs as importCalendarIcs, calendar_listAccounts as listAccounts, calendar_listBookingPages as listBookingPages, calendar_listCalDavProfiles as listCalDavProfiles, calendar_listCalendars as listCalendars, calendar_listEvents as listEvents, calendar_listHolidayCountries as listHolidayCountries, calendar_listInvitations as listInvitations, calendar_listOverlays as listOverlays, calendar_listRooms as listRooms, calendar_listShares as listShares, calendar_lookupEventByUid as lookupEventByUid, calendar_lookupPeopleKeys as lookupPeopleKeys, calendar_moveEvent as moveEvent, calendar_publishCalendarToAccount as publishCalendarToAccount, calendar_putBookingPage as putBookingPage, calendar_putCalendarSettings as putCalendarSettings, calendar_refreshCalendar as refreshCalendar, calendar_respondToEvent as respondToEvent, calendar_shareCalendar as shareCalendar, calendar_subscribeCalendar as subscribeCalendar, calendar_syncAccount as syncAccount, calendar_unlockCalendarKeys as unlockCalendarKeys, calendar_unshareCalendar as unshareCalendar, calendar_updateAccount as updateAccount, calendar_updateCalendar as updateCalendar, calendar_updateEvent as updateEvent };
|
|
7167
7327
|
}
|
|
7168
7328
|
|
|
7329
|
+
/**
|
|
7330
|
+
* How a refused call request reads: a {@link CallApiError} carrying the server's machine code and a
|
|
7331
|
+
* sentence for the person.
|
|
7332
|
+
*/
|
|
7333
|
+
|
|
7334
|
+
/** A refused call request. `code` is the server's machine code when it sent one. */
|
|
7335
|
+
declare class CallApiError extends ArbiApiError {
|
|
7336
|
+
readonly code?: string;
|
|
7337
|
+
constructor(message: string, status?: number, code?: string, apiError?: unknown);
|
|
7338
|
+
}
|
|
7339
|
+
interface ErrorOptions {
|
|
7340
|
+
/** Texts for this request that override the shared ones (by machine code). */
|
|
7341
|
+
texts?: Record<string, string>;
|
|
7342
|
+
/** Texts by HTTP status, used when the code has none. */
|
|
7343
|
+
statusTexts?: Record<number, string>;
|
|
7344
|
+
/** A recording write: 507 / 402 mean the storage quota is full. */
|
|
7345
|
+
quota?: boolean;
|
|
7346
|
+
}
|
|
7347
|
+
/** A refusal as a {@link CallApiError}: the code's sentence, else the server's words, else `fallback`. */
|
|
7348
|
+
declare function callError(error: unknown, status: number | undefined, fallback: string, options?: ErrorOptions): CallApiError;
|
|
7349
|
+
/** Storage quota refusals (507, or 402): the recording stops. */
|
|
7350
|
+
declare function isQuotaError(err: unknown): boolean;
|
|
7351
|
+
|
|
7352
|
+
/**
|
|
7353
|
+
* Webinar operations (`/v1/calls/{call}/webinar…`, ARBI `docs/webinars-plan.md`). A webinar is an
|
|
7354
|
+
* ordinary call with `mode = 'webinar'`; every request takes an optional `?link_version=` (a link
|
|
7355
|
+
* holder not yet in the room). Question `body` / `answer` are client ciphertext under the call key.
|
|
7356
|
+
*/
|
|
7357
|
+
|
|
7358
|
+
type Schemas$2 = components['schemas'];
|
|
7359
|
+
type WebinarState = Schemas$2['WebinarState'];
|
|
7360
|
+
type WebinarUpdate = Schemas$2['WebinarUpdate'];
|
|
7361
|
+
type WebinarRole = WebinarState['my_role'];
|
|
7362
|
+
type WebinarChat = WebinarState['chat'];
|
|
7363
|
+
type CallQuestion = Schemas$2['CallQuestionResponse'];
|
|
7364
|
+
type CallQuestionStatus = CallQuestion['status'];
|
|
7365
|
+
type CallQuestionUpdate = Schemas$2['CallQuestionUpdate'];
|
|
7366
|
+
/** WS `call.webinar`. */
|
|
7367
|
+
type CallWebinarMessage = Schemas$2['CallWebinarMessage'];
|
|
7368
|
+
/** Who runs a webinar (go live, promote, settings). */
|
|
7369
|
+
declare const WEBINAR_MODERATORS: ReadonlySet<WebinarRole>;
|
|
7370
|
+
/** Who is on the webinar's team (answers questions). */
|
|
7371
|
+
declare const WEBINAR_TEAM: ReadonlySet<WebinarRole>;
|
|
7372
|
+
/** The webinar's state (also for a link holder before admission). */
|
|
7373
|
+
declare function getWebinar(arbi: ArbiClient, callExtId: string, linkVersion?: number | null): Promise<WebinarState>;
|
|
7374
|
+
/** Moderators: `live` true opens the stage, false ends the webinar for everyone; `chat` who may chat. */
|
|
7375
|
+
declare function updateWebinar(arbi: ArbiClient, callExtId: string, body: WebinarUpdate, linkVersion?: number | null): Promise<WebinarState>;
|
|
7376
|
+
/** The audience raises or lowers a hand (409 on_stage). */
|
|
7377
|
+
declare function setWebinarHand(arbi: ArbiClient, callExtId: string, raised: boolean, linkVersion?: number | null): Promise<WebinarState>;
|
|
7378
|
+
/** Moderators: bring someone in the room on stage. */
|
|
7379
|
+
declare function promoteToStage(arbi: ArbiClient, callExtId: string, identity: string, linkVersion?: number | null): Promise<void>;
|
|
7380
|
+
/** Moderators move someone to the audience; anyone on stage may step down (their own identity). */
|
|
7381
|
+
declare function demoteFromStage(arbi: ArbiClient, callExtId: string, identity: string, linkVersion?: number | null): Promise<void>;
|
|
7382
|
+
/** The webinar's questions (`body` / `answer` are ciphertext under K). */
|
|
7383
|
+
declare function listQuestions(arbi: ArbiClient, callExtId: string, linkVersion?: number | null): Promise<CallQuestion[]>;
|
|
7384
|
+
declare function askQuestion(arbi: ArbiClient, callExtId: string, bodyCiphertext: string, linkVersion?: number | null): Promise<CallQuestion>;
|
|
7385
|
+
declare function voteQuestion(arbi: ArbiClient, callExtId: string, questionExtId: string, up: boolean, linkVersion?: number | null): Promise<CallQuestion>;
|
|
7386
|
+
/** Team: a status (answering live, answered, dismissed, open) and / or a text answer (ciphertext). */
|
|
7387
|
+
declare function updateQuestion(arbi: ArbiClient, callExtId: string, questionExtId: string, body: CallQuestionUpdate, linkVersion?: number | null): Promise<CallQuestion>;
|
|
7388
|
+
declare function deleteQuestion(arbi: ArbiClient, callExtId: string, questionExtId: string, linkVersion?: number | null): Promise<void>;
|
|
7389
|
+
|
|
7390
|
+
/**
|
|
7391
|
+
* Calls (`/v1/calls`, LiveKit). One call system: thread, chat (DM / group), contacts and scheduled
|
|
7392
|
+
* calls are all `/v1/calls` rows (ARBI `docs/calls-and-meetings-plan.md`, `docs/meeting-chats-plan.md`
|
|
7393
|
+
* §3–6, `docs/webinars-plan.md`).
|
|
7394
|
+
*
|
|
7395
|
+
* Everyone in a call is signed in (no anonymous guests). An unregistered contact gets a personal
|
|
7396
|
+
* invite link instead: a registration link that lands them in the call (`?i=<token>`) once they
|
|
7397
|
+
* have an account. The call key K never reaches the server in the clear (see `@arbidocs/client`
|
|
7398
|
+
* call-keys); `Arbi.calls` does the sealing and opening, these operations only move ciphertext.
|
|
7399
|
+
*
|
|
7400
|
+
* calls GET /config · POST / · GET|PATCH|DELETE /{id} · POST /{id}/token|ring|decline|knock
|
|
7401
|
+
* GET|POST /{id}/knock/{knock} · POST /{id}/chat · invite-links · participants/{identity}
|
|
7402
|
+
* transcribe POST /{id}/transcription {on} (host) · POST /{id}/transcribe (multipart, my own mic)
|
|
7403
|
+
* recording GET /{id}/recording/quota · POST /{id}/recording[/stop] · tracks · parts · commit
|
|
7404
|
+
* GET /{id}/recordings[/{crc}] · PATCH · DELETE …/media · DELETE · POST …/transcribe
|
|
7405
|
+
* webinar GET|PATCH /{id}/webinar · hand · stage/{usr} · questions[/{cqn}[/vote]]
|
|
7406
|
+
*
|
|
7407
|
+
* Every refusal is a {@link CallApiError} carrying the server's machine code (`locked`,
|
|
7408
|
+
* `knock_required`, `host_only`, `storage_quota_exceeded`, …) and a sentence for the person.
|
|
7409
|
+
*/
|
|
7410
|
+
|
|
7411
|
+
type Schemas$1 = components['schemas'];
|
|
7412
|
+
/** Make the fields the server defaults optional (the generator marks defaulted fields required). */
|
|
7413
|
+
type WithDefaults<T, K extends keyof T> = Omit<T, K> & Partial<Pick<T, K>>;
|
|
7414
|
+
type CallsConfig = Schemas$1['CallsConfigResponse'];
|
|
7415
|
+
type CallCreate = Schemas$1['CallCreate'];
|
|
7416
|
+
type CallUpdate = WithDefaults<Schemas$1['CallUpdate'], 'reset_link'>;
|
|
7417
|
+
type CallResponse = Schemas$1['CallResponse'];
|
|
7418
|
+
type CallTokenResponse = Schemas$1['CallTokenResponse'];
|
|
7419
|
+
type CallKnockResponse = Schemas$1['CallKnockResponse'];
|
|
7420
|
+
type CallJoinPolicy = CallResponse['join_policy'];
|
|
7421
|
+
type CallChatCreate = Schemas$1['CallChatCreate'];
|
|
7422
|
+
type CallChatResponse = Schemas$1['CallChatResponse'];
|
|
7423
|
+
/** `link` is the full call link (`…/call/<id>#k=…&v=…`); the server wraps it in a registration link. */
|
|
7424
|
+
type CallInviteLinkCreate = Schemas$1['CallInviteLinkCreate'];
|
|
7425
|
+
type CallInviteLinkResponse = Schemas$1['CallInviteLinkResponse'];
|
|
7426
|
+
type CallRingingMessage = Schemas$1['CallRingingMessage'];
|
|
7427
|
+
type CallDeclinedMessage = Schemas$1['CallDeclinedMessage'];
|
|
7428
|
+
type CallStartedMessage = Schemas$1['CallStartedMessage'];
|
|
7429
|
+
type CallEndedMessage = Schemas$1['CallEndedMessage'];
|
|
7430
|
+
type CallKnockMessage = Schemas$1['CallKnockMessage'];
|
|
7431
|
+
type CallKnockResolvedMessage = Schemas$1['CallKnockResolvedMessage'];
|
|
7432
|
+
/** WS `call.transcription`. */
|
|
7433
|
+
type CallTranscriptionMessage = Schemas$1['CallTranscriptionMessage'];
|
|
7434
|
+
/** `POST /v1/calls/{id}/transcribe` answer. */
|
|
7435
|
+
type CallTranscribeResponse = Schemas$1['CallTranscribeResponse'];
|
|
7436
|
+
/** `transcript` on `POST /v1/conversation/message` (stored as a `transcript_segment` tool). */
|
|
7437
|
+
type TranscriptSegmentRef = Schemas$1['TranscriptSegmentRef'];
|
|
7438
|
+
type RecordingMode = Schemas$1['CallRecordingStart']['mode'];
|
|
7439
|
+
type RecordingTrackKind = Schemas$1['CallRecordingTrackCreate']['kind'];
|
|
7440
|
+
/** The call's recording state (`CallResponse.recording`, WS `call.recording`, `arbi.recording`). */
|
|
7441
|
+
type CallRecordingState = Schemas$1['CallRecordingState'];
|
|
7442
|
+
type RecordingQuota = Schemas$1['CallRecordingQuota'];
|
|
7443
|
+
type RecordingPart = Schemas$1['CallRecordingPartResponse'];
|
|
7444
|
+
type RecordingTrack = Schemas$1['CallRecordingTrackResponse'];
|
|
7445
|
+
type CallRecording = Schemas$1['CallRecordingResponse'];
|
|
7446
|
+
type CreateTrackBody = Schemas$1['CallRecordingTrackCreate'];
|
|
7447
|
+
type PartBody = Schemas$1['CallRecordingPartCreate'];
|
|
7448
|
+
type PartUpload = Schemas$1['CallRecordingPartUpload'];
|
|
7449
|
+
type RecordingTranscribeResponse = Schemas$1['CallRecordingTranscribeResponse'];
|
|
7450
|
+
/** The role an invitee is given in a webinar (the host is whoever made it). */
|
|
7451
|
+
type InviteeRole = NonNullable<NonNullable<CallCreate['invitees']>[number]['role']>;
|
|
7452
|
+
declare function getCallsConfig(arbi: ArbiClient): Promise<CallsConfig>;
|
|
7453
|
+
declare function createCall(arbi: ArbiClient, body: CallCreate): Promise<CallResponse>;
|
|
7454
|
+
declare function getCall(arbi: ArbiClient, callExtId: string): Promise<CallResponse>;
|
|
7455
|
+
declare function updateCall(arbi: ArbiClient, callExtId: string, body: CallUpdate): Promise<CallResponse>;
|
|
7456
|
+
declare function cancelCall(arbi: ArbiClient, callExtId: string): Promise<void>;
|
|
7457
|
+
/**
|
|
7458
|
+
* A room token. `inviteToken` (a personal invite link's `?i=`, redeemed by the account it was meant
|
|
7459
|
+
* for) admits straight into the room, with no lobby.
|
|
7460
|
+
*/
|
|
7461
|
+
declare function fetchCallToken(arbi: ArbiClient, callExtId: string, linkVersion?: number | null, inviteToken?: string | null): Promise<CallTokenResponse>;
|
|
7462
|
+
/** Ring users: `sealedKeys` maps each user ext id to the call key sealed to them. */
|
|
7463
|
+
declare function ringCall(arbi: ArbiClient, callExtId: string, sealedKeys: Record<string, string>, linkVersion?: number | null): Promise<void>;
|
|
7464
|
+
declare function declineCall(arbi: ArbiClient, callExtId: string): Promise<void>;
|
|
7465
|
+
/**
|
|
7466
|
+
* Ask to be let in (a signed-in user the call's policy makes knock, e.g. via a forwarded link).
|
|
7467
|
+
* The server names me to the hosts from my account; a policy that lets me straight in answers
|
|
7468
|
+
* `admitted` with the token at once.
|
|
7469
|
+
*/
|
|
7470
|
+
declare function knockCall(arbi: ArbiClient, callExtId: string, linkVersion: number | null): Promise<CallKnockResponse>;
|
|
7471
|
+
/** Poll my knock (only its knocker may). */
|
|
7472
|
+
declare function pollKnock(arbi: ArbiClient, callExtId: string, knockId: string): Promise<CallKnockResponse>;
|
|
7473
|
+
/** A host admits or turns away someone in the lobby. */
|
|
7474
|
+
declare function decideKnock(arbi: ArbiClient, callExtId: string, knockId: string, admit: boolean): Promise<void>;
|
|
7475
|
+
/**
|
|
7476
|
+
* The call's meeting chat, made on first use. An E2E meeting chat needs `body` (the chat key sealed
|
|
7477
|
+
* to each member, plus K for members who are not yet invitees); a thread call or a chat's call takes
|
|
7478
|
+
* none. A 409 means the call is locked to a workspace this session has not opened.
|
|
7479
|
+
*/
|
|
7480
|
+
declare function getOrCreateCallChat(arbi: ArbiClient, callExtId: string, body?: CallChatCreate | null): Promise<CallChatResponse>;
|
|
7481
|
+
/**
|
|
7482
|
+
* Mail one of my unregistered contacts a personal invite link: an ARBI registration link whose
|
|
7483
|
+
* destination, once they have an account, is the call (`?i=<token>`, then the key fragment).
|
|
7484
|
+
* `link` is the full call link.
|
|
7485
|
+
*/
|
|
7486
|
+
declare function createCallInviteLink(arbi: ArbiClient, callExtId: string, body: CallInviteLinkCreate): Promise<CallInviteLinkResponse>;
|
|
7487
|
+
declare function listCallInviteLinks(arbi: ArbiClient, callExtId: string): Promise<CallInviteLinkResponse[]>;
|
|
7488
|
+
declare function revokeCallInviteLink(arbi: ArbiClient, callExtId: string, inviteLinkExtId: string): Promise<void>;
|
|
7489
|
+
declare function removeCallParticipant(arbi: ArbiClient, callExtId: string, identity: string): Promise<void>;
|
|
7490
|
+
/**
|
|
7491
|
+
* The host mutes a participant's microphone (`audio`) or turns off their camera (`video`). They
|
|
7492
|
+
* keep the right to publish, so they can turn it back on; they are told who did it (data message
|
|
7493
|
+
* `arbi.moderation` and WS `call.muted`).
|
|
7494
|
+
*/
|
|
7495
|
+
declare function muteCallParticipant(arbi: ArbiClient, callExtId: string, identity: string, track: 'audio' | 'video'): Promise<void>;
|
|
7496
|
+
/** The call's transcription state, normalised (absent fields → null). */
|
|
7497
|
+
interface CallTranscriptionState {
|
|
7498
|
+
on: boolean;
|
|
7499
|
+
/** LiveKit identity (user ext id) of whoever turned it on. */
|
|
7500
|
+
by_identity: string | null;
|
|
7501
|
+
by_name: string | null;
|
|
7502
|
+
}
|
|
7503
|
+
/** Coerce a transcription state (the call row, a WS event, the server's data message). */
|
|
7504
|
+
declare function transcriptionStateFrom(value: unknown): CallTranscriptionState | null;
|
|
7505
|
+
/** Turn transcription on or off. The call creator's setting: anyone else gets 403 `host_only`. */
|
|
7506
|
+
declare function setCallTranscription(arbi: ArbiClient, callExtId: string, on: boolean): Promise<CallTranscriptionState | null>;
|
|
7507
|
+
interface TranscribeSegmentParams {
|
|
7508
|
+
audio: Blob;
|
|
7509
|
+
segmentId: string;
|
|
7510
|
+
startedAt?: string;
|
|
7511
|
+
linkVersion?: number | null;
|
|
7512
|
+
language?: string | null;
|
|
7513
|
+
prompt?: string | null;
|
|
7514
|
+
}
|
|
7515
|
+
/**
|
|
7516
|
+
* Transcribe one speech segment of my own microphone. Nothing is stored server-side.
|
|
7517
|
+
*
|
|
7518
|
+
* `language` (ISO-639-1) and `prompt` (my previous line, a continuity hint; ≤ 500 chars) are
|
|
7519
|
+
* optional form fields. The server also takes a segment for 30 s after transcription was turned off
|
|
7520
|
+
* (or the room ended) when it started before that, so the line being spoken then is not lost.
|
|
7521
|
+
*/
|
|
7522
|
+
declare function transcribeCallSegment(arbi: ArbiClient, callExtId: string, params: TranscribeSegmentParams): Promise<CallTranscribeResponse>;
|
|
7523
|
+
/**
|
|
7524
|
+
* Post an (already encrypted) transcript line to an E2E chat (meeting, direct or call-bound group).
|
|
7525
|
+
* Idempotent per `dedupe_key`: a duplicate answers 200 with the message already stored.
|
|
7526
|
+
*/
|
|
7527
|
+
declare function postChatTranscriptLine(arbi: ArbiClient, chatExtId: string, body: {
|
|
7528
|
+
content: string;
|
|
7529
|
+
key_version: number;
|
|
7530
|
+
dedupe_key: string;
|
|
7531
|
+
}): Promise<Schemas$1['ChatMessageResponse']>;
|
|
7532
|
+
/** Coerce a recording state (the call row, a WS event, the server's data message). */
|
|
7533
|
+
declare function recordingStateFrom(value: unknown): CallRecordingState | null;
|
|
7534
|
+
/** The recording state on a call row (`CallResponse.recording`, null = off). */
|
|
7535
|
+
declare function recordingStateOfCall(call: {
|
|
7536
|
+
recording?: CallRecordingState | null;
|
|
7537
|
+
}): {
|
|
7538
|
+
on: boolean;
|
|
7539
|
+
mode?: ("audio" | "audio_video") | null;
|
|
7540
|
+
recording_ext_id?: string | null;
|
|
7541
|
+
by_identity?: string | null;
|
|
7542
|
+
by_name?: string | null;
|
|
7543
|
+
reason?: string | null;
|
|
7544
|
+
started_at?: string | null;
|
|
7545
|
+
} | null;
|
|
7546
|
+
/**
|
|
7547
|
+
* Whether to warn the host before starting: the project is near its limit, or has less left than
|
|
7548
|
+
* a recording needs to start.
|
|
7549
|
+
*/
|
|
7550
|
+
declare function quotaNeedsWarning(quota: RecordingQuota): boolean;
|
|
7551
|
+
declare function getRecordingQuota(arbi: ArbiClient, callExtId: string): Promise<RecordingQuota>;
|
|
7552
|
+
/** The host starts recording (403 host_only, 409 already_recording, 507 storage_quota_exceeded). */
|
|
7553
|
+
declare function startCallRecording(arbi: ArbiClient, callExtId: string, mode: RecordingMode): Promise<CallRecordingState | null>;
|
|
7554
|
+
/** The host stops recording; uploads keep a 5-minute grace for the tail. */
|
|
7555
|
+
declare function stopCallRecording(arbi: ArbiClient, callExtId: string): Promise<CallRecordingState | null>;
|
|
7556
|
+
/**
|
|
7557
|
+
* Create my track. Idempotent per speaker (and for the composite): 200 with the existing track and
|
|
7558
|
+
* its committed parts on a reconnect; 409 `recording_stopped` once the recording is over.
|
|
7559
|
+
*/
|
|
7560
|
+
declare function createRecordingTrack(arbi: ArbiClient, callExtId: string, recordingExtId: string, body: CreateTrackBody): Promise<RecordingTrack>;
|
|
7561
|
+
/** Presign a part's PUT (again, until it is committed). 507: the server stopped the recording. */
|
|
7562
|
+
declare function presignRecordingPart(arbi: ArbiClient, callExtId: string, recordingExtId: string, trackExtId: string, body: PartBody): Promise<PartUpload>;
|
|
7563
|
+
/** HEAD-verifies the PUT object and its size server-side. */
|
|
7564
|
+
declare function commitRecordingPart(arbi: ArbiClient, callExtId: string, recordingExtId: string, trackExtId: string, seq: number): Promise<void>;
|
|
7565
|
+
/** The call's recordings (readers only; 403 not_a_member). */
|
|
7566
|
+
declare function listCallRecordings(arbi: ArbiClient, callExtId: string): Promise<CallRecording[]>;
|
|
7567
|
+
declare function getCallRecording(arbi: ArbiClient, callExtId: string, recordingExtId: string): Promise<CallRecording>;
|
|
7568
|
+
/** The host sets (or clears, with null) when the media expires. */
|
|
7569
|
+
declare function setRecordingExpiry(arbi: ArbiClient, callExtId: string, recordingExtId: string, expiresAt: string | null): Promise<CallRecording>;
|
|
7570
|
+
/** "Keep transcript, delete audio/video" (409 `recording_active` while it records). */
|
|
7571
|
+
declare function deleteRecordingMedia(arbi: ArbiClient, callExtId: string, recordingExtId: string): Promise<CallRecording>;
|
|
7572
|
+
/** The host deletes the recording entirely (WS `call.recording_deleted`). */
|
|
7573
|
+
declare function deleteRecording(arbi: ArbiClient, callExtId: string, recordingExtId: string): Promise<void>;
|
|
7574
|
+
interface TranscribeRecordingParams {
|
|
7575
|
+
audio: Blob;
|
|
7576
|
+
trackExtId: string;
|
|
7577
|
+
seq?: number | null;
|
|
7578
|
+
segment?: number | null;
|
|
7579
|
+
segmentOffsetMs?: number;
|
|
7580
|
+
language?: string | null;
|
|
7581
|
+
prompt?: string | null;
|
|
7582
|
+
}
|
|
7583
|
+
/**
|
|
7584
|
+
* The host transcribes one (locally decrypted) piece of a speaker track.
|
|
7585
|
+
*
|
|
7586
|
+
* - Continuous track (the default): `seq` omitted; `segment` is the piece's index across the whole
|
|
7587
|
+
* track and `segmentOffsetMs` its start from the RECORDING start → segment id `rec-<track>-s<n>`.
|
|
7588
|
+
* - One part (a part this browser cannot decode, sent whole): `seq`, no `segment` →
|
|
7589
|
+
* `rec-<track>-<seq>`.
|
|
7590
|
+
*
|
|
7591
|
+
* `language` (ISO-639-1) and `prompt` (the speaker's previous text; ≤ 500 chars) are optional.
|
|
7592
|
+
*/
|
|
7593
|
+
declare function transcribeRecordingPart(arbi: ArbiClient, callExtId: string, recordingExtId: string, params: TranscribeRecordingParams): Promise<RecordingTranscribeResponse>;
|
|
7594
|
+
/** Download one part's ciphertext from its presigned GET. */
|
|
7595
|
+
declare function downloadRecordingPart(url: string): Promise<Uint8Array>;
|
|
7596
|
+
|
|
7597
|
+
type calls_CallApiError = CallApiError;
|
|
7598
|
+
declare const calls_CallApiError: typeof CallApiError;
|
|
7599
|
+
type calls_CallChatCreate = CallChatCreate;
|
|
7600
|
+
type calls_CallChatResponse = CallChatResponse;
|
|
7601
|
+
type calls_CallCreate = CallCreate;
|
|
7602
|
+
type calls_CallDeclinedMessage = CallDeclinedMessage;
|
|
7603
|
+
type calls_CallEndedMessage = CallEndedMessage;
|
|
7604
|
+
type calls_CallInviteLinkCreate = CallInviteLinkCreate;
|
|
7605
|
+
type calls_CallInviteLinkResponse = CallInviteLinkResponse;
|
|
7606
|
+
type calls_CallJoinPolicy = CallJoinPolicy;
|
|
7607
|
+
type calls_CallKnockMessage = CallKnockMessage;
|
|
7608
|
+
type calls_CallKnockResolvedMessage = CallKnockResolvedMessage;
|
|
7609
|
+
type calls_CallKnockResponse = CallKnockResponse;
|
|
7610
|
+
declare const calls_CallPeer: typeof CallPeer;
|
|
7611
|
+
type calls_CallQuestion = CallQuestion;
|
|
7612
|
+
type calls_CallQuestionStatus = CallQuestionStatus;
|
|
7613
|
+
type calls_CallQuestionUpdate = CallQuestionUpdate;
|
|
7614
|
+
type calls_CallRecording = CallRecording;
|
|
7615
|
+
type calls_CallRecordingState = CallRecordingState;
|
|
7616
|
+
type calls_CallResponse = CallResponse;
|
|
7617
|
+
type calls_CallRingingMessage = CallRingingMessage;
|
|
7618
|
+
type calls_CallStartedMessage = CallStartedMessage;
|
|
7619
|
+
type calls_CallTokenResponse = CallTokenResponse;
|
|
7620
|
+
type calls_CallTranscribeResponse = CallTranscribeResponse;
|
|
7621
|
+
type calls_CallTranscriptionMessage = CallTranscriptionMessage;
|
|
7622
|
+
type calls_CallTranscriptionState = CallTranscriptionState;
|
|
7623
|
+
type calls_CallUpdate = CallUpdate;
|
|
7624
|
+
type calls_CallWebinarMessage = CallWebinarMessage;
|
|
7625
|
+
type calls_CallsConfig = CallsConfig;
|
|
7626
|
+
type calls_CreateTrackBody = CreateTrackBody;
|
|
7627
|
+
type calls_InviteeRole = InviteeRole;
|
|
7628
|
+
type calls_PartBody = PartBody;
|
|
7629
|
+
type calls_PartUpload = PartUpload;
|
|
7630
|
+
type calls_RecordingMode = RecordingMode;
|
|
7631
|
+
type calls_RecordingPart = RecordingPart;
|
|
7632
|
+
type calls_RecordingQuota = RecordingQuota;
|
|
7633
|
+
type calls_RecordingTrack = RecordingTrack;
|
|
7634
|
+
type calls_RecordingTrackKind = RecordingTrackKind;
|
|
7635
|
+
type calls_RecordingTranscribeResponse = RecordingTranscribeResponse;
|
|
7636
|
+
type calls_TranscribeRecordingParams = TranscribeRecordingParams;
|
|
7637
|
+
type calls_TranscribeSegmentParams = TranscribeSegmentParams;
|
|
7638
|
+
type calls_TranscriptSegmentRef = TranscriptSegmentRef;
|
|
7639
|
+
declare const calls_WEBINAR_MODERATORS: typeof WEBINAR_MODERATORS;
|
|
7640
|
+
declare const calls_WEBINAR_TEAM: typeof WEBINAR_TEAM;
|
|
7641
|
+
type calls_WebinarChat = WebinarChat;
|
|
7642
|
+
type calls_WebinarRole = WebinarRole;
|
|
7643
|
+
type calls_WebinarState = WebinarState;
|
|
7644
|
+
type calls_WebinarUpdate = WebinarUpdate;
|
|
7645
|
+
declare const calls_askQuestion: typeof askQuestion;
|
|
7646
|
+
declare const calls_callError: typeof callError;
|
|
7647
|
+
declare const calls_cancelCall: typeof cancelCall;
|
|
7648
|
+
declare const calls_commitRecordingPart: typeof commitRecordingPart;
|
|
7649
|
+
declare const calls_createCall: typeof createCall;
|
|
7650
|
+
declare const calls_createCallInviteLink: typeof createCallInviteLink;
|
|
7651
|
+
declare const calls_createRecordingTrack: typeof createRecordingTrack;
|
|
7652
|
+
declare const calls_decideKnock: typeof decideKnock;
|
|
7653
|
+
declare const calls_declineCall: typeof declineCall;
|
|
7654
|
+
declare const calls_deleteQuestion: typeof deleteQuestion;
|
|
7655
|
+
declare const calls_deleteRecording: typeof deleteRecording;
|
|
7656
|
+
declare const calls_deleteRecordingMedia: typeof deleteRecordingMedia;
|
|
7657
|
+
declare const calls_demoteFromStage: typeof demoteFromStage;
|
|
7658
|
+
declare const calls_downloadRecordingPart: typeof downloadRecordingPart;
|
|
7659
|
+
declare const calls_fetchCallToken: typeof fetchCallToken;
|
|
7660
|
+
declare const calls_getCall: typeof getCall;
|
|
7661
|
+
declare const calls_getCallRecording: typeof getCallRecording;
|
|
7662
|
+
declare const calls_getCallsConfig: typeof getCallsConfig;
|
|
7663
|
+
declare const calls_getOrCreateCallChat: typeof getOrCreateCallChat;
|
|
7664
|
+
declare const calls_getRecordingQuota: typeof getRecordingQuota;
|
|
7665
|
+
declare const calls_getWebinar: typeof getWebinar;
|
|
7666
|
+
declare const calls_isQuotaError: typeof isQuotaError;
|
|
7667
|
+
declare const calls_knockCall: typeof knockCall;
|
|
7668
|
+
declare const calls_listCallInviteLinks: typeof listCallInviteLinks;
|
|
7669
|
+
declare const calls_listCallRecordings: typeof listCallRecordings;
|
|
7670
|
+
declare const calls_listQuestions: typeof listQuestions;
|
|
7671
|
+
declare const calls_muteCallParticipant: typeof muteCallParticipant;
|
|
7672
|
+
declare const calls_pollKnock: typeof pollKnock;
|
|
7673
|
+
declare const calls_postChatTranscriptLine: typeof postChatTranscriptLine;
|
|
7674
|
+
declare const calls_presignRecordingPart: typeof presignRecordingPart;
|
|
7675
|
+
declare const calls_promoteToStage: typeof promoteToStage;
|
|
7676
|
+
declare const calls_quotaNeedsWarning: typeof quotaNeedsWarning;
|
|
7677
|
+
declare const calls_recordingStateFrom: typeof recordingStateFrom;
|
|
7678
|
+
declare const calls_recordingStateOfCall: typeof recordingStateOfCall;
|
|
7679
|
+
declare const calls_removeCallParticipant: typeof removeCallParticipant;
|
|
7680
|
+
declare const calls_revokeCallInviteLink: typeof revokeCallInviteLink;
|
|
7681
|
+
declare const calls_ringCall: typeof ringCall;
|
|
7682
|
+
declare const calls_setCallTranscription: typeof setCallTranscription;
|
|
7683
|
+
declare const calls_setRecordingExpiry: typeof setRecordingExpiry;
|
|
7684
|
+
declare const calls_setWebinarHand: typeof setWebinarHand;
|
|
7685
|
+
declare const calls_startCallRecording: typeof startCallRecording;
|
|
7686
|
+
declare const calls_stopCallRecording: typeof stopCallRecording;
|
|
7687
|
+
declare const calls_transcribeCallSegment: typeof transcribeCallSegment;
|
|
7688
|
+
declare const calls_transcribeRecordingPart: typeof transcribeRecordingPart;
|
|
7689
|
+
declare const calls_transcriptionStateFrom: typeof transcriptionStateFrom;
|
|
7690
|
+
declare const calls_updateCall: typeof updateCall;
|
|
7691
|
+
declare const calls_updateQuestion: typeof updateQuestion;
|
|
7692
|
+
declare const calls_updateWebinar: typeof updateWebinar;
|
|
7693
|
+
declare const calls_voteQuestion: typeof voteQuestion;
|
|
7694
|
+
declare namespace calls {
|
|
7695
|
+
export { calls_CallApiError as CallApiError, type calls_CallChatCreate as CallChatCreate, type calls_CallChatResponse as CallChatResponse, type calls_CallCreate as CallCreate, type calls_CallDeclinedMessage as CallDeclinedMessage, type calls_CallEndedMessage as CallEndedMessage, type calls_CallInviteLinkCreate as CallInviteLinkCreate, type calls_CallInviteLinkResponse as CallInviteLinkResponse, type calls_CallJoinPolicy as CallJoinPolicy, type calls_CallKnockMessage as CallKnockMessage, type calls_CallKnockResolvedMessage as CallKnockResolvedMessage, type calls_CallKnockResponse as CallKnockResponse, calls_CallPeer as CallPeer, type calls_CallQuestion as CallQuestion, type calls_CallQuestionStatus as CallQuestionStatus, type calls_CallQuestionUpdate as CallQuestionUpdate, type calls_CallRecording as CallRecording, type calls_CallRecordingState as CallRecordingState, type calls_CallResponse as CallResponse, type calls_CallRingingMessage as CallRingingMessage, type calls_CallStartedMessage as CallStartedMessage, type calls_CallTokenResponse as CallTokenResponse, type calls_CallTranscribeResponse as CallTranscribeResponse, type calls_CallTranscriptionMessage as CallTranscriptionMessage, type calls_CallTranscriptionState as CallTranscriptionState, type calls_CallUpdate as CallUpdate, type calls_CallWebinarMessage as CallWebinarMessage, type calls_CallsConfig as CallsConfig, type calls_CreateTrackBody as CreateTrackBody, type calls_InviteeRole as InviteeRole, type calls_PartBody as PartBody, type calls_PartUpload as PartUpload, type calls_RecordingMode as RecordingMode, type calls_RecordingPart as RecordingPart, type calls_RecordingQuota as RecordingQuota, type calls_RecordingTrack as RecordingTrack, type calls_RecordingTrackKind as RecordingTrackKind, type calls_RecordingTranscribeResponse as RecordingTranscribeResponse, type calls_TranscribeRecordingParams as TranscribeRecordingParams, type calls_TranscribeSegmentParams as TranscribeSegmentParams, type calls_TranscriptSegmentRef as TranscriptSegmentRef, calls_WEBINAR_MODERATORS as WEBINAR_MODERATORS, calls_WEBINAR_TEAM as WEBINAR_TEAM, type calls_WebinarChat as WebinarChat, type calls_WebinarRole as WebinarRole, type calls_WebinarState as WebinarState, type calls_WebinarUpdate as WebinarUpdate, calls_askQuestion as askQuestion, calls_callError as callError, calls_cancelCall as cancelCall, calls_commitRecordingPart as commitRecordingPart, calls_createCall as createCall, calls_createCallInviteLink as createCallInviteLink, calls_createRecordingTrack as createRecordingTrack, calls_decideKnock as decideKnock, calls_declineCall as declineCall, calls_deleteQuestion as deleteQuestion, calls_deleteRecording as deleteRecording, calls_deleteRecordingMedia as deleteRecordingMedia, calls_demoteFromStage as demoteFromStage, calls_downloadRecordingPart as downloadRecordingPart, calls_fetchCallToken as fetchCallToken, calls_getCall as getCall, calls_getCallRecording as getCallRecording, calls_getCallsConfig as getCallsConfig, calls_getOrCreateCallChat as getOrCreateCallChat, calls_getRecordingQuota as getRecordingQuota, calls_getWebinar as getWebinar, calls_isQuotaError as isQuotaError, calls_knockCall as knockCall, calls_listCallInviteLinks as listCallInviteLinks, calls_listCallRecordings as listCallRecordings, calls_listQuestions as listQuestions, calls_muteCallParticipant as muteCallParticipant, calls_pollKnock as pollKnock, calls_postChatTranscriptLine as postChatTranscriptLine, calls_presignRecordingPart as presignRecordingPart, calls_promoteToStage as promoteToStage, calls_quotaNeedsWarning as quotaNeedsWarning, calls_recordingStateFrom as recordingStateFrom, calls_recordingStateOfCall as recordingStateOfCall, calls_removeCallParticipant as removeCallParticipant, calls_revokeCallInviteLink as revokeCallInviteLink, calls_ringCall as ringCall, calls_setCallTranscription as setCallTranscription, calls_setRecordingExpiry as setRecordingExpiry, calls_setWebinarHand as setWebinarHand, calls_startCallRecording as startCallRecording, calls_stopCallRecording as stopCallRecording, calls_transcribeCallSegment as transcribeCallSegment, calls_transcribeRecordingPart as transcribeRecordingPart, calls_transcriptionStateFrom as transcriptionStateFrom, calls_updateCall as updateCall, calls_updateQuestion as updateQuestion, calls_updateWebinar as updateWebinar, calls_voteQuestion as voteQuestion };
|
|
7696
|
+
}
|
|
7697
|
+
|
|
7169
7698
|
type DocUpdateRequest = components['schemas']['DocUpdateRequest'];
|
|
7170
7699
|
type WorkspaceUpdateRequest = components['schemas']['WorkspaceUpdateRequest'];
|
|
7171
7700
|
type TagFormat$1 = components['schemas']['TagFormat'];
|
|
7172
7701
|
type CitationSources$1 = components['schemas']['CitationSources'];
|
|
7173
7702
|
type UserSettingsUpdate = components['schemas']['UserSettingsUpdate'];
|
|
7174
7703
|
type ConfigUpdateData$1 = components['schemas']['ConfigUpdateData'];
|
|
7704
|
+
type WorkspaceOpenResponse = components['schemas']['WorkspaceOpenResponse'];
|
|
7175
7705
|
|
|
7176
7706
|
interface ArbiOptions {
|
|
7177
7707
|
/** Backend API URL (e.g. 'https://arbi.mycompany.com') */
|
|
@@ -7186,59 +7716,37 @@ interface ArbiOptions {
|
|
|
7186
7716
|
* the host's login and open workspace. A new host session or workspace is a new instance.
|
|
7187
7717
|
*/
|
|
7188
7718
|
session?: ArbiHostSession;
|
|
7719
|
+
/**
|
|
7720
|
+
* Keep this instance's signed-in session across reloads (a blocks-only site:
|
|
7721
|
+
* `browserSessionStateStorage()`); `restore()` then signs in again from it. Ignored with a host
|
|
7722
|
+
* `session`. Default: in memory, signed out on reload.
|
|
7723
|
+
*/
|
|
7724
|
+
sessionStorage?: SessionStateStorage;
|
|
7189
7725
|
}
|
|
7190
|
-
/** The host's
|
|
7726
|
+
/** The host's session, for an `Arbi` that runs on it (`ArbiOptions.session`). */
|
|
7191
7727
|
interface ArbiHostSession {
|
|
7192
|
-
/** The host's client
|
|
7728
|
+
/** The host's client: `createArbiClient({ session, persistence, sso })` on the host's state. */
|
|
7193
7729
|
client: ArbiClient;
|
|
7194
|
-
/** The login the host holds
|
|
7195
|
-
login: LoginResult;
|
|
7730
|
+
/** The login the host holds (the keys, the server session key, the profile); `null` signed out. */
|
|
7731
|
+
login: LoginResult | null;
|
|
7196
7732
|
/** The workspace the host has opened on the server, if any. */
|
|
7197
7733
|
workspaceId?: string | null;
|
|
7198
7734
|
}
|
|
7199
|
-
|
|
7200
|
-
|
|
7201
|
-
agentId?: string;
|
|
7202
|
-
/** Explicit workspace for an independent agent chat. */
|
|
7735
|
+
/** A turn to ask: {@link TurnRequest}, in the open workspace unless it names one. */
|
|
7736
|
+
type AskRequest = Omit<TurnRequest, 'workspaceId'> & {
|
|
7203
7737
|
workspaceId?: string;
|
|
7204
|
-
|
|
7205
|
-
|
|
7206
|
-
|
|
7207
|
-
|
|
7208
|
-
/** Previous response ID for follow-up questions */
|
|
7209
|
-
previousResponseId?: string | null;
|
|
7210
|
-
/** Existing task or conversation, including one with no previous response yet. */
|
|
7211
|
-
conversationId?: string;
|
|
7212
|
-
/** Mode for a newly created conversation. */
|
|
7213
|
-
assistantMode?: AssistantQueryOptions['assistantMode'];
|
|
7214
|
-
/** Workspace people and assistant mentions in the question. */
|
|
7215
|
-
mentions?: AssistantQueryOptions['mentions'];
|
|
7216
|
-
/** Model to use for generation */
|
|
7217
|
-
model?: string;
|
|
7218
|
-
/** Aborts the request and the stream; the returned promise rejects with an `AbortError`. */
|
|
7738
|
+
};
|
|
7739
|
+
/** What a caller hears while a turn streams. */
|
|
7740
|
+
interface AskHandlers extends Omit<SSEStreamCallbacks, 'onError' | 'onArbiError'> {
|
|
7741
|
+
/** Aborts the request and the stream; `ask` then rejects with an `AbortError`. */
|
|
7219
7742
|
signal?: AbortSignal;
|
|
7220
|
-
/**
|
|
7221
|
-
|
|
7222
|
-
|
|
7223
|
-
|
|
7224
|
-
|
|
7225
|
-
|
|
7226
|
-
|
|
7227
|
-
onError?: (message: string) => void;
|
|
7228
|
-
/** Called when a user message event is received */
|
|
7229
|
-
onUserMessage?: (data: UserMessageEvent) => void;
|
|
7230
|
-
/** Called when message metadata is received */
|
|
7231
|
-
onMetadata?: (data: MessageMetadataPayload$1) => void;
|
|
7232
|
-
/** Called when the agent requests user input */
|
|
7233
|
-
onUserInputRequest?: (data: UserInputRequestEvent) => void;
|
|
7234
|
-
/** Called when an artifact event is received */
|
|
7235
|
-
onArtifact?: (data: ArtifactEvent) => void;
|
|
7236
|
-
/** Called when the agent saved an email draft in the person's mailbox */
|
|
7237
|
-
onMailDraft?: (data: MailDraftSSEEvent) => void;
|
|
7238
|
-
/** Called when backend elapsed time is received */
|
|
7239
|
-
onElapsedTime?: (t: number) => void;
|
|
7240
|
-
/** Called when stream completes */
|
|
7241
|
-
onComplete?: () => void;
|
|
7743
|
+
/**
|
|
7744
|
+
* The turn failed: a string is the server's own report (it refused the turn, or failed it
|
|
7745
|
+
* mid-stream); an `Error` is the connection (the run may well go on on the server).
|
|
7746
|
+
*/
|
|
7747
|
+
onError?: (error: string | Error) => void;
|
|
7748
|
+
/** The project's AI usage is used up (refused with a 402, or cut off mid-stream). */
|
|
7749
|
+
onQuotaExceeded?: (quota: QuotaExceeded) => void;
|
|
7242
7750
|
}
|
|
7243
7751
|
declare class Arbi {
|
|
7244
7752
|
private client;
|
|
@@ -7246,15 +7754,13 @@ declare class Arbi {
|
|
|
7246
7754
|
private userProfile;
|
|
7247
7755
|
private readonly profileListeners;
|
|
7248
7756
|
private currentWorkspaceId;
|
|
7249
|
-
/** Wrapped workspace keys seen in the last list/create, so selecting needs no re-fetch. */
|
|
7250
|
-
private readonly wrappedKeys;
|
|
7251
|
-
/** Workspaces whose key this server session holds (`workspaces.open`), keyed per session key. */
|
|
7252
|
-
private readonly openedWorkspaces;
|
|
7253
|
-
private openedForSessionKey;
|
|
7254
7757
|
private chatCryptoContext;
|
|
7255
7758
|
/** The chat keys I hold, opened once per set of epochs (`chatRingSignature`). */
|
|
7256
7759
|
private chatRings;
|
|
7257
7760
|
private readonly sessionExpiredListeners;
|
|
7761
|
+
private readonly signedInListeners;
|
|
7762
|
+
/** The client is this instance's own (`init`), not a host's (`options.session`). */
|
|
7763
|
+
private ownsClient;
|
|
7258
7764
|
private readonly options;
|
|
7259
7765
|
constructor(options: ArbiOptions);
|
|
7260
7766
|
/**
|
|
@@ -7266,51 +7772,97 @@ declare class Arbi {
|
|
|
7266
7772
|
/** Initialize the SDK client and sodium crypto. Called automatically by login(). */
|
|
7267
7773
|
init(): Promise<ArbiClient>;
|
|
7268
7774
|
/**
|
|
7269
|
-
* Request a verification email for registration.
|
|
7270
|
-
*
|
|
7775
|
+
* Request a verification email for registration. The user will receive an email with a link and
|
|
7776
|
+
* a 3-word verification code. Resolves to the server's confirmation; throws with its `detail`.
|
|
7271
7777
|
*/
|
|
7272
|
-
requestVerification(email: string): Promise<
|
|
7778
|
+
requestVerification(email: string): Promise<string>;
|
|
7273
7779
|
/**
|
|
7274
|
-
* Register a new account
|
|
7780
|
+
* Register a new account with the verification code received by email (or, for an SSO account,
|
|
7781
|
+
* the provider's token as `verificationCode`). Resolves to the new identity key, for the recovery
|
|
7782
|
+
* key backup. Does not sign in: `login` follows.
|
|
7275
7783
|
*/
|
|
7276
|
-
register(params:
|
|
7277
|
-
|
|
7278
|
-
|
|
7279
|
-
|
|
7280
|
-
|
|
7281
|
-
|
|
7282
|
-
|
|
7784
|
+
register(params: RegisterParams): Promise<RegisterResult>;
|
|
7785
|
+
/**
|
|
7786
|
+
* Log in with email and password (and the SSO provider's token for an SSO account). Signs the
|
|
7787
|
+
* session in; resolves to the login, its response included. Initializes the client if needed.
|
|
7788
|
+
*/
|
|
7789
|
+
login(email: string, password: string, options?: Pick<LoginParams, 'ssoToken' | 'profile'>): Promise<LoginResult>;
|
|
7790
|
+
/** This instance signed in (`login`, `loginWithKey`, `restore`, an SSO sign-in). */
|
|
7791
|
+
private signedIn;
|
|
7792
|
+
/**
|
|
7793
|
+
* Be told when this instance signs in, by whatever path (a sign-in page, a restored session).
|
|
7794
|
+
* Returns an unsubscribe.
|
|
7795
|
+
*/
|
|
7796
|
+
onSignedIn(listener: (login: LoginResult) => void): () => void;
|
|
7797
|
+
/**
|
|
7798
|
+
* Sign in on this device while offline: the password must open the identity saved here at the
|
|
7799
|
+
* last login (see `ArbiClient.auth.unlock`).
|
|
7800
|
+
*/
|
|
7801
|
+
unlock(email: string, password: string): Promise<void>;
|
|
7283
7802
|
/**
|
|
7284
|
-
*
|
|
7285
|
-
*
|
|
7803
|
+
* Single sign-on, after the provider (Auth0) signed the user in and handed over its token. The
|
|
7804
|
+
* account still has its own master password (the keys are derived from it); the provider's token
|
|
7805
|
+
* proves the identity:
|
|
7806
|
+
* - `status`: is there an account for this email, and how does it sign in (`new_user`,
|
|
7807
|
+
* `sso_exists`, `local_exists`), with the names the server knows;
|
|
7808
|
+
* - `register`: a new account (the token stands in for the verification code); resolves with the
|
|
7809
|
+
* identity key, for its backup; `login` follows (with the provider's name and picture);
|
|
7810
|
+
* - `login`: an SSO account signs in; `link`: a password account signs in with the token and is
|
|
7811
|
+
* linked to SSO from then on;
|
|
7812
|
+
* - `resendVerification`: the provider's verification email again (its user id).
|
|
7286
7813
|
*/
|
|
7287
|
-
|
|
7814
|
+
readonly sso: {
|
|
7815
|
+
status: (params: {
|
|
7816
|
+
token: string;
|
|
7817
|
+
email: string;
|
|
7818
|
+
picture?: string | null;
|
|
7819
|
+
}) => Promise<components["schemas"]["SSOStatusResponse"]>;
|
|
7820
|
+
register: (params: {
|
|
7821
|
+
token: string;
|
|
7822
|
+
email: string;
|
|
7823
|
+
password: string;
|
|
7824
|
+
firstName: string;
|
|
7825
|
+
lastName: string;
|
|
7826
|
+
picture?: string | null;
|
|
7827
|
+
}) => Promise<RegisterResult>;
|
|
7828
|
+
login: (params: {
|
|
7829
|
+
token: string;
|
|
7830
|
+
email: string;
|
|
7831
|
+
password: string;
|
|
7832
|
+
profile?: LoginParams["profile"];
|
|
7833
|
+
}) => Promise<LoginResult>;
|
|
7834
|
+
link: (params: {
|
|
7835
|
+
token: string;
|
|
7836
|
+
email: string;
|
|
7837
|
+
password: string;
|
|
7838
|
+
}) => Promise<LoginResult>;
|
|
7839
|
+
resendVerification: (providerUserId: string) => Promise<string>;
|
|
7840
|
+
};
|
|
7288
7841
|
/**
|
|
7289
|
-
*
|
|
7290
|
-
*
|
|
7842
|
+
* Sign in with the account's identity key itself (a recovery key, a stored key; bytes or base64)
|
|
7843
|
+
* instead of the password. Resolves to the login, its response included.
|
|
7291
7844
|
*/
|
|
7292
|
-
loginWithKey(email: string,
|
|
7293
|
-
|
|
7294
|
-
|
|
7295
|
-
/** Remember the wrapped keys of workspaces the server just returned. */
|
|
7296
|
-
private rememberWorkspaces;
|
|
7845
|
+
loginWithKey(email: string, signingPrivateKey: Uint8Array | string, options?: {
|
|
7846
|
+
ssoToken?: string;
|
|
7847
|
+
}): Promise<LoginResult>;
|
|
7297
7848
|
/**
|
|
7298
|
-
*
|
|
7299
|
-
*
|
|
7849
|
+
* Sign in again from the session kept on this device (`sessionStorage`): the account signed in
|
|
7850
|
+
* last, with its identity key from the encrypted store. False, and the kept session dropped,
|
|
7851
|
+
* when there is none to restore.
|
|
7300
7852
|
*/
|
|
7301
|
-
|
|
7853
|
+
restore(): Promise<boolean>;
|
|
7302
7854
|
/**
|
|
7303
|
-
* Run `withKey` with the workspace's wrapped key
|
|
7304
|
-
* re-granted with a new key) is
|
|
7855
|
+
* Run `withKey` with the workspace's wrapped key (the client's, from the lists it has seen). A
|
|
7856
|
+
* remembered key that no longer works (access was re-granted with a new key) is read again and
|
|
7857
|
+
* the call retried once. Throws for a public workspace the user holds no key for.
|
|
7305
7858
|
*/
|
|
7306
7859
|
private withWrappedKey;
|
|
7307
7860
|
/** A workspace's key, sealed to the caller's own session (what `/open` and `POST /workspace/users` take). */
|
|
7308
7861
|
private sealWorkspaceKey;
|
|
7309
7862
|
/**
|
|
7310
7863
|
* Make a workspace usable for requests that name it, WITHOUT changing the current workspace (on
|
|
7311
|
-
* the server or here): its key, sealed to this server session, is deposited with `/prime-key
|
|
7312
|
-
*
|
|
7313
|
-
* request, and the current workspace is already open.
|
|
7864
|
+
* the server or here): its key, sealed to this server session, is deposited with `/prime-key`
|
|
7865
|
+
* (the client's `workspaceKeys.prime`: once per server session). The current workspace is open.
|
|
7314
7866
|
*/
|
|
7315
7867
|
private openWorkspace;
|
|
7316
7868
|
/** The workspace a call names, opened for this session; `undefined` for the current one. */
|
|
@@ -7318,27 +7870,43 @@ declare class Arbi {
|
|
|
7318
7870
|
/**
|
|
7319
7871
|
* Make a workspace the CURRENT one: decrypt its key, open it on the server (which makes it the
|
|
7320
7872
|
* session's active workspace) and record it in the session. This is navigation: only the host's
|
|
7321
|
-
* workspace switch calls it. Package code that needs
|
|
7322
|
-
* `workspaces.open(id)` and passes the workspace to the request instead.
|
|
7873
|
+
* workspace switch (`useSwitchWorkspace` in `@arbidocs/react`) calls it. Package code that needs
|
|
7874
|
+
* another workspace calls `workspaces.open(id)` and passes the workspace to the request instead.
|
|
7875
|
+
*
|
|
7876
|
+
* Returns what the server opened: the workspace with its conversations and tags (not its
|
|
7877
|
+
* documents, which are listed page by page). A public workspace has no key and opens without one.
|
|
7323
7878
|
*/
|
|
7324
|
-
selectWorkspace(workspaceId: string): Promise<
|
|
7879
|
+
selectWorkspace(workspaceId: string): Promise<WorkspaceOpenResponse>;
|
|
7325
7880
|
/**
|
|
7326
7881
|
* Subscribe to "the session cannot be recovered". Fires when a request failed with 401 or
|
|
7327
7882
|
* "No active workspace" and neither a workspace re-open nor a silent re-login was possible
|
|
7328
7883
|
* (the server refused; an unreachable server does not fire). The local session is already
|
|
7329
7884
|
* cleared when it fires: show "Your session expired, sign in again". Returns an unsubscribe.
|
|
7885
|
+
* On a host's session it is the host client's expiry.
|
|
7330
7886
|
*/
|
|
7331
7887
|
onSessionExpired(listener: () => void): () => void;
|
|
7332
7888
|
private expireSession;
|
|
7333
7889
|
/**
|
|
7334
7890
|
* Run a raw-fetch operation (streaming, multipart: no middleware) and, when it fails because
|
|
7335
7891
|
* the token expired or the server lost the open workspace, recover once and run it again.
|
|
7336
|
-
* `run` must read the auth headers itself so the retry carries the fresh token.
|
|
7892
|
+
* `run` must read the auth headers itself so the retry carries the fresh token. The client's
|
|
7893
|
+
* re-login is the one recovery: a refused one has already ended the session (`onSessionExpired`).
|
|
7337
7894
|
*/
|
|
7338
7895
|
private recovering;
|
|
7339
7896
|
private setUserProfile;
|
|
7340
|
-
/**
|
|
7341
|
-
|
|
7897
|
+
/**
|
|
7898
|
+
* Sign out: the server session ends (every session of the user with `everywhere`), the session
|
|
7899
|
+
* state is cleared and, with `everywhere`, so are the keys kept on this device (a single sign-out
|
|
7900
|
+
* keeps them for an offline unlock). Then this instance's own state is cleared.
|
|
7901
|
+
*/
|
|
7902
|
+
logout(options?: {
|
|
7903
|
+
everywhere?: boolean;
|
|
7904
|
+
}): Promise<void>;
|
|
7905
|
+
/**
|
|
7906
|
+
* The session state this instance runs on (token, user, SSO mode, signed in), to read and
|
|
7907
|
+
* subscribe to; `null` before a client exists.
|
|
7908
|
+
*/
|
|
7909
|
+
get session(): SessionManager | null;
|
|
7342
7910
|
/** Get the underlying ArbiClient (throws if not initialized). */
|
|
7343
7911
|
getClient(): ArbiClient;
|
|
7344
7912
|
/** Get the current workspace ID (throws if none selected). */
|
|
@@ -8631,6 +9199,7 @@ declare class Arbi {
|
|
|
8631
9199
|
encryption_public_key: string;
|
|
8632
9200
|
is_sso: boolean;
|
|
8633
9201
|
is_identity_verified: boolean;
|
|
9202
|
+
temporary_access_only: boolean;
|
|
8634
9203
|
can_create_projects: boolean;
|
|
8635
9204
|
is_deployment_admin: boolean;
|
|
8636
9205
|
user_type: components["schemas"]["UserRole"];
|
|
@@ -8842,6 +9411,17 @@ declare class Arbi {
|
|
|
8842
9411
|
* Idempotent and cached per server session. Navigation uses `selectWorkspace`.
|
|
8843
9412
|
*/
|
|
8844
9413
|
open: (workspaceId: string) => Promise<void>;
|
|
9414
|
+
/**
|
|
9415
|
+
* A workspace's key sealed to this server session: what `POST /workspace/users` takes to give
|
|
9416
|
+
* someone (an agent) access, and what `/prime-key` deposits. Throws when the user holds no key
|
|
9417
|
+
* for it (a public workspace, or one they can see but never joined).
|
|
9418
|
+
*/
|
|
9419
|
+
sealKey: (workspaceId: string) => Promise<string>;
|
|
9420
|
+
/**
|
|
9421
|
+
* A workspace's raw key, unwrapped with my identity (for content I encrypt under it myself,
|
|
9422
|
+
* such as a thread call's recording). Never sent anywhere.
|
|
9423
|
+
*/
|
|
9424
|
+
key: (workspaceId: string) => Promise<Uint8Array<ArrayBufferLike>>;
|
|
8845
9425
|
/** Hand this server session a workspace's key (sealed to the session) without opening it. */
|
|
8846
9426
|
primeKey: (workspaceExtId: string, sessionSealedKey: string) => Promise<void>;
|
|
8847
9427
|
list: () => Promise<{
|
|
@@ -8872,7 +9452,7 @@ declare class Arbi {
|
|
|
8872
9452
|
encryption_public_key: string;
|
|
8873
9453
|
is_sso: boolean;
|
|
8874
9454
|
is_identity_verified: boolean;
|
|
8875
|
-
temporary_access_only
|
|
9455
|
+
temporary_access_only: boolean;
|
|
8876
9456
|
};
|
|
8877
9457
|
role: components["schemas"]["WorkspaceRole"];
|
|
8878
9458
|
joined_at: string;
|
|
@@ -8923,7 +9503,7 @@ declare class Arbi {
|
|
|
8923
9503
|
encryption_public_key: string;
|
|
8924
9504
|
is_sso: boolean;
|
|
8925
9505
|
is_identity_verified: boolean;
|
|
8926
|
-
temporary_access_only
|
|
9506
|
+
temporary_access_only: boolean;
|
|
8927
9507
|
};
|
|
8928
9508
|
role: components["schemas"]["WorkspaceRole"];
|
|
8929
9509
|
joined_at: string;
|
|
@@ -8975,7 +9555,7 @@ declare class Arbi {
|
|
|
8975
9555
|
encryption_public_key: string;
|
|
8976
9556
|
is_sso: boolean;
|
|
8977
9557
|
is_identity_verified: boolean;
|
|
8978
|
-
temporary_access_only
|
|
9558
|
+
temporary_access_only: boolean;
|
|
8979
9559
|
};
|
|
8980
9560
|
role: components["schemas"]["WorkspaceRole"];
|
|
8981
9561
|
joined_at: string;
|
|
@@ -9009,7 +9589,7 @@ declare class Arbi {
|
|
|
9009
9589
|
encryption_public_key: string;
|
|
9010
9590
|
is_sso: boolean;
|
|
9011
9591
|
is_identity_verified: boolean;
|
|
9012
|
-
temporary_access_only
|
|
9592
|
+
temporary_access_only: boolean;
|
|
9013
9593
|
};
|
|
9014
9594
|
role: components["schemas"]["WorkspaceRole"];
|
|
9015
9595
|
joined_at: string;
|
|
@@ -9057,7 +9637,7 @@ declare class Arbi {
|
|
|
9057
9637
|
encryption_public_key: string;
|
|
9058
9638
|
is_sso: boolean;
|
|
9059
9639
|
is_identity_verified: boolean;
|
|
9060
|
-
temporary_access_only
|
|
9640
|
+
temporary_access_only: boolean;
|
|
9061
9641
|
};
|
|
9062
9642
|
role: components["schemas"]["WorkspaceRole"];
|
|
9063
9643
|
joined_at: string;
|
|
@@ -9083,7 +9663,7 @@ declare class Arbi {
|
|
|
9083
9663
|
encryption_public_key: string;
|
|
9084
9664
|
is_sso: boolean;
|
|
9085
9665
|
is_identity_verified: boolean;
|
|
9086
|
-
temporary_access_only
|
|
9666
|
+
temporary_access_only: boolean;
|
|
9087
9667
|
};
|
|
9088
9668
|
role: components["schemas"]["WorkspaceRole"];
|
|
9089
9669
|
joined_at: string;
|
|
@@ -9116,7 +9696,7 @@ declare class Arbi {
|
|
|
9116
9696
|
encryption_public_key: string;
|
|
9117
9697
|
is_sso: boolean;
|
|
9118
9698
|
is_identity_verified: boolean;
|
|
9119
|
-
temporary_access_only
|
|
9699
|
+
temporary_access_only: boolean;
|
|
9120
9700
|
};
|
|
9121
9701
|
role: components["schemas"]["WorkspaceRole"];
|
|
9122
9702
|
joined_at: string;
|
|
@@ -9146,7 +9726,7 @@ declare class Arbi {
|
|
|
9146
9726
|
encryption_public_key: string;
|
|
9147
9727
|
is_sso: boolean;
|
|
9148
9728
|
is_identity_verified: boolean;
|
|
9149
|
-
temporary_access_only
|
|
9729
|
+
temporary_access_only: boolean;
|
|
9150
9730
|
};
|
|
9151
9731
|
role: components["schemas"]["WorkspaceRole"];
|
|
9152
9732
|
joined_at: string;
|
|
@@ -9172,7 +9752,7 @@ declare class Arbi {
|
|
|
9172
9752
|
encryption_public_key: string;
|
|
9173
9753
|
is_sso: boolean;
|
|
9174
9754
|
is_identity_verified: boolean;
|
|
9175
|
-
temporary_access_only
|
|
9755
|
+
temporary_access_only: boolean;
|
|
9176
9756
|
};
|
|
9177
9757
|
role: components["schemas"]["WorkspaceRole"];
|
|
9178
9758
|
joined_at: string;
|
|
@@ -9207,7 +9787,7 @@ declare class Arbi {
|
|
|
9207
9787
|
encryption_public_key: string;
|
|
9208
9788
|
is_sso: boolean;
|
|
9209
9789
|
is_identity_verified: boolean;
|
|
9210
|
-
temporary_access_only
|
|
9790
|
+
temporary_access_only: boolean;
|
|
9211
9791
|
};
|
|
9212
9792
|
recipient: {
|
|
9213
9793
|
external_id: string;
|
|
@@ -9219,7 +9799,7 @@ declare class Arbi {
|
|
|
9219
9799
|
encryption_public_key: string;
|
|
9220
9800
|
is_sso: boolean;
|
|
9221
9801
|
is_identity_verified: boolean;
|
|
9222
|
-
temporary_access_only
|
|
9802
|
+
temporary_access_only: boolean;
|
|
9223
9803
|
};
|
|
9224
9804
|
workspace_ext_id?: string | null | undefined;
|
|
9225
9805
|
content?: string | null | undefined;
|
|
@@ -9246,6 +9826,134 @@ declare class Arbi {
|
|
|
9246
9826
|
skipped: boolean;
|
|
9247
9827
|
}[];
|
|
9248
9828
|
}>;
|
|
9829
|
+
/**
|
|
9830
|
+
* Download, copy or move a scope of the current workspace (`/v1/workspace/transfer*`): plan it,
|
|
9831
|
+
* run a copy or move into another workspace as a background job (its key is sealed here), follow,
|
|
9832
|
+
* resume or cancel the job, or export the scope's data for a download.
|
|
9833
|
+
*/
|
|
9834
|
+
transfer: {
|
|
9835
|
+
plan: (scope: TransferScope, mode: TransferMode) => Promise<{
|
|
9836
|
+
counts: {
|
|
9837
|
+
[key: string]: number;
|
|
9838
|
+
};
|
|
9839
|
+
added: {
|
|
9840
|
+
[key: string]: number;
|
|
9841
|
+
};
|
|
9842
|
+
relations_inside: number;
|
|
9843
|
+
relations_outside: number;
|
|
9844
|
+
dangling_references: number;
|
|
9845
|
+
not_removable: number;
|
|
9846
|
+
total_bytes: number;
|
|
9847
|
+
item_count: number;
|
|
9848
|
+
}>;
|
|
9849
|
+
start: (params: {
|
|
9850
|
+
scope: TransferScope;
|
|
9851
|
+
mode: TransferMode;
|
|
9852
|
+
targetWorkspaceId: string;
|
|
9853
|
+
onConflict?: TransferConflictPolicy;
|
|
9854
|
+
}) => Promise<{
|
|
9855
|
+
external_id: string;
|
|
9856
|
+
mode: components["schemas"]["TransferMode"];
|
|
9857
|
+
status: components["schemas"]["TransferStatus"];
|
|
9858
|
+
phase: components["schemas"]["TransferPhase"];
|
|
9859
|
+
source_workspace_ext_id?: string | null;
|
|
9860
|
+
target_workspace_ext_id?: string | null;
|
|
9861
|
+
total: number;
|
|
9862
|
+
processed: number;
|
|
9863
|
+
counts: {
|
|
9864
|
+
[key: string]: unknown;
|
|
9865
|
+
};
|
|
9866
|
+
error?: string | null;
|
|
9867
|
+
created_at: string;
|
|
9868
|
+
finished_at?: string | null;
|
|
9869
|
+
issues: components["schemas"]["TransferItemResult"][];
|
|
9870
|
+
}>;
|
|
9871
|
+
resume: (transferId: string, targetWorkspaceId: string) => Promise<{
|
|
9872
|
+
external_id: string;
|
|
9873
|
+
mode: components["schemas"]["TransferMode"];
|
|
9874
|
+
status: components["schemas"]["TransferStatus"];
|
|
9875
|
+
phase: components["schemas"]["TransferPhase"];
|
|
9876
|
+
source_workspace_ext_id?: string | null;
|
|
9877
|
+
target_workspace_ext_id?: string | null;
|
|
9878
|
+
total: number;
|
|
9879
|
+
processed: number;
|
|
9880
|
+
counts: {
|
|
9881
|
+
[key: string]: unknown;
|
|
9882
|
+
};
|
|
9883
|
+
error?: string | null;
|
|
9884
|
+
created_at: string;
|
|
9885
|
+
finished_at?: string | null;
|
|
9886
|
+
issues: components["schemas"]["TransferItemResult"][];
|
|
9887
|
+
}>;
|
|
9888
|
+
cancel: (transferId: string) => Promise<{
|
|
9889
|
+
external_id: string;
|
|
9890
|
+
mode: components["schemas"]["TransferMode"];
|
|
9891
|
+
status: components["schemas"]["TransferStatus"];
|
|
9892
|
+
phase: components["schemas"]["TransferPhase"];
|
|
9893
|
+
source_workspace_ext_id?: string | null | undefined;
|
|
9894
|
+
target_workspace_ext_id?: string | null | undefined;
|
|
9895
|
+
total: number;
|
|
9896
|
+
processed: number;
|
|
9897
|
+
counts: {
|
|
9898
|
+
[x: string]: unknown;
|
|
9899
|
+
};
|
|
9900
|
+
error?: string | null | undefined;
|
|
9901
|
+
created_at: string;
|
|
9902
|
+
finished_at?: string | null | undefined;
|
|
9903
|
+
issues: {
|
|
9904
|
+
kind: string;
|
|
9905
|
+
source_ext_id: string;
|
|
9906
|
+
target_ext_id?: string | null | undefined;
|
|
9907
|
+
status: components["schemas"]["TransferItemStatus"];
|
|
9908
|
+
message?: string | null | undefined;
|
|
9909
|
+
}[];
|
|
9910
|
+
}>;
|
|
9911
|
+
get: (transferId: string) => Promise<{
|
|
9912
|
+
external_id: string;
|
|
9913
|
+
mode: components["schemas"]["TransferMode"];
|
|
9914
|
+
status: components["schemas"]["TransferStatus"];
|
|
9915
|
+
phase: components["schemas"]["TransferPhase"];
|
|
9916
|
+
source_workspace_ext_id?: string | null;
|
|
9917
|
+
target_workspace_ext_id?: string | null;
|
|
9918
|
+
total: number;
|
|
9919
|
+
processed: number;
|
|
9920
|
+
counts: {
|
|
9921
|
+
[key: string]: unknown;
|
|
9922
|
+
};
|
|
9923
|
+
error?: string | null;
|
|
9924
|
+
created_at: string;
|
|
9925
|
+
finished_at?: string | null;
|
|
9926
|
+
issues: components["schemas"]["TransferItemResult"][];
|
|
9927
|
+
}>;
|
|
9928
|
+
list: () => Promise<{
|
|
9929
|
+
external_id: string;
|
|
9930
|
+
mode: components["schemas"]["TransferMode"];
|
|
9931
|
+
status: components["schemas"]["TransferStatus"];
|
|
9932
|
+
phase: components["schemas"]["TransferPhase"];
|
|
9933
|
+
source_workspace_ext_id?: string | null;
|
|
9934
|
+
target_workspace_ext_id?: string | null;
|
|
9935
|
+
total: number;
|
|
9936
|
+
processed: number;
|
|
9937
|
+
counts: {
|
|
9938
|
+
[key: string]: unknown;
|
|
9939
|
+
};
|
|
9940
|
+
error?: string | null;
|
|
9941
|
+
created_at: string;
|
|
9942
|
+
finished_at?: string | null;
|
|
9943
|
+
issues: components["schemas"]["TransferItemResult"][];
|
|
9944
|
+
}[]>;
|
|
9945
|
+
exportData: (scope: TransferScope) => Promise<{
|
|
9946
|
+
manifest: {
|
|
9947
|
+
[key: string]: unknown;
|
|
9948
|
+
};
|
|
9949
|
+
data: {
|
|
9950
|
+
[key: string]: {
|
|
9951
|
+
[key: string]: unknown;
|
|
9952
|
+
}[];
|
|
9953
|
+
};
|
|
9954
|
+
files: components["schemas"]["ExportFile"][];
|
|
9955
|
+
}>;
|
|
9956
|
+
};
|
|
9249
9957
|
};
|
|
9250
9958
|
readonly documents: {
|
|
9251
9959
|
/** The current workspace's documents, or `options.workspaceId`'s (opened, not switched to). */
|
|
@@ -9258,6 +9966,7 @@ declare class Arbi {
|
|
|
9258
9966
|
status?: string | null | undefined;
|
|
9259
9967
|
error_message?: string | null | undefined;
|
|
9260
9968
|
failed_stage?: string | null | undefined;
|
|
9969
|
+
status_seq: number;
|
|
9261
9970
|
n_pages?: number | null | undefined;
|
|
9262
9971
|
n_chunks?: number | null | undefined;
|
|
9263
9972
|
tokens?: number | null | undefined;
|
|
@@ -9349,6 +10058,7 @@ declare class Arbi {
|
|
|
9349
10058
|
status?: string | null;
|
|
9350
10059
|
error_message?: string | null;
|
|
9351
10060
|
failed_stage?: string | null;
|
|
10061
|
+
status_seq: number;
|
|
9352
10062
|
n_pages?: number | null;
|
|
9353
10063
|
n_chunks?: number | null;
|
|
9354
10064
|
tokens?: number | null;
|
|
@@ -9391,6 +10101,7 @@ declare class Arbi {
|
|
|
9391
10101
|
status?: string | null;
|
|
9392
10102
|
error_message?: string | null;
|
|
9393
10103
|
failed_stage?: string | null;
|
|
10104
|
+
status_seq: number;
|
|
9394
10105
|
n_pages?: number | null;
|
|
9395
10106
|
n_chunks?: number | null;
|
|
9396
10107
|
tokens?: number | null;
|
|
@@ -9426,6 +10137,7 @@ declare class Arbi {
|
|
|
9426
10137
|
status?: string | null | undefined;
|
|
9427
10138
|
error_message?: string | null | undefined;
|
|
9428
10139
|
failed_stage?: string | null | undefined;
|
|
10140
|
+
status_seq: number;
|
|
9429
10141
|
n_pages?: number | null | undefined;
|
|
9430
10142
|
n_chunks?: number | null | undefined;
|
|
9431
10143
|
tokens?: number | null | undefined;
|
|
@@ -9533,6 +10245,7 @@ declare class Arbi {
|
|
|
9533
10245
|
status?: string | null | undefined;
|
|
9534
10246
|
error_message?: string | null | undefined;
|
|
9535
10247
|
failed_stage?: string | null | undefined;
|
|
10248
|
+
status_seq: number;
|
|
9536
10249
|
n_pages?: number | null | undefined;
|
|
9537
10250
|
n_chunks?: number | null | undefined;
|
|
9538
10251
|
tokens?: number | null | undefined;
|
|
@@ -10611,7 +11324,10 @@ declare class Arbi {
|
|
|
10611
11324
|
deleteMessage: (messageId: string) => Promise<{
|
|
10612
11325
|
detail: string;
|
|
10613
11326
|
}>;
|
|
10614
|
-
/**
|
|
11327
|
+
/**
|
|
11328
|
+
* Post a human comment (no assistant run) — see `postConversationMessage`. A thread in another
|
|
11329
|
+
* workspace than the current one works too: its key is handed to the session on demand.
|
|
11330
|
+
*/
|
|
10615
11331
|
postMessage: (body: PostMessageRequest) => Promise<{
|
|
10616
11332
|
role: "user" | "assistant" | "system";
|
|
10617
11333
|
content: string;
|
|
@@ -10834,7 +11550,7 @@ declare class Arbi {
|
|
|
10834
11550
|
encryption_public_key: string;
|
|
10835
11551
|
is_sso: boolean;
|
|
10836
11552
|
is_identity_verified: boolean;
|
|
10837
|
-
temporary_access_only
|
|
11553
|
+
temporary_access_only: boolean;
|
|
10838
11554
|
};
|
|
10839
11555
|
recipient: {
|
|
10840
11556
|
external_id: string;
|
|
@@ -10846,7 +11562,7 @@ declare class Arbi {
|
|
|
10846
11562
|
encryption_public_key: string;
|
|
10847
11563
|
is_sso: boolean;
|
|
10848
11564
|
is_identity_verified: boolean;
|
|
10849
|
-
temporary_access_only
|
|
11565
|
+
temporary_access_only: boolean;
|
|
10850
11566
|
};
|
|
10851
11567
|
workspace_ext_id?: string | null | undefined;
|
|
10852
11568
|
content?: string | null | undefined;
|
|
@@ -10875,7 +11591,40 @@ declare class Arbi {
|
|
|
10875
11591
|
unlockNative: () => Promise<void>;
|
|
10876
11592
|
};
|
|
10877
11593
|
readonly assistant: {
|
|
10878
|
-
|
|
11594
|
+
/**
|
|
11595
|
+
* Ask the assistant: send one turn (the body is `buildTurnRequest`) and stream it into
|
|
11596
|
+
* `handlers`. Resolves with the accumulated result when the stream ends.
|
|
11597
|
+
*
|
|
11598
|
+
* The token is renewed before a long stream starts and once on a 401. A refusal (402 quota,
|
|
11599
|
+
* 409, 503, …) reaches `onError` as the server's words, a 402 quota also `onQuotaExceeded`,
|
|
11600
|
+
* and `ask` rejects with it; a dropped connection reaches `onError` as the `Error` and rejects
|
|
11601
|
+
* with it; an abort just rejects.
|
|
11602
|
+
*/
|
|
11603
|
+
ask: (request: AskRequest, handlers?: AskHandlers) => Promise<SSEStreamResult>;
|
|
11604
|
+
/**
|
|
11605
|
+
* Attach to a running turn by its response id: replays its frames so far, then tails the live
|
|
11606
|
+
* ones until it ends. Rejects when the run is no longer active ("This run is no longer active.").
|
|
11607
|
+
*/
|
|
11608
|
+
attachRun: (responseId: string, handlers?: Omit<SSEStreamCallbacks, "onArbiError"> & {
|
|
11609
|
+
signal?: AbortSignal;
|
|
11610
|
+
}) => Promise<SSEStreamResult>;
|
|
11611
|
+
/**
|
|
11612
|
+
* Interject into a running turn: answer its question, steer it, or send a run-control command
|
|
11613
|
+
* (`/pause`, `/resume`, `/report`).
|
|
11614
|
+
*/
|
|
11615
|
+
interject: (assistantMessageExtId: string, answer: string) => Promise<unknown>;
|
|
11616
|
+
/** Stop a run on the server (closing its stream alone leaves it running). */
|
|
11617
|
+
cancel: (responseId: string) => Promise<void>;
|
|
11618
|
+
/** The backend's built-in slash commands (`/compact`, `/goal`, …), for a slash menu. */
|
|
11619
|
+
commands: () => Promise<{
|
|
11620
|
+
name: string;
|
|
11621
|
+
description: string;
|
|
11622
|
+
arg_hint: string;
|
|
11623
|
+
user_invocable: boolean;
|
|
11624
|
+
category: string;
|
|
11625
|
+
}[]>;
|
|
11626
|
+
/** Transcribe a voice recording to text (empty when no speech was found). */
|
|
11627
|
+
transcribe: (audio: Blob) => Promise<string>;
|
|
10879
11628
|
/** Start a durable background turn; task options make its thread a work item. */
|
|
10880
11629
|
submit: (question: string, options: Omit<SubmitBackgroundQueryOptions, keyof AuthHeaders | "workspaceId" | "question">) => Promise<{
|
|
10881
11630
|
id: string;
|
|
@@ -10912,15 +11661,6 @@ declare class Arbi {
|
|
|
10912
11661
|
} | null;
|
|
10913
11662
|
conversation_ext_id?: string | null;
|
|
10914
11663
|
}>;
|
|
10915
|
-
/**
|
|
10916
|
-
* Send a question to the RAG assistant with streaming support.
|
|
10917
|
-
* Returns the accumulated result after the stream completes.
|
|
10918
|
-
*/
|
|
10919
|
-
query: (question: string, options: QueryOptions) => Promise<SSEStreamResult>;
|
|
10920
|
-
/**
|
|
10921
|
-
* Respond to an agent's question during a human-in-the-loop workflow.
|
|
10922
|
-
*/
|
|
10923
|
-
respond: (assistantMessageExtId: string, answer: string) => Promise<unknown>;
|
|
10924
11664
|
/** The skills the caller can run (own + shared marketplace), metadata only. */
|
|
10925
11665
|
listSkills: (options?: {
|
|
10926
11666
|
includeHidden?: boolean;
|
|
@@ -12205,6 +12945,607 @@ declare class Arbi {
|
|
|
12205
12945
|
/** Fetch, decrypt and size-check one attachment. */
|
|
12206
12946
|
downloadAttachment: (file: ChatAttachmentFile) => Promise<Uint8Array<ArrayBufferLike>>;
|
|
12207
12947
|
};
|
|
12948
|
+
/** My copy of a call's key K from its row (sealed to me as creator or invitee), or null. */
|
|
12949
|
+
private callKeyOf;
|
|
12950
|
+
/** A call's title under K, in plaintext; null when it has none or it does not open. */
|
|
12951
|
+
private callTitleOf;
|
|
12952
|
+
/**
|
|
12953
|
+
* Calls (LiveKit): one call system for thread, chat (DM / group), contacts and scheduled calls.
|
|
12954
|
+
* Each call has one random key K made in the creator's process; the server and the media server
|
|
12955
|
+
* only ever hold it sealed to people (or in a link's fragment). `start`, `open`, `answer` and
|
|
12956
|
+
* `resetLink` do the key work and hand back K with the call; everything else moves ciphertext.
|
|
12957
|
+
*/
|
|
12958
|
+
readonly calls: {
|
|
12959
|
+
/** The deployment's calls config (`enabled`, `transcription_available`, …). */
|
|
12960
|
+
config: () => Promise<{
|
|
12961
|
+
enabled: boolean;
|
|
12962
|
+
experimental: boolean;
|
|
12963
|
+
default_join_policy: "invited" | "signed_in" | "open";
|
|
12964
|
+
transcription_available: boolean;
|
|
12965
|
+
}>;
|
|
12966
|
+
get: (callExtId: string) => Promise<{
|
|
12967
|
+
external_id: string;
|
|
12968
|
+
room_name: string;
|
|
12969
|
+
title?: string | null;
|
|
12970
|
+
creator_ext_id: string;
|
|
12971
|
+
creator_name: string;
|
|
12972
|
+
creator_encryption_public_key?: string | null;
|
|
12973
|
+
chat_ext_id?: string | null;
|
|
12974
|
+
meeting_conversation_ext_id?: string | null;
|
|
12975
|
+
log_conversation_ext_id?: string | null;
|
|
12976
|
+
locked_workspace_ext_id?: string | null;
|
|
12977
|
+
workspace_locked: boolean;
|
|
12978
|
+
locked: boolean;
|
|
12979
|
+
join_policy: "invited" | "signed_in" | "open";
|
|
12980
|
+
link_version: number;
|
|
12981
|
+
cancelled: boolean;
|
|
12982
|
+
started_at?: string | null;
|
|
12983
|
+
ended_at?: string | null;
|
|
12984
|
+
last_participants?: string[];
|
|
12985
|
+
created_at: string;
|
|
12986
|
+
my_sealed_key?: string | null;
|
|
12987
|
+
is_creator: boolean;
|
|
12988
|
+
created?: boolean | null;
|
|
12989
|
+
invitees?: components["schemas"]["CallInviteeResponse"][];
|
|
12990
|
+
participants?: components["schemas"]["CallParticipant"][];
|
|
12991
|
+
transcription?: components["schemas"]["CallTranscriptionState"] | null;
|
|
12992
|
+
recording?: components["schemas"]["CallRecordingState"] | null;
|
|
12993
|
+
link_path: string;
|
|
12994
|
+
mode: "call" | "webinar";
|
|
12995
|
+
webinar?: components["schemas"]["CallWebinarSummary"] | null;
|
|
12996
|
+
}>;
|
|
12997
|
+
/** Create a call row as is (a scheduled call's ciphertext made by the caller). */
|
|
12998
|
+
create: (body: CallCreate) => Promise<{
|
|
12999
|
+
external_id: string;
|
|
13000
|
+
room_name: string;
|
|
13001
|
+
title?: string | null;
|
|
13002
|
+
creator_ext_id: string;
|
|
13003
|
+
creator_name: string;
|
|
13004
|
+
creator_encryption_public_key?: string | null;
|
|
13005
|
+
chat_ext_id?: string | null;
|
|
13006
|
+
meeting_conversation_ext_id?: string | null;
|
|
13007
|
+
log_conversation_ext_id?: string | null;
|
|
13008
|
+
locked_workspace_ext_id?: string | null;
|
|
13009
|
+
workspace_locked: boolean;
|
|
13010
|
+
locked: boolean;
|
|
13011
|
+
join_policy: "invited" | "signed_in" | "open";
|
|
13012
|
+
link_version: number;
|
|
13013
|
+
cancelled: boolean;
|
|
13014
|
+
started_at?: string | null;
|
|
13015
|
+
ended_at?: string | null;
|
|
13016
|
+
last_participants?: string[];
|
|
13017
|
+
created_at: string;
|
|
13018
|
+
my_sealed_key?: string | null;
|
|
13019
|
+
is_creator: boolean;
|
|
13020
|
+
created?: boolean | null;
|
|
13021
|
+
invitees?: components["schemas"]["CallInviteeResponse"][];
|
|
13022
|
+
participants?: components["schemas"]["CallParticipant"][];
|
|
13023
|
+
transcription?: components["schemas"]["CallTranscriptionState"] | null;
|
|
13024
|
+
recording?: components["schemas"]["CallRecordingState"] | null;
|
|
13025
|
+
link_path: string;
|
|
13026
|
+
mode: "call" | "webinar";
|
|
13027
|
+
webinar?: components["schemas"]["CallWebinarSummary"] | null;
|
|
13028
|
+
}>;
|
|
13029
|
+
update: (callExtId: string, body: CallUpdate) => Promise<{
|
|
13030
|
+
external_id: string;
|
|
13031
|
+
room_name: string;
|
|
13032
|
+
title?: string | null;
|
|
13033
|
+
creator_ext_id: string;
|
|
13034
|
+
creator_name: string;
|
|
13035
|
+
creator_encryption_public_key?: string | null;
|
|
13036
|
+
chat_ext_id?: string | null;
|
|
13037
|
+
meeting_conversation_ext_id?: string | null;
|
|
13038
|
+
log_conversation_ext_id?: string | null;
|
|
13039
|
+
locked_workspace_ext_id?: string | null;
|
|
13040
|
+
workspace_locked: boolean;
|
|
13041
|
+
locked: boolean;
|
|
13042
|
+
join_policy: "invited" | "signed_in" | "open";
|
|
13043
|
+
link_version: number;
|
|
13044
|
+
cancelled: boolean;
|
|
13045
|
+
started_at?: string | null;
|
|
13046
|
+
ended_at?: string | null;
|
|
13047
|
+
last_participants?: string[];
|
|
13048
|
+
created_at: string;
|
|
13049
|
+
my_sealed_key?: string | null;
|
|
13050
|
+
is_creator: boolean;
|
|
13051
|
+
created?: boolean | null;
|
|
13052
|
+
invitees?: components["schemas"]["CallInviteeResponse"][];
|
|
13053
|
+
participants?: components["schemas"]["CallParticipant"][];
|
|
13054
|
+
transcription?: components["schemas"]["CallTranscriptionState"] | null;
|
|
13055
|
+
recording?: components["schemas"]["CallRecordingState"] | null;
|
|
13056
|
+
link_path: string;
|
|
13057
|
+
mode: "call" | "webinar";
|
|
13058
|
+
webinar?: components["schemas"]["CallWebinarSummary"] | null;
|
|
13059
|
+
}>;
|
|
13060
|
+
cancel: (callExtId: string) => Promise<void>;
|
|
13061
|
+
/**
|
|
13062
|
+
* Start a call: a fresh K sealed to me and to each of `invitees` (people without a key are
|
|
13063
|
+
* skipped), the title under K. Returns K and `sealedKeys` (K per invitee: what `ring` takes).
|
|
13064
|
+
* A thread call is get-or-create: when the thread already has a running call, that one comes
|
|
13065
|
+
* back with my copy of its key, and `sealedKeys` are sealed to its key instead.
|
|
13066
|
+
*
|
|
13067
|
+
* A scheduled call has no thread or chat; a webinar (`mode: 'webinar'`) gives each invitee
|
|
13068
|
+
* their `roles` entry (attendee by default).
|
|
13069
|
+
*/
|
|
13070
|
+
start: (params: {
|
|
13071
|
+
threadExtId?: string | null;
|
|
13072
|
+
chatExtId?: string | null;
|
|
13073
|
+
title?: string | null;
|
|
13074
|
+
invitees: readonly CallPeer[];
|
|
13075
|
+
mode?: CallCreate["mode"];
|
|
13076
|
+
joinPolicy?: CallJoinPolicy;
|
|
13077
|
+
roles?: Record<string, InviteeRole>;
|
|
13078
|
+
}) => Promise<{
|
|
13079
|
+
call: {
|
|
13080
|
+
external_id: string;
|
|
13081
|
+
room_name: string;
|
|
13082
|
+
title?: string | null;
|
|
13083
|
+
creator_ext_id: string;
|
|
13084
|
+
creator_name: string;
|
|
13085
|
+
creator_encryption_public_key?: string | null;
|
|
13086
|
+
chat_ext_id?: string | null;
|
|
13087
|
+
meeting_conversation_ext_id?: string | null;
|
|
13088
|
+
log_conversation_ext_id?: string | null;
|
|
13089
|
+
locked_workspace_ext_id?: string | null;
|
|
13090
|
+
workspace_locked: boolean;
|
|
13091
|
+
locked: boolean;
|
|
13092
|
+
join_policy: "invited" | "signed_in" | "open";
|
|
13093
|
+
link_version: number;
|
|
13094
|
+
cancelled: boolean;
|
|
13095
|
+
started_at?: string | null;
|
|
13096
|
+
ended_at?: string | null;
|
|
13097
|
+
last_participants?: string[];
|
|
13098
|
+
created_at: string;
|
|
13099
|
+
my_sealed_key?: string | null;
|
|
13100
|
+
is_creator: boolean;
|
|
13101
|
+
created?: boolean | null;
|
|
13102
|
+
invitees?: components["schemas"]["CallInviteeResponse"][];
|
|
13103
|
+
participants?: components["schemas"]["CallParticipant"][];
|
|
13104
|
+
transcription?: components["schemas"]["CallTranscriptionState"] | null;
|
|
13105
|
+
recording?: components["schemas"]["CallRecordingState"] | null;
|
|
13106
|
+
link_path: string;
|
|
13107
|
+
mode: "call" | "webinar";
|
|
13108
|
+
webinar?: components["schemas"]["CallWebinarSummary"] | null;
|
|
13109
|
+
};
|
|
13110
|
+
key: Uint8Array<ArrayBufferLike>;
|
|
13111
|
+
title: string | null;
|
|
13112
|
+
sealedKeys: Record<string, string>;
|
|
13113
|
+
}>;
|
|
13114
|
+
/**
|
|
13115
|
+
* Open a call by id (a link, the calendar, a notification): K from the link fragment when
|
|
13116
|
+
* given, else my sealed copy. Refuses a cancelled call and a call I hold no key for.
|
|
13117
|
+
*/
|
|
13118
|
+
open: (callExtId: string, linkKey?: Uint8Array | null) => Promise<{
|
|
13119
|
+
call: {
|
|
13120
|
+
external_id: string;
|
|
13121
|
+
room_name: string;
|
|
13122
|
+
title?: string | null;
|
|
13123
|
+
creator_ext_id: string;
|
|
13124
|
+
creator_name: string;
|
|
13125
|
+
creator_encryption_public_key?: string | null;
|
|
13126
|
+
chat_ext_id?: string | null;
|
|
13127
|
+
meeting_conversation_ext_id?: string | null;
|
|
13128
|
+
log_conversation_ext_id?: string | null;
|
|
13129
|
+
locked_workspace_ext_id?: string | null;
|
|
13130
|
+
workspace_locked: boolean;
|
|
13131
|
+
locked: boolean;
|
|
13132
|
+
join_policy: "invited" | "signed_in" | "open";
|
|
13133
|
+
link_version: number;
|
|
13134
|
+
cancelled: boolean;
|
|
13135
|
+
started_at?: string | null;
|
|
13136
|
+
ended_at?: string | null;
|
|
13137
|
+
last_participants?: string[];
|
|
13138
|
+
created_at: string;
|
|
13139
|
+
my_sealed_key?: string | null;
|
|
13140
|
+
is_creator: boolean;
|
|
13141
|
+
created?: boolean | null;
|
|
13142
|
+
invitees?: components["schemas"]["CallInviteeResponse"][];
|
|
13143
|
+
participants?: components["schemas"]["CallParticipant"][];
|
|
13144
|
+
transcription?: components["schemas"]["CallTranscriptionState"] | null;
|
|
13145
|
+
recording?: components["schemas"]["CallRecordingState"] | null;
|
|
13146
|
+
link_path: string;
|
|
13147
|
+
mode: "call" | "webinar";
|
|
13148
|
+
webinar?: components["schemas"]["CallWebinarSummary"] | null;
|
|
13149
|
+
};
|
|
13150
|
+
key: Uint8Array<ArrayBufferLike>;
|
|
13151
|
+
title: string | null;
|
|
13152
|
+
}>;
|
|
13153
|
+
/** My copy of a call's K from its row, or null. */
|
|
13154
|
+
key: (call: {
|
|
13155
|
+
my_sealed_key?: string | null;
|
|
13156
|
+
}) => Promise<Uint8Array<ArrayBufferLike> | null>;
|
|
13157
|
+
/** A call's title in plaintext under K; null when it has none or it does not open. */
|
|
13158
|
+
title: (call: {
|
|
13159
|
+
title?: string | null;
|
|
13160
|
+
}, key: Uint8Array | null) => Promise<string | null>;
|
|
13161
|
+
/** K sealed to each peer with a key (not to me): what `ring` and invitations take. */
|
|
13162
|
+
sealFor: (key: Uint8Array, peers: readonly CallPeer[]) => Promise<Record<string, string>>;
|
|
13163
|
+
/** Answer a ring: open K from its sealed blob and fetch a room token. */
|
|
13164
|
+
answer: (ring: {
|
|
13165
|
+
call_ext_id: string;
|
|
13166
|
+
sealed_key: string;
|
|
13167
|
+
link_version: number;
|
|
13168
|
+
title?: string | null;
|
|
13169
|
+
}) => Promise<{
|
|
13170
|
+
key: Uint8Array<ArrayBufferLike>;
|
|
13171
|
+
token: {
|
|
13172
|
+
server_url: string;
|
|
13173
|
+
token: string;
|
|
13174
|
+
room_name: string;
|
|
13175
|
+
identity: string;
|
|
13176
|
+
call_ext_id: string;
|
|
13177
|
+
link_version: number;
|
|
13178
|
+
sealed_key?: string | null;
|
|
13179
|
+
title?: string | null;
|
|
13180
|
+
};
|
|
13181
|
+
title: string | null;
|
|
13182
|
+
}>;
|
|
13183
|
+
/**
|
|
13184
|
+
* A new link for a call I created: a fresh K re-sealed to me and every invitee with a key, the
|
|
13185
|
+
* title re-encrypted, and `link_version` bumped server-side so the old link stops working.
|
|
13186
|
+
*/
|
|
13187
|
+
resetLink: (call: Pick<CallResponse, "external_id">, title: string | null, invitees: readonly CallPeer[]) => Promise<{
|
|
13188
|
+
call: {
|
|
13189
|
+
external_id: string;
|
|
13190
|
+
room_name: string;
|
|
13191
|
+
title?: string | null;
|
|
13192
|
+
creator_ext_id: string;
|
|
13193
|
+
creator_name: string;
|
|
13194
|
+
creator_encryption_public_key?: string | null;
|
|
13195
|
+
chat_ext_id?: string | null;
|
|
13196
|
+
meeting_conversation_ext_id?: string | null;
|
|
13197
|
+
log_conversation_ext_id?: string | null;
|
|
13198
|
+
locked_workspace_ext_id?: string | null;
|
|
13199
|
+
workspace_locked: boolean;
|
|
13200
|
+
locked: boolean;
|
|
13201
|
+
join_policy: "invited" | "signed_in" | "open";
|
|
13202
|
+
link_version: number;
|
|
13203
|
+
cancelled: boolean;
|
|
13204
|
+
started_at?: string | null;
|
|
13205
|
+
ended_at?: string | null;
|
|
13206
|
+
last_participants?: string[];
|
|
13207
|
+
created_at: string;
|
|
13208
|
+
my_sealed_key?: string | null;
|
|
13209
|
+
is_creator: boolean;
|
|
13210
|
+
created?: boolean | null;
|
|
13211
|
+
invitees?: components["schemas"]["CallInviteeResponse"][];
|
|
13212
|
+
participants?: components["schemas"]["CallParticipant"][];
|
|
13213
|
+
transcription?: components["schemas"]["CallTranscriptionState"] | null;
|
|
13214
|
+
recording?: components["schemas"]["CallRecordingState"] | null;
|
|
13215
|
+
link_path: string;
|
|
13216
|
+
mode: "call" | "webinar";
|
|
13217
|
+
webinar?: components["schemas"]["CallWebinarSummary"] | null;
|
|
13218
|
+
};
|
|
13219
|
+
key: Uint8Array<ArrayBufferLike>;
|
|
13220
|
+
}>;
|
|
13221
|
+
/**
|
|
13222
|
+
* Make a call's E2E meeting chat now: a fresh chat key sealed to me and to every member, and K
|
|
13223
|
+
* sealed to each member so they can always join. The existing chat when the call has one.
|
|
13224
|
+
*/
|
|
13225
|
+
createChat: (params: {
|
|
13226
|
+
callExtId: string;
|
|
13227
|
+
callKey: Uint8Array;
|
|
13228
|
+
title?: string | null;
|
|
13229
|
+
members: readonly CallPeer[];
|
|
13230
|
+
}) => Promise<{
|
|
13231
|
+
call_ext_id: string;
|
|
13232
|
+
created: boolean;
|
|
13233
|
+
chat_ext_id?: string | null;
|
|
13234
|
+
meeting_conversation_ext_id?: string | null;
|
|
13235
|
+
workspace_ext_id?: string | null;
|
|
13236
|
+
}>;
|
|
13237
|
+
/** The call's meeting chat as is, made with `body` (an E2E chat) when it has none yet. */
|
|
13238
|
+
chat: (callExtId: string, body?: CallChatCreate | null) => Promise<{
|
|
13239
|
+
call_ext_id: string;
|
|
13240
|
+
created: boolean;
|
|
13241
|
+
chat_ext_id?: string | null;
|
|
13242
|
+
meeting_conversation_ext_id?: string | null;
|
|
13243
|
+
workspace_ext_id?: string | null;
|
|
13244
|
+
}>;
|
|
13245
|
+
/** A room token; `inviteToken` (a personal invite link's `?i=`) admits with no lobby. */
|
|
13246
|
+
token: (callExtId: string, linkVersion?: number | null, inviteToken?: string | null) => Promise<{
|
|
13247
|
+
server_url: string;
|
|
13248
|
+
token: string;
|
|
13249
|
+
room_name: string;
|
|
13250
|
+
identity: string;
|
|
13251
|
+
call_ext_id: string;
|
|
13252
|
+
link_version: number;
|
|
13253
|
+
sealed_key?: string | null;
|
|
13254
|
+
title?: string | null;
|
|
13255
|
+
}>;
|
|
13256
|
+
/** Ring users: `sealedKeys` maps each user ext id to K sealed to them (`sealFor`). */
|
|
13257
|
+
ring: (callExtId: string, sealedKeys: Record<string, string>, linkVersion?: number | null) => Promise<void>;
|
|
13258
|
+
decline: (callExtId: string) => Promise<void>;
|
|
13259
|
+
knock: (callExtId: string, linkVersion: number | null) => Promise<{
|
|
13260
|
+
knock_id: string;
|
|
13261
|
+
status: "pending" | "admitted" | "denied" | "expired";
|
|
13262
|
+
token?: components["schemas"]["CallTokenResponse"] | null;
|
|
13263
|
+
}>;
|
|
13264
|
+
pollKnock: (callExtId: string, knockId: string) => Promise<{
|
|
13265
|
+
knock_id: string;
|
|
13266
|
+
status: "pending" | "admitted" | "denied" | "expired";
|
|
13267
|
+
token?: components["schemas"]["CallTokenResponse"] | null;
|
|
13268
|
+
}>;
|
|
13269
|
+
/** A host admits or turns away someone in the lobby. */
|
|
13270
|
+
decideKnock: (callExtId: string, knockId: string, admit: boolean) => Promise<void>;
|
|
13271
|
+
removeParticipant: (callExtId: string, identity: string) => Promise<void>;
|
|
13272
|
+
muteParticipant: (callExtId: string, identity: string, track: "audio" | "video") => Promise<void>;
|
|
13273
|
+
/** Personal invite links for my unregistered contacts (register, then straight into the call). */
|
|
13274
|
+
inviteLinks: {
|
|
13275
|
+
create: (callExtId: string, body: CallInviteLinkCreate) => Promise<{
|
|
13276
|
+
external_id: string;
|
|
13277
|
+
call_ext_id: string;
|
|
13278
|
+
contact_ext_id?: string | null;
|
|
13279
|
+
email: string;
|
|
13280
|
+
invited_by_ext_id?: string | null;
|
|
13281
|
+
created_at: string;
|
|
13282
|
+
used_at?: string | null;
|
|
13283
|
+
revoked_at?: string | null;
|
|
13284
|
+
emailed?: boolean | null;
|
|
13285
|
+
}>;
|
|
13286
|
+
list: (callExtId: string) => Promise<{
|
|
13287
|
+
external_id: string;
|
|
13288
|
+
call_ext_id: string;
|
|
13289
|
+
contact_ext_id?: string | null;
|
|
13290
|
+
email: string;
|
|
13291
|
+
invited_by_ext_id?: string | null;
|
|
13292
|
+
created_at: string;
|
|
13293
|
+
used_at?: string | null;
|
|
13294
|
+
revoked_at?: string | null;
|
|
13295
|
+
emailed?: boolean | null;
|
|
13296
|
+
}[]>;
|
|
13297
|
+
revoke: (callExtId: string, inviteLinkExtId: string) => Promise<void>;
|
|
13298
|
+
};
|
|
13299
|
+
/** Live transcription: each client transcribes its own microphone; the host turns it on. */
|
|
13300
|
+
transcription: {
|
|
13301
|
+
set: (callExtId: string, on: boolean) => Promise<CallTranscriptionState | null>;
|
|
13302
|
+
transcribe: (callExtId: string, params: TranscribeSegmentParams) => Promise<{
|
|
13303
|
+
text: string;
|
|
13304
|
+
segment_id: string;
|
|
13305
|
+
speaker_identity: string;
|
|
13306
|
+
speaker_name: string;
|
|
13307
|
+
}>;
|
|
13308
|
+
/** Store an (already encrypted) line in an E2E chat, idempotent per `dedupe_key`. */
|
|
13309
|
+
postChatLine: (chatExtId: string, body: {
|
|
13310
|
+
content: string;
|
|
13311
|
+
key_version: number;
|
|
13312
|
+
dedupe_key: string;
|
|
13313
|
+
}) => Promise<{
|
|
13314
|
+
external_id: string;
|
|
13315
|
+
chat_ext_id: string;
|
|
13316
|
+
sender_ext_id?: string | null;
|
|
13317
|
+
kind: "text" | "call" | "system" | "transcript" | "recording";
|
|
13318
|
+
content?: string | null;
|
|
13319
|
+
key_version: number;
|
|
13320
|
+
attachments?: string | null;
|
|
13321
|
+
call_ext_id?: string | null;
|
|
13322
|
+
recording_ext_id?: string | null;
|
|
13323
|
+
dedupe_key?: string | null;
|
|
13324
|
+
deleted: boolean;
|
|
13325
|
+
workspace_ext_id?: string | null;
|
|
13326
|
+
context_only: boolean;
|
|
13327
|
+
conversation_ext_id?: string | null;
|
|
13328
|
+
created_at: string;
|
|
13329
|
+
updated_at: string;
|
|
13330
|
+
}>;
|
|
13331
|
+
};
|
|
13332
|
+
/** End-to-end encrypted recording: encrypted parts uploaded by each client, host-run. */
|
|
13333
|
+
recording: {
|
|
13334
|
+
quota: (callExtId: string) => Promise<{
|
|
13335
|
+
project_ext_id?: string | null;
|
|
13336
|
+
remaining_mb?: number | null;
|
|
13337
|
+
limit_mb?: number | null;
|
|
13338
|
+
near_limit: boolean;
|
|
13339
|
+
min_start_mb: number;
|
|
13340
|
+
}>;
|
|
13341
|
+
start: (callExtId: string, mode: RecordingMode) => Promise<{
|
|
13342
|
+
on: boolean;
|
|
13343
|
+
mode?: ("audio" | "audio_video") | null;
|
|
13344
|
+
recording_ext_id?: string | null;
|
|
13345
|
+
by_identity?: string | null;
|
|
13346
|
+
by_name?: string | null;
|
|
13347
|
+
reason?: string | null;
|
|
13348
|
+
started_at?: string | null;
|
|
13349
|
+
} | null>;
|
|
13350
|
+
stop: (callExtId: string) => Promise<{
|
|
13351
|
+
on: boolean;
|
|
13352
|
+
mode?: ("audio" | "audio_video") | null;
|
|
13353
|
+
recording_ext_id?: string | null;
|
|
13354
|
+
by_identity?: string | null;
|
|
13355
|
+
by_name?: string | null;
|
|
13356
|
+
reason?: string | null;
|
|
13357
|
+
started_at?: string | null;
|
|
13358
|
+
} | null>;
|
|
13359
|
+
createTrack: (callExtId: string, recordingExtId: string, body: CreateTrackBody) => Promise<{
|
|
13360
|
+
external_id: string;
|
|
13361
|
+
kind: "speaker" | "composite";
|
|
13362
|
+
speaker_ext_id?: string | null;
|
|
13363
|
+
speaker_name?: string | null;
|
|
13364
|
+
wrapped_key: string;
|
|
13365
|
+
key_version?: number | null;
|
|
13366
|
+
mime_type: string;
|
|
13367
|
+
created_at: string;
|
|
13368
|
+
parts?: components["schemas"]["CallRecordingPartResponse"][];
|
|
13369
|
+
}>;
|
|
13370
|
+
presignPart: (callExtId: string, recordingExtId: string, trackExtId: string, body: PartBody) => Promise<{
|
|
13371
|
+
seq: number;
|
|
13372
|
+
object_name: string;
|
|
13373
|
+
upload_url: string;
|
|
13374
|
+
headers?: {
|
|
13375
|
+
[key: string]: string;
|
|
13376
|
+
};
|
|
13377
|
+
expires_in: number;
|
|
13378
|
+
}>;
|
|
13379
|
+
commitPart: (callExtId: string, recordingExtId: string, trackExtId: string, seq: number) => Promise<void>;
|
|
13380
|
+
list: (callExtId: string) => Promise<{
|
|
13381
|
+
external_id: string;
|
|
13382
|
+
call_ext_id: string;
|
|
13383
|
+
mode: "audio" | "audio_video";
|
|
13384
|
+
state: "recording" | "stopped";
|
|
13385
|
+
started_by_ext_id?: string | null;
|
|
13386
|
+
started_by_name?: string | null;
|
|
13387
|
+
started_at: string;
|
|
13388
|
+
stopped_at?: string | null;
|
|
13389
|
+
expires_at?: string | null;
|
|
13390
|
+
media_deleted_at?: string | null;
|
|
13391
|
+
project_ext_id?: string | null;
|
|
13392
|
+
workspace_ext_id?: string | null;
|
|
13393
|
+
size_bytes: number;
|
|
13394
|
+
tracks?: components["schemas"]["CallRecordingTrackResponse"][];
|
|
13395
|
+
}[]>;
|
|
13396
|
+
get: (callExtId: string, recordingExtId: string) => Promise<{
|
|
13397
|
+
external_id: string;
|
|
13398
|
+
call_ext_id: string;
|
|
13399
|
+
mode: "audio" | "audio_video";
|
|
13400
|
+
state: "recording" | "stopped";
|
|
13401
|
+
started_by_ext_id?: string | null;
|
|
13402
|
+
started_by_name?: string | null;
|
|
13403
|
+
started_at: string;
|
|
13404
|
+
stopped_at?: string | null;
|
|
13405
|
+
expires_at?: string | null;
|
|
13406
|
+
media_deleted_at?: string | null;
|
|
13407
|
+
project_ext_id?: string | null;
|
|
13408
|
+
workspace_ext_id?: string | null;
|
|
13409
|
+
size_bytes: number;
|
|
13410
|
+
tracks?: components["schemas"]["CallRecordingTrackResponse"][];
|
|
13411
|
+
}>;
|
|
13412
|
+
setExpiry: (callExtId: string, recordingExtId: string, expiresAt: string | null) => Promise<{
|
|
13413
|
+
external_id: string;
|
|
13414
|
+
call_ext_id: string;
|
|
13415
|
+
mode: "audio" | "audio_video";
|
|
13416
|
+
state: "recording" | "stopped";
|
|
13417
|
+
started_by_ext_id?: string | null;
|
|
13418
|
+
started_by_name?: string | null;
|
|
13419
|
+
started_at: string;
|
|
13420
|
+
stopped_at?: string | null;
|
|
13421
|
+
expires_at?: string | null;
|
|
13422
|
+
media_deleted_at?: string | null;
|
|
13423
|
+
project_ext_id?: string | null;
|
|
13424
|
+
workspace_ext_id?: string | null;
|
|
13425
|
+
size_bytes: number;
|
|
13426
|
+
tracks?: components["schemas"]["CallRecordingTrackResponse"][];
|
|
13427
|
+
}>;
|
|
13428
|
+
deleteMedia: (callExtId: string, recordingExtId: string) => Promise<{
|
|
13429
|
+
external_id: string;
|
|
13430
|
+
call_ext_id: string;
|
|
13431
|
+
mode: "audio" | "audio_video";
|
|
13432
|
+
state: "recording" | "stopped";
|
|
13433
|
+
started_by_ext_id?: string | null;
|
|
13434
|
+
started_by_name?: string | null;
|
|
13435
|
+
started_at: string;
|
|
13436
|
+
stopped_at?: string | null;
|
|
13437
|
+
expires_at?: string | null;
|
|
13438
|
+
media_deleted_at?: string | null;
|
|
13439
|
+
project_ext_id?: string | null;
|
|
13440
|
+
workspace_ext_id?: string | null;
|
|
13441
|
+
size_bytes: number;
|
|
13442
|
+
tracks?: components["schemas"]["CallRecordingTrackResponse"][];
|
|
13443
|
+
}>;
|
|
13444
|
+
delete: (callExtId: string, recordingExtId: string) => Promise<void>;
|
|
13445
|
+
transcribe: (callExtId: string, recordingExtId: string, params: TranscribeRecordingParams) => Promise<{
|
|
13446
|
+
text: string;
|
|
13447
|
+
segment_id: string;
|
|
13448
|
+
track_ext_id: string;
|
|
13449
|
+
seq?: number | null;
|
|
13450
|
+
segment?: number | null;
|
|
13451
|
+
speaker_ext_id?: string | null;
|
|
13452
|
+
speaker_name?: string | null;
|
|
13453
|
+
offset_ms: number;
|
|
13454
|
+
}>;
|
|
13455
|
+
/** One part's ciphertext from its presigned GET. */
|
|
13456
|
+
downloadPart: (url: string) => Promise<Uint8Array<ArrayBufferLike>>;
|
|
13457
|
+
};
|
|
13458
|
+
/** Webinars: a call with `mode = 'webinar'`. `linkVersion` for a link holder not yet admitted. */
|
|
13459
|
+
webinar: {
|
|
13460
|
+
get: (callExtId: string, linkVersion?: number | null) => Promise<{
|
|
13461
|
+
live: boolean;
|
|
13462
|
+
live_at?: string | null;
|
|
13463
|
+
chat: "panelists" | "everyone";
|
|
13464
|
+
my_role: "host" | "cohost" | "panelist" | "attendee";
|
|
13465
|
+
on_stage: boolean;
|
|
13466
|
+
hand_raised: boolean;
|
|
13467
|
+
hands?: components["schemas"]["WebinarHand"][];
|
|
13468
|
+
attendees?: components["schemas"]["WebinarAttendee"][];
|
|
13469
|
+
}>;
|
|
13470
|
+
update: (callExtId: string, body: WebinarUpdate, linkVersion?: number | null) => Promise<{
|
|
13471
|
+
live: boolean;
|
|
13472
|
+
live_at?: string | null;
|
|
13473
|
+
chat: "panelists" | "everyone";
|
|
13474
|
+
my_role: "host" | "cohost" | "panelist" | "attendee";
|
|
13475
|
+
on_stage: boolean;
|
|
13476
|
+
hand_raised: boolean;
|
|
13477
|
+
hands?: components["schemas"]["WebinarHand"][];
|
|
13478
|
+
attendees?: components["schemas"]["WebinarAttendee"][];
|
|
13479
|
+
}>;
|
|
13480
|
+
setHand: (callExtId: string, raised: boolean, linkVersion?: number | null) => Promise<{
|
|
13481
|
+
live: boolean;
|
|
13482
|
+
live_at?: string | null;
|
|
13483
|
+
chat: "panelists" | "everyone";
|
|
13484
|
+
my_role: "host" | "cohost" | "panelist" | "attendee";
|
|
13485
|
+
on_stage: boolean;
|
|
13486
|
+
hand_raised: boolean;
|
|
13487
|
+
hands?: components["schemas"]["WebinarHand"][];
|
|
13488
|
+
attendees?: components["schemas"]["WebinarAttendee"][];
|
|
13489
|
+
}>;
|
|
13490
|
+
promote: (callExtId: string, identity: string, linkVersion?: number | null) => Promise<void>;
|
|
13491
|
+
demote: (callExtId: string, identity: string, linkVersion?: number | null) => Promise<void>;
|
|
13492
|
+
questions: {
|
|
13493
|
+
list: (callExtId: string, linkVersion?: number | null) => Promise<{
|
|
13494
|
+
external_id: string;
|
|
13495
|
+
body: string;
|
|
13496
|
+
status: "open" | "answering" | "answered" | "dismissed";
|
|
13497
|
+
answer?: string | null;
|
|
13498
|
+
answered_by_ext_id?: string | null;
|
|
13499
|
+
answered_at?: string | null;
|
|
13500
|
+
vote_count: number;
|
|
13501
|
+
voted: boolean;
|
|
13502
|
+
asker_ext_id?: string | null;
|
|
13503
|
+
mine: boolean;
|
|
13504
|
+
created_at: string;
|
|
13505
|
+
}[]>;
|
|
13506
|
+
ask: (callExtId: string, bodyCiphertext: string, linkVersion?: number | null) => Promise<{
|
|
13507
|
+
external_id: string;
|
|
13508
|
+
body: string;
|
|
13509
|
+
status: "open" | "answering" | "answered" | "dismissed";
|
|
13510
|
+
answer?: string | null;
|
|
13511
|
+
answered_by_ext_id?: string | null;
|
|
13512
|
+
answered_at?: string | null;
|
|
13513
|
+
vote_count: number;
|
|
13514
|
+
voted: boolean;
|
|
13515
|
+
asker_ext_id?: string | null;
|
|
13516
|
+
mine: boolean;
|
|
13517
|
+
created_at: string;
|
|
13518
|
+
}>;
|
|
13519
|
+
vote: (callExtId: string, questionExtId: string, up: boolean, linkVersion?: number | null) => Promise<{
|
|
13520
|
+
external_id: string;
|
|
13521
|
+
body: string;
|
|
13522
|
+
status: "open" | "answering" | "answered" | "dismissed";
|
|
13523
|
+
answer?: string | null;
|
|
13524
|
+
answered_by_ext_id?: string | null;
|
|
13525
|
+
answered_at?: string | null;
|
|
13526
|
+
vote_count: number;
|
|
13527
|
+
voted: boolean;
|
|
13528
|
+
asker_ext_id?: string | null;
|
|
13529
|
+
mine: boolean;
|
|
13530
|
+
created_at: string;
|
|
13531
|
+
}>;
|
|
13532
|
+
update: (callExtId: string, questionExtId: string, body: CallQuestionUpdate, linkVersion?: number | null) => Promise<{
|
|
13533
|
+
external_id: string;
|
|
13534
|
+
body: string;
|
|
13535
|
+
status: "open" | "answering" | "answered" | "dismissed";
|
|
13536
|
+
answer?: string | null;
|
|
13537
|
+
answered_by_ext_id?: string | null;
|
|
13538
|
+
answered_at?: string | null;
|
|
13539
|
+
vote_count: number;
|
|
13540
|
+
voted: boolean;
|
|
13541
|
+
asker_ext_id?: string | null;
|
|
13542
|
+
mine: boolean;
|
|
13543
|
+
created_at: string;
|
|
13544
|
+
}>;
|
|
13545
|
+
delete: (callExtId: string, questionExtId: string, linkVersion?: number | null) => Promise<void>;
|
|
13546
|
+
};
|
|
13547
|
+
};
|
|
13548
|
+
};
|
|
12208
13549
|
/** Direct-chat conveniences addressed by peer (email or `usr-`/`agt-` id). */
|
|
12209
13550
|
readonly dm: {
|
|
12210
13551
|
/**
|
|
@@ -12233,7 +13574,7 @@ declare class Arbi {
|
|
|
12233
13574
|
encryption_public_key: string;
|
|
12234
13575
|
is_sso: boolean;
|
|
12235
13576
|
is_identity_verified: boolean;
|
|
12236
|
-
temporary_access_only
|
|
13577
|
+
temporary_access_only: boolean;
|
|
12237
13578
|
};
|
|
12238
13579
|
recipient: {
|
|
12239
13580
|
external_id: string;
|
|
@@ -12245,7 +13586,7 @@ declare class Arbi {
|
|
|
12245
13586
|
encryption_public_key: string;
|
|
12246
13587
|
is_sso: boolean;
|
|
12247
13588
|
is_identity_verified: boolean;
|
|
12248
|
-
temporary_access_only
|
|
13589
|
+
temporary_access_only: boolean;
|
|
12249
13590
|
};
|
|
12250
13591
|
workspace_ext_id?: string | null | undefined;
|
|
12251
13592
|
content?: string | null | undefined;
|
|
@@ -12942,7 +14283,7 @@ declare class Arbi {
|
|
|
12942
14283
|
encryption_public_key: string;
|
|
12943
14284
|
is_sso: boolean;
|
|
12944
14285
|
is_identity_verified: boolean;
|
|
12945
|
-
temporary_access_only
|
|
14286
|
+
temporary_access_only: boolean;
|
|
12946
14287
|
}[]>;
|
|
12947
14288
|
create: (name: string) => Promise<{
|
|
12948
14289
|
external_id: string;
|
|
@@ -12954,6 +14295,7 @@ declare class Arbi {
|
|
|
12954
14295
|
encryption_public_key: string;
|
|
12955
14296
|
is_sso: boolean;
|
|
12956
14297
|
is_identity_verified: boolean;
|
|
14298
|
+
temporary_access_only: boolean;
|
|
12957
14299
|
signing_private_key: string;
|
|
12958
14300
|
}>;
|
|
12959
14301
|
getConfig: (agentExtId: string) => Promise<{
|
|
@@ -13826,7 +15168,7 @@ declare class Arbi {
|
|
|
13826
15168
|
currentId: () => string | null;
|
|
13827
15169
|
/** End one of your own sessions now (not the one this device is on: that is `logout`). */
|
|
13828
15170
|
terminate: (sessionId: string) => Promise<void>;
|
|
13829
|
-
/** Sign out of every device on the server, then clear this instance. */
|
|
15171
|
+
/** Sign out of every device on the server, then clear this instance and this device. */
|
|
13830
15172
|
logoutAll: () => Promise<void>;
|
|
13831
15173
|
};
|
|
13832
15174
|
private requireClient;
|
|
@@ -13908,7 +15250,7 @@ declare function listNotifications(arbi: ArbiClient): Promise<{
|
|
|
13908
15250
|
encryption_public_key: string;
|
|
13909
15251
|
is_sso: boolean;
|
|
13910
15252
|
is_identity_verified: boolean;
|
|
13911
|
-
temporary_access_only
|
|
15253
|
+
temporary_access_only: boolean;
|
|
13912
15254
|
};
|
|
13913
15255
|
recipient: {
|
|
13914
15256
|
external_id: string;
|
|
@@ -13920,7 +15262,7 @@ declare function listNotifications(arbi: ArbiClient): Promise<{
|
|
|
13920
15262
|
encryption_public_key: string;
|
|
13921
15263
|
is_sso: boolean;
|
|
13922
15264
|
is_identity_verified: boolean;
|
|
13923
|
-
temporary_access_only
|
|
15265
|
+
temporary_access_only: boolean;
|
|
13924
15266
|
};
|
|
13925
15267
|
workspace_ext_id?: string | null | undefined;
|
|
13926
15268
|
content?: string | null | undefined;
|
|
@@ -13953,7 +15295,7 @@ declare function listActivity(arbi: ArbiClient, options?: {
|
|
|
13953
15295
|
encryption_public_key: string;
|
|
13954
15296
|
is_sso: boolean;
|
|
13955
15297
|
is_identity_verified: boolean;
|
|
13956
|
-
temporary_access_only
|
|
15298
|
+
temporary_access_only: boolean;
|
|
13957
15299
|
};
|
|
13958
15300
|
recipient: {
|
|
13959
15301
|
external_id: string;
|
|
@@ -13965,7 +15307,7 @@ declare function listActivity(arbi: ArbiClient, options?: {
|
|
|
13965
15307
|
encryption_public_key: string;
|
|
13966
15308
|
is_sso: boolean;
|
|
13967
15309
|
is_identity_verified: boolean;
|
|
13968
|
-
temporary_access_only
|
|
15310
|
+
temporary_access_only: boolean;
|
|
13969
15311
|
};
|
|
13970
15312
|
workspace_ext_id?: string | null | undefined;
|
|
13971
15313
|
content?: string | null | undefined;
|
|
@@ -13988,7 +15330,7 @@ declare function markNotificationsRead(arbi: ArbiClient, ids: string[]): Promise
|
|
|
13988
15330
|
encryption_public_key: string;
|
|
13989
15331
|
is_sso: boolean;
|
|
13990
15332
|
is_identity_verified: boolean;
|
|
13991
|
-
temporary_access_only
|
|
15333
|
+
temporary_access_only: boolean;
|
|
13992
15334
|
};
|
|
13993
15335
|
recipient: {
|
|
13994
15336
|
external_id: string;
|
|
@@ -14000,7 +15342,7 @@ declare function markNotificationsRead(arbi: ArbiClient, ids: string[]): Promise
|
|
|
14000
15342
|
encryption_public_key: string;
|
|
14001
15343
|
is_sso: boolean;
|
|
14002
15344
|
is_identity_verified: boolean;
|
|
14003
|
-
temporary_access_only
|
|
15345
|
+
temporary_access_only: boolean;
|
|
14004
15346
|
};
|
|
14005
15347
|
workspace_ext_id?: string | null | undefined;
|
|
14006
15348
|
content?: string | null | undefined;
|
|
@@ -14041,7 +15383,7 @@ declare function requestWorkspaceAccess(arbi: ArbiClient, params: {
|
|
|
14041
15383
|
encryption_public_key: string;
|
|
14042
15384
|
is_sso: boolean;
|
|
14043
15385
|
is_identity_verified: boolean;
|
|
14044
|
-
temporary_access_only
|
|
15386
|
+
temporary_access_only: boolean;
|
|
14045
15387
|
};
|
|
14046
15388
|
recipient: {
|
|
14047
15389
|
external_id: string;
|
|
@@ -14053,7 +15395,7 @@ declare function requestWorkspaceAccess(arbi: ArbiClient, params: {
|
|
|
14053
15395
|
encryption_public_key: string;
|
|
14054
15396
|
is_sso: boolean;
|
|
14055
15397
|
is_identity_verified: boolean;
|
|
14056
|
-
temporary_access_only
|
|
15398
|
+
temporary_access_only: boolean;
|
|
14057
15399
|
};
|
|
14058
15400
|
workspace_ext_id?: string | null | undefined;
|
|
14059
15401
|
content?: string | null | undefined;
|
|
@@ -14621,6 +15963,32 @@ declare namespace mail {
|
|
|
14621
15963
|
export { type mail_ListMessagesOptions as ListMessagesOptions, type mail_MailAccount as MailAccount, type mail_MailAddress as MailAddress, type mail_MailAddressInput as MailAddressInput, type mail_MailAttachment as MailAttachment, type mail_MailCompose as MailCompose, type mail_MailDraftSaved as MailDraftSaved, type mail_MailFetch as MailFetch, type mail_MailFolder as MailFolder, type mail_MailMessage as MailMessage, type mail_MailMessagePage as MailMessagePage, type mail_MailMessageUpdate as MailMessageUpdate, type mail_MailPolicy as MailPolicy, type mail_MailSend as MailSend, type mail_MailSendResult as MailSendResult, mail_NATIVE_ACCOUNT as NATIVE_ACCOUNT, type mail_NativeMailKeys as NativeMailKeys, mail_attachmentFromBytes as attachmentFromBytes, mail_claimNativeAlias as claimNativeAlias, mail_claimSecureMail as claimSecureMail, mail_createMailFetch as createMailFetch, mail_downloadAttachment as downloadAttachment, mail_getMailPolicy as getMailPolicy, mail_getMessage as getMessage, mail_listFolders as listFolders, mail_listMailAccounts as listMailAccounts, mail_listMessages as listMessages, mail_saveDraft as saveDraft, mail_sendMessage as sendMessage, mail_unlockNativeMail as unlockNativeMail, mail_updateMessage as updateMessage };
|
|
14622
15964
|
}
|
|
14623
15965
|
|
|
15966
|
+
/**
|
|
15967
|
+
* The optional hints every transcription route takes (`/v1/assistant/transcribe`, a call's live
|
|
15968
|
+
* `/transcribe`, a recording's `/transcribe`): `language` (ISO-639-1) and `prompt` (≤ 500 chars, a
|
|
15969
|
+
* continuity hint).
|
|
15970
|
+
*/
|
|
15971
|
+
/** How much of the speaker's previous text is sent as the continuity prompt. */
|
|
15972
|
+
declare const PROMPT_CONTEXT_CHARS = 200;
|
|
15973
|
+
/**
|
|
15974
|
+
* The continuity prompt for the next clip of a speaker: the end (≤ {@link PROMPT_CONTEXT_CHARS}
|
|
15975
|
+
* characters, starting on a word) of what they said before, or undefined when there is nothing.
|
|
15976
|
+
* It keeps names, figures and currency consistent from one clip to the next.
|
|
15977
|
+
*
|
|
15978
|
+
* No route sends the browser's locale as the language: the language of the UI is not the language
|
|
15979
|
+
* spoken. Whisper detects the spoken language itself, anchored by this prompt; `language` is for a
|
|
15980
|
+
* caller that actually knows it.
|
|
15981
|
+
*/
|
|
15982
|
+
declare function continuityPrompt(previous: string | null | undefined): string | undefined;
|
|
15983
|
+
/**
|
|
15984
|
+
* Append the optional `language` (ISO-639-1) / `prompt` (≤ 500 chars) hints every transcription
|
|
15985
|
+
* route takes to a multipart body.
|
|
15986
|
+
*/
|
|
15987
|
+
declare function appendTranscriptionHints(form: FormData, hints: {
|
|
15988
|
+
language?: string | null;
|
|
15989
|
+
prompt?: string | null;
|
|
15990
|
+
}): void;
|
|
15991
|
+
|
|
14624
15992
|
/**
|
|
14625
15993
|
* Tag helpers: what kind of tag a tag is, how much carries it, which side of the workspace it is
|
|
14626
15994
|
* used on, and its hierarchy (labels and annotations nest one level; issues, people and
|
|
@@ -14756,14 +16124,11 @@ declare function listSessions(arbi: ArbiClient): Promise<SessionInfoResponse[]>;
|
|
|
14756
16124
|
* the logout flow's job, not this one's.
|
|
14757
16125
|
*/
|
|
14758
16126
|
declare function terminateSession(arbi: ArbiClient, sessionId: string): Promise<void>;
|
|
14759
|
-
/** Sign the user out of every device (all sessions, this one included) on the server. */
|
|
14760
|
-
declare function logoutAllSessions(arbi: ArbiClient): Promise<void>;
|
|
14761
16127
|
|
|
14762
16128
|
declare const sessions_listSessions: typeof listSessions;
|
|
14763
|
-
declare const sessions_logoutAllSessions: typeof logoutAllSessions;
|
|
14764
16129
|
declare const sessions_terminateSession: typeof terminateSession;
|
|
14765
16130
|
declare namespace sessions {
|
|
14766
|
-
export { sessions_listSessions as listSessions,
|
|
16131
|
+
export { sessions_listSessions as listSessions, sessions_terminateSession as terminateSession };
|
|
14767
16132
|
}
|
|
14768
16133
|
|
|
14769
16134
|
/**
|
|
@@ -14849,4 +16214,479 @@ declare namespace identity {
|
|
|
14849
16214
|
export { type identity_IdentityErrorCode as IdentityErrorCode, type identity_IdentityPurchase as IdentityPurchase, type identity_IdentityState as IdentityState, type identity_IdentityStatus as IdentityStatus, identity_acceptName as acceptName, identity_getStatus as getStatus, identity_identityErrorCode as identityErrorCode, identity_purchase as purchase, identity_refresh as refresh, identity_remove as remove, identity_startSession as startSession };
|
|
14850
16215
|
}
|
|
14851
16216
|
|
|
14852
|
-
|
|
16217
|
+
/**
|
|
16218
|
+
* The chat model's shapes: a stored message plus what the engine records on it while a turn runs.
|
|
16219
|
+
*/
|
|
16220
|
+
|
|
16221
|
+
/** A conversation thread: one root-to-leaf line of messages. */
|
|
16222
|
+
type Thread = components['schemas']['Thread'];
|
|
16223
|
+
type ThreadsResponse = components['schemas']['ThreadsResponse'];
|
|
16224
|
+
/** A message as the chat holds it: the stored message plus the engine's live state. */
|
|
16225
|
+
type ChatMessage = components['schemas']['MessageResponse'] & {
|
|
16226
|
+
isLoading?: boolean;
|
|
16227
|
+
isError?: boolean;
|
|
16228
|
+
is_branch_point?: boolean;
|
|
16229
|
+
/**
|
|
16230
|
+
* Follow-up query suggested by the backend (SUGGESTED_QUERIES config). Arrives on the
|
|
16231
|
+
* message_metadata SSE payload and is folded into the cached message by the completion spread;
|
|
16232
|
+
* the live copy the composer offers as a chip lives in the session, so this field documents the
|
|
16233
|
+
* cached shape rather than being a render source.
|
|
16234
|
+
*/
|
|
16235
|
+
suggested_query?: string | null;
|
|
16236
|
+
agentSteps?: AgentStepEvent[];
|
|
16237
|
+
/** Total stream elapsed time from response.completed (for last step duration on persisted messages) */
|
|
16238
|
+
agentStepsTotalElapsed?: number | null;
|
|
16239
|
+
/**
|
|
16240
|
+
* Final per-turn token/£ budget snapshot from response.completed — distinct from any individual
|
|
16241
|
+
* agent step's `context`: steps only cover `function_call`/`reasoning` items (see
|
|
16242
|
+
* output-item-reducer.ts), so a step-level context is always a mid-turn partial. This is the
|
|
16243
|
+
* true final total for the whole turn (all LLM calls, spent_gbp, budget_gbp).
|
|
16244
|
+
*/
|
|
16245
|
+
finalContextUsage?: AgentStepEvent['context'] | null;
|
|
16246
|
+
pendingUserInput?: UserInputRequestEvent | null;
|
|
16247
|
+
/**
|
|
16248
|
+
* Where the LIVE segment of a streaming body begins, in characters.
|
|
16249
|
+
*
|
|
16250
|
+
* Narration and the answer stream into one `content` string, so nothing in the text marks where
|
|
16251
|
+
* one output item ended and the next began. This is that boundary, stamped when the server
|
|
16252
|
+
* settles a narration item: everything before it is prose the model has already moved on from,
|
|
16253
|
+
* everything after is what is being written right now.
|
|
16254
|
+
*
|
|
16255
|
+
* Drives two things that were previously impossible with a single string — fading only the
|
|
16256
|
+
* superseded prose (never the text being read), and putting a real paragraph break between
|
|
16257
|
+
* items instead of hoping the model emitted one.
|
|
16258
|
+
*/
|
|
16259
|
+
settledNarrationLength?: number;
|
|
16260
|
+
meta?: {
|
|
16261
|
+
tools?: Record<string, components['schemas']['ModelCitationTool'] | components['schemas']['RetrievalChunkTool'] | components['schemas']['RetrievalFullContextTool'] | components['schemas']['RetrievalTOCTool'] | components['schemas']['CompactionTool'] | components['schemas']['StreamEventsTool']>;
|
|
16262
|
+
[key: string]: unknown;
|
|
16263
|
+
};
|
|
16264
|
+
};
|
|
16265
|
+
|
|
16266
|
+
/**
|
|
16267
|
+
* Responses output-item protocol v3 → internal step model (#2075).
|
|
16268
|
+
*
|
|
16269
|
+
* The wire speaks OpenAI Responses: every message and tool call is an
|
|
16270
|
+
* `output_item` with an opaque id. This module folds the `output_item.done`
|
|
16271
|
+
* stream into the `AgentStepEvent[]` shape the trace renderer already consumes,
|
|
16272
|
+
* so the display layer (and its ~3600 tests) is untouched and all protocol
|
|
16273
|
+
* logic lives in one place.
|
|
16274
|
+
*
|
|
16275
|
+
* `function_call` (tool call) and `reasoning` (goal / plan / goal check) items are
|
|
16276
|
+
* always trace items. A `message` item is body text — narration or the answer —
|
|
16277
|
+
* and is a trace row ONLY when the backend declares it one via `arbi.step`
|
|
16278
|
+
* (`answering`): the answer is a lifecycle moment with its own model and token
|
|
16279
|
+
* cost, and dropping it lost both from the UI. Its text stays out of the step (the
|
|
16280
|
+
* row reads "Answered — 5.1k"); the body renders it, not the trace. The internal
|
|
16281
|
+
* `index` is a display order derived from a step's id (one per id), never
|
|
16282
|
+
* something an event claims — the v3 point.
|
|
16283
|
+
*/
|
|
16284
|
+
|
|
16285
|
+
type ArbiMeta = components['schemas']['ArbiItemMeta'];
|
|
16286
|
+
type OutputTextContent = components['schemas']['OutputTextContent'];
|
|
16287
|
+
/** Structural shape covering all three Responses output-item types. */
|
|
16288
|
+
interface OutputItem {
|
|
16289
|
+
type: 'message' | 'function_call' | 'reasoning';
|
|
16290
|
+
id?: string;
|
|
16291
|
+
name?: string;
|
|
16292
|
+
summary?: OutputTextContent[];
|
|
16293
|
+
content?: OutputTextContent[];
|
|
16294
|
+
arbi?: ArbiMeta | null;
|
|
16295
|
+
}
|
|
16296
|
+
/** A settled output item from `response.output_item.done`. */
|
|
16297
|
+
interface OutputItemDone {
|
|
16298
|
+
item: OutputItem;
|
|
16299
|
+
/**
|
|
16300
|
+
* Seconds since stream start, stamped on the EVENT (not the item) by the
|
|
16301
|
+
* backend's central emitter. The trace derives every step's duration from the
|
|
16302
|
+
* gap to the next step's `t`, so it has to be lifted onto the step here — with
|
|
16303
|
+
* it dropped, v3 rendered a trace with no timings at all.
|
|
16304
|
+
*/
|
|
16305
|
+
t?: number | null;
|
|
16306
|
+
}
|
|
16307
|
+
/**
|
|
16308
|
+
* Is this settled item a trace row? Tool calls and reasoning always are. A
|
|
16309
|
+
* message is only when it declares a lifecycle step — the answer does, narration
|
|
16310
|
+
* doesn't.
|
|
16311
|
+
*/
|
|
16312
|
+
declare function isTraceItem(item: {
|
|
16313
|
+
type?: string;
|
|
16314
|
+
arbi?: ArbiMeta | null;
|
|
16315
|
+
}): boolean;
|
|
16316
|
+
/**
|
|
16317
|
+
* Fold one settled output item into the current step list, returning a new list.
|
|
16318
|
+
* Pure: the same reducer drives the live stream and the persisted-history replay,
|
|
16319
|
+
* so they cannot diverge. Message items are ignored (not trace steps).
|
|
16320
|
+
*/
|
|
16321
|
+
declare function reduceOutputItem(steps: AgentStepEvent[], ev: OutputItemDone, assignIndex: (id: string) => number, resolveIndex: (id: string) => number | undefined): AgentStepEvent[];
|
|
16322
|
+
/** id→index bookkeeping for one message's reduction (stable, first-seen order). */
|
|
16323
|
+
declare function createIndexAssigner(seed?: AgentStepEvent[]): {
|
|
16324
|
+
assign: (id: string) => number;
|
|
16325
|
+
resolve: (id: string) => number | undefined;
|
|
16326
|
+
};
|
|
16327
|
+
|
|
16328
|
+
interface HydratedAgentSteps {
|
|
16329
|
+
steps: AgentStepEvent[];
|
|
16330
|
+
/** Total stream elapsed time (from response.completed) — used for last step duration */
|
|
16331
|
+
totalElapsed: number | null;
|
|
16332
|
+
/** Final per-turn token/£ budget snapshot (from response.completed) */
|
|
16333
|
+
finalContext: ChatMessage['finalContextUsage'];
|
|
16334
|
+
}
|
|
16335
|
+
/**
|
|
16336
|
+
* Extracts agent steps from a message's persisted stream_events tool data.
|
|
16337
|
+
* Checks both direct tools (current format) and meta.tools (legacy format).
|
|
16338
|
+
* Returns undefined when no steps are found.
|
|
16339
|
+
*
|
|
16340
|
+
* Handles both wire versions: a message persisted after the v3 cutover carries
|
|
16341
|
+
* response.output_item.done events and is reduced through the live reducer; one
|
|
16342
|
+
* persisted before carries arbi.agent_step and takes the legacy path.
|
|
16343
|
+
*/
|
|
16344
|
+
declare function hydrateAgentSteps(message: ChatMessage): HydratedAgentSteps | undefined;
|
|
16345
|
+
|
|
16346
|
+
/**
|
|
16347
|
+
* How an agent step is *presented* — the single source of truth shared by the
|
|
16348
|
+
* live turn bar and the settled steps trace, so the two never disagree.
|
|
16349
|
+
*
|
|
16350
|
+
* The backend owns what a step *says* — it sends the step's semantic identity
|
|
16351
|
+
* (`step`, `focus`, `detail[].tool`, `outcome`) and its display `label`. This
|
|
16352
|
+
* module owns only how those are *arranged*: the label as a short headline, the
|
|
16353
|
+
* agent's narrative as a separate line (not mashed into the label), and the
|
|
16354
|
+
* facts the narrative displaced kept beneath it rather than dropped.
|
|
16355
|
+
*
|
|
16356
|
+
* It deliberately holds no label vocabulary of its own. Every local map that
|
|
16357
|
+
* mirrored the backend's eventually disagreed with it. Icons and colours are the
|
|
16358
|
+
* renderer's (blocks); this module is plain data.
|
|
16359
|
+
*/
|
|
16360
|
+
|
|
16361
|
+
interface DocInfo {
|
|
16362
|
+
name: string;
|
|
16363
|
+
pages: number | null;
|
|
16364
|
+
}
|
|
16365
|
+
type DocInfoMap = Record<string, DocInfo>;
|
|
16366
|
+
/** The tool a step is about, if any (tool-call and tool_progress steps). */
|
|
16367
|
+
declare function getStepTool(step: AgentStepEvent): string | undefined;
|
|
16368
|
+
/**
|
|
16369
|
+
* Resolve {doc_ext_id} placeholders and (full) markers in a summary string.
|
|
16370
|
+
* E.g. "Reading {doc-abc12345} (full)" → "Reading Contract A.pdf (42 pages)"
|
|
16371
|
+
*/
|
|
16372
|
+
declare function resolveSummary(summary: string, docInfo: DocInfoMap): string;
|
|
16373
|
+
/**
|
|
16374
|
+
* Collapse the raw SSE event stream into the logical steps a reader sees.
|
|
16375
|
+
*
|
|
16376
|
+
* The backend emits several events per logical step: a 20s "working" heartbeat
|
|
16377
|
+
* (agent_workflow.py:_keepalive) and follow-ups that re-use the same `index` to
|
|
16378
|
+
* attach an outcome or usage. Rendering those raw would repeat a row per
|
|
16379
|
+
* heartbeat, so both the trace and the `N steps` counter must count *this*, not
|
|
16380
|
+
* `steps.length` — otherwise the counter promises dozens of rows the list
|
|
16381
|
+
* never shows.
|
|
16382
|
+
*
|
|
16383
|
+
* Parallel tool calls carry distinct indexes and sub-agent steps are merely
|
|
16384
|
+
* nested at render time, so neither is collapsed here. Calls the duplicate guard refused are
|
|
16385
|
+
* dropped. Idempotent: merging an already-merged trace is a no-op.
|
|
16386
|
+
*/
|
|
16387
|
+
declare function mergeAgentSteps(steps: AgentStepEvent[]): AgentStepEvent[];
|
|
16388
|
+
/**
|
|
16389
|
+
* The steps a reader sees at the top level — sub-agent steps fold under the
|
|
16390
|
+
* parent that spawned them, so they are not counted here.
|
|
16391
|
+
*
|
|
16392
|
+
* The `N steps` counter must use this, not `mergeAgentSteps().length`: a
|
|
16393
|
+
* deep_research run contributes one row plus a fold, and counting its innards
|
|
16394
|
+
* would promise rows the collapsed trace never shows. A `parent_index` that
|
|
16395
|
+
* doesn't resolve degrades to top-level, matching how AgentSteps renders it.
|
|
16396
|
+
*/
|
|
16397
|
+
declare function topLevelAgentSteps(steps: AgentStepEvent[]): AgentStepEvent[];
|
|
16398
|
+
/** Format a token count compactly: 1234 → "1.2k", 12345 → "12k", 123456 → "123k". */
|
|
16399
|
+
declare function formatTokens(n: number): string;
|
|
16400
|
+
/**
|
|
16401
|
+
* At-a-glance run totals for the turn bar — deliberately NOT tokens (those are
|
|
16402
|
+
* already reported per-step and in the settled bar; a total there would just
|
|
16403
|
+
* duplicate). These two are what the bar can't otherwise show at a glance.
|
|
16404
|
+
*/
|
|
16405
|
+
interface RunStats {
|
|
16406
|
+
/** Tool invocations across the whole run (parent + every sub-agent's own calls). */
|
|
16407
|
+
toolCalls: number;
|
|
16408
|
+
/** Distinct sub-agents spawned this run. */
|
|
16409
|
+
subagents: number;
|
|
16410
|
+
/** Sub-agents still running (spawned, no done/failed marker yet). */
|
|
16411
|
+
subagentsRunning: number;
|
|
16412
|
+
}
|
|
16413
|
+
/**
|
|
16414
|
+
* Derive the run's headline totals from its raw step stream — the counts shown
|
|
16415
|
+
* collapsed in the turn bar.
|
|
16416
|
+
*
|
|
16417
|
+
* - **toolCalls**: a tool-call step is one with no lifecycle `step` and no lane
|
|
16418
|
+
* lifecycle marker — counted across parent AND children, since a sub-agent's
|
|
16419
|
+
* web_search is a real tool call the run made.
|
|
16420
|
+
* - **subagents**: distinct `subagent` handles; a lane is "running" once it has a
|
|
16421
|
+
* spawn marker and no terminal (done/failed) marker.
|
|
16422
|
+
*/
|
|
16423
|
+
declare function computeRunStats(steps: AgentStepEvent[]): RunStats;
|
|
16424
|
+
/**
|
|
16425
|
+
* A short, human job label for a sub-agent — what it's DOING, derived from its
|
|
16426
|
+
* task, so the UI never has to say "sub-1"/"sub-2". Takes the head of the task
|
|
16427
|
+
* up to the first natural break (parenthetical, sentence, colon, dash) and caps
|
|
16428
|
+
* the length. "Find Apple's most recent annual revenue (FY2025…)" → "Find
|
|
16429
|
+
* Apple's most recent annual revenue".
|
|
16430
|
+
*/
|
|
16431
|
+
declare function subagentJobLabel(task: string, maxLen?: number): string;
|
|
16432
|
+
/** One sub-agent's live state, distilled from its relayed steps. */
|
|
16433
|
+
interface SubagentLaneInfo {
|
|
16434
|
+
/** Backend handle (e.g. 'sub-1') — used only as a stable key / testid, never shown. */
|
|
16435
|
+
handle: string;
|
|
16436
|
+
/** Short job label shown to the user (see {@link subagentJobLabel}). */
|
|
16437
|
+
job: string;
|
|
16438
|
+
/** Full task text (spawn payload) — for a tooltip / the expanded lane. */
|
|
16439
|
+
task: string;
|
|
16440
|
+
/** The child's latest focus ("Searching the web") — its live "now". */
|
|
16441
|
+
focus: string;
|
|
16442
|
+
status: 'running' | 'done' | 'failed';
|
|
16443
|
+
/** How many real steps the child has taken so far. */
|
|
16444
|
+
steps: number;
|
|
16445
|
+
/**
|
|
16446
|
+
* The branch this sub-agent's run lives in (a message in the SAME
|
|
16447
|
+
* conversation carrying a `tools.subagent` marker) — undefined when the
|
|
16448
|
+
* delegation type doesn't persist one (deep_research/run_skill/
|
|
16449
|
+
* spawn_coding_agent stay ephemeral/inline-only), or before the backend's
|
|
16450
|
+
* spawn event has arrived yet.
|
|
16451
|
+
*/
|
|
16452
|
+
taskMessageExtId?: string;
|
|
16453
|
+
}
|
|
16454
|
+
/**
|
|
16455
|
+
* Group a step stream into per-sub-agent lanes — the shared source for both the
|
|
16456
|
+
* live status bar's running-sub-agent lines and the steps-drawer chips, so the
|
|
16457
|
+
* two never disagree on a child's job, focus, or status.
|
|
16458
|
+
*
|
|
16459
|
+
* A lane is opened by a `subagent_status: 'running'` marker (its `content`/`focus`
|
|
16460
|
+
* carries the task), closed by a `done`/`failed` marker, and its intermediate
|
|
16461
|
+
* steps (no marker) advance the step count + latest focus. Returned in spawn order.
|
|
16462
|
+
*/
|
|
16463
|
+
declare function extractSubagentLanes(steps: AgentStepEvent[]): SubagentLaneInfo[];
|
|
16464
|
+
interface StepDisplay {
|
|
16465
|
+
/** Short human label — the headline of the step. */
|
|
16466
|
+
label: string;
|
|
16467
|
+
/** The agent's narrative for this step, rendered as its own line. */
|
|
16468
|
+
summary: string | null;
|
|
16469
|
+
/** True when the summary is genuinely multi-line and must keep its breaks. */
|
|
16470
|
+
isMultiLine: boolean;
|
|
16471
|
+
/**
|
|
16472
|
+
* Facts the summary didn't carry, shown beneath it.
|
|
16473
|
+
*
|
|
16474
|
+
* A step often has two things worth reading: what the agent is *doing*
|
|
16475
|
+
* (`focus` — "Reading the termination clause") and what it is doing it *to*
|
|
16476
|
+
* (`detail[].summary` — "Contract A.pdf pp. 5–10 +digest", or a plan step's
|
|
16477
|
+
* checklist in `content`). These used to be an `||` chain, so whichever lost
|
|
16478
|
+
* was dropped — the page range and digest never reached the reader even
|
|
16479
|
+
* though the backend sent them.
|
|
16480
|
+
*/
|
|
16481
|
+
details: string[];
|
|
16482
|
+
}
|
|
16483
|
+
/**
|
|
16484
|
+
* Split a step into a short headline + the narrative beneath it. Keeping these
|
|
16485
|
+
* apart is what stops the trace reading like a debug log.
|
|
16486
|
+
*/
|
|
16487
|
+
declare function getStepDisplay(step: AgentStepEvent, docInfo?: DocInfoMap): StepDisplay;
|
|
16488
|
+
/**
|
|
16489
|
+
* One-line label for the live bar: the step's narrative when it has one, so the
|
|
16490
|
+
* pinned bar reads like a running commentary ("Running code — sum the first 15
|
|
16491
|
+
* primes") rather than a bare noun.
|
|
16492
|
+
*/
|
|
16493
|
+
declare function getAgentStepLabel(step: AgentStepEvent, docInfo?: DocInfoMap): string;
|
|
16494
|
+
/**
|
|
16495
|
+
* The step to surface while streaming: the most recent *substantive* step of the
|
|
16496
|
+
* AGENT ITSELF, skipping (a) pure "working" heartbeats and (b) sub-agent-tagged
|
|
16497
|
+
* steps — those belong to a child and are shown on their own lines in the roster
|
|
16498
|
+
* beneath the status, so the main line stays the parent's own commentary (e.g.
|
|
16499
|
+
* "Searching the web") instead of borrowing a child's step ("Sub-agent sub-2").
|
|
16500
|
+
*/
|
|
16501
|
+
declare function getCurrentStep(steps: AgentStepEvent[]): AgentStepEvent | undefined;
|
|
16502
|
+
|
|
16503
|
+
type SubagentBranchRecord = components['schemas']['SubagentToolRecord'];
|
|
16504
|
+
/** Reads the `tools.subagent` marker off a message, or null if it isn't one. */
|
|
16505
|
+
declare function getSubagentBranchRecord(message: Pick<ChatMessage, 'tools'>): SubagentBranchRecord | null;
|
|
16506
|
+
/**
|
|
16507
|
+
* Find the thread currently representing a sub-agent's branch: the one whose
|
|
16508
|
+
* history contains the task message. Its LEAF (not the task message itself)
|
|
16509
|
+
* is what `setParentMessageId` needs — while running that's the task message
|
|
16510
|
+
* itself (no reply yet); once done it's the reply, or further if continued.
|
|
16511
|
+
*/
|
|
16512
|
+
declare function findLeafForTaskMessage(threads: Thread[], taskMessageExtId: string): string | null;
|
|
16513
|
+
/**
|
|
16514
|
+
* When the currently displayed thread IS a sub-agent's branch, find the way
|
|
16515
|
+
* back: a sibling thread that shares the same spawn-point ancestor (the
|
|
16516
|
+
* message right before the task message) but isn't itself currently mid- (or
|
|
16517
|
+
* just past) a delegation — the ordinary continuation of the conversation
|
|
16518
|
+
* this branch was delegated from. Sub-agent branches are deliberately
|
|
16519
|
+
* excluded from `useBranchNavigation`'s branch-point counting (they're a
|
|
16520
|
+
* delegation, not a reply variant), so this is the only way back once you've
|
|
16521
|
+
* opened one.
|
|
16522
|
+
*
|
|
16523
|
+
* A sibling can perfectly well have used a sub-agent earlier in ITS OWN
|
|
16524
|
+
* history too (e.g. after two sequential delegations in the same
|
|
16525
|
+
* conversation) — what disqualifies it as "the way back" is its own tail
|
|
16526
|
+
* being mid-delegation, not whether a sub-agent was ever involved upstream.
|
|
16527
|
+
*/
|
|
16528
|
+
declare function findMainSiblingLeaf(threads: Thread[], currentHistory: ChatMessage[]): string | null;
|
|
16529
|
+
/**
|
|
16530
|
+
* What should actually RENDER for a sub-agent's own thread: just that
|
|
16531
|
+
* delegation's own transcript — the instruction ARBI handed the sub-agent,
|
|
16532
|
+
* and its reply — not the full shared history leading up to it. The human's
|
|
16533
|
+
* real earlier messages belong to the main conversation, not to this
|
|
16534
|
+
* delegation; `findMainSiblingLeaf` (the "Back to conversation" link) is how
|
|
16535
|
+
* you see them again. Returns `history` unchanged when it isn't currently a
|
|
16536
|
+
* sub-agent thread.
|
|
16537
|
+
*/
|
|
16538
|
+
declare function sliceToSubagentThread(history: ChatMessage[]): ChatMessage[];
|
|
16539
|
+
/**
|
|
16540
|
+
* The thread to show by default among `threads`: never a sub-agent's branch when the
|
|
16541
|
+
* conversation's own thread is there. A sub-agent branch shares its history up to the spawn
|
|
16542
|
+
* point with the main thread, so "the first thread" or "the first thread containing this
|
|
16543
|
+
* message" can land in a delegation the person never opened. Prefers a thread with no
|
|
16544
|
+
* delegation marker at all (the newest of them: a thread opens on its latest version), then one whose tail is not mid-delegation (a main thread that
|
|
16545
|
+
* delegated earlier and carried on), and only then whatever is first.
|
|
16546
|
+
*/
|
|
16547
|
+
declare function pickMainThread(threads: Thread[]): Thread | undefined;
|
|
16548
|
+
/**
|
|
16549
|
+
* The sub-agent run `messageId` belongs to, when it sits in a sub-agent's branch (at or after the
|
|
16550
|
+
* branch's task message); null when it is in the conversation's own thread. A sub-agent's run id
|
|
16551
|
+
* is `<parent run id>:sub:<suffix>`, so this also names the run that delegated it.
|
|
16552
|
+
*/
|
|
16553
|
+
declare function findSubagentRunId(threads: Thread[], messageId: string): string | null;
|
|
16554
|
+
|
|
16555
|
+
/**
|
|
16556
|
+
* The message a new turn replies to.
|
|
16557
|
+
*
|
|
16558
|
+
* The server refuses to continue from a failed message (409 "Cannot reply to a message with
|
|
16559
|
+
* status 'failed'") and from one that no longer exists (404 "Parent message not found"). Both
|
|
16560
|
+
* happen after a failure: the answer failed (stream error, the 10-minute stall bound, a restart
|
|
16561
|
+
* sweep that also fails the follow-ups queued behind it), or a Retry deleted the message the
|
|
16562
|
+
* view still pointed at. Sending to such a parent fails again on every Retry and every new
|
|
16563
|
+
* message, so the thread could never move on. A turn instead replies to the nearest message
|
|
16564
|
+
* above it that the server accepts.
|
|
16565
|
+
*/
|
|
16566
|
+
|
|
16567
|
+
/**
|
|
16568
|
+
* @param threads The conversation's threads
|
|
16569
|
+
* @param parentId The parent the turn would reply to
|
|
16570
|
+
* @returns The nearest message at or above `parentId` that is not failed; when `parentId` is not
|
|
16571
|
+
* in the conversation any more, the same from the end of its main thread. Null when nothing
|
|
16572
|
+
* above can be replied to.
|
|
16573
|
+
*/
|
|
16574
|
+
declare function findReplyTarget(threads: Thread[], parentId: string | null): string | null;
|
|
16575
|
+
|
|
16576
|
+
/**
|
|
16577
|
+
* What a Stop cancels on the server, and when it can.
|
|
16578
|
+
*
|
|
16579
|
+
* Stop must always reach the server: closing the stream alone leaves the run going, and its answer
|
|
16580
|
+
* (and any sub-agents it spawns) keep landing in the thread. Two cases need help to find the run:
|
|
16581
|
+
* - Stop pressed before the stream has reported its response id. The run already exists on the
|
|
16582
|
+
* server, so the Stop waits briefly for the id rather than give up on the cancel.
|
|
16583
|
+
* - The viewer is in a sub-agent's branch. The id it streams there is not a run the cancel endpoint
|
|
16584
|
+
* knows; the run to stop is the one that delegated it (stopping that also stops the sub-agent).
|
|
16585
|
+
*/
|
|
16586
|
+
|
|
16587
|
+
/** How long a Stop pressed before the run has an id waits for one. */
|
|
16588
|
+
declare const STOP_ID_WAIT_MS = 5000;
|
|
16589
|
+
/**
|
|
16590
|
+
* A press this soon after a Stop is the same double tap, not a new Stop. The queue starts the next
|
|
16591
|
+
* follow-up as soon as a Stop lands, so without this a second tap would stop that follow-up too.
|
|
16592
|
+
*/
|
|
16593
|
+
declare const STOP_REPEAT_WINDOW_MS = 1000;
|
|
16594
|
+
/**
|
|
16595
|
+
* The run the server must cancel to stop `responseId`: the delegating run when `responseId` is in
|
|
16596
|
+
* a sub-agent's branch, otherwise `responseId`'s own top-level run.
|
|
16597
|
+
*/
|
|
16598
|
+
declare function getRunToCancel(threads: Thread[], responseId: string): string;
|
|
16599
|
+
|
|
16600
|
+
/**
|
|
16601
|
+
* A turn's context and AI usage (the `context` snapshot a stream reports): how full the context
|
|
16602
|
+
* window is, and how much of the turn's £ budget it has spent.
|
|
16603
|
+
*/
|
|
16604
|
+
type ContextUsage = {
|
|
16605
|
+
context_window: number;
|
|
16606
|
+
budget: number;
|
|
16607
|
+
total_input: number;
|
|
16608
|
+
system: number;
|
|
16609
|
+
history: number;
|
|
16610
|
+
compaction: number;
|
|
16611
|
+
retrieval: number;
|
|
16612
|
+
query: number;
|
|
16613
|
+
total_output: number;
|
|
16614
|
+
truncated: boolean;
|
|
16615
|
+
all_llm_calls?: {
|
|
16616
|
+
last_input_tokens: number;
|
|
16617
|
+
count: number;
|
|
16618
|
+
input_tokens: number;
|
|
16619
|
+
output_tokens: number;
|
|
16620
|
+
} | null;
|
|
16621
|
+
spent_gbp?: number | null;
|
|
16622
|
+
budget_gbp?: number | null;
|
|
16623
|
+
};
|
|
16624
|
+
declare function isNearAiUsageBudget(usage: ContextUsage): boolean;
|
|
16625
|
+
declare function getContextUsedTokens(usage: ContextUsage): number;
|
|
16626
|
+
declare function estimateDraftTokens(draftLength: number): number;
|
|
16627
|
+
declare function getContextUsedPercent(usage: ContextUsage, draftLength?: number): number;
|
|
16628
|
+
declare function getContextRemainingPercent(usage: ContextUsage, draftLength?: number): number;
|
|
16629
|
+
|
|
16630
|
+
/**
|
|
16631
|
+
* The context a conversation's stored turns carry: the documents and facts the last turn was asked
|
|
16632
|
+
* with, read back from the tools on its messages (the inverse of the turn request's tool builders),
|
|
16633
|
+
* so a reopened conversation shows the same context.
|
|
16634
|
+
*/
|
|
16635
|
+
|
|
16636
|
+
type StoredMessage = components['schemas']['MessageResponse'];
|
|
16637
|
+
/**
|
|
16638
|
+
* Extracts document IDs and their pinned status from the last user message in the thread.
|
|
16639
|
+
* Document IDs are stored in user messages' tools (retrieval_chunk / retrieval_full_context)
|
|
16640
|
+
* because that's what the frontend sends when creating a message.
|
|
16641
|
+
*
|
|
16642
|
+
* Returns documents with isPinned: true for retrieval_full_context, false for retrieval_chunk.
|
|
16643
|
+
*/
|
|
16644
|
+
declare function extractDocumentIdsFromMessages(messageHistory: StoredMessage[]): Array<{
|
|
16645
|
+
docId: string;
|
|
16646
|
+
isPinned: boolean;
|
|
16647
|
+
}>;
|
|
16648
|
+
/**
|
|
16649
|
+
* The chat's fact ids, from the latest user message that carries a `facts_context` tool (each
|
|
16650
|
+
* message carries the chat's full list, so the latest one is the chat's current set). Returns
|
|
16651
|
+
* null when no message carries one (a chat from before facts were per chat, or with none sent).
|
|
16652
|
+
*/
|
|
16653
|
+
declare function extractFactIdsFromMessages(messageHistory: StoredMessage[]): string[] | null;
|
|
16654
|
+
|
|
16655
|
+
/**
|
|
16656
|
+
* Which run a conversation view attaches to.
|
|
16657
|
+
*
|
|
16658
|
+
* A run's output is one durable, reconnectable event stream keyed by its response id (its
|
|
16659
|
+
* assistant message id), and the run exists whether or not anyone watches it. A view attaches to
|
|
16660
|
+
* the run its conversation shows as still running when this client is not already streaming it
|
|
16661
|
+
* itself: a scheduled run, or the same account on another device.
|
|
16662
|
+
*/
|
|
16663
|
+
/** The fields of a message the choice reads. */
|
|
16664
|
+
interface RunMessage {
|
|
16665
|
+
external_id: string;
|
|
16666
|
+
role: string;
|
|
16667
|
+
status?: string | null;
|
|
16668
|
+
}
|
|
16669
|
+
/** The fields of this client's own generation state the choice reads. */
|
|
16670
|
+
interface LocalGeneration {
|
|
16671
|
+
isGenerating: boolean;
|
|
16672
|
+
/** The local stream of a turn this client started (absent for an attached run). */
|
|
16673
|
+
abortController?: AbortController | null;
|
|
16674
|
+
}
|
|
16675
|
+
/**
|
|
16676
|
+
* The newest assistant message the server still runs. Follow-ups sent mid-answer each carry their
|
|
16677
|
+
* own `queued` answer row behind the running one, so those trailing queued rows are skipped in
|
|
16678
|
+
* favour of the `in_progress` answer before them. With nothing in progress, the oldest of the
|
|
16679
|
+
* trailing queued answers (the next to start) is watched.
|
|
16680
|
+
*/
|
|
16681
|
+
declare function getAttachableRunId(messages: readonly RunMessage[]): string | null;
|
|
16682
|
+
/**
|
|
16683
|
+
* The run a conversation view attaches to, given this client's own generation state.
|
|
16684
|
+
*
|
|
16685
|
+
* A local turn already owns its stream (it holds an AbortController), so it is skipped: that is the
|
|
16686
|
+
* only discriminator. The attach itself marks the conversation as generating WITHOUT a controller,
|
|
16687
|
+
* so it never disables itself; if it did, the attach would detach, re-attach and detach again on
|
|
16688
|
+
* every render.
|
|
16689
|
+
*/
|
|
16690
|
+
declare function getRunToAttach(localGeneration: LocalGeneration | undefined, messages: readonly RunMessage[]): string | null;
|
|
16691
|
+
|
|
16692
|
+
export { type ConnectorCatalogEntry as $, ACCOUNT_VENDOR as A, type BookingConfirmation as B, type CalDavConnectBody as C, type CalendarRead as D, type CalendarSettings as E, type CalendarSettingsBody as F, type CalendarUpdate as G, type CalendarWindow as H, CallApiError as I, type ChatAttachmentFile as J, type ChatAttachmentInput as K, type ChatCryptoContext as L, type ChatKeyRing as M, type ChatKind as N, type ChatMemberKey as O, type ChatMemberResponse as P, type ChatMessage as Q, type ChatMessageResponse as R, type ChatResponse as S, type ChatSession as T, type CitationSummary as U, type CitationToolSources as V, type CliConfig as W, type CliCredentials as X, type CommandDescriptor as Y, type ConfigStore as Z, type ConnectOptions as _, type AccountSyncResult as a, type MessageLevel as a$, type ConnectorFolder as a0, type ConnectorSyncProgress as a1, type ConnectorSyncStatus as a2, type ConnectorVendorKey as a3, type ConnectorVisibilitySettings as a4, type ContextUsage as a5, type ConversationResponse as a6, type ConversationUsageResponse as a7, type CreateFactRequest as a8, type CreateFactsRequest as a9, FLAT_TAG_KINDS as aA, type FactResponse as aB, type FactSearchRequest as aC, type FactSearchResponse as aD, type FindTimeParams as aE, type FormattedWsMessage as aF, type FreeBusyEntry as aG, type FullContextSelection as aH, GOOGLE_VENDORS as aI, type HolidayCountry as aJ, type HouseTemplateCandidate as aK, IMANAGE_VENDORS as aL, type IdentityErrorCode as aM, type IdentityPurchase as aN, type IdentityState as aO, type IdentityStatus as aP, type ImportResult as aQ, type InvitationRead as aR, type LinkedRun as aS, type ListAllOptions as aT, type ListEventsParams as aU, type ListFactsOptions as aV, type ListPaginatedOptions as aW, MAILBOX_SYNC_VENDORS as aX, MAX_RETRIEVE_DOC_IDS as aY, MICROSOFT_VENDORS as aZ, type MailAttachment as a_, type CreateWorkRequest as aa, type CreateWorkflowRequest as ab, DEFAULT_AI_USD_PER_GBP as ac, DOC_TERMINAL_STATUSES as ad, DRIVE_SYNC_VENDORS as ae, type DateTimeSpec as af, type DecryptedChat as ag, type DecryptedChatMessage as ah, type DeploymentHouseTemplate as ai, type DocInfo as aj, type DocInfoMap as ak, type DocNameMap as al, type DocumentAutomationAction as am, type DocumentListFields as an, type DocumentListOrder as ao, type DocumentSelector as ap, type DocumentWaiter as aq, type DocumentWaiterOptions as ar, type DriveSyncProgress as as, type DriveSyncSummary as at, DuplicateContactError as au, ENTITY_KINDS as av, type EditScope as aw, type EntityKind as ax, type EventCreateBody as ay, type EventPatchBody as az, type ActivityKind as b, type StepAssignee as b$, type OAuthAccountKind as b0, type OutputItemDone as b1, type OverlayItem as b2, type OverlayLayerName as b3, PRESENCE_KINDS as b4, PROMPT_CONTEXT_CHARS as b5, type ParsedSlashCommand as b6, type PendingAuthResponse as b7, type PersonKey as b8, PlanStepsError as b9, type RespondParams as bA, type RespondPartstat as bB, type RoomCreateBody as bC, type RoomQuery as bD, type RoomRead as bE, type RunProgress as bF, type RunStats as bG, type RunStep as bH, type RunWaitingOn as bI, SHAREPOINT_VENDORS as bJ, type SSEEvent as bK, type SSEStreamCallbacks as bL, type SSEStreamResult as bM, STEP_FIELD_OPTION_TONES as bN, STOP_ID_WAIT_MS as bO, STOP_REPEAT_WINDOW_MS as bP, SUPPORTED_EXTENSIONS as bQ, type ScopedTarget as bR, type SearchChunk as bS, type SendBack as bT, type ShareRead as bU, type ShareRole as bV, type SkillSummary as bW, type SkippedFile as bX, type SlackConnectionStatus as bY, type StepActionRequest as bZ, type StepActivityEvent as b_, type PlanWorkRequest as ba, type ProductResponse as bb, type ProjectAddonKind as bc, type ProjectAddonSettingsRequest as bd, type ProjectBudget as be, type ProjectCheckoutRequest as bf, type ProjectConversationUsageResponse as bg, type ProjectCreateOptions as bh, type ProjectDetails as bi, type ProjectEventKind as bj, type ProjectEventResponse as bk, type ProjectInvoicesResponse as bl, type ProjectNextPeriodAddonsRequest as bm, type ProjectPlanChangeRequest as bn, type ProjectQuoteRequest as bo, type ProjectResponse as bp, type ProjectUpdateRequest as bq, type ProjectUsageResponse as br, PublicBookingError as bs, type PublicBookingPage as bt, type QuotaExceeded as bu, type RaisedSignal as bv, type ReconnectOptions as bw, type ReconnectableWsConnection as bx, type ResolvedCitation as by, type ResolvedRecipient as bz, type ActivityResponse as c, appendTranscriptionHints as c$, type StepDisplay as c0, type StepField as c1, type StepFieldOption as c2, type StepFieldOptionTone as c3, type StepKind as c4, type StepPhase as c5, type StepSignal as c6, type StepSignalWhen as c7, type StepState as c8, type StepStatus as c9, type UpdateConversationRequest as cA, type UpdateFactRequest as cB, type UpdateWorkflowRequest as cC, type UploadBatchResult as cD, type UploadDirectOptions as cE, type UploadDirectResult as cF, type UploadDocumentsOptions as cG, type UploadOptions as cH, type UploadProgressListener as cI, type UploadResult as cJ, type UsageBreakdown as cK, type UserConnectorEntry as cL, type UserDailyUsageResponse as cM, type UserInfo as cN, WebSocketAuthError as cO, type WeeklyHoursSpec as cP, type WorkStatus as cQ, type WorkflowAuthMode as cR, type WorkflowResponse as cS, type WorkflowRunHistoryResponse as cT, type WorkflowRunResponse as cU, type WorkspaceContext as cV, type WorkspaceOpenResponse as cW, type WsConnection as cX, account as cY, agentconfig as cZ, agents as c_, type SubagentBranchRecord as ca, type SubagentLaneInfo as cb, type SubmitBackgroundQueryOptions as cc, type SubscribeParams as cd, type SyncTriggerResult as ce, TAG_KINDS as cf, TAG_NESTING_MAX_DEPTH as cg, type TagChange as ch, type TagFieldDefinition as ci, type TagGroup as cj, type TagKind as ck, type TagKindField as cl, type TagKindSchema as cm, type TagLinks as cn, type TagListQuery as co, type TagNode as cp, type TagResponse as cq, type TagScope as cr, type TagTreeRow as cs, type TaskPlan as ct, type TaskPlanStep as cu, type TaxQuoteResponse as cv, type Thread as cw, type ThreadsResponse as cx, type TimeSuggestion as cy, type TurnRequest as cz, Arbi as d, getContextUsedTokens as d$, assistant as d0, authenticatedFetch as d1, bookPublicSlot as d2, buildCitationChunkData as d3, buildDocNameMap as d4, buildDocumentTools as d5, buildFactsContextTool as d6, buildRetrievalChunkTool as d7, buildRetrievalFullContextTool as d8, buildRetrievalTocTool as d9, extractSubagentLanes as dA, facts as dB, files as dC, filterDocumentTags as dD, filterSkills as dE, findLeafForTaskMessage as dF, findMainSiblingLeaf as dG, findReplyTarget as dH, findSubagentRunId as dI, flattenTagTree as dJ, formatAgentStepLabel as dK, formatFileSize as dL, formatGbp as dM, formatGbpPerMillionTokens as dN, formatItemLabel as dO, formatStreamSummary as dP, formatTokens as dQ, formatUserName as dR, formatWorkspaceChoices as dS, formatWsMessage as dT, generateEncryptedWorkspaceKey as dU, generateNewWorkspaceKey as dV, getAgentStepLabel as dW, getAttachableRunId as dX, getChildTags as dY, getContextRemainingPercent as dZ, getContextUsedPercent as d_, buildTurnRequest as da, calendar as db, calls as dc, canTagHaveParent as dd, cancelPublicBooking as de, chats as df, computeRunStats as dg, connectErrorMessage as dh, connectWebSocket as di, connectWithReconnect as dj, connectors as dk, consumeSSEStream as dl, contacts as dm, continuityPrompt as dn, conversations as dp, countCitations as dq, createAuthenticatedClient as dr, createDocumentWaiter as ds, createIndexAssigner as dt, defaultKindForFormat as du, doctags as dv, documents as dw, estimateDraftTokens as dx, extractDocumentIdsFromMessages as dy, extractFactIdsFromMessages as dz, ArbiApiError as e, subagentJobLabel as e$, getCurrentStep as e0, getEligibleParentTags as e1, getErrorCode as e2, getErrorMessage as e3, getPublicBookingPage as e4, getRawWorkspaceKey as e5, getRunToAttach as e6, getRunToCancel as e7, getStepDisplay as e8, getStepTool as e9, performSigningKeyLogin as eA, performSsoDeviceFlowLogin as eB, pickMainThread as eC, profile as eD, progressFetch as eE, projects as eF, quotaExceededFrom as eG, quotaFromStreamError as eH, reduceOutputItem as eI, refusalReason as eJ, requireData as eK, requireOk as eL, resolveAuth as eM, resolveCitations as eN, resolveSummary as eO, resolveWorkspace as eP, responses as eQ, searchChunks as eR, selectFullContextDocument as eS, selectWorkspace as eT, selectWorkspaceById as eU, sessions as eV, settings as eW, signatureRequests as eX, sliceToSubagentThread as eY, streamSSE as eZ, stripCitationMarkdown as e_, getSubagentBranchRecord as ea, getTagDescendantIds as eb, health as ec, houseTemplate as ed, hydrateAgentSteps as ee, identity as ef, identityErrorCode as eg, isAnnotationTag as eh, isConnectorVendorVisible as ei, isDriveSyncVendor as ej, isEntityTag as ek, isFlatKind as el, isLabelTag as em, isMailboxSyncVendor as en, isNearAiUsageBudget as eo, isPresenceTag as ep, isSharePointVendor as eq, isSharedSkill as er, isTraceItem as es, mail as et, mergeAgentSteps as eu, notifications as ev, parseSSEEvents as ew, parseSlashCommand as ex, parseSlashTokenInProgress as ey, performPasswordLogin as ez, ArbiError as f, summarizeCitations as f0, tagUseCount as f1, tags as f2, tagsForScope as f3, tagsOfGroup as f4, topLevelAgentSteps as f5, uploadSkill as f6, usdToGbp as f7, work as f8, workflowSteps as f9, workflows as fa, workspaces as fb, wouldCreateTagCycle as fc, type ArbiHostSession as g, type ArbiOptions as h, ArbiSessionExpiredError as i, type AskHandlers as j, type AskRequest as k, type AttendeeRead as l, type AuthContext as m, type AuthHeaders as n, type AuthMode as o, type AuthenticatedClient as p, type BookingPage as q, type BookingPageWriteBody as r, type BookingRequestBody as s, type BridgeTokensOptions as t, type CalDavProfile as u, type CalendarAccount as v, type CalendarAccountKind as w, type CalendarCreateBody as x, type CalendarEvent as y, type CalendarKeys as z };
|