@arbidocs/sdk 0.4.169 → 0.5.1
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/dist/{browser-jyiyv5Wh.d.ts → browser-DDboSTjo.d.ts} +41 -2
- package/dist/{browser-3s6asEn1.d.cts → browser-XUJbRPTm.d.cts} +41 -2
- package/dist/browser.cjs +106 -9
- package/dist/browser.cjs.map +1 -1
- package/dist/browser.d.cts +1 -1
- package/dist/browser.d.ts +1 -1
- package/dist/browser.js +105 -10
- package/dist/browser.js.map +1 -1
- package/dist/index.cjs +106 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +105 -10
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { A as ACCOUNT_VENDOR, a as AccountSyncResult, b as ActivityKind, c as ActivityResponse, d as Arbi, e as ArbiApiError, f as ArbiError, g as ArbiHostSession, h as ArbiOptions, i as ArbiSessionExpiredError, j as
|
|
1
|
+
import { $ as ConfigStore, Y as CliConfig, Z as CliCredentials, V as ChatSession, bZ as SkippedFile, cL as UploadResult, p as AuthHeaders, cF as UploadBatchResult, cJ as UploadOptions, cG as UploadDirectOptions, cH as UploadDirectResult, bS as SUPPORTED_EXTENSIONS, b0 as MailAttachment, N as ChatCryptoContext } from './browser-XUJbRPTm.cjs';
|
|
2
|
+
export { A as ACCOUNT_VENDOR, a as AccountSyncResult, b as ActivityKind, c as ActivityResponse, d as Arbi, e as ArbiApiError, f as ArbiError, g as ArbiHostSession, h as ArbiOptions, i as ArbiSessionExpiredError, j as ArbiWorkspaceChangedError, k as ArbiWorkspaceSupersededError, l as AskHandlers, m as AskRequest, n as AttendeeRead, o as AuthContext, q as AuthMode, r as AuthenticatedClient, B as BookingConfirmation, s as BookingPage, t as BookingPageWriteBody, u as BookingRequestBody, v as BridgeTokensOptions, C as CalDavConnectBody, w as CalDavProfile, x as CalendarAccount, y as CalendarAccountKind, z as CalendarCreateBody, D as CalendarEvent, E as CalendarKeys, F as CalendarRead, G as CalendarSettings, H as CalendarSettingsBody, I as CalendarUpdate, J as CalendarWindow, K as CallApiError, L as ChatAttachmentFile, M as ChatAttachmentInput, O as ChatKeyRing, P as ChatKind, Q as ChatMemberKey, R as ChatMemberResponse, S as ChatMessage, T as ChatMessageResponse, U as ChatResponse, W as CitationSummary, X as CitationToolSources, _ as CommandDescriptor, a0 as ConnectOptions, a1 as ConnectorCatalogEntry, a2 as ConnectorFolder, a3 as ConnectorSyncProgress, a4 as ConnectorSyncStatus, a5 as ConnectorVendorKey, a6 as ConnectorVisibilitySettings, a7 as ContextUsage, a8 as ConversationResponse, a9 as ConversationUsageResponse, ac as CreateWorkRequest, ad as CreateWorkflowRequest, ae as DEFAULT_AI_USD_PER_GBP, af as DOC_TERMINAL_STATUSES, ag as DRIVE_SYNC_VENDORS, ah as DateTimeSpec, ai as DecryptedChat, aj as DecryptedChatMessage, ak as DeploymentHouseTemplate, al as DocInfo, am as DocInfoMap, an as DocNameMap, ao as DocumentAutomationAction, ap as DocumentListFields, aq as DocumentListOrder, ar as DocumentSelector, as as DocumentWaiter, at as DocumentWaiterOptions, au as DriveSyncProgress, av as DriveSyncSummary, aw as DuplicateContactError, ax as ENTITY_KINDS, ay as EditScope, az as EntityKind, aA as EventCreateBody, aB as EventPatchBody, aC as FLAT_TAG_KINDS, aG as FindTimeParams, aH as FormattedWsMessage, aI as FreeBusyEntry, aJ as FullContextSelection, aK as GOOGLE_VENDORS, aL as HolidayCountry, aM as HouseTemplateCandidate, aN as IMANAGE_VENDORS, aO as IdentityErrorCode, aP as IdentityPurchase, aQ as IdentityState, aR as IdentityStatus, aS as ImportResult, aT as InvitationRead, aU as LinkedRun, aV as ListAllOptions, aW as ListEventsParams, aY as ListPaginatedOptions, aZ as MAILBOX_SYNC_VENDORS, a_ as MAX_RETRIEVE_DOC_IDS, a$ as MICROSOFT_VENDORS, b1 as MessageLevel, b2 as OAuthAccountKind, b3 as OutputItemDone, b4 as OverlayItem, b5 as OverlayLayerName, b6 as PRESENCE_KINDS, b7 as PROMPT_CONTEXT_CHARS, b8 as ParsedSlashCommand, b9 as PendingAuthResponse, ba as PersonKey, bb as PlanStepsError, bc as PlanWorkRequest, bd as ProductResponse, be as ProjectAddonKind, bf as ProjectAddonSettingsRequest, bg as ProjectBudget, bh as ProjectCheckoutRequest, bi as ProjectConversationUsageResponse, bj as ProjectCreateOptions, bk as ProjectDetails, bl as ProjectEventKind, bm as ProjectEventResponse, bn as ProjectInvoicesResponse, bo as ProjectNextPeriodAddonsRequest, bp as ProjectPlanChangeRequest, bq as ProjectQuoteRequest, br as ProjectResponse, bs as ProjectUpdateRequest, bt as ProjectUsageResponse, bu as PublicBookingError, bv as PublicBookingPage, bw as QuotaExceeded, bx as RaisedSignal, by as ReconnectOptions, bz as ReconnectableWsConnection, bA as ResolvedCitation, bB as ResolvedRecipient, bC as RespondParams, bD as RespondPartstat, bE as RoomCreateBody, bF as RoomQuery, bG as RoomRead, bH as RunProgress, bI as RunStats, bJ as RunStep, bK as RunWaitingOn, bL as SHAREPOINT_VENDORS, bM as SSEEvent, bN as SSEStreamCallbacks, bO as SSEStreamResult, bP as STEP_FIELD_OPTION_TONES, bQ as STOP_ID_WAIT_MS, bR as STOP_REPEAT_WINDOW_MS, bT as ScopedTarget, bU as SearchChunk, bV as SendBack, bW as ShareRead, bX as ShareRole, bY as SkillSummary, b_ as SlackConnectionStatus, b$ as StepActionRequest, c0 as StepActivityEvent, c1 as StepAssignee, c2 as StepDisplay, c3 as StepField, c4 as StepFieldOption, c5 as StepFieldOptionTone, c6 as StepKind, c7 as StepPhase, c8 as StepSignal, c9 as StepSignalWhen, ca as StepState, cb as StepStatus, cc as SubagentBranchRecord, cd as SubagentLaneInfo, ce as SubmitBackgroundQueryOptions, cf as SubscribeParams, cg as SyncTriggerResult, ch as TAG_KINDS, ci as TAG_NESTING_MAX_DEPTH, cj as TagChange, ck as TagFieldDefinition, cl as TagGroup, cm as TagKind, cn as TagKindField, co as TagKindSchema, cp as TagLinks, cq as TagListQuery, cr as TagNode, cs as TagResponse, ct as TagScope, cu as TagTreeRow, cv as TaskPlan, cw as TaskPlanStep, cx as TaxQuoteResponse, cy as Thread, cz as ThreadsResponse, cA as TimeSuggestion, cB as TurnRequest, cC as UpdateConversationRequest, cE as UpdateWorkflowRequest, cI as UploadDocumentsOptions, cK as UploadProgressListener, cM as UsageBreakdown, cN as UserConnectorEntry, cO as UserDailyUsageResponse, cP as UserInfo, cQ as WebSocketAuthError, cR as WeeklyHoursSpec, cS as WorkStatus, cT as WorkflowAuthMode, cU as WorkflowResponse, cV as WorkflowRunHistoryResponse, cW as WorkflowRunResponse, cX as WorkspaceContext, cY as WorkspaceOpenResponse, cZ as WsConnection, c_ as account, c$ as agentconfig, d0 as agents, d1 as appendTranscriptionHints, d2 as assistant, d3 as authenticatedFetch, d4 as bookPublicSlot, d5 as buildCitationChunkData, d6 as buildDocNameMap, d7 as buildDocumentTools, d8 as buildFactsContextTool, d9 as buildRetrievalChunkTool, da as buildRetrievalFullContextTool, db as buildRetrievalTocTool, dc as buildTurnRequest, dd as calendar, de as calls, df as canTagHaveParent, dg as cancelPublicBooking, dh as chats, di as computeRunStats, dj as connectErrorMessage, dk as connectWebSocket, dl as connectWithReconnect, dm as connectors, dn as consumeSSEStream, dp as contacts, dq as continuityPrompt, dr as conversations, ds as countCitations, dt as createAuthenticatedClient, du as createDocumentWaiter, dv as createIndexAssigner, dw as defaultKindForFormat, dx as doctags, dy as documents, dz as estimateDraftTokens, dA as extractDocumentIdsFromMessages, dB as extractFactIdsFromMessages, dC as extractSubagentLanes, dD as facts, dE as files, dF as filterDocumentTags, dG as filterSkills, dH as findLeafForTaskMessage, dI as findMainSiblingLeaf, dJ as findReplyTarget, dK as findSubagentRunId, dL as flattenTagTree, dM as formatAgentStepLabel, dN as formatFileSize, dO as formatGbp, dP as formatGbpPerMillionTokens, dQ as formatItemLabel, dR as formatStreamSummary, dS as formatTokens, dT as formatUserName, dU as formatWorkspaceChoices, dV as formatWsMessage, dW as generateEncryptedWorkspaceKey, dX as generateNewWorkspaceKey, dY as getAgentStepLabel, dZ as getAttachableRunId, d_ as getChildTags, d$ as getContextRemainingPercent, e0 as getContextUsedPercent, e1 as getContextUsedTokens, e2 as getCurrentStep, e3 as getEligibleParentTags, e4 as getErrorCode, e5 as getErrorMessage, e6 as getPublicBookingPage, e7 as getRawWorkspaceKey, e8 as getRunToAttach, e9 as getRunToCancel, ea as getStepDisplay, eb as getStepTool, ec as getSubagentBranchRecord, ed as getTagDescendantIds, ee as health, ef as houseTemplates, eg as hydrateAgentSteps, ei as identityErrorCode, eh as identityVerification, ej as isAnnotationTag, ek as isConnectorVendorVisible, el as isDriveSyncVendor, em as isEntityTag, en as isFlatKind, eo as isLabelTag, ep as isMailboxSyncVendor, eq as isNearAiUsageBudget, er as isPresenceTag, es as isSharePointVendor, et as isSharedSkill, eu as isTraceItem, ev as mail, ew as mergeAgentSteps, ex as notifications, ey as parseSSEEvents, ez as parseSlashCommand, eA as parseSlashTokenInProgress, eB as performPasswordLogin, eC as performSigningKeyLogin, eD as performSsoDeviceFlowLogin, eE as pickMainThread, eF as profile, eG as progressFetch, eH as projects, eI as quotaExceededFrom, eJ as quotaFromStreamError, eK as reduceOutputItem, eL as refusalReason, eM as requireData, eN as requireOk, eO as resolveAuth, eP as resolveCitations, eQ as resolveSummary, eR as resolveWorkspace, eS as responses, eT as searchChunks, eU as selectFullContextDocument, eV as selectWorkspace, eW as selectWorkspaceById, eX as sessions, eY as settings, eZ as signatureRequests, e_ as sliceToSubagentThread, e$ as streamSSE, f0 as stripCitationMarkdown, f1 as subagentJobLabel, f2 as summarizeCitations, f3 as tagUseCount, f4 as tags, f5 as tagsForScope, f6 as tagsOfGroup, f7 as topLevelAgentSteps, f8 as uploadSkill, f9 as usdToGbp, fa as work, fb as workflowSteps, fc as workflows, fd as workspaces, fe as wouldCreateTagCycle } from './browser-XUJbRPTm.cjs';
|
|
3
3
|
import { SessionPersistence, ArbiClient, components } from '@arbidocs/client';
|
|
4
4
|
export { CallPeer, LoginProfile } from '@arbidocs/client';
|
|
5
5
|
export { b as AgentStepEvent, d as ArtifactEvent, M as MailDraftSSEEvent, e as MessageMetadataPayload, f as MessageQueuedEvent, O as OutputTokensDetails, R as ResponseCompletedEvent, g as ResponseContentPartAddedEvent, h as ResponseCreatedEvent, i as ResponseFailedEvent, j as ResponseOutputItemAddedEvent, k as ResponseOutputItemDoneEvent, l as ResponseOutputTextDeltaEvent, m as ResponseOutputTextDoneEvent, n as ResponseUsage, S as SSEStreamStartData, T as TokenBudgetContext, U as UserInputRequestEvent, o as UserMessageEvent } from './sse-types-BbR7JG5o.cjs';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { A as ACCOUNT_VENDOR, a as AccountSyncResult, b as ActivityKind, c as ActivityResponse, d as Arbi, e as ArbiApiError, f as ArbiError, g as ArbiHostSession, h as ArbiOptions, i as ArbiSessionExpiredError, j as
|
|
1
|
+
import { $ as ConfigStore, Y as CliConfig, Z as CliCredentials, V as ChatSession, bZ as SkippedFile, cL as UploadResult, p as AuthHeaders, cF as UploadBatchResult, cJ as UploadOptions, cG as UploadDirectOptions, cH as UploadDirectResult, bS as SUPPORTED_EXTENSIONS, b0 as MailAttachment, N as ChatCryptoContext } from './browser-DDboSTjo.js';
|
|
2
|
+
export { A as ACCOUNT_VENDOR, a as AccountSyncResult, b as ActivityKind, c as ActivityResponse, d as Arbi, e as ArbiApiError, f as ArbiError, g as ArbiHostSession, h as ArbiOptions, i as ArbiSessionExpiredError, j as ArbiWorkspaceChangedError, k as ArbiWorkspaceSupersededError, l as AskHandlers, m as AskRequest, n as AttendeeRead, o as AuthContext, q as AuthMode, r as AuthenticatedClient, B as BookingConfirmation, s as BookingPage, t as BookingPageWriteBody, u as BookingRequestBody, v as BridgeTokensOptions, C as CalDavConnectBody, w as CalDavProfile, x as CalendarAccount, y as CalendarAccountKind, z as CalendarCreateBody, D as CalendarEvent, E as CalendarKeys, F as CalendarRead, G as CalendarSettings, H as CalendarSettingsBody, I as CalendarUpdate, J as CalendarWindow, K as CallApiError, L as ChatAttachmentFile, M as ChatAttachmentInput, O as ChatKeyRing, P as ChatKind, Q as ChatMemberKey, R as ChatMemberResponse, S as ChatMessage, T as ChatMessageResponse, U as ChatResponse, W as CitationSummary, X as CitationToolSources, _ as CommandDescriptor, a0 as ConnectOptions, a1 as ConnectorCatalogEntry, a2 as ConnectorFolder, a3 as ConnectorSyncProgress, a4 as ConnectorSyncStatus, a5 as ConnectorVendorKey, a6 as ConnectorVisibilitySettings, a7 as ContextUsage, a8 as ConversationResponse, a9 as ConversationUsageResponse, ac as CreateWorkRequest, ad as CreateWorkflowRequest, ae as DEFAULT_AI_USD_PER_GBP, af as DOC_TERMINAL_STATUSES, ag as DRIVE_SYNC_VENDORS, ah as DateTimeSpec, ai as DecryptedChat, aj as DecryptedChatMessage, ak as DeploymentHouseTemplate, al as DocInfo, am as DocInfoMap, an as DocNameMap, ao as DocumentAutomationAction, ap as DocumentListFields, aq as DocumentListOrder, ar as DocumentSelector, as as DocumentWaiter, at as DocumentWaiterOptions, au as DriveSyncProgress, av as DriveSyncSummary, aw as DuplicateContactError, ax as ENTITY_KINDS, ay as EditScope, az as EntityKind, aA as EventCreateBody, aB as EventPatchBody, aC as FLAT_TAG_KINDS, aG as FindTimeParams, aH as FormattedWsMessage, aI as FreeBusyEntry, aJ as FullContextSelection, aK as GOOGLE_VENDORS, aL as HolidayCountry, aM as HouseTemplateCandidate, aN as IMANAGE_VENDORS, aO as IdentityErrorCode, aP as IdentityPurchase, aQ as IdentityState, aR as IdentityStatus, aS as ImportResult, aT as InvitationRead, aU as LinkedRun, aV as ListAllOptions, aW as ListEventsParams, aY as ListPaginatedOptions, aZ as MAILBOX_SYNC_VENDORS, a_ as MAX_RETRIEVE_DOC_IDS, a$ as MICROSOFT_VENDORS, b1 as MessageLevel, b2 as OAuthAccountKind, b3 as OutputItemDone, b4 as OverlayItem, b5 as OverlayLayerName, b6 as PRESENCE_KINDS, b7 as PROMPT_CONTEXT_CHARS, b8 as ParsedSlashCommand, b9 as PendingAuthResponse, ba as PersonKey, bb as PlanStepsError, bc as PlanWorkRequest, bd as ProductResponse, be as ProjectAddonKind, bf as ProjectAddonSettingsRequest, bg as ProjectBudget, bh as ProjectCheckoutRequest, bi as ProjectConversationUsageResponse, bj as ProjectCreateOptions, bk as ProjectDetails, bl as ProjectEventKind, bm as ProjectEventResponse, bn as ProjectInvoicesResponse, bo as ProjectNextPeriodAddonsRequest, bp as ProjectPlanChangeRequest, bq as ProjectQuoteRequest, br as ProjectResponse, bs as ProjectUpdateRequest, bt as ProjectUsageResponse, bu as PublicBookingError, bv as PublicBookingPage, bw as QuotaExceeded, bx as RaisedSignal, by as ReconnectOptions, bz as ReconnectableWsConnection, bA as ResolvedCitation, bB as ResolvedRecipient, bC as RespondParams, bD as RespondPartstat, bE as RoomCreateBody, bF as RoomQuery, bG as RoomRead, bH as RunProgress, bI as RunStats, bJ as RunStep, bK as RunWaitingOn, bL as SHAREPOINT_VENDORS, bM as SSEEvent, bN as SSEStreamCallbacks, bO as SSEStreamResult, bP as STEP_FIELD_OPTION_TONES, bQ as STOP_ID_WAIT_MS, bR as STOP_REPEAT_WINDOW_MS, bT as ScopedTarget, bU as SearchChunk, bV as SendBack, bW as ShareRead, bX as ShareRole, bY as SkillSummary, b_ as SlackConnectionStatus, b$ as StepActionRequest, c0 as StepActivityEvent, c1 as StepAssignee, c2 as StepDisplay, c3 as StepField, c4 as StepFieldOption, c5 as StepFieldOptionTone, c6 as StepKind, c7 as StepPhase, c8 as StepSignal, c9 as StepSignalWhen, ca as StepState, cb as StepStatus, cc as SubagentBranchRecord, cd as SubagentLaneInfo, ce as SubmitBackgroundQueryOptions, cf as SubscribeParams, cg as SyncTriggerResult, ch as TAG_KINDS, ci as TAG_NESTING_MAX_DEPTH, cj as TagChange, ck as TagFieldDefinition, cl as TagGroup, cm as TagKind, cn as TagKindField, co as TagKindSchema, cp as TagLinks, cq as TagListQuery, cr as TagNode, cs as TagResponse, ct as TagScope, cu as TagTreeRow, cv as TaskPlan, cw as TaskPlanStep, cx as TaxQuoteResponse, cy as Thread, cz as ThreadsResponse, cA as TimeSuggestion, cB as TurnRequest, cC as UpdateConversationRequest, cE as UpdateWorkflowRequest, cI as UploadDocumentsOptions, cK as UploadProgressListener, cM as UsageBreakdown, cN as UserConnectorEntry, cO as UserDailyUsageResponse, cP as UserInfo, cQ as WebSocketAuthError, cR as WeeklyHoursSpec, cS as WorkStatus, cT as WorkflowAuthMode, cU as WorkflowResponse, cV as WorkflowRunHistoryResponse, cW as WorkflowRunResponse, cX as WorkspaceContext, cY as WorkspaceOpenResponse, cZ as WsConnection, c_ as account, c$ as agentconfig, d0 as agents, d1 as appendTranscriptionHints, d2 as assistant, d3 as authenticatedFetch, d4 as bookPublicSlot, d5 as buildCitationChunkData, d6 as buildDocNameMap, d7 as buildDocumentTools, d8 as buildFactsContextTool, d9 as buildRetrievalChunkTool, da as buildRetrievalFullContextTool, db as buildRetrievalTocTool, dc as buildTurnRequest, dd as calendar, de as calls, df as canTagHaveParent, dg as cancelPublicBooking, dh as chats, di as computeRunStats, dj as connectErrorMessage, dk as connectWebSocket, dl as connectWithReconnect, dm as connectors, dn as consumeSSEStream, dp as contacts, dq as continuityPrompt, dr as conversations, ds as countCitations, dt as createAuthenticatedClient, du as createDocumentWaiter, dv as createIndexAssigner, dw as defaultKindForFormat, dx as doctags, dy as documents, dz as estimateDraftTokens, dA as extractDocumentIdsFromMessages, dB as extractFactIdsFromMessages, dC as extractSubagentLanes, dD as facts, dE as files, dF as filterDocumentTags, dG as filterSkills, dH as findLeafForTaskMessage, dI as findMainSiblingLeaf, dJ as findReplyTarget, dK as findSubagentRunId, dL as flattenTagTree, dM as formatAgentStepLabel, dN as formatFileSize, dO as formatGbp, dP as formatGbpPerMillionTokens, dQ as formatItemLabel, dR as formatStreamSummary, dS as formatTokens, dT as formatUserName, dU as formatWorkspaceChoices, dV as formatWsMessage, dW as generateEncryptedWorkspaceKey, dX as generateNewWorkspaceKey, dY as getAgentStepLabel, dZ as getAttachableRunId, d_ as getChildTags, d$ as getContextRemainingPercent, e0 as getContextUsedPercent, e1 as getContextUsedTokens, e2 as getCurrentStep, e3 as getEligibleParentTags, e4 as getErrorCode, e5 as getErrorMessage, e6 as getPublicBookingPage, e7 as getRawWorkspaceKey, e8 as getRunToAttach, e9 as getRunToCancel, ea as getStepDisplay, eb as getStepTool, ec as getSubagentBranchRecord, ed as getTagDescendantIds, ee as health, ef as houseTemplates, eg as hydrateAgentSteps, ei as identityErrorCode, eh as identityVerification, ej as isAnnotationTag, ek as isConnectorVendorVisible, el as isDriveSyncVendor, em as isEntityTag, en as isFlatKind, eo as isLabelTag, ep as isMailboxSyncVendor, eq as isNearAiUsageBudget, er as isPresenceTag, es as isSharePointVendor, et as isSharedSkill, eu as isTraceItem, ev as mail, ew as mergeAgentSteps, ex as notifications, ey as parseSSEEvents, ez as parseSlashCommand, eA as parseSlashTokenInProgress, eB as performPasswordLogin, eC as performSigningKeyLogin, eD as performSsoDeviceFlowLogin, eE as pickMainThread, eF as profile, eG as progressFetch, eH as projects, eI as quotaExceededFrom, eJ as quotaFromStreamError, eK as reduceOutputItem, eL as refusalReason, eM as requireData, eN as requireOk, eO as resolveAuth, eP as resolveCitations, eQ as resolveSummary, eR as resolveWorkspace, eS as responses, eT as searchChunks, eU as selectFullContextDocument, eV as selectWorkspace, eW as selectWorkspaceById, eX as sessions, eY as settings, eZ as signatureRequests, e_ as sliceToSubagentThread, e$ as streamSSE, f0 as stripCitationMarkdown, f1 as subagentJobLabel, f2 as summarizeCitations, f3 as tagUseCount, f4 as tags, f5 as tagsForScope, f6 as tagsOfGroup, f7 as topLevelAgentSteps, f8 as uploadSkill, f9 as usdToGbp, fa as work, fb as workflowSteps, fc as workflows, fd as workspaces, fe as wouldCreateTagCycle } from './browser-DDboSTjo.js';
|
|
3
3
|
import { SessionPersistence, ArbiClient, components } from '@arbidocs/client';
|
|
4
4
|
export { CallPeer, LoginProfile } from '@arbidocs/client';
|
|
5
5
|
export { b as AgentStepEvent, d as ArtifactEvent, M as MailDraftSSEEvent, e as MessageMetadataPayload, f as MessageQueuedEvent, O as OutputTokensDetails, R as ResponseCompletedEvent, g as ResponseContentPartAddedEvent, h as ResponseCreatedEvent, i as ResponseFailedEvent, j as ResponseOutputItemAddedEvent, k as ResponseOutputItemDoneEvent, l as ResponseOutputTextDeltaEvent, m as ResponseOutputTextDoneEvent, n as ResponseUsage, S as SSEStreamStartData, T as TokenBudgetContext, U as UserInputRequestEvent, o as UserMessageEvent } from './sse-types-BbR7JG5o.js';
|
package/dist/index.js
CHANGED
|
@@ -3493,6 +3493,24 @@ var ArbiSessionExpiredError = class extends ArbiError {
|
|
|
3493
3493
|
this.name = "ArbiSessionExpiredError";
|
|
3494
3494
|
}
|
|
3495
3495
|
};
|
|
3496
|
+
var ArbiWorkspaceSupersededError = class extends ArbiError {
|
|
3497
|
+
constructor(workspaceId, supersededBy) {
|
|
3498
|
+
super(`Opening ${workspaceId} was superseded by opening ${supersededBy}`);
|
|
3499
|
+
this.workspaceId = workspaceId;
|
|
3500
|
+
this.supersededBy = supersededBy;
|
|
3501
|
+
this.name = "ArbiWorkspaceSupersededError";
|
|
3502
|
+
}
|
|
3503
|
+
workspaceId;
|
|
3504
|
+
supersededBy;
|
|
3505
|
+
};
|
|
3506
|
+
var ArbiWorkspaceChangedError = class extends ArbiError {
|
|
3507
|
+
constructor(workspaceId) {
|
|
3508
|
+
super(`The workspace changed while reading ${workspaceId}`);
|
|
3509
|
+
this.workspaceId = workspaceId;
|
|
3510
|
+
this.name = "ArbiWorkspaceChangedError";
|
|
3511
|
+
}
|
|
3512
|
+
workspaceId;
|
|
3513
|
+
};
|
|
3496
3514
|
function detailText(detail) {
|
|
3497
3515
|
if (typeof detail === "string") return detail || void 0;
|
|
3498
3516
|
if (Array.isArray(detail)) {
|
|
@@ -5048,7 +5066,8 @@ async function* listPaginated(arbi, options = {}) {
|
|
|
5048
5066
|
order = "id_asc",
|
|
5049
5067
|
fields,
|
|
5050
5068
|
signal,
|
|
5051
|
-
lookahead = 1
|
|
5069
|
+
lookahead = 1,
|
|
5070
|
+
workspaceExtId
|
|
5052
5071
|
} = options;
|
|
5053
5072
|
const fetchPage = async (pageOffset, limit) => {
|
|
5054
5073
|
const query2 = {
|
|
@@ -5057,6 +5076,7 @@ async function* listPaginated(arbi, options = {}) {
|
|
|
5057
5076
|
order
|
|
5058
5077
|
};
|
|
5059
5078
|
if (fields) query2.fields = fields;
|
|
5079
|
+
if (workspaceExtId) query2.workspace_ext_id = workspaceExtId;
|
|
5060
5080
|
const { data, error } = await arbi.fetch.GET("/v1/document/list", {
|
|
5061
5081
|
params: { query: query2 },
|
|
5062
5082
|
signal
|
|
@@ -5064,7 +5084,11 @@ async function* listPaginated(arbi, options = {}) {
|
|
|
5064
5084
|
if (error) {
|
|
5065
5085
|
throw new Error(typeof error === "string" ? error : JSON.stringify(error));
|
|
5066
5086
|
}
|
|
5067
|
-
|
|
5087
|
+
const page = data ?? [];
|
|
5088
|
+
if (workspaceExtId && page.some((doc) => doc.workspace_ext_id !== workspaceExtId)) {
|
|
5089
|
+
throw new ArbiError(`The server returned another workspace's documents for ${workspaceExtId}`);
|
|
5090
|
+
}
|
|
5091
|
+
return page;
|
|
5068
5092
|
};
|
|
5069
5093
|
if (signal?.aborted) return;
|
|
5070
5094
|
const depth = Math.max(1, Math.min(lookahead, MAX_PAGES));
|
|
@@ -10389,12 +10413,21 @@ function tokenExpiresWithin(token, seconds) {
|
|
|
10389
10413
|
const expiresAt = readSessionClaims(token)?.expiresAt;
|
|
10390
10414
|
return expiresAt != null && expiresAt - Date.now() < seconds * 1e3;
|
|
10391
10415
|
}
|
|
10416
|
+
var WorkspaceOpenIntent = class {
|
|
10417
|
+
constructor(workspaceId) {
|
|
10418
|
+
this.workspaceId = workspaceId;
|
|
10419
|
+
}
|
|
10420
|
+
workspaceId;
|
|
10421
|
+
result = null;
|
|
10422
|
+
};
|
|
10392
10423
|
var Arbi = class {
|
|
10393
10424
|
client = null;
|
|
10394
10425
|
loginResult = null;
|
|
10395
10426
|
userProfile = null;
|
|
10396
10427
|
profileListeners = /* @__PURE__ */ new Set();
|
|
10397
10428
|
currentWorkspaceId = null;
|
|
10429
|
+
/** The latest `selectWorkspace` asked for: only it may open when its turn comes. */
|
|
10430
|
+
openIntent = null;
|
|
10398
10431
|
chatCryptoContext = null;
|
|
10399
10432
|
/** The chat keys I hold, opened once per set of epochs (`chatRingSignature`). */
|
|
10400
10433
|
chatRings = /* @__PURE__ */ new Map();
|
|
@@ -10630,6 +10663,38 @@ var Arbi = class {
|
|
|
10630
10663
|
* documents, which are listed page by page). A public workspace has no key and opens without one.
|
|
10631
10664
|
*/
|
|
10632
10665
|
async selectWorkspace(workspaceId) {
|
|
10666
|
+
const client = this.requireClient();
|
|
10667
|
+
this.requireLogin();
|
|
10668
|
+
const intent = new WorkspaceOpenIntent(workspaceId);
|
|
10669
|
+
this.openIntent = intent;
|
|
10670
|
+
client.session.setSelectedWorkspace(workspaceId);
|
|
10671
|
+
const result = client.workspaceOpens.run(
|
|
10672
|
+
() => workspaceId,
|
|
10673
|
+
async () => {
|
|
10674
|
+
const latest = this.openIntent;
|
|
10675
|
+
if (latest && latest !== intent) return latest;
|
|
10676
|
+
const opened = await this.openOnServer(workspaceId);
|
|
10677
|
+
this.currentWorkspaceId = workspaceId;
|
|
10678
|
+
return opened;
|
|
10679
|
+
}
|
|
10680
|
+
).then(
|
|
10681
|
+
(outcome) => {
|
|
10682
|
+
if (!(outcome instanceof WorkspaceOpenIntent)) return outcome;
|
|
10683
|
+
if (outcome.workspaceId === workspaceId && outcome.result) return outcome.result;
|
|
10684
|
+
throw new ArbiWorkspaceSupersededError(workspaceId, outcome.workspaceId);
|
|
10685
|
+
},
|
|
10686
|
+
(error) => {
|
|
10687
|
+
if (this.openIntent === intent) {
|
|
10688
|
+
client.session.setSelectedWorkspace(this.currentWorkspaceId);
|
|
10689
|
+
}
|
|
10690
|
+
throw error;
|
|
10691
|
+
}
|
|
10692
|
+
);
|
|
10693
|
+
intent.result = result;
|
|
10694
|
+
return result;
|
|
10695
|
+
}
|
|
10696
|
+
/** `POST /open` with the workspace's key sealed to this session (none for a public workspace). */
|
|
10697
|
+
async openOnServer(workspaceId) {
|
|
10633
10698
|
const client = this.requireClient();
|
|
10634
10699
|
const lr2 = this.requireLogin();
|
|
10635
10700
|
const open = async (workspaceKey) => requireData(
|
|
@@ -10642,21 +10707,40 @@ var Arbi = class {
|
|
|
10642
10707
|
const listed = await client.workspaceKeys.wrappedKey(workspaceId).catch((error) => {
|
|
10643
10708
|
throw new ArbiError(error instanceof Error ? error.message : String(error));
|
|
10644
10709
|
});
|
|
10645
|
-
|
|
10710
|
+
if (!listed.wrappedKey) return open("");
|
|
10711
|
+
return this.withWrappedKey(
|
|
10646
10712
|
workspaceId,
|
|
10647
10713
|
async (wrappedKey) => open(
|
|
10648
|
-
await
|
|
10714
|
+
await generateEncryptedWorkspaceKey(
|
|
10649
10715
|
client,
|
|
10650
|
-
workspaceId,
|
|
10651
10716
|
wrappedKey,
|
|
10652
10717
|
lr2.serverSessionKey,
|
|
10653
10718
|
client.crypto.bytesToBase64(lr2.signingPrivateKey)
|
|
10654
10719
|
)
|
|
10655
10720
|
)
|
|
10656
10721
|
);
|
|
10657
|
-
|
|
10658
|
-
|
|
10659
|
-
|
|
10722
|
+
}
|
|
10723
|
+
/** Resolves once no workspace open is running or waiting (a switch has landed on the server). */
|
|
10724
|
+
workspaceSettled() {
|
|
10725
|
+
return this.client ? this.client.workspaceOpens.idle() : Promise.resolve();
|
|
10726
|
+
}
|
|
10727
|
+
/**
|
|
10728
|
+
* Run `read` — a request answered from the session's open workspace — for `workspaceId`, and
|
|
10729
|
+
* keep its answer only if it can only be that workspace's: once no open is pending, the open
|
|
10730
|
+
* workspace must be `workspaceId` when it is sent and still be when it returns, with no open
|
|
10731
|
+
* started in between. Otherwise it throws `ArbiWorkspaceChangedError` and nothing it returned
|
|
10732
|
+
* is kept, so a list read across a switch can never be cached as another workspace's.
|
|
10733
|
+
*/
|
|
10734
|
+
async readInWorkspace(workspaceId, read) {
|
|
10735
|
+
const opens = this.requireClient().workspaceOpens;
|
|
10736
|
+
await opens.idle();
|
|
10737
|
+
const generation = opens.generation;
|
|
10738
|
+
if (this.currentWorkspaceId !== workspaceId) throw new ArbiWorkspaceChangedError(workspaceId);
|
|
10739
|
+
const result = await read();
|
|
10740
|
+
if (opens.generation !== generation || this.currentWorkspaceId !== workspaceId) {
|
|
10741
|
+
throw new ArbiWorkspaceChangedError(workspaceId);
|
|
10742
|
+
}
|
|
10743
|
+
return result;
|
|
10660
10744
|
}
|
|
10661
10745
|
/**
|
|
10662
10746
|
* Subscribe to "the session cannot be recovered". Fires when a request failed with 401 or
|
|
@@ -10678,6 +10762,7 @@ var Arbi = class {
|
|
|
10678
10762
|
this.loginResult = null;
|
|
10679
10763
|
this.userProfile = null;
|
|
10680
10764
|
this.currentWorkspaceId = null;
|
|
10765
|
+
this.openIntent = null;
|
|
10681
10766
|
this.chatCryptoContext = null;
|
|
10682
10767
|
this.chatRings.clear();
|
|
10683
10768
|
for (const listener of [...this.sessionExpiredListeners]) listener();
|
|
@@ -10725,6 +10810,7 @@ var Arbi = class {
|
|
|
10725
10810
|
this.loginResult = null;
|
|
10726
10811
|
this.userProfile = null;
|
|
10727
10812
|
this.currentWorkspaceId = null;
|
|
10813
|
+
this.openIntent = null;
|
|
10728
10814
|
this.chatCryptoContext = null;
|
|
10729
10815
|
this.chatRings.clear();
|
|
10730
10816
|
}
|
|
@@ -11119,7 +11205,16 @@ var Arbi = class {
|
|
|
11119
11205
|
* }
|
|
11120
11206
|
* ```
|
|
11121
11207
|
*/
|
|
11122
|
-
listPaginated: (options) =>
|
|
11208
|
+
listPaginated: (options) => {
|
|
11209
|
+
const { workspaceId, ...rest } = options ?? {};
|
|
11210
|
+
if (!workspaceId) return listPaginated(this.requireClient(), rest);
|
|
11211
|
+
const client = this.requireClient();
|
|
11212
|
+
const open = () => this.openWorkspace(workspaceId);
|
|
11213
|
+
return (async function* () {
|
|
11214
|
+
await open();
|
|
11215
|
+
yield* listPaginated(client, { ...rest, workspaceExtId: workspaceId });
|
|
11216
|
+
})();
|
|
11217
|
+
},
|
|
11123
11218
|
/**
|
|
11124
11219
|
* Collect all workspace documents into a single array using sequential pagination.
|
|
11125
11220
|
*
|
|
@@ -13885,6 +13980,6 @@ function getRunToAttach(localGeneration, messages) {
|
|
|
13885
13980
|
return getAttachableRunId(messages);
|
|
13886
13981
|
}
|
|
13887
13982
|
|
|
13888
|
-
export { ACCOUNT_VENDOR, Arbi, ArbiApiError, ArbiError, ArbiSessionExpiredError, CallApiError, ClaudeOrchestrator, DEFAULT_AI_USD_PER_GBP, DOC_TERMINAL_STATUSES, DRIVE_SYNC_VENDORS, DuplicateContactError, ENTITY_KINDS, FLAT_TAG_KINDS, FileConfigStore, GOOGLE_VENDORS, IMANAGE_VENDORS, MAILBOX_SYNC_VENDORS, MAX_RETRIEVE_DOC_IDS, MICROSOFT_VENDORS, OpenClawOrchestrator, PRESENCE_KINDS, PROMPT_CONTEXT_CHARS, PlanStepsError, PublicBookingError, SHAREPOINT_VENDORS, STEP_FIELD_OPTION_TONES, STOP_ID_WAIT_MS, STOP_REPEAT_WINDOW_MS, TAG_KINDS, TAG_NESTING_MAX_DEPTH, WebSocketAuthError, account_exports as account, agentconfig_exports as agentconfig, agents_exports as agents, appendTranscriptionHints, assistant_exports as assistant, authenticatedFetch, bookPublicSlot, buildCitationChunkData, buildDocNameMap, buildDocumentTools, buildFactsContextTool, buildRetrievalChunkTool, buildRetrievalFullContextTool, buildRetrievalTocTool, buildTurnRequest, calendar_exports as calendar, calls_exports as calls, canTagHaveParent, cancelPublicBooking, chats_exports as chats, computeRunStats, connectErrorMessage, connectWebSocket, connectWithReconnect, connectors_exports as connectors, consumeSSEStream, contacts_exports as contacts, continuityPrompt, conversations_exports as conversations, countCitations, createAuthenticatedClient, createDocumentWaiter, createIndexAssigner, defaultKindForFormat, device_flow_exports as deviceFlow, doctags_exports as doctags, documents_exports as documents, documents_node_exports as documentsNode, estimateDraftTokens, extractDocumentIdsFromMessages, extractFactIdsFromMessages, extractSubagentLanes, facts_exports as facts, files_exports as files, filterDocumentTags, filterSkills, findLeafForTaskMessage, findMainSiblingLeaf, findReplyTarget, findSubagentRunId, firm_exports as firm, flattenTagTree, formatAgentStepLabel, formatFileSize, formatGbp, formatGbpPerMillionTokens, formatItemLabel, formatStreamSummary, formatTokens, formatUserName, formatWorkspaceChoices, formatWsMessage, generateEncryptedWorkspaceKey, generateNewWorkspaceKey, getAgentStepLabel, getAttachableRunId, getChildTags, getContextRemainingPercent, getContextUsedPercent, getContextUsedTokens, getCurrentStep, getEligibleParentTags, getErrorCode, getErrorMessage, getPublicBookingPage, getRawWorkspaceKey, getRunToAttach, getRunToCancel, getStepDisplay, getStepTool, getSubagentBranchRecord, getTagDescendantIds, health_exports as health, house_template_exports as houseTemplates, hydrateAgentSteps, identityErrorCode, identity_exports as identityVerification, isAnnotationTag, isConnectorVendorVisible, isDriveSyncVendor, isEntityTag, isFlatKind, isLabelTag, isMailboxSyncVendor, isNearAiUsageBudget, isPresenceTag, isSharePointVendor, isSharedSkill, isTraceItem, listen_exports as listen, mail_exports as mail, mail_node_exports as mailNode, mergeAgentSteps, notifications_exports as notifications, parseSSEEvents, parseSlashCommand, parseSlashTokenInProgress, performPasswordLogin, performSigningKeyLogin, performSsoDeviceFlowLogin, pickMainThread, profile_exports as profile, progressFetch, projects_exports as projects, quotaExceededFrom, quotaFromStreamError, reduceOutputItem, refusalReason, requireData, requireOk, resolveAuth, resolveCitations, resolveSummary, resolveWorkspace, responses_exports as responses, searchChunks, selectFullContextDocument, selectWorkspace, selectWorkspaceById, sessions_exports as sessions, settings_exports as settings, signature_requests_exports as signatureRequests, sliceToSubagentThread, startDmListener, streamSSE, stripCitationMarkdown, subagentJobLabel, summarizeCitations, tagUseCount, tags_exports as tags, tagsForScope, tagsOfGroup, topLevelAgentSteps, uploadSkill, usdToGbp, work_exports as work, workflow_steps_exports as workflowSteps, workflows_exports as workflows, workspaces_exports as workspaces, wouldCreateTagCycle };
|
|
13983
|
+
export { ACCOUNT_VENDOR, Arbi, ArbiApiError, ArbiError, ArbiSessionExpiredError, ArbiWorkspaceChangedError, ArbiWorkspaceSupersededError, CallApiError, ClaudeOrchestrator, DEFAULT_AI_USD_PER_GBP, DOC_TERMINAL_STATUSES, DRIVE_SYNC_VENDORS, DuplicateContactError, ENTITY_KINDS, FLAT_TAG_KINDS, FileConfigStore, GOOGLE_VENDORS, IMANAGE_VENDORS, MAILBOX_SYNC_VENDORS, MAX_RETRIEVE_DOC_IDS, MICROSOFT_VENDORS, OpenClawOrchestrator, PRESENCE_KINDS, PROMPT_CONTEXT_CHARS, PlanStepsError, PublicBookingError, SHAREPOINT_VENDORS, STEP_FIELD_OPTION_TONES, STOP_ID_WAIT_MS, STOP_REPEAT_WINDOW_MS, TAG_KINDS, TAG_NESTING_MAX_DEPTH, WebSocketAuthError, account_exports as account, agentconfig_exports as agentconfig, agents_exports as agents, appendTranscriptionHints, assistant_exports as assistant, authenticatedFetch, bookPublicSlot, buildCitationChunkData, buildDocNameMap, buildDocumentTools, buildFactsContextTool, buildRetrievalChunkTool, buildRetrievalFullContextTool, buildRetrievalTocTool, buildTurnRequest, calendar_exports as calendar, calls_exports as calls, canTagHaveParent, cancelPublicBooking, chats_exports as chats, computeRunStats, connectErrorMessage, connectWebSocket, connectWithReconnect, connectors_exports as connectors, consumeSSEStream, contacts_exports as contacts, continuityPrompt, conversations_exports as conversations, countCitations, createAuthenticatedClient, createDocumentWaiter, createIndexAssigner, defaultKindForFormat, device_flow_exports as deviceFlow, doctags_exports as doctags, documents_exports as documents, documents_node_exports as documentsNode, estimateDraftTokens, extractDocumentIdsFromMessages, extractFactIdsFromMessages, extractSubagentLanes, facts_exports as facts, files_exports as files, filterDocumentTags, filterSkills, findLeafForTaskMessage, findMainSiblingLeaf, findReplyTarget, findSubagentRunId, firm_exports as firm, flattenTagTree, formatAgentStepLabel, formatFileSize, formatGbp, formatGbpPerMillionTokens, formatItemLabel, formatStreamSummary, formatTokens, formatUserName, formatWorkspaceChoices, formatWsMessage, generateEncryptedWorkspaceKey, generateNewWorkspaceKey, getAgentStepLabel, getAttachableRunId, getChildTags, getContextRemainingPercent, getContextUsedPercent, getContextUsedTokens, getCurrentStep, getEligibleParentTags, getErrorCode, getErrorMessage, getPublicBookingPage, getRawWorkspaceKey, getRunToAttach, getRunToCancel, getStepDisplay, getStepTool, getSubagentBranchRecord, getTagDescendantIds, health_exports as health, house_template_exports as houseTemplates, hydrateAgentSteps, identityErrorCode, identity_exports as identityVerification, isAnnotationTag, isConnectorVendorVisible, isDriveSyncVendor, isEntityTag, isFlatKind, isLabelTag, isMailboxSyncVendor, isNearAiUsageBudget, isPresenceTag, isSharePointVendor, isSharedSkill, isTraceItem, listen_exports as listen, mail_exports as mail, mail_node_exports as mailNode, mergeAgentSteps, notifications_exports as notifications, parseSSEEvents, parseSlashCommand, parseSlashTokenInProgress, performPasswordLogin, performSigningKeyLogin, performSsoDeviceFlowLogin, pickMainThread, profile_exports as profile, progressFetch, projects_exports as projects, quotaExceededFrom, quotaFromStreamError, reduceOutputItem, refusalReason, requireData, requireOk, resolveAuth, resolveCitations, resolveSummary, resolveWorkspace, responses_exports as responses, searchChunks, selectFullContextDocument, selectWorkspace, selectWorkspaceById, sessions_exports as sessions, settings_exports as settings, signature_requests_exports as signatureRequests, sliceToSubagentThread, startDmListener, streamSSE, stripCitationMarkdown, subagentJobLabel, summarizeCitations, tagUseCount, tags_exports as tags, tagsForScope, tagsOfGroup, topLevelAgentSteps, uploadSkill, usdToGbp, work_exports as work, workflow_steps_exports as workflowSteps, workflows_exports as workflows, workspaces_exports as workspaces, wouldCreateTagCycle };
|
|
13889
13984
|
//# sourceMappingURL=index.js.map
|
|
13890
13985
|
//# sourceMappingURL=index.js.map
|