@arbidocs/sdk 0.4.130 → 0.4.132
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-BRF6pkOB.d.cts → browser-BsfRh5ih.d.cts} +29 -2
- package/dist/{browser-BRF6pkOB.d.ts → browser-BsfRh5ih.d.ts} +29 -2
- package/dist/browser.cjs +17 -0
- 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 +17 -0
- package/dist/browser.js.map +1 -1
- package/dist/index.cjs +18 -0
- 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 +18 -0
- 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 ActivityKind, a as ActivityResponse, d as AgentStepEvent, e as Arbi, f as ArbiApiError, g as ArbiError, i as
|
|
1
|
+
import { G as ConfigStore, D as CliConfig, E as CliCredentials, y as ChatSession, aV as SkippedFile, bq as UploadResult, n as AuthHeaders, bm as UploadBatchResult, bp as UploadOptions, bn as UploadDirectOptions, bo as UploadDirectResult, aS as SUPPORTED_EXTENSIONS, ab as MailAttachment, r as ChatCryptoContext } from './browser-BsfRh5ih.cjs';
|
|
2
|
+
export { A as ActivityKind, a as ActivityResponse, d as AgentStepEvent, e as Arbi, f as ArbiApiError, g as ArbiError, i as ArbiHostSession, j as ArbiOptions, k as ArbiSessionExpiredError, l as ArtifactEvent, m as AuthContext, o as AuthMode, p as AuthenticatedClient, C as ChatAttachmentFile, q as ChatAttachmentInput, s as ChatKeyRing, t as ChatKind, u as ChatMemberKey, v as ChatMemberResponse, w as ChatMessageResponse, x as ChatResponse, z as CitationSummary, B as CitationToolSources, F as CommandDescriptor, H as ConnectOptions, I as ConversationResponse, J as ConversationUsageResponse, M as CreateWorkRequest, N as CreateWorkflowRequest, O as DEFAULT_AI_USD_PER_GBP, P as DOC_TERMINAL_STATUSES, Q as DecryptedChat, R as DecryptedChatMessage, T as DocNameMap, U as DocumentAutomationAction, V as DocumentListFields, W as DocumentListOrder, X as DocumentSelector, Y as DocumentWaiter, Z as DocumentWaiterOptions, _ as FLAT_TAG_KINDS, a2 as FormattedWsMessage, a3 as IdentityErrorCode, a4 as IdentityPurchase, a5 as IdentityState, a6 as IdentityStatus, a7 as LinkedRun, a8 as ListAllOptions, aa as ListPaginatedOptions, ac as MailDraftSSEEvent, ad as MessageLevel, ae as MessageMetadataPayload, af as MessageQueuedEvent, ag as OutputTokensDetails, ah as ParsedSlashCommand, ai as PendingAuthResponse, aj as PlanStepsError, ak as PlanWorkRequest, am as ProjectBudget, an as ProjectConversationUsageResponse, ao as ProjectDetails, ap as ProjectEventKind, aq as ProjectEventResponse, ar as ProjectInvoicesResponse, as as ProjectResponse, at as ProjectUpdateRequest, au as ProjectUsageResponse, av as QueryOptions, aw as RaisedSignal, ax as ReconnectOptions, ay as ReconnectableWsConnection, az as ResolvedCitation, aA as ResolvedRecipient, aB as ResponseCompletedEvent, aC as ResponseContentPartAddedEvent, aD as ResponseCreatedEvent, aE as ResponseFailedEvent, aF as ResponseOutputItemAddedEvent, aG as ResponseOutputItemDoneEvent, aH as ResponseOutputTextDeltaEvent, aI as ResponseOutputTextDoneEvent, aJ as ResponseUsage, aK as RunProgress, aL as RunStep, aM as RunWaitingOn, aN as SSEEvent, aO as SSEStreamCallbacks, aP as SSEStreamResult, aQ as SSEStreamStartData, aR as STEP_FIELD_OPTION_TONES, aT as SendBack, aU as SkillSummary, aW as StepActionRequest, aX as StepActivityEvent, aY as StepAssignee, aZ as StepField, a_ as StepFieldOption, a$ as StepFieldOptionTone, b0 as StepKind, b1 as StepPhase, b2 as StepSignal, b3 as StepSignalWhen, b4 as StepState, b5 as StepStatus, b6 as SubmitBackgroundQueryOptions, b7 as TAG_KINDS, b8 as TagChange, b9 as TagFieldDefinition, ba as TagKind, bb as TagKindField, bc as TagKindSchema, bd as TagLinks, be as TagListQuery, bf as TagResponse, bg as TaskPlan, bh as TaskPlanStep, bi as TokenBudgetContext, bj as UpdateConversationRequest, bl as UpdateWorkflowRequest, br as UsageBreakdown, bs as UserDailyUsageResponse, bt as UserInfo, bu as UserInputRequestEvent, bv as UserMessageEvent, bw as WebSocketAuthError, bx as WorkStatus, by as WorkflowAuthMode, bz as WorkflowResponse, bA as WorkflowRunHistoryResponse, bB as WorkflowRunResponse, bC as WorkspaceContext, bD as WsConnection, bE as account, bF as agentconfig, bG as agents, bH as assistant, bI as authenticatedFetch, bJ as buildCitationChunkData, bK as buildDocNameMap, bL as buildFactsContextTool, bM as buildRetrievalChunkTool, bN as buildRetrievalFullContextTool, bO as buildRetrievalTocTool, bP as chats, bQ as connectWebSocket, bR as connectWithReconnect, bS as consumeSSEStream, bT as contacts, bU as conversations, bV as countCitations, bW as createAuthenticatedClient, bX as createDocumentWaiter, bY as doctags, bZ as documents, b_ as facts, b$ as files, c0 as filterSkills, c1 as formatAgentStepLabel, c2 as formatFileSize, c3 as formatGbp, c4 as formatGbpPerMillionTokens, c5 as formatItemLabel, c6 as formatStreamSummary, c7 as formatUserName, c8 as formatWorkspaceChoices, c9 as formatWsMessage, ca as generateEncryptedWorkspaceKey, cb as generateNewWorkspaceKey, cc as getErrorCode, cd as getErrorMessage, ce as getRawWorkspaceKey, cf as health, ch as identityErrorCode, cg as identityVerification, ci as mail, cj as notifications, ck as parseSSEEvents, cl as parseSlashCommand, cm as parseSlashTokenInProgress, cn as performPasswordLogin, co as performSigningKeyLogin, cp as performSsoDeviceFlowLogin, cq as profile, cr as projects, cs as requireData, ct as requireOk, cu as resolveAuth, cv as resolveCitations, cw as resolveWorkspace, cx as responses, cy as selectWorkspace, cz as selectWorkspaceById, cA as sessions, cB as settings, cC as signatureRequests, cD as streamSSE, cE as stripCitationMarkdown, cF as summarizeCitations, cG as tags, cH as usdToGbp, cI as work, cJ as workflowSteps, cK as workflows, cL as workspaces } from './browser-BsfRh5ih.cjs';
|
|
3
3
|
import { SessionStorageProvider, ArbiClient, components } from '@arbidocs/client';
|
|
4
4
|
export { LoginProfile } from '@arbidocs/client';
|
|
5
5
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { A as ActivityKind, a as ActivityResponse, d as AgentStepEvent, e as Arbi, f as ArbiApiError, g as ArbiError, i as
|
|
1
|
+
import { G as ConfigStore, D as CliConfig, E as CliCredentials, y as ChatSession, aV as SkippedFile, bq as UploadResult, n as AuthHeaders, bm as UploadBatchResult, bp as UploadOptions, bn as UploadDirectOptions, bo as UploadDirectResult, aS as SUPPORTED_EXTENSIONS, ab as MailAttachment, r as ChatCryptoContext } from './browser-BsfRh5ih.js';
|
|
2
|
+
export { A as ActivityKind, a as ActivityResponse, d as AgentStepEvent, e as Arbi, f as ArbiApiError, g as ArbiError, i as ArbiHostSession, j as ArbiOptions, k as ArbiSessionExpiredError, l as ArtifactEvent, m as AuthContext, o as AuthMode, p as AuthenticatedClient, C as ChatAttachmentFile, q as ChatAttachmentInput, s as ChatKeyRing, t as ChatKind, u as ChatMemberKey, v as ChatMemberResponse, w as ChatMessageResponse, x as ChatResponse, z as CitationSummary, B as CitationToolSources, F as CommandDescriptor, H as ConnectOptions, I as ConversationResponse, J as ConversationUsageResponse, M as CreateWorkRequest, N as CreateWorkflowRequest, O as DEFAULT_AI_USD_PER_GBP, P as DOC_TERMINAL_STATUSES, Q as DecryptedChat, R as DecryptedChatMessage, T as DocNameMap, U as DocumentAutomationAction, V as DocumentListFields, W as DocumentListOrder, X as DocumentSelector, Y as DocumentWaiter, Z as DocumentWaiterOptions, _ as FLAT_TAG_KINDS, a2 as FormattedWsMessage, a3 as IdentityErrorCode, a4 as IdentityPurchase, a5 as IdentityState, a6 as IdentityStatus, a7 as LinkedRun, a8 as ListAllOptions, aa as ListPaginatedOptions, ac as MailDraftSSEEvent, ad as MessageLevel, ae as MessageMetadataPayload, af as MessageQueuedEvent, ag as OutputTokensDetails, ah as ParsedSlashCommand, ai as PendingAuthResponse, aj as PlanStepsError, ak as PlanWorkRequest, am as ProjectBudget, an as ProjectConversationUsageResponse, ao as ProjectDetails, ap as ProjectEventKind, aq as ProjectEventResponse, ar as ProjectInvoicesResponse, as as ProjectResponse, at as ProjectUpdateRequest, au as ProjectUsageResponse, av as QueryOptions, aw as RaisedSignal, ax as ReconnectOptions, ay as ReconnectableWsConnection, az as ResolvedCitation, aA as ResolvedRecipient, aB as ResponseCompletedEvent, aC as ResponseContentPartAddedEvent, aD as ResponseCreatedEvent, aE as ResponseFailedEvent, aF as ResponseOutputItemAddedEvent, aG as ResponseOutputItemDoneEvent, aH as ResponseOutputTextDeltaEvent, aI as ResponseOutputTextDoneEvent, aJ as ResponseUsage, aK as RunProgress, aL as RunStep, aM as RunWaitingOn, aN as SSEEvent, aO as SSEStreamCallbacks, aP as SSEStreamResult, aQ as SSEStreamStartData, aR as STEP_FIELD_OPTION_TONES, aT as SendBack, aU as SkillSummary, aW as StepActionRequest, aX as StepActivityEvent, aY as StepAssignee, aZ as StepField, a_ as StepFieldOption, a$ as StepFieldOptionTone, b0 as StepKind, b1 as StepPhase, b2 as StepSignal, b3 as StepSignalWhen, b4 as StepState, b5 as StepStatus, b6 as SubmitBackgroundQueryOptions, b7 as TAG_KINDS, b8 as TagChange, b9 as TagFieldDefinition, ba as TagKind, bb as TagKindField, bc as TagKindSchema, bd as TagLinks, be as TagListQuery, bf as TagResponse, bg as TaskPlan, bh as TaskPlanStep, bi as TokenBudgetContext, bj as UpdateConversationRequest, bl as UpdateWorkflowRequest, br as UsageBreakdown, bs as UserDailyUsageResponse, bt as UserInfo, bu as UserInputRequestEvent, bv as UserMessageEvent, bw as WebSocketAuthError, bx as WorkStatus, by as WorkflowAuthMode, bz as WorkflowResponse, bA as WorkflowRunHistoryResponse, bB as WorkflowRunResponse, bC as WorkspaceContext, bD as WsConnection, bE as account, bF as agentconfig, bG as agents, bH as assistant, bI as authenticatedFetch, bJ as buildCitationChunkData, bK as buildDocNameMap, bL as buildFactsContextTool, bM as buildRetrievalChunkTool, bN as buildRetrievalFullContextTool, bO as buildRetrievalTocTool, bP as chats, bQ as connectWebSocket, bR as connectWithReconnect, bS as consumeSSEStream, bT as contacts, bU as conversations, bV as countCitations, bW as createAuthenticatedClient, bX as createDocumentWaiter, bY as doctags, bZ as documents, b_ as facts, b$ as files, c0 as filterSkills, c1 as formatAgentStepLabel, c2 as formatFileSize, c3 as formatGbp, c4 as formatGbpPerMillionTokens, c5 as formatItemLabel, c6 as formatStreamSummary, c7 as formatUserName, c8 as formatWorkspaceChoices, c9 as formatWsMessage, ca as generateEncryptedWorkspaceKey, cb as generateNewWorkspaceKey, cc as getErrorCode, cd as getErrorMessage, ce as getRawWorkspaceKey, cf as health, ch as identityErrorCode, cg as identityVerification, ci as mail, cj as notifications, ck as parseSSEEvents, cl as parseSlashCommand, cm as parseSlashTokenInProgress, cn as performPasswordLogin, co as performSigningKeyLogin, cp as performSsoDeviceFlowLogin, cq as profile, cr as projects, cs as requireData, ct as requireOk, cu as resolveAuth, cv as resolveCitations, cw as resolveWorkspace, cx as responses, cy as selectWorkspace, cz as selectWorkspaceById, cA as sessions, cB as settings, cC as signatureRequests, cD as streamSSE, cE as stripCitationMarkdown, cF as summarizeCitations, cG as tags, cH as usdToGbp, cI as work, cJ as workflowSteps, cK as workflows, cL as workspaces } from './browser-BsfRh5ih.js';
|
|
3
3
|
import { SessionStorageProvider, ArbiClient, components } from '@arbidocs/client';
|
|
4
4
|
export { LoginProfile } from '@arbidocs/client';
|
|
5
5
|
|
package/dist/index.js
CHANGED
|
@@ -6140,6 +6140,7 @@ __export(agents_exports, {
|
|
|
6140
6140
|
closeAgentSession: () => closeAgentSession,
|
|
6141
6141
|
createAgent: () => createAgent,
|
|
6142
6142
|
deleteAgents: () => deleteAgents,
|
|
6143
|
+
generateAgentAvatar: () => generateAgentAvatar,
|
|
6143
6144
|
getAgentConfig: () => getAgentConfig,
|
|
6144
6145
|
getAgentSession: () => getAgentSession,
|
|
6145
6146
|
getAuthorizeLimits: () => getAuthorizeLimits,
|
|
@@ -6180,6 +6181,15 @@ async function deleteAgents(arbi, agentExtIds) {
|
|
|
6180
6181
|
"Failed to delete agents"
|
|
6181
6182
|
);
|
|
6182
6183
|
}
|
|
6184
|
+
async function generateAgentAvatar(arbi, agentExtId, prompt) {
|
|
6185
|
+
return requireData(
|
|
6186
|
+
await arbi.fetch.POST("/v1/agents/{agent_ext_id}/avatar", {
|
|
6187
|
+
params: { path: { agent_ext_id: agentExtId } },
|
|
6188
|
+
body: { prompt }
|
|
6189
|
+
}),
|
|
6190
|
+
"Failed to generate the agent avatar"
|
|
6191
|
+
);
|
|
6192
|
+
}
|
|
6183
6193
|
async function authorizeAgent(arbi, agentExtId, workspaceExtId, ttlSeconds) {
|
|
6184
6194
|
return requireData(
|
|
6185
6195
|
await arbi.fetch.POST("/v1/agents/{agent_ext_id}/authorize", {
|
|
@@ -8318,6 +8328,12 @@ var Arbi = class {
|
|
|
8318
8328
|
options;
|
|
8319
8329
|
constructor(options) {
|
|
8320
8330
|
this.options = options;
|
|
8331
|
+
if (options.session) {
|
|
8332
|
+
this.client = options.session.client;
|
|
8333
|
+
this.loginResult = options.session.login;
|
|
8334
|
+
this.userProfile = options.session.login.profile ?? null;
|
|
8335
|
+
this.currentWorkspaceId = options.session.workspaceId ?? null;
|
|
8336
|
+
}
|
|
8321
8337
|
}
|
|
8322
8338
|
// ── Lifecycle ───────────────────────────────────────────────────────────
|
|
8323
8339
|
/**
|
|
@@ -9260,6 +9276,8 @@ var Arbi = class {
|
|
|
9260
9276
|
getConfig: (agentExtId) => getAgentConfig(this.requireClient(), agentExtId),
|
|
9261
9277
|
listWorkspaces: (agentExtId) => listAgentWorkspaces(this.requireClient(), agentExtId),
|
|
9262
9278
|
delete: (agentExtIds) => deleteAgents(this.requireClient(), agentExtIds),
|
|
9279
|
+
/** Generate an avatar from `prompt` and set it as the agent's picture. */
|
|
9280
|
+
generateAvatar: (agentExtId, prompt) => generateAgentAvatar(this.requireClient(), agentExtId, prompt),
|
|
9263
9281
|
/** Mint a TTL'd run session for an agent; see `grantTemporaryAccess` to also deposit a key. */
|
|
9264
9282
|
authorize: (agentExtId, workspaceId, ttlSeconds) => authorizeAgent(this.requireClient(), agentExtId, workspaceId, ttlSeconds),
|
|
9265
9283
|
authorizeLimits: () => getAuthorizeLimits(this.requireClient()),
|