@arbidocs/sdk 0.4.72 → 0.4.74

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.
@@ -1408,6 +1408,9 @@ declare function listConversations(arbi: ArbiClient): Promise<{
1408
1408
  workflow_ext_id?: string | null | undefined;
1409
1409
  agent_ext_id?: string | null | undefined;
1410
1410
  skill_ref?: string | null | undefined;
1411
+ skill_inputs?: {
1412
+ [x: string]: unknown;
1413
+ } | null | undefined;
1411
1414
  has_agent_action: boolean;
1412
1415
  auth_mode?: (components["schemas"]["src__models__work__AuthMode"] | null) | undefined;
1413
1416
  plan?: {
@@ -1418,6 +1421,22 @@ declare function listConversations(arbi: ArbiClient): Promise<{
1418
1421
  }[];
1419
1422
  max_passes: number;
1420
1423
  documents: string[];
1424
+ steps: {
1425
+ id: string;
1426
+ title: string;
1427
+ kind: "form" | "upload" | "agent" | "review";
1428
+ after?: string[] | null | undefined;
1429
+ skill?: string | null | undefined;
1430
+ prompt?: string | null | undefined;
1431
+ inputs?: {
1432
+ [x: string]: string;
1433
+ } | null | undefined;
1434
+ branch: boolean;
1435
+ requires_files: boolean;
1436
+ ui?: {
1437
+ [x: string]: unknown;
1438
+ } | null | undefined;
1439
+ }[];
1421
1440
  } | null | undefined;
1422
1441
  goal_state?: {
1423
1442
  [x: string]: unknown;
@@ -3234,6 +3253,7 @@ type UpdateConversationRequest = components['schemas']['UpdateConversationReques
3234
3253
  type CreateWorkRequest = components['schemas']['CreateWorkRequest'];
3235
3254
  type PendingAuthResponse = components['schemas']['PendingAuthResponse'];
3236
3255
  type PlanWorkRequest = components['schemas']['PlanWorkRequest'];
3256
+ type StepActionRequest = components['schemas']['StepActionRequest'];
3237
3257
  type TaskPlan = components['schemas']['TaskPlan'];
3238
3258
  type ActivityResponse = components['schemas']['ActivityResponse'];
3239
3259
  type ActivityKind = components['schemas']['ActivityKind'];
@@ -3252,6 +3272,16 @@ declare function createWork(arbi: ArbiClient, body: CreateWorkRequest): Promise<
3252
3272
  declare function runConversation(arbi: ArbiClient, conversationId: string): Promise<ConversationResponse>;
3253
3273
  /** What an unattended run waits on (agent email + session public key); 404 when nothing waits. */
3254
3274
  declare function getPendingAuth(arbi: ArbiClient, conversationId: string): Promise<PendingAuthResponse>;
3275
+ /**
3276
+ * A person finishes a step of a workflow run: completes a form (its inputs join the run's), an upload
3277
+ * or a review (the approval), or skips a step. The run then goes on to its next agent step.
3278
+ */
3279
+ declare function actOnStep(arbi: ArbiClient, conversationId: string, body: StepActionRequest): Promise<ConversationResponse>;
3280
+ /**
3281
+ * Tell people about a conversation (a notification each, e.g. "please review this"). Resolves with
3282
+ * the ids that were notified.
3283
+ */
3284
+ declare function notifyConversation(arbi: ArbiClient, conversationId: string, userIds: string[]): Promise<string[]>;
3255
3285
  /** The task's history, oldest first: created, run started, handed off, sent back, done and so on. */
3256
3286
  declare function getActivity(arbi: ArbiClient, conversationId: string): Promise<ActivityResponse[]>;
3257
3287
  /** Draft an editable plan (goal and acceptance checklist) from a plain objective. */
@@ -3264,17 +3294,20 @@ type work_ConversationResponse = ConversationResponse;
3264
3294
  type work_CreateWorkRequest = CreateWorkRequest;
3265
3295
  type work_PendingAuthResponse = PendingAuthResponse;
3266
3296
  type work_PlanWorkRequest = PlanWorkRequest;
3297
+ type work_StepActionRequest = StepActionRequest;
3267
3298
  type work_TaskPlan = TaskPlan;
3268
3299
  type work_UpdateConversationRequest = UpdateConversationRequest;
3269
3300
  type work_WorkStatus = WorkStatus;
3301
+ declare const work_actOnStep: typeof actOnStep;
3270
3302
  declare const work_createWork: typeof createWork;
3271
3303
  declare const work_getActivity: typeof getActivity;
3272
3304
  declare const work_getPendingAuth: typeof getPendingAuth;
3305
+ declare const work_notifyConversation: typeof notifyConversation;
3273
3306
  declare const work_planWork: typeof planWork;
3274
3307
  declare const work_runConversation: typeof runConversation;
3275
3308
  declare const work_updateConversation: typeof updateConversation;
3276
3309
  declare namespace work {
3277
- export { type work_ActivityKind as ActivityKind, type work_ActivityResponse as ActivityResponse, type work_AuthMode as AuthMode, type work_ConversationResponse as ConversationResponse, type work_CreateWorkRequest as CreateWorkRequest, type work_PendingAuthResponse as PendingAuthResponse, type work_PlanWorkRequest as PlanWorkRequest, type work_TaskPlan as TaskPlan, type work_UpdateConversationRequest as UpdateConversationRequest, type work_WorkStatus as WorkStatus, work_createWork as createWork, work_getActivity as getActivity, work_getPendingAuth as getPendingAuth, work_planWork as planWork, work_runConversation as runConversation, work_updateConversation as updateConversation };
3310
+ export { type work_ActivityKind as ActivityKind, type work_ActivityResponse as ActivityResponse, type work_AuthMode as AuthMode, type work_ConversationResponse as ConversationResponse, type work_CreateWorkRequest as CreateWorkRequest, type work_PendingAuthResponse as PendingAuthResponse, type work_PlanWorkRequest as PlanWorkRequest, type work_StepActionRequest as StepActionRequest, type work_TaskPlan as TaskPlan, type work_UpdateConversationRequest as UpdateConversationRequest, type work_WorkStatus as WorkStatus, work_actOnStep as actOnStep, work_createWork as createWork, work_getActivity as getActivity, work_getPendingAuth as getPendingAuth, work_notifyConversation as notifyConversation, work_planWork as planWork, work_runConversation as runConversation, work_updateConversation as updateConversation };
3278
3311
  }
3279
3312
 
3280
3313
  /**
@@ -4707,6 +4740,9 @@ declare class Arbi {
4707
4740
  workflow_ext_id?: string | null | undefined;
4708
4741
  agent_ext_id?: string | null | undefined;
4709
4742
  skill_ref?: string | null | undefined;
4743
+ skill_inputs?: {
4744
+ [x: string]: unknown;
4745
+ } | null | undefined;
4710
4746
  has_agent_action: boolean;
4711
4747
  auth_mode?: (components["schemas"]["src__models__work__AuthMode"] | null) | undefined;
4712
4748
  plan?: {
@@ -4717,6 +4753,22 @@ declare class Arbi {
4717
4753
  }[];
4718
4754
  max_passes: number;
4719
4755
  documents: string[];
4756
+ steps: {
4757
+ id: string;
4758
+ title: string;
4759
+ kind: "form" | "upload" | "agent" | "review";
4760
+ after?: string[] | null | undefined;
4761
+ skill?: string | null | undefined;
4762
+ prompt?: string | null | undefined;
4763
+ inputs?: {
4764
+ [x: string]: string;
4765
+ } | null | undefined;
4766
+ branch: boolean;
4767
+ requires_files: boolean;
4768
+ ui?: {
4769
+ [x: string]: unknown;
4770
+ } | null | undefined;
4771
+ }[];
4720
4772
  } | null | undefined;
4721
4773
  goal_state?: {
4722
4774
  [x: string]: unknown;
@@ -4948,6 +5000,9 @@ declare class Arbi {
4948
5000
  workflow_ext_id?: string | null;
4949
5001
  agent_ext_id?: string | null;
4950
5002
  skill_ref?: string | null;
5003
+ skill_inputs?: {
5004
+ [key: string]: unknown;
5005
+ } | null;
4951
5006
  has_agent_action: boolean;
4952
5007
  auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
4953
5008
  plan?: components["schemas"]["TaskPlan"] | null;
@@ -4988,6 +5043,9 @@ declare class Arbi {
4988
5043
  workflow_ext_id?: string | null;
4989
5044
  agent_ext_id?: string | null;
4990
5045
  skill_ref?: string | null;
5046
+ skill_inputs?: {
5047
+ [key: string]: unknown;
5048
+ } | null;
4991
5049
  has_agent_action: boolean;
4992
5050
  auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
4993
5051
  plan?: components["schemas"]["TaskPlan"] | null;
@@ -5028,6 +5086,9 @@ declare class Arbi {
5028
5086
  workflow_ext_id?: string | null;
5029
5087
  agent_ext_id?: string | null;
5030
5088
  skill_ref?: string | null;
5089
+ skill_inputs?: {
5090
+ [key: string]: unknown;
5091
+ } | null;
5031
5092
  has_agent_action: boolean;
5032
5093
  auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
5033
5094
  plan?: components["schemas"]["TaskPlan"] | null;
@@ -5059,12 +5120,58 @@ declare class Arbi {
5059
5120
  } | null;
5060
5121
  created_at: string;
5061
5122
  }[]>;
5123
+ /** Complete or skip a step of a workflow run; the run goes on to its next agent step. */
5124
+ actOnStep: (conversationId: string, body: StepActionRequest) => Promise<{
5125
+ label_ext_ids?: string[];
5126
+ external_id: string;
5127
+ title: string | null;
5128
+ created_by_ext_id: string;
5129
+ updated_by_ext_id?: string | null;
5130
+ created_at: string;
5131
+ updated_at: string;
5132
+ is_shared: boolean;
5133
+ message_count: number;
5134
+ last_message_actor?: components["schemas"]["ConversationTurnActor"] | null;
5135
+ last_message_ext_id?: string | null;
5136
+ last_message_role?: string | null;
5137
+ last_message_updated_at?: string | null;
5138
+ last_message_status?: string | null;
5139
+ assistant_mode: components["schemas"]["AssistantMode"];
5140
+ status?: components["schemas"]["WorkStatus"] | null;
5141
+ description?: string | null;
5142
+ due_at?: string | null;
5143
+ completed_at?: string | null;
5144
+ completed_by_ext_id?: string | null;
5145
+ parent_conversation_ext_id?: string | null;
5146
+ workflow_ext_id?: string | null;
5147
+ agent_ext_id?: string | null;
5148
+ skill_ref?: string | null;
5149
+ skill_inputs?: {
5150
+ [key: string]: unknown;
5151
+ } | null;
5152
+ has_agent_action: boolean;
5153
+ auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
5154
+ plan?: components["schemas"]["TaskPlan"] | null;
5155
+ goal_state?: {
5156
+ [key: string]: unknown;
5157
+ } | null;
5158
+ last_error?: string | null;
5159
+ pending_auth_request_id?: string | null;
5160
+ in_progress: boolean;
5161
+ active_response_id?: string | null;
5162
+ run_started_at?: string | null;
5163
+ owner_ext_id?: string | null;
5164
+ is_owner: boolean;
5165
+ }>;
5166
+ /** Notify people about a conversation (each gets a notification); resolves with who was. */
5167
+ notify: (conversationId: string, userIds: string[]) => Promise<string[]>;
5062
5168
  /** Draft an editable plan from an objective. */
5063
5169
  plan: (body: PlanWorkRequest) => Promise<{
5064
5170
  goal: string;
5065
5171
  criteria: components["schemas"]["TaskPlanCriterion"][];
5066
5172
  max_passes: number;
5067
5173
  documents: string[];
5174
+ steps: components["schemas"]["TaskPlanStep"][];
5068
5175
  }>;
5069
5176
  /**
5070
5177
  * Run a work item and, when the run is parked waiting for workspace access, grant the agent's
@@ -5096,6 +5203,9 @@ declare class Arbi {
5096
5203
  workflow_ext_id?: string | null;
5097
5204
  agent_ext_id?: string | null;
5098
5205
  skill_ref?: string | null;
5206
+ skill_inputs?: {
5207
+ [key: string]: unknown;
5208
+ } | null;
5099
5209
  has_agent_action: boolean;
5100
5210
  auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
5101
5211
  plan?: components["schemas"]["TaskPlan"] | null;
@@ -8565,4 +8675,4 @@ declare namespace identity {
8565
8675
  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 };
8566
8676
  }
8567
8677
 
8568
- export { type MessageLevel as $, type ActivityKind as A, type DecryptedDmNotification as B, type ChatSession as C, DOC_TERMINAL_STATUSES as D, type DeferredInterjectionEvent as E, type DmAttachmentFile as F, type DmAttachmentInput as G, type DmCryptoContext as H, type DocNameMap as I, type DocumentAutomationAction as J, type DocumentListFields as K, type DocumentListOrder as L, type DocumentSelector as M, type DocumentWaiter as N, type DocumentWaiterOptions as O, type FactResponse as P, type FactSearchRequest as Q, type FactSearchResponse as R, type FormattedWsMessage as S, type IdentityErrorCode as T, type IdentityPurchase as U, type IdentityState as V, type IdentityStatus as W, type ListAllOptions as X, type ListFactsOptions as Y, type ListPaginatedOptions as Z, type MailAttachment as _, type ActivityResponse as a, connectWebSocket as a$, type MessageMetadataPayload$1 as a0, type MessageQueuedEvent as a1, type OutputTokensDetails as a2, type ParsedSlashCommand as a3, type PendingAuthResponse as a4, type PlanWorkRequest as a5, type ProbeAnswerEvent as a6, type ProjectInvoicesResponse as a7, type ProjectUsageResponse as a8, type QueryOptions as a9, type UploadBatchResult as aA, type UploadDirectOptions as aB, type UploadDirectResult as aC, type UploadOptions as aD, type UploadResult as aE, type UserDailyUsageResponse as aF, type UserInfo as aG, type UserInputRequestEvent as aH, type UserMessageEvent as aI, WebSocketAuthError as aJ, type WorkStatus as aK, type WorkflowAuthMode as aL, type WorkflowResponse as aM, type WorkflowRunHistoryResponse as aN, type WorkflowRunResponse as aO, type WorkspaceContext as aP, type WsConnection as aQ, account as aR, agentconfig as aS, agents as aT, assistant as aU, authenticatedFetch as aV, buildDocNameMap as aW, buildFactsContextTool as aX, buildRetrievalChunkTool as aY, buildRetrievalFullContextTool as aZ, buildRetrievalTocTool as a_, type ReconnectOptions as aa, type ReconnectableWsConnection as ab, type ResolvedCitation as ac, type ResolvedRecipient as ad, type ResponseCompletedEvent as ae, type ResponseContentPartAddedEvent as af, type ResponseCreatedEvent as ag, type ResponseFailedEvent as ah, type ResponseOutputItemAddedEvent as ai, type ResponseOutputItemDoneEvent as aj, type ResponseOutputTextDeltaEvent as ak, type ResponseOutputTextDoneEvent as al, type ResponseUsage as am, type SSEEvent as an, type SSEStreamCallbacks as ao, type SSEStreamResult as ap, type SSEStreamStartData as aq, SUPPORTED_EXTENSIONS as ar, type SkillSummary as as, type SkippedFile as at, type SubmitBackgroundQueryOptions as au, type TaskPlan as av, type TokenBudgetContext as aw, type UpdateConversationRequest as ax, type UpdateFactRequest as ay, type UpdateWorkflowRequest as az, type AgentControlStateEvent as b, connectWithReconnect as b0, consumeSSEStream as b1, contacts as b2, conversations as b3, countCitations as b4, createAuthenticatedClient as b5, createDocumentWaiter as b6, dm as b7, doctags as b8, documents as b9, projects as bA, requireData as bB, requireOk as bC, resolveAuth as bD, resolveCitations as bE, resolveWorkspace as bF, responses as bG, selectWorkspace as bH, selectWorkspaceById as bI, sessions as bJ, settings as bK, streamSSE as bL, stripCitationMarkdown as bM, summarizeCitations as bN, tags as bO, work as bP, workflows as bQ, workspaces as bR, facts as ba, files as bb, filterSkills as bc, formatAgentStepLabel as bd, formatFileSize as be, formatItemLabel as bf, formatStreamSummary as bg, formatUserName as bh, formatWorkspaceChoices as bi, formatWsMessage as bj, generateEncryptedWorkspaceKey as bk, generateNewWorkspaceKey as bl, getErrorCode as bm, getErrorMessage as bn, getRawWorkspaceKey as bo, health as bp, identity as bq, identityErrorCode as br, mail as bs, parseSSEEvents as bt, parseSlashCommand as bu, parseSlashTokenInProgress as bv, performPasswordLogin as bw, performSigningKeyLogin as bx, performSsoDeviceFlowLogin as by, profile as bz, type AgentStepDeltaEvent as c, type AgentStepEvent as d, Arbi as e, ArbiApiError as f, ArbiError as g, type ArbiErrorEvent as h, type ArbiOptions as i, ArbiSessionExpiredError as j, type ArtifactEvent as k, type AuthContext as l, type AuthHeaders as m, type AuthMode as n, type AuthenticatedClient as o, type CitationSummary as p, type CliConfig as q, type CliCredentials as r, type CommandDescriptor as s, type ConfigStore as t, type ConnectOptions as u, type ConversationResponse as v, type CreateFactRequest as w, type CreateFactsRequest as x, type CreateWorkRequest as y, type CreateWorkflowRequest as z };
8678
+ export { type MessageLevel as $, type ActivityKind as A, type DecryptedDmNotification as B, type ChatSession as C, DOC_TERMINAL_STATUSES as D, type DeferredInterjectionEvent as E, type DmAttachmentFile as F, type DmAttachmentInput as G, type DmCryptoContext as H, type DocNameMap as I, type DocumentAutomationAction as J, type DocumentListFields as K, type DocumentListOrder as L, type DocumentSelector as M, type DocumentWaiter as N, type DocumentWaiterOptions as O, type FactResponse as P, type FactSearchRequest as Q, type FactSearchResponse as R, type FormattedWsMessage as S, type IdentityErrorCode as T, type IdentityPurchase as U, type IdentityState as V, type IdentityStatus as W, type ListAllOptions as X, type ListFactsOptions as Y, type ListPaginatedOptions as Z, type MailAttachment as _, type ActivityResponse as a, buildRetrievalTocTool as a$, type MessageMetadataPayload$1 as a0, type MessageQueuedEvent as a1, type OutputTokensDetails as a2, type ParsedSlashCommand as a3, type PendingAuthResponse as a4, type PlanWorkRequest as a5, type ProbeAnswerEvent as a6, type ProjectInvoicesResponse as a7, type ProjectUsageResponse as a8, type QueryOptions as a9, type UpdateWorkflowRequest as aA, type UploadBatchResult as aB, type UploadDirectOptions as aC, type UploadDirectResult as aD, type UploadOptions as aE, type UploadResult as aF, type UserDailyUsageResponse as aG, type UserInfo as aH, type UserInputRequestEvent as aI, type UserMessageEvent as aJ, WebSocketAuthError as aK, type WorkStatus as aL, type WorkflowAuthMode as aM, type WorkflowResponse as aN, type WorkflowRunHistoryResponse as aO, type WorkflowRunResponse as aP, type WorkspaceContext as aQ, type WsConnection as aR, account as aS, agentconfig as aT, agents as aU, assistant as aV, authenticatedFetch as aW, buildDocNameMap as aX, buildFactsContextTool as aY, buildRetrievalChunkTool as aZ, buildRetrievalFullContextTool as a_, type ReconnectOptions as aa, type ReconnectableWsConnection as ab, type ResolvedCitation as ac, type ResolvedRecipient as ad, type ResponseCompletedEvent as ae, type ResponseContentPartAddedEvent as af, type ResponseCreatedEvent as ag, type ResponseFailedEvent as ah, type ResponseOutputItemAddedEvent as ai, type ResponseOutputItemDoneEvent as aj, type ResponseOutputTextDeltaEvent as ak, type ResponseOutputTextDoneEvent as al, type ResponseUsage as am, type SSEEvent as an, type SSEStreamCallbacks as ao, type SSEStreamResult as ap, type SSEStreamStartData as aq, SUPPORTED_EXTENSIONS as ar, type SkillSummary as as, type SkippedFile as at, type StepActionRequest as au, type SubmitBackgroundQueryOptions as av, type TaskPlan as aw, type TokenBudgetContext as ax, type UpdateConversationRequest as ay, type UpdateFactRequest as az, type AgentControlStateEvent as b, connectWebSocket as b0, connectWithReconnect as b1, consumeSSEStream as b2, contacts as b3, conversations as b4, countCitations as b5, createAuthenticatedClient as b6, createDocumentWaiter as b7, dm as b8, doctags as b9, profile as bA, projects as bB, requireData as bC, requireOk as bD, resolveAuth as bE, resolveCitations as bF, resolveWorkspace as bG, responses as bH, selectWorkspace as bI, selectWorkspaceById as bJ, sessions as bK, settings as bL, streamSSE as bM, stripCitationMarkdown as bN, summarizeCitations as bO, tags as bP, work as bQ, workflows as bR, workspaces as bS, documents as ba, facts as bb, files as bc, filterSkills as bd, formatAgentStepLabel as be, formatFileSize as bf, formatItemLabel as bg, formatStreamSummary as bh, formatUserName as bi, formatWorkspaceChoices as bj, formatWsMessage as bk, generateEncryptedWorkspaceKey as bl, generateNewWorkspaceKey as bm, getErrorCode as bn, getErrorMessage as bo, getRawWorkspaceKey as bp, health as bq, identity as br, identityErrorCode as bs, mail as bt, parseSSEEvents as bu, parseSlashCommand as bv, parseSlashTokenInProgress as bw, performPasswordLogin as bx, performSigningKeyLogin as by, performSsoDeviceFlowLogin as bz, type AgentStepDeltaEvent as c, type AgentStepEvent as d, Arbi as e, ArbiApiError as f, ArbiError as g, type ArbiErrorEvent as h, type ArbiOptions as i, ArbiSessionExpiredError as j, type ArtifactEvent as k, type AuthContext as l, type AuthHeaders as m, type AuthMode as n, type AuthenticatedClient as o, type CitationSummary as p, type CliConfig as q, type CliCredentials as r, type CommandDescriptor as s, type ConfigStore as t, type ConnectOptions as u, type ConversationResponse as v, type CreateFactRequest as w, type CreateFactsRequest as x, type CreateWorkRequest as y, type CreateWorkflowRequest as z };
@@ -1408,6 +1408,9 @@ declare function listConversations(arbi: ArbiClient): Promise<{
1408
1408
  workflow_ext_id?: string | null | undefined;
1409
1409
  agent_ext_id?: string | null | undefined;
1410
1410
  skill_ref?: string | null | undefined;
1411
+ skill_inputs?: {
1412
+ [x: string]: unknown;
1413
+ } | null | undefined;
1411
1414
  has_agent_action: boolean;
1412
1415
  auth_mode?: (components["schemas"]["src__models__work__AuthMode"] | null) | undefined;
1413
1416
  plan?: {
@@ -1418,6 +1421,22 @@ declare function listConversations(arbi: ArbiClient): Promise<{
1418
1421
  }[];
1419
1422
  max_passes: number;
1420
1423
  documents: string[];
1424
+ steps: {
1425
+ id: string;
1426
+ title: string;
1427
+ kind: "form" | "upload" | "agent" | "review";
1428
+ after?: string[] | null | undefined;
1429
+ skill?: string | null | undefined;
1430
+ prompt?: string | null | undefined;
1431
+ inputs?: {
1432
+ [x: string]: string;
1433
+ } | null | undefined;
1434
+ branch: boolean;
1435
+ requires_files: boolean;
1436
+ ui?: {
1437
+ [x: string]: unknown;
1438
+ } | null | undefined;
1439
+ }[];
1421
1440
  } | null | undefined;
1422
1441
  goal_state?: {
1423
1442
  [x: string]: unknown;
@@ -3234,6 +3253,7 @@ type UpdateConversationRequest = components['schemas']['UpdateConversationReques
3234
3253
  type CreateWorkRequest = components['schemas']['CreateWorkRequest'];
3235
3254
  type PendingAuthResponse = components['schemas']['PendingAuthResponse'];
3236
3255
  type PlanWorkRequest = components['schemas']['PlanWorkRequest'];
3256
+ type StepActionRequest = components['schemas']['StepActionRequest'];
3237
3257
  type TaskPlan = components['schemas']['TaskPlan'];
3238
3258
  type ActivityResponse = components['schemas']['ActivityResponse'];
3239
3259
  type ActivityKind = components['schemas']['ActivityKind'];
@@ -3252,6 +3272,16 @@ declare function createWork(arbi: ArbiClient, body: CreateWorkRequest): Promise<
3252
3272
  declare function runConversation(arbi: ArbiClient, conversationId: string): Promise<ConversationResponse>;
3253
3273
  /** What an unattended run waits on (agent email + session public key); 404 when nothing waits. */
3254
3274
  declare function getPendingAuth(arbi: ArbiClient, conversationId: string): Promise<PendingAuthResponse>;
3275
+ /**
3276
+ * A person finishes a step of a workflow run: completes a form (its inputs join the run's), an upload
3277
+ * or a review (the approval), or skips a step. The run then goes on to its next agent step.
3278
+ */
3279
+ declare function actOnStep(arbi: ArbiClient, conversationId: string, body: StepActionRequest): Promise<ConversationResponse>;
3280
+ /**
3281
+ * Tell people about a conversation (a notification each, e.g. "please review this"). Resolves with
3282
+ * the ids that were notified.
3283
+ */
3284
+ declare function notifyConversation(arbi: ArbiClient, conversationId: string, userIds: string[]): Promise<string[]>;
3255
3285
  /** The task's history, oldest first: created, run started, handed off, sent back, done and so on. */
3256
3286
  declare function getActivity(arbi: ArbiClient, conversationId: string): Promise<ActivityResponse[]>;
3257
3287
  /** Draft an editable plan (goal and acceptance checklist) from a plain objective. */
@@ -3264,17 +3294,20 @@ type work_ConversationResponse = ConversationResponse;
3264
3294
  type work_CreateWorkRequest = CreateWorkRequest;
3265
3295
  type work_PendingAuthResponse = PendingAuthResponse;
3266
3296
  type work_PlanWorkRequest = PlanWorkRequest;
3297
+ type work_StepActionRequest = StepActionRequest;
3267
3298
  type work_TaskPlan = TaskPlan;
3268
3299
  type work_UpdateConversationRequest = UpdateConversationRequest;
3269
3300
  type work_WorkStatus = WorkStatus;
3301
+ declare const work_actOnStep: typeof actOnStep;
3270
3302
  declare const work_createWork: typeof createWork;
3271
3303
  declare const work_getActivity: typeof getActivity;
3272
3304
  declare const work_getPendingAuth: typeof getPendingAuth;
3305
+ declare const work_notifyConversation: typeof notifyConversation;
3273
3306
  declare const work_planWork: typeof planWork;
3274
3307
  declare const work_runConversation: typeof runConversation;
3275
3308
  declare const work_updateConversation: typeof updateConversation;
3276
3309
  declare namespace work {
3277
- export { type work_ActivityKind as ActivityKind, type work_ActivityResponse as ActivityResponse, type work_AuthMode as AuthMode, type work_ConversationResponse as ConversationResponse, type work_CreateWorkRequest as CreateWorkRequest, type work_PendingAuthResponse as PendingAuthResponse, type work_PlanWorkRequest as PlanWorkRequest, type work_TaskPlan as TaskPlan, type work_UpdateConversationRequest as UpdateConversationRequest, type work_WorkStatus as WorkStatus, work_createWork as createWork, work_getActivity as getActivity, work_getPendingAuth as getPendingAuth, work_planWork as planWork, work_runConversation as runConversation, work_updateConversation as updateConversation };
3310
+ export { type work_ActivityKind as ActivityKind, type work_ActivityResponse as ActivityResponse, type work_AuthMode as AuthMode, type work_ConversationResponse as ConversationResponse, type work_CreateWorkRequest as CreateWorkRequest, type work_PendingAuthResponse as PendingAuthResponse, type work_PlanWorkRequest as PlanWorkRequest, type work_StepActionRequest as StepActionRequest, type work_TaskPlan as TaskPlan, type work_UpdateConversationRequest as UpdateConversationRequest, type work_WorkStatus as WorkStatus, work_actOnStep as actOnStep, work_createWork as createWork, work_getActivity as getActivity, work_getPendingAuth as getPendingAuth, work_notifyConversation as notifyConversation, work_planWork as planWork, work_runConversation as runConversation, work_updateConversation as updateConversation };
3278
3311
  }
3279
3312
 
3280
3313
  /**
@@ -4707,6 +4740,9 @@ declare class Arbi {
4707
4740
  workflow_ext_id?: string | null | undefined;
4708
4741
  agent_ext_id?: string | null | undefined;
4709
4742
  skill_ref?: string | null | undefined;
4743
+ skill_inputs?: {
4744
+ [x: string]: unknown;
4745
+ } | null | undefined;
4710
4746
  has_agent_action: boolean;
4711
4747
  auth_mode?: (components["schemas"]["src__models__work__AuthMode"] | null) | undefined;
4712
4748
  plan?: {
@@ -4717,6 +4753,22 @@ declare class Arbi {
4717
4753
  }[];
4718
4754
  max_passes: number;
4719
4755
  documents: string[];
4756
+ steps: {
4757
+ id: string;
4758
+ title: string;
4759
+ kind: "form" | "upload" | "agent" | "review";
4760
+ after?: string[] | null | undefined;
4761
+ skill?: string | null | undefined;
4762
+ prompt?: string | null | undefined;
4763
+ inputs?: {
4764
+ [x: string]: string;
4765
+ } | null | undefined;
4766
+ branch: boolean;
4767
+ requires_files: boolean;
4768
+ ui?: {
4769
+ [x: string]: unknown;
4770
+ } | null | undefined;
4771
+ }[];
4720
4772
  } | null | undefined;
4721
4773
  goal_state?: {
4722
4774
  [x: string]: unknown;
@@ -4948,6 +5000,9 @@ declare class Arbi {
4948
5000
  workflow_ext_id?: string | null;
4949
5001
  agent_ext_id?: string | null;
4950
5002
  skill_ref?: string | null;
5003
+ skill_inputs?: {
5004
+ [key: string]: unknown;
5005
+ } | null;
4951
5006
  has_agent_action: boolean;
4952
5007
  auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
4953
5008
  plan?: components["schemas"]["TaskPlan"] | null;
@@ -4988,6 +5043,9 @@ declare class Arbi {
4988
5043
  workflow_ext_id?: string | null;
4989
5044
  agent_ext_id?: string | null;
4990
5045
  skill_ref?: string | null;
5046
+ skill_inputs?: {
5047
+ [key: string]: unknown;
5048
+ } | null;
4991
5049
  has_agent_action: boolean;
4992
5050
  auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
4993
5051
  plan?: components["schemas"]["TaskPlan"] | null;
@@ -5028,6 +5086,9 @@ declare class Arbi {
5028
5086
  workflow_ext_id?: string | null;
5029
5087
  agent_ext_id?: string | null;
5030
5088
  skill_ref?: string | null;
5089
+ skill_inputs?: {
5090
+ [key: string]: unknown;
5091
+ } | null;
5031
5092
  has_agent_action: boolean;
5032
5093
  auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
5033
5094
  plan?: components["schemas"]["TaskPlan"] | null;
@@ -5059,12 +5120,58 @@ declare class Arbi {
5059
5120
  } | null;
5060
5121
  created_at: string;
5061
5122
  }[]>;
5123
+ /** Complete or skip a step of a workflow run; the run goes on to its next agent step. */
5124
+ actOnStep: (conversationId: string, body: StepActionRequest) => Promise<{
5125
+ label_ext_ids?: string[];
5126
+ external_id: string;
5127
+ title: string | null;
5128
+ created_by_ext_id: string;
5129
+ updated_by_ext_id?: string | null;
5130
+ created_at: string;
5131
+ updated_at: string;
5132
+ is_shared: boolean;
5133
+ message_count: number;
5134
+ last_message_actor?: components["schemas"]["ConversationTurnActor"] | null;
5135
+ last_message_ext_id?: string | null;
5136
+ last_message_role?: string | null;
5137
+ last_message_updated_at?: string | null;
5138
+ last_message_status?: string | null;
5139
+ assistant_mode: components["schemas"]["AssistantMode"];
5140
+ status?: components["schemas"]["WorkStatus"] | null;
5141
+ description?: string | null;
5142
+ due_at?: string | null;
5143
+ completed_at?: string | null;
5144
+ completed_by_ext_id?: string | null;
5145
+ parent_conversation_ext_id?: string | null;
5146
+ workflow_ext_id?: string | null;
5147
+ agent_ext_id?: string | null;
5148
+ skill_ref?: string | null;
5149
+ skill_inputs?: {
5150
+ [key: string]: unknown;
5151
+ } | null;
5152
+ has_agent_action: boolean;
5153
+ auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
5154
+ plan?: components["schemas"]["TaskPlan"] | null;
5155
+ goal_state?: {
5156
+ [key: string]: unknown;
5157
+ } | null;
5158
+ last_error?: string | null;
5159
+ pending_auth_request_id?: string | null;
5160
+ in_progress: boolean;
5161
+ active_response_id?: string | null;
5162
+ run_started_at?: string | null;
5163
+ owner_ext_id?: string | null;
5164
+ is_owner: boolean;
5165
+ }>;
5166
+ /** Notify people about a conversation (each gets a notification); resolves with who was. */
5167
+ notify: (conversationId: string, userIds: string[]) => Promise<string[]>;
5062
5168
  /** Draft an editable plan from an objective. */
5063
5169
  plan: (body: PlanWorkRequest) => Promise<{
5064
5170
  goal: string;
5065
5171
  criteria: components["schemas"]["TaskPlanCriterion"][];
5066
5172
  max_passes: number;
5067
5173
  documents: string[];
5174
+ steps: components["schemas"]["TaskPlanStep"][];
5068
5175
  }>;
5069
5176
  /**
5070
5177
  * Run a work item and, when the run is parked waiting for workspace access, grant the agent's
@@ -5096,6 +5203,9 @@ declare class Arbi {
5096
5203
  workflow_ext_id?: string | null;
5097
5204
  agent_ext_id?: string | null;
5098
5205
  skill_ref?: string | null;
5206
+ skill_inputs?: {
5207
+ [key: string]: unknown;
5208
+ } | null;
5099
5209
  has_agent_action: boolean;
5100
5210
  auth_mode?: components["schemas"]["src__models__work__AuthMode"] | null;
5101
5211
  plan?: components["schemas"]["TaskPlan"] | null;
@@ -8565,4 +8675,4 @@ declare namespace identity {
8565
8675
  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 };
8566
8676
  }
8567
8677
 
8568
- export { type MessageLevel as $, type ActivityKind as A, type DecryptedDmNotification as B, type ChatSession as C, DOC_TERMINAL_STATUSES as D, type DeferredInterjectionEvent as E, type DmAttachmentFile as F, type DmAttachmentInput as G, type DmCryptoContext as H, type DocNameMap as I, type DocumentAutomationAction as J, type DocumentListFields as K, type DocumentListOrder as L, type DocumentSelector as M, type DocumentWaiter as N, type DocumentWaiterOptions as O, type FactResponse as P, type FactSearchRequest as Q, type FactSearchResponse as R, type FormattedWsMessage as S, type IdentityErrorCode as T, type IdentityPurchase as U, type IdentityState as V, type IdentityStatus as W, type ListAllOptions as X, type ListFactsOptions as Y, type ListPaginatedOptions as Z, type MailAttachment as _, type ActivityResponse as a, connectWebSocket as a$, type MessageMetadataPayload$1 as a0, type MessageQueuedEvent as a1, type OutputTokensDetails as a2, type ParsedSlashCommand as a3, type PendingAuthResponse as a4, type PlanWorkRequest as a5, type ProbeAnswerEvent as a6, type ProjectInvoicesResponse as a7, type ProjectUsageResponse as a8, type QueryOptions as a9, type UploadBatchResult as aA, type UploadDirectOptions as aB, type UploadDirectResult as aC, type UploadOptions as aD, type UploadResult as aE, type UserDailyUsageResponse as aF, type UserInfo as aG, type UserInputRequestEvent as aH, type UserMessageEvent as aI, WebSocketAuthError as aJ, type WorkStatus as aK, type WorkflowAuthMode as aL, type WorkflowResponse as aM, type WorkflowRunHistoryResponse as aN, type WorkflowRunResponse as aO, type WorkspaceContext as aP, type WsConnection as aQ, account as aR, agentconfig as aS, agents as aT, assistant as aU, authenticatedFetch as aV, buildDocNameMap as aW, buildFactsContextTool as aX, buildRetrievalChunkTool as aY, buildRetrievalFullContextTool as aZ, buildRetrievalTocTool as a_, type ReconnectOptions as aa, type ReconnectableWsConnection as ab, type ResolvedCitation as ac, type ResolvedRecipient as ad, type ResponseCompletedEvent as ae, type ResponseContentPartAddedEvent as af, type ResponseCreatedEvent as ag, type ResponseFailedEvent as ah, type ResponseOutputItemAddedEvent as ai, type ResponseOutputItemDoneEvent as aj, type ResponseOutputTextDeltaEvent as ak, type ResponseOutputTextDoneEvent as al, type ResponseUsage as am, type SSEEvent as an, type SSEStreamCallbacks as ao, type SSEStreamResult as ap, type SSEStreamStartData as aq, SUPPORTED_EXTENSIONS as ar, type SkillSummary as as, type SkippedFile as at, type SubmitBackgroundQueryOptions as au, type TaskPlan as av, type TokenBudgetContext as aw, type UpdateConversationRequest as ax, type UpdateFactRequest as ay, type UpdateWorkflowRequest as az, type AgentControlStateEvent as b, connectWithReconnect as b0, consumeSSEStream as b1, contacts as b2, conversations as b3, countCitations as b4, createAuthenticatedClient as b5, createDocumentWaiter as b6, dm as b7, doctags as b8, documents as b9, projects as bA, requireData as bB, requireOk as bC, resolveAuth as bD, resolveCitations as bE, resolveWorkspace as bF, responses as bG, selectWorkspace as bH, selectWorkspaceById as bI, sessions as bJ, settings as bK, streamSSE as bL, stripCitationMarkdown as bM, summarizeCitations as bN, tags as bO, work as bP, workflows as bQ, workspaces as bR, facts as ba, files as bb, filterSkills as bc, formatAgentStepLabel as bd, formatFileSize as be, formatItemLabel as bf, formatStreamSummary as bg, formatUserName as bh, formatWorkspaceChoices as bi, formatWsMessage as bj, generateEncryptedWorkspaceKey as bk, generateNewWorkspaceKey as bl, getErrorCode as bm, getErrorMessage as bn, getRawWorkspaceKey as bo, health as bp, identity as bq, identityErrorCode as br, mail as bs, parseSSEEvents as bt, parseSlashCommand as bu, parseSlashTokenInProgress as bv, performPasswordLogin as bw, performSigningKeyLogin as bx, performSsoDeviceFlowLogin as by, profile as bz, type AgentStepDeltaEvent as c, type AgentStepEvent as d, Arbi as e, ArbiApiError as f, ArbiError as g, type ArbiErrorEvent as h, type ArbiOptions as i, ArbiSessionExpiredError as j, type ArtifactEvent as k, type AuthContext as l, type AuthHeaders as m, type AuthMode as n, type AuthenticatedClient as o, type CitationSummary as p, type CliConfig as q, type CliCredentials as r, type CommandDescriptor as s, type ConfigStore as t, type ConnectOptions as u, type ConversationResponse as v, type CreateFactRequest as w, type CreateFactsRequest as x, type CreateWorkRequest as y, type CreateWorkflowRequest as z };
8678
+ export { type MessageLevel as $, type ActivityKind as A, type DecryptedDmNotification as B, type ChatSession as C, DOC_TERMINAL_STATUSES as D, type DeferredInterjectionEvent as E, type DmAttachmentFile as F, type DmAttachmentInput as G, type DmCryptoContext as H, type DocNameMap as I, type DocumentAutomationAction as J, type DocumentListFields as K, type DocumentListOrder as L, type DocumentSelector as M, type DocumentWaiter as N, type DocumentWaiterOptions as O, type FactResponse as P, type FactSearchRequest as Q, type FactSearchResponse as R, type FormattedWsMessage as S, type IdentityErrorCode as T, type IdentityPurchase as U, type IdentityState as V, type IdentityStatus as W, type ListAllOptions as X, type ListFactsOptions as Y, type ListPaginatedOptions as Z, type MailAttachment as _, type ActivityResponse as a, buildRetrievalTocTool as a$, type MessageMetadataPayload$1 as a0, type MessageQueuedEvent as a1, type OutputTokensDetails as a2, type ParsedSlashCommand as a3, type PendingAuthResponse as a4, type PlanWorkRequest as a5, type ProbeAnswerEvent as a6, type ProjectInvoicesResponse as a7, type ProjectUsageResponse as a8, type QueryOptions as a9, type UpdateWorkflowRequest as aA, type UploadBatchResult as aB, type UploadDirectOptions as aC, type UploadDirectResult as aD, type UploadOptions as aE, type UploadResult as aF, type UserDailyUsageResponse as aG, type UserInfo as aH, type UserInputRequestEvent as aI, type UserMessageEvent as aJ, WebSocketAuthError as aK, type WorkStatus as aL, type WorkflowAuthMode as aM, type WorkflowResponse as aN, type WorkflowRunHistoryResponse as aO, type WorkflowRunResponse as aP, type WorkspaceContext as aQ, type WsConnection as aR, account as aS, agentconfig as aT, agents as aU, assistant as aV, authenticatedFetch as aW, buildDocNameMap as aX, buildFactsContextTool as aY, buildRetrievalChunkTool as aZ, buildRetrievalFullContextTool as a_, type ReconnectOptions as aa, type ReconnectableWsConnection as ab, type ResolvedCitation as ac, type ResolvedRecipient as ad, type ResponseCompletedEvent as ae, type ResponseContentPartAddedEvent as af, type ResponseCreatedEvent as ag, type ResponseFailedEvent as ah, type ResponseOutputItemAddedEvent as ai, type ResponseOutputItemDoneEvent as aj, type ResponseOutputTextDeltaEvent as ak, type ResponseOutputTextDoneEvent as al, type ResponseUsage as am, type SSEEvent as an, type SSEStreamCallbacks as ao, type SSEStreamResult as ap, type SSEStreamStartData as aq, SUPPORTED_EXTENSIONS as ar, type SkillSummary as as, type SkippedFile as at, type StepActionRequest as au, type SubmitBackgroundQueryOptions as av, type TaskPlan as aw, type TokenBudgetContext as ax, type UpdateConversationRequest as ay, type UpdateFactRequest as az, type AgentControlStateEvent as b, connectWebSocket as b0, connectWithReconnect as b1, consumeSSEStream as b2, contacts as b3, conversations as b4, countCitations as b5, createAuthenticatedClient as b6, createDocumentWaiter as b7, dm as b8, doctags as b9, profile as bA, projects as bB, requireData as bC, requireOk as bD, resolveAuth as bE, resolveCitations as bF, resolveWorkspace as bG, responses as bH, selectWorkspace as bI, selectWorkspaceById as bJ, sessions as bK, settings as bL, streamSSE as bM, stripCitationMarkdown as bN, summarizeCitations as bO, tags as bP, work as bQ, workflows as bR, workspaces as bS, documents as ba, facts as bb, files as bc, filterSkills as bd, formatAgentStepLabel as be, formatFileSize as bf, formatItemLabel as bg, formatStreamSummary as bh, formatUserName as bi, formatWorkspaceChoices as bj, formatWsMessage as bk, generateEncryptedWorkspaceKey as bl, generateNewWorkspaceKey as bm, getErrorCode as bn, getErrorMessage as bo, getRawWorkspaceKey as bp, health as bq, identity as br, identityErrorCode as bs, mail as bt, parseSSEEvents as bu, parseSlashCommand as bv, parseSlashTokenInProgress as bw, performPasswordLogin as bx, performSigningKeyLogin as by, performSsoDeviceFlowLogin as bz, type AgentStepDeltaEvent as c, type AgentStepEvent as d, Arbi as e, ArbiApiError as f, ArbiError as g, type ArbiErrorEvent as h, type ArbiOptions as i, ArbiSessionExpiredError as j, type ArtifactEvent as k, type AuthContext as l, type AuthHeaders as m, type AuthMode as n, type AuthenticatedClient as o, type CitationSummary as p, type CliConfig as q, type CliCredentials as r, type CommandDescriptor as s, type ConfigStore as t, type ConnectOptions as u, type ConversationResponse as v, type CreateFactRequest as w, type CreateFactsRequest as x, type CreateWorkRequest as y, type CreateWorkflowRequest as z };
package/dist/browser.cjs CHANGED
@@ -6063,9 +6063,11 @@ async function getUserUsageToday(arbi) {
6063
6063
  // src/operations/work.ts
6064
6064
  var work_exports = {};
6065
6065
  __export(work_exports, {
6066
+ actOnStep: () => actOnStep,
6066
6067
  createWork: () => createWork,
6067
6068
  getActivity: () => getActivity,
6068
6069
  getPendingAuth: () => getPendingAuth,
6070
+ notifyConversation: () => notifyConversation,
6069
6071
  planWork: () => planWork,
6070
6072
  runConversation: () => runConversation,
6071
6073
  updateConversation: () => updateConversation
@@ -6103,6 +6105,24 @@ async function getPendingAuth(arbi, conversationId) {
6103
6105
  "Failed to read the pending access request"
6104
6106
  );
6105
6107
  }
6108
+ async function actOnStep(arbi, conversationId, body) {
6109
+ return requireData(
6110
+ await arbi.fetch.POST("/v1/conversation/{conversation_ext_id}/step", {
6111
+ ...byId(conversationId),
6112
+ body
6113
+ }),
6114
+ "Failed to update the workflow step"
6115
+ );
6116
+ }
6117
+ async function notifyConversation(arbi, conversationId, userIds) {
6118
+ return requireData(
6119
+ await arbi.fetch.POST("/v1/conversation/{conversation_ext_id}/notify", {
6120
+ ...byId(conversationId),
6121
+ body: { user_ext_ids: userIds }
6122
+ }),
6123
+ "Failed to notify people about the conversation"
6124
+ );
6125
+ }
6106
6126
  async function getActivity(arbi, conversationId) {
6107
6127
  return requireData(
6108
6128
  await arbi.fetch.GET("/v1/conversation/{conversation_ext_id}/activity", byId(conversationId)),
@@ -6755,6 +6775,10 @@ var Arbi = class {
6755
6775
  pendingAuth: (conversationId) => getPendingAuth(this.requireClient(), conversationId),
6756
6776
  /** The task's history, oldest first. */
6757
6777
  activity: (conversationId) => getActivity(this.requireClient(), conversationId),
6778
+ /** Complete or skip a step of a workflow run; the run goes on to its next agent step. */
6779
+ actOnStep: (conversationId, body) => actOnStep(this.requireClient(), conversationId, body),
6780
+ /** Notify people about a conversation (each gets a notification); resolves with who was. */
6781
+ notify: (conversationId, userIds) => notifyConversation(this.requireClient(), conversationId, userIds),
6758
6782
  /** Draft an editable plan from an objective. */
6759
6783
  plan: (body) => planWork(this.requireClient(), body),
6760
6784
  /**