@arbidocs/sdk 0.5.5 → 0.5.7

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.
@@ -2378,6 +2378,8 @@ declare function listConversations(arbi: ArbiClient): Promise<{
2378
2378
  last_message_status?: string | null | undefined;
2379
2379
  assistant_mode: components["schemas"]["AssistantMode"];
2380
2380
  meeting_call_ext_id?: string | null | undefined;
2381
+ bound_document_ext_id?: string | null | undefined;
2382
+ bound_document_unavailable: boolean;
2381
2383
  status?: (components["schemas"]["WorkStatus"] | null) | undefined;
2382
2384
  description?: string | null | undefined;
2383
2385
  due_at?: string | null | undefined;
@@ -2708,6 +2710,8 @@ declare function getConversationThreads(arbi: ArbiClient, conversationId: string
2708
2710
  }[];
2709
2711
  }[];
2710
2712
  assistant_mode: components["schemas"]["AssistantMode"];
2713
+ bound_document_ext_id?: string | null | undefined;
2714
+ bound_document_unavailable: boolean;
2711
2715
  }>;
2712
2716
  declare function deleteConversation(arbi: ArbiClient, conversationId: string): Promise<{
2713
2717
  detail: string;
@@ -3185,6 +3189,11 @@ interface TurnRequest {
3185
3189
  * demand and edits it in place.
3186
3190
  */
3187
3191
  activeArtifactExtId?: string | null;
3192
+ /**
3193
+ * Bind the conversation this turn starts to a document ("chat about this document"): every later
3194
+ * turn of it, from any device, drafts in it. Only read when the turn starts a conversation.
3195
+ */
3196
+ bindDocumentId?: string | null;
3188
3197
  /** The message this turn replies to. */
3189
3198
  previousResponseId?: string | null;
3190
3199
  /** An existing conversation with no previous response yet (a task's empty thread). */
@@ -8368,6 +8377,9 @@ declare class Arbi {
8368
8377
  }[]>;
8369
8378
  /** The project's spend by conversation in a billing period (£). */
8370
8379
  usageByConversation: (projectExtId: string, monthsBack?: number) => Promise<{
8380
+ external_usage?: {
8381
+ [key: string]: unknown;
8382
+ } | null;
8371
8383
  project_ext_id: string;
8372
8384
  period_start: string;
8373
8385
  period_end: string;
@@ -8499,6 +8511,9 @@ declare class Arbi {
8499
8511
  }>;
8500
8512
  /** AI usage + spend breakdown for a project's billing period. */
8501
8513
  usage: (projectExtId: string, monthsBack?: number) => Promise<{
8514
+ external_usage?: {
8515
+ [key: string]: unknown;
8516
+ } | null;
8502
8517
  project_ext_id: string;
8503
8518
  period_start: string;
8504
8519
  period_end: string;
@@ -10469,6 +10484,8 @@ declare class Arbi {
10469
10484
  last_message_status?: string | null | undefined;
10470
10485
  assistant_mode: components["schemas"]["AssistantMode"];
10471
10486
  meeting_call_ext_id?: string | null | undefined;
10487
+ bound_document_ext_id?: string | null | undefined;
10488
+ bound_document_unavailable: boolean;
10472
10489
  status?: (components["schemas"]["WorkStatus"] | null) | undefined;
10473
10490
  description?: string | null | undefined;
10474
10491
  due_at?: string | null | undefined;
@@ -10789,14 +10806,17 @@ declare class Arbi {
10789
10806
  }[];
10790
10807
  }[];
10791
10808
  assistant_mode: components["schemas"]["AssistantMode"];
10809
+ bound_document_ext_id?: string | null | undefined;
10810
+ bound_document_unavailable: boolean;
10792
10811
  }>;
10793
10812
  delete: (conversationId: string) => Promise<{
10794
10813
  detail: string;
10795
10814
  }>;
10796
10815
  /**
10797
- * Patch a conversation: `title`, `shared` (owner only), and the work fields (`description`,
10798
- * `due_at`, `parent_conversation_ext_id`, `status`, `plan`). The one call
10799
- * behind rename, share and unshare.
10816
+ * Patch a conversation: `title`, `shared` (owner only), its bound document
10817
+ * (`bound_document_ext_id`, `null` unbinds), and the work fields (`description`, `due_at`,
10818
+ * `parent_conversation_ext_id`, `status`, `plan`). The one call behind rename, share, unshare
10819
+ * and attaching a thread to a document.
10800
10820
  */
10801
10821
  update: (conversationId: string, body: UpdateConversationRequest) => Promise<{
10802
10822
  label_ext_ids?: string[];
@@ -10815,6 +10835,8 @@ declare class Arbi {
10815
10835
  last_message_status?: string | null;
10816
10836
  assistant_mode: components["schemas"]["AssistantMode"];
10817
10837
  meeting_call_ext_id?: string | null;
10838
+ bound_document_ext_id?: string | null;
10839
+ bound_document_unavailable: boolean;
10818
10840
  status?: components["schemas"]["WorkStatus"] | null;
10819
10841
  description?: string | null;
10820
10842
  due_at?: string | null;
@@ -10859,6 +10881,8 @@ declare class Arbi {
10859
10881
  last_message_status?: string | null;
10860
10882
  assistant_mode: components["schemas"]["AssistantMode"];
10861
10883
  meeting_call_ext_id?: string | null;
10884
+ bound_document_ext_id?: string | null;
10885
+ bound_document_unavailable: boolean;
10862
10886
  status?: components["schemas"]["WorkStatus"] | null;
10863
10887
  description?: string | null;
10864
10888
  due_at?: string | null;
@@ -10903,6 +10927,8 @@ declare class Arbi {
10903
10927
  last_message_status?: string | null;
10904
10928
  assistant_mode: components["schemas"]["AssistantMode"];
10905
10929
  meeting_call_ext_id?: string | null;
10930
+ bound_document_ext_id?: string | null;
10931
+ bound_document_unavailable: boolean;
10906
10932
  status?: components["schemas"]["WorkStatus"] | null;
10907
10933
  description?: string | null;
10908
10934
  due_at?: string | null;
@@ -10964,6 +10990,8 @@ declare class Arbi {
10964
10990
  last_message_status?: string | null;
10965
10991
  assistant_mode: components["schemas"]["AssistantMode"];
10966
10992
  meeting_call_ext_id?: string | null;
10993
+ bound_document_ext_id?: string | null;
10994
+ bound_document_unavailable: boolean;
10967
10995
  status?: components["schemas"]["WorkStatus"] | null;
10968
10996
  description?: string | null;
10969
10997
  due_at?: string | null;
@@ -11008,6 +11036,8 @@ declare class Arbi {
11008
11036
  last_message_status?: string | null;
11009
11037
  assistant_mode: components["schemas"]["AssistantMode"];
11010
11038
  meeting_call_ext_id?: string | null;
11039
+ bound_document_ext_id?: string | null;
11040
+ bound_document_unavailable: boolean;
11011
11041
  status?: components["schemas"]["WorkStatus"] | null;
11012
11042
  description?: string | null;
11013
11043
  due_at?: string | null;
@@ -11052,6 +11082,8 @@ declare class Arbi {
11052
11082
  last_message_status?: string | null;
11053
11083
  assistant_mode: components["schemas"]["AssistantMode"];
11054
11084
  meeting_call_ext_id?: string | null;
11085
+ bound_document_ext_id?: string | null;
11086
+ bound_document_unavailable: boolean;
11055
11087
  status?: components["schemas"]["WorkStatus"] | null;
11056
11088
  description?: string | null;
11057
11089
  due_at?: string | null;
@@ -11099,6 +11131,8 @@ declare class Arbi {
11099
11131
  last_message_status?: string | null;
11100
11132
  assistant_mode: components["schemas"]["AssistantMode"];
11101
11133
  meeting_call_ext_id?: string | null;
11134
+ bound_document_ext_id?: string | null;
11135
+ bound_document_unavailable: boolean;
11102
11136
  status?: components["schemas"]["WorkStatus"] | null;
11103
11137
  description?: string | null;
11104
11138
  due_at?: string | null;
@@ -11129,6 +11163,9 @@ declare class Arbi {
11129
11163
  runProgress: (conversationId: string) => Promise<RunProgress>;
11130
11164
  /** What the conversation's AI work cost: by step, run, model, agent and feature (£). */
11131
11165
  usage: (conversationId: string) => Promise<{
11166
+ external_usage?: {
11167
+ [key: string]: unknown;
11168
+ } | null;
11132
11169
  conversation_ext_id: string;
11133
11170
  project_ext_id: string;
11134
11171
  period_start: string;
@@ -11184,6 +11221,8 @@ declare class Arbi {
11184
11221
  last_message_status?: string | null;
11185
11222
  assistant_mode: components["schemas"]["AssistantMode"];
11186
11223
  meeting_call_ext_id?: string | null;
11224
+ bound_document_ext_id?: string | null;
11225
+ bound_document_unavailable: boolean;
11187
11226
  status?: components["schemas"]["WorkStatus"] | null;
11188
11227
  description?: string | null;
11189
11228
  due_at?: string | null;
@@ -14217,6 +14256,9 @@ declare class Arbi {
14217
14256
  getSchema: () => Promise<unknown>;
14218
14257
  getModels: () => Promise<{
14219
14258
  models: {
14259
+ display_name?: string | null | undefined;
14260
+ connection_scope?: string | null | undefined;
14261
+ externally_billed: boolean;
14220
14262
  model_name: string;
14221
14263
  api_type: string;
14222
14264
  tags?: string[] | null | undefined;
@@ -14259,6 +14301,9 @@ declare class Arbi {
14259
14301
  }>;
14260
14302
  models: () => Promise<{
14261
14303
  models: {
14304
+ display_name?: string | null | undefined;
14305
+ connection_scope?: string | null | undefined;
14306
+ externally_billed: boolean;
14262
14307
  model_name: string;
14263
14308
  api_type: string;
14264
14309
  tags?: string[] | null | undefined;
@@ -15825,6 +15870,9 @@ declare function deleteConfig(arbi: ArbiClient, configId: string): Promise<{
15825
15870
  declare function getSchema(arbi: ArbiClient): Promise<unknown>;
15826
15871
  declare function getModels(arbi: ArbiClient): Promise<{
15827
15872
  models: {
15873
+ display_name?: string | null | undefined;
15874
+ connection_scope?: string | null | undefined;
15875
+ externally_billed: boolean;
15828
15876
  model_name: string;
15829
15877
  api_type: string;
15830
15878
  tags?: string[] | null | undefined;
@@ -15880,6 +15928,9 @@ declare function getHealth(arbi: ArbiClient): Promise<{
15880
15928
  }>;
15881
15929
  declare function getHealthModels(arbi: ArbiClient): Promise<{
15882
15930
  models: {
15931
+ display_name?: string | null | undefined;
15932
+ connection_scope?: string | null | undefined;
15933
+ externally_billed: boolean;
15883
15934
  model_name: string;
15884
15935
  api_type: string;
15885
15936
  tags?: string[] | null | undefined;
@@ -2378,6 +2378,8 @@ declare function listConversations(arbi: ArbiClient): Promise<{
2378
2378
  last_message_status?: string | null | undefined;
2379
2379
  assistant_mode: components["schemas"]["AssistantMode"];
2380
2380
  meeting_call_ext_id?: string | null | undefined;
2381
+ bound_document_ext_id?: string | null | undefined;
2382
+ bound_document_unavailable: boolean;
2381
2383
  status?: (components["schemas"]["WorkStatus"] | null) | undefined;
2382
2384
  description?: string | null | undefined;
2383
2385
  due_at?: string | null | undefined;
@@ -2708,6 +2710,8 @@ declare function getConversationThreads(arbi: ArbiClient, conversationId: string
2708
2710
  }[];
2709
2711
  }[];
2710
2712
  assistant_mode: components["schemas"]["AssistantMode"];
2713
+ bound_document_ext_id?: string | null | undefined;
2714
+ bound_document_unavailable: boolean;
2711
2715
  }>;
2712
2716
  declare function deleteConversation(arbi: ArbiClient, conversationId: string): Promise<{
2713
2717
  detail: string;
@@ -3185,6 +3189,11 @@ interface TurnRequest {
3185
3189
  * demand and edits it in place.
3186
3190
  */
3187
3191
  activeArtifactExtId?: string | null;
3192
+ /**
3193
+ * Bind the conversation this turn starts to a document ("chat about this document"): every later
3194
+ * turn of it, from any device, drafts in it. Only read when the turn starts a conversation.
3195
+ */
3196
+ bindDocumentId?: string | null;
3188
3197
  /** The message this turn replies to. */
3189
3198
  previousResponseId?: string | null;
3190
3199
  /** An existing conversation with no previous response yet (a task's empty thread). */
@@ -8368,6 +8377,9 @@ declare class Arbi {
8368
8377
  }[]>;
8369
8378
  /** The project's spend by conversation in a billing period (£). */
8370
8379
  usageByConversation: (projectExtId: string, monthsBack?: number) => Promise<{
8380
+ external_usage?: {
8381
+ [key: string]: unknown;
8382
+ } | null;
8371
8383
  project_ext_id: string;
8372
8384
  period_start: string;
8373
8385
  period_end: string;
@@ -8499,6 +8511,9 @@ declare class Arbi {
8499
8511
  }>;
8500
8512
  /** AI usage + spend breakdown for a project's billing period. */
8501
8513
  usage: (projectExtId: string, monthsBack?: number) => Promise<{
8514
+ external_usage?: {
8515
+ [key: string]: unknown;
8516
+ } | null;
8502
8517
  project_ext_id: string;
8503
8518
  period_start: string;
8504
8519
  period_end: string;
@@ -10469,6 +10484,8 @@ declare class Arbi {
10469
10484
  last_message_status?: string | null | undefined;
10470
10485
  assistant_mode: components["schemas"]["AssistantMode"];
10471
10486
  meeting_call_ext_id?: string | null | undefined;
10487
+ bound_document_ext_id?: string | null | undefined;
10488
+ bound_document_unavailable: boolean;
10472
10489
  status?: (components["schemas"]["WorkStatus"] | null) | undefined;
10473
10490
  description?: string | null | undefined;
10474
10491
  due_at?: string | null | undefined;
@@ -10789,14 +10806,17 @@ declare class Arbi {
10789
10806
  }[];
10790
10807
  }[];
10791
10808
  assistant_mode: components["schemas"]["AssistantMode"];
10809
+ bound_document_ext_id?: string | null | undefined;
10810
+ bound_document_unavailable: boolean;
10792
10811
  }>;
10793
10812
  delete: (conversationId: string) => Promise<{
10794
10813
  detail: string;
10795
10814
  }>;
10796
10815
  /**
10797
- * Patch a conversation: `title`, `shared` (owner only), and the work fields (`description`,
10798
- * `due_at`, `parent_conversation_ext_id`, `status`, `plan`). The one call
10799
- * behind rename, share and unshare.
10816
+ * Patch a conversation: `title`, `shared` (owner only), its bound document
10817
+ * (`bound_document_ext_id`, `null` unbinds), and the work fields (`description`, `due_at`,
10818
+ * `parent_conversation_ext_id`, `status`, `plan`). The one call behind rename, share, unshare
10819
+ * and attaching a thread to a document.
10800
10820
  */
10801
10821
  update: (conversationId: string, body: UpdateConversationRequest) => Promise<{
10802
10822
  label_ext_ids?: string[];
@@ -10815,6 +10835,8 @@ declare class Arbi {
10815
10835
  last_message_status?: string | null;
10816
10836
  assistant_mode: components["schemas"]["AssistantMode"];
10817
10837
  meeting_call_ext_id?: string | null;
10838
+ bound_document_ext_id?: string | null;
10839
+ bound_document_unavailable: boolean;
10818
10840
  status?: components["schemas"]["WorkStatus"] | null;
10819
10841
  description?: string | null;
10820
10842
  due_at?: string | null;
@@ -10859,6 +10881,8 @@ declare class Arbi {
10859
10881
  last_message_status?: string | null;
10860
10882
  assistant_mode: components["schemas"]["AssistantMode"];
10861
10883
  meeting_call_ext_id?: string | null;
10884
+ bound_document_ext_id?: string | null;
10885
+ bound_document_unavailable: boolean;
10862
10886
  status?: components["schemas"]["WorkStatus"] | null;
10863
10887
  description?: string | null;
10864
10888
  due_at?: string | null;
@@ -10903,6 +10927,8 @@ declare class Arbi {
10903
10927
  last_message_status?: string | null;
10904
10928
  assistant_mode: components["schemas"]["AssistantMode"];
10905
10929
  meeting_call_ext_id?: string | null;
10930
+ bound_document_ext_id?: string | null;
10931
+ bound_document_unavailable: boolean;
10906
10932
  status?: components["schemas"]["WorkStatus"] | null;
10907
10933
  description?: string | null;
10908
10934
  due_at?: string | null;
@@ -10964,6 +10990,8 @@ declare class Arbi {
10964
10990
  last_message_status?: string | null;
10965
10991
  assistant_mode: components["schemas"]["AssistantMode"];
10966
10992
  meeting_call_ext_id?: string | null;
10993
+ bound_document_ext_id?: string | null;
10994
+ bound_document_unavailable: boolean;
10967
10995
  status?: components["schemas"]["WorkStatus"] | null;
10968
10996
  description?: string | null;
10969
10997
  due_at?: string | null;
@@ -11008,6 +11036,8 @@ declare class Arbi {
11008
11036
  last_message_status?: string | null;
11009
11037
  assistant_mode: components["schemas"]["AssistantMode"];
11010
11038
  meeting_call_ext_id?: string | null;
11039
+ bound_document_ext_id?: string | null;
11040
+ bound_document_unavailable: boolean;
11011
11041
  status?: components["schemas"]["WorkStatus"] | null;
11012
11042
  description?: string | null;
11013
11043
  due_at?: string | null;
@@ -11052,6 +11082,8 @@ declare class Arbi {
11052
11082
  last_message_status?: string | null;
11053
11083
  assistant_mode: components["schemas"]["AssistantMode"];
11054
11084
  meeting_call_ext_id?: string | null;
11085
+ bound_document_ext_id?: string | null;
11086
+ bound_document_unavailable: boolean;
11055
11087
  status?: components["schemas"]["WorkStatus"] | null;
11056
11088
  description?: string | null;
11057
11089
  due_at?: string | null;
@@ -11099,6 +11131,8 @@ declare class Arbi {
11099
11131
  last_message_status?: string | null;
11100
11132
  assistant_mode: components["schemas"]["AssistantMode"];
11101
11133
  meeting_call_ext_id?: string | null;
11134
+ bound_document_ext_id?: string | null;
11135
+ bound_document_unavailable: boolean;
11102
11136
  status?: components["schemas"]["WorkStatus"] | null;
11103
11137
  description?: string | null;
11104
11138
  due_at?: string | null;
@@ -11129,6 +11163,9 @@ declare class Arbi {
11129
11163
  runProgress: (conversationId: string) => Promise<RunProgress>;
11130
11164
  /** What the conversation's AI work cost: by step, run, model, agent and feature (£). */
11131
11165
  usage: (conversationId: string) => Promise<{
11166
+ external_usage?: {
11167
+ [key: string]: unknown;
11168
+ } | null;
11132
11169
  conversation_ext_id: string;
11133
11170
  project_ext_id: string;
11134
11171
  period_start: string;
@@ -11184,6 +11221,8 @@ declare class Arbi {
11184
11221
  last_message_status?: string | null;
11185
11222
  assistant_mode: components["schemas"]["AssistantMode"];
11186
11223
  meeting_call_ext_id?: string | null;
11224
+ bound_document_ext_id?: string | null;
11225
+ bound_document_unavailable: boolean;
11187
11226
  status?: components["schemas"]["WorkStatus"] | null;
11188
11227
  description?: string | null;
11189
11228
  due_at?: string | null;
@@ -14217,6 +14256,9 @@ declare class Arbi {
14217
14256
  getSchema: () => Promise<unknown>;
14218
14257
  getModels: () => Promise<{
14219
14258
  models: {
14259
+ display_name?: string | null | undefined;
14260
+ connection_scope?: string | null | undefined;
14261
+ externally_billed: boolean;
14220
14262
  model_name: string;
14221
14263
  api_type: string;
14222
14264
  tags?: string[] | null | undefined;
@@ -14259,6 +14301,9 @@ declare class Arbi {
14259
14301
  }>;
14260
14302
  models: () => Promise<{
14261
14303
  models: {
14304
+ display_name?: string | null | undefined;
14305
+ connection_scope?: string | null | undefined;
14306
+ externally_billed: boolean;
14262
14307
  model_name: string;
14263
14308
  api_type: string;
14264
14309
  tags?: string[] | null | undefined;
@@ -15825,6 +15870,9 @@ declare function deleteConfig(arbi: ArbiClient, configId: string): Promise<{
15825
15870
  declare function getSchema(arbi: ArbiClient): Promise<unknown>;
15826
15871
  declare function getModels(arbi: ArbiClient): Promise<{
15827
15872
  models: {
15873
+ display_name?: string | null | undefined;
15874
+ connection_scope?: string | null | undefined;
15875
+ externally_billed: boolean;
15828
15876
  model_name: string;
15829
15877
  api_type: string;
15830
15878
  tags?: string[] | null | undefined;
@@ -15880,6 +15928,9 @@ declare function getHealth(arbi: ArbiClient): Promise<{
15880
15928
  }>;
15881
15929
  declare function getHealthModels(arbi: ArbiClient): Promise<{
15882
15930
  models: {
15931
+ display_name?: string | null | undefined;
15932
+ connection_scope?: string | null | undefined;
15933
+ externally_billed: boolean;
15883
15934
  model_name: string;
15884
15935
  api_type: string;
15885
15936
  tags?: string[] | null | undefined;
package/dist/browser.cjs CHANGED
@@ -5461,6 +5461,7 @@ function buildTurnRequest(request) {
5461
5461
  ...request.conversationId ? { conversation_ext_id: request.conversationId } : {},
5462
5462
  ...request.model && !pa2 ? { model: request.model } : {},
5463
5463
  ...activeArtifactExtId ? { active_artifact_ext_id: activeArtifactExtId } : {},
5464
+ ...request.bindDocumentId && !request.previousResponseId && !pa2 ? { bound_document_ext_id: request.bindDocumentId } : {},
5464
5465
  ...request.mentions && request.mentions.length > 0 ? { mentions: request.mentions } : {},
5465
5466
  ...request.assistantMode ? { assistant_mode: request.assistantMode } : {}
5466
5467
  };
@@ -10723,9 +10724,10 @@ var Arbi = class {
10723
10724
  getThreads: (conversationId) => getConversationThreads(this.requireClient(), conversationId),
10724
10725
  delete: (conversationId) => deleteConversation(this.requireClient(), conversationId),
10725
10726
  /**
10726
- * Patch a conversation: `title`, `shared` (owner only), and the work fields (`description`,
10727
- * `due_at`, `parent_conversation_ext_id`, `status`, `plan`). The one call
10728
- * behind rename, share and unshare.
10727
+ * Patch a conversation: `title`, `shared` (owner only), its bound document
10728
+ * (`bound_document_ext_id`, `null` unbinds), and the work fields (`description`, `due_at`,
10729
+ * `parent_conversation_ext_id`, `status`, `plan`). The one call behind rename, share, unshare
10730
+ * and attaching a thread to a document.
10729
10731
  */
10730
10732
  update: (conversationId, body) => updateConversation(this.requireClient(), conversationId, body),
10731
10733
  /** Create a work item: a plain to-do, or (with a prompt / skill) agent work that starts now. */