@blade-hq/agent-client 2612.0.0-beta.77 → 2612.0.0-beta.78

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/public-api.md CHANGED
@@ -3,7 +3,7 @@
3
3
  > 本文件由 `scripts/public-api-report.mjs` 生成,请勿手改。
4
4
  > 公共面变更时重新生成本报告,并同步更新 README 对应章节——CI 会校验两者。
5
5
 
6
- 共 162 个公开声明。
6
+ 共 176 个公开声明。
7
7
 
8
8
  ## `AccountComputer` (interface)
9
9
 
@@ -202,6 +202,12 @@ cli: AppCliDefinition | undefined
202
202
  getContext: () => Record<string, unknown> | Promise<Record<string, unknown>>
203
203
  ```
204
204
 
205
+ ## `attachPackPageBridge` (function)
206
+
207
+ ```ts
208
+ attachPackPageBridge: (options: { client: BladeClient; frame: Window; pack: string; collections: readonly string[]; openSession: (sessionId: string) => void; host?: Window; }) => () => void
209
+ ```
210
+
205
211
  ## `AuthResource` (class)
206
212
 
207
213
  ```ts
@@ -268,8 +274,10 @@ logoutToken: () => void
268
274
  models: ModelsResource
269
275
  onSocketReplaced: (listener: () => void) => () => void
270
276
  options: BladeClientOptions
277
+ packs: PacksResource
271
278
  phones: PhonesResource
272
279
  plugins: PluginsResource
280
+ profile: ProfileResource
273
281
  requestCommand: (event: string, payload: Record<string, unknown>, timeoutMs: number) => Promise<Record<string, unknown>>
274
282
  responseFromInit: (path: string, init?: RequestInit) => Promise<Response>
275
283
  sandbox: SandboxResource
@@ -623,7 +631,7 @@ url: string | null | undefined
623
631
  ```ts
624
632
  audit_events: ConnectorAuditEvent[]
625
633
  connection: ConnectorAuthorization
626
- runtime: ConnectorRuntimeDiagnostics | undefined
634
+ runtime: ConnectorRuntimeDiagnostics | { last_sync_at_ms: number; next_retry_at_ms: number; consecutive_failures: number; } | undefined
627
635
  ```
628
636
 
629
637
  ## `ConnectorDomain` (interface)
@@ -661,6 +669,34 @@ template: boolean | undefined
661
669
  user_status: "unknown" | "granted" | "not_granted" | undefined
662
670
  ```
663
671
 
672
+ ## `ConnectorPushSetting` (interface)
673
+
674
+ ```ts
675
+ default: string
676
+ description: string
677
+ id: string
678
+ next_push_at: number | null
679
+ options: { value: string; label: string; interval_seconds?: number; }[]
680
+ value: string
681
+ ```
682
+
683
+ ## `ConnectorPushSettings` (interface)
684
+
685
+ ```ts
686
+ ack_reaction: boolean | undefined
687
+ ack_reaction_available: boolean | undefined
688
+ connection_id: string
689
+ items: ConnectorPushSetting[]
690
+ ```
691
+
692
+ ## `ConnectorPushSettingsResult` (type)
693
+
694
+ ```ts
695
+ export type ConnectorPushSettingsResult =
696
+ | (ConnectorPushSettings & { available: true })
697
+ | { available: false; reason: string }
698
+ ```
699
+
664
700
  ## `ConnectorRuleGroup` (interface)
665
701
 
666
702
  ```ts
@@ -716,8 +752,10 @@ downloadFile: (name: string, artifactId: string) => Promise<Blob>
716
752
  guide: (name: string, section?: "first-connection", init?: RequestInit) => Promise<{ description: string; content: string; }>
717
753
  list: (init?: RequestInit) => Promise<{ connectors: AccountConnector[]; }>
718
754
  listForSession: (sessionId: string, init?: RequestInit) => Promise<{ connectors: AccountConnector[]; }>
755
+ pushSettings: (name: string, init?: RequestInit) => Promise<ConnectorPushSettingsResult>
719
756
  read: (name: string, init?: RequestInit) => Promise<ConnectorConnectionView>
720
757
  rules: (name: string) => Promise<ConnectorRules>
758
+ setPushSettings: (name: string, changes: Record<string, string | boolean>, init?: RequestInit & { expectedConnectionId?: string; }) => Promise<ConnectorPushSettingsResult>
721
759
  startBrowserAuthorization: (name: string, sessionId?: string) => Promise<{ session_id: string; view: ConnectorConnectionView; }>
722
760
  startGeneration: ({ connector, onCreated, initiator }?: { connector?: Pick<AccountConnector, "name" | "display_name">; onCreated?: (created: { session_id: string; intent: string; }) => void | Promise<void>; initiator?: "ui" | "sdk"; }) => Promise<{ session_id: string; sent: boolean; }>
723
761
  update: (name: string, draft: ConnectorDraft) => Promise<{ name: string; }>
@@ -888,6 +926,16 @@ image_url: { url: string; source_path?: string; width?: number; height?: number;
888
926
  type: "image_url"
889
927
  ```
890
928
 
929
+ ## `InstalledPack` (interface)
930
+
931
+ ```ts
932
+ digest: string
933
+ enabled: boolean
934
+ files: Record<string, string>
935
+ manifest: PackManifest
936
+ source: "builtin" | "user" | "fixture"
937
+ ```
938
+
891
939
  ## `LlmResource` (class)
892
940
 
893
941
  ```ts
@@ -1019,6 +1067,81 @@ normalizePluginRefs: (value: unknown) => PluginRef[]
1019
1067
  normalizeTopicAssetRefs: (value: unknown) => TopicAssetRef[]
1020
1068
  ```
1021
1069
 
1070
+ ## `PackLayoutOperation` (interface)
1071
+
1072
+ ```ts
1073
+ after: string | undefined
1074
+ component: string | undefined
1075
+ op: "hide" | "show" | "add" | "move"
1076
+ region: string | undefined
1077
+ target: string | undefined
1078
+ ```
1079
+
1080
+ ## `PackManifest` (interface)
1081
+
1082
+ ```ts
1083
+ collections: { name: string; title?: string; fields: Record<string, string>; }[] | undefined
1084
+ components: ProfileComponent[] | undefined
1085
+ hooks: Record<string, unknown[]> | undefined
1086
+ layout: PackLayoutOperation[] | undefined
1087
+ limits: { daily_wakeups: number; consecutive_event_turns: number; } | undefined
1088
+ name: string
1089
+ persona: string | undefined
1090
+ title: string
1091
+ triggers: { id: string; on: string; function: string; deliver: Record<string, unknown>; }[] | undefined
1092
+ version: string
1093
+ ```
1094
+
1095
+ ## `PackProfile` (interface)
1096
+
1097
+ ```ts
1098
+ agent: { hooks: { pack: string; hooks: Record<string, unknown[]>; }[]; persona: { pack: string; text: string; }[]; collections: { pack: string; name: string; title?: string; fields: Record<string, string>; }[]; }
1099
+ hidden: string[]
1100
+ packs: { name: string; version: string; title: string; }[]
1101
+ regions: Record<string, ProfileComponent[]>
1102
+ version: string
1103
+ warnings: string[]
1104
+ ```
1105
+
1106
+ ## `PackRecord` (interface)
1107
+
1108
+ ```ts
1109
+ data: Record<string, string | number | boolean>
1110
+ id: string
1111
+ rev: number
1112
+ updated_at: string
1113
+ ```
1114
+
1115
+ ## `PackRecordQuery` (interface)
1116
+
1117
+ ```ts
1118
+ filter: Record<string, string | number | boolean> | undefined
1119
+ limit: number | undefined
1120
+ offset: number | undefined
1121
+ ```
1122
+
1123
+ ## `PackRecordsResource` (class)
1124
+
1125
+ ```ts
1126
+ delete: (pack: string, collection: string, id: string) => Promise<{ deleted: boolean; }>
1127
+ list: (pack: string, collection: string, query?: PackRecordQuery, init?: RequestInit) => Promise<{ items: PackRecord[]; }>
1128
+ onChanged: (pack: string, collection: string, listener: () => void) => () => void
1129
+ upsert: (pack: string, collection: string, data: PackRecord["data"], id?: string) => Promise<PackRecord>
1130
+ ```
1131
+
1132
+ ## `PacksResource` (class)
1133
+
1134
+ ```ts
1135
+ disable: (name: string) => Promise<PackProfile>
1136
+ enable: (name: string) => Promise<PackProfile>
1137
+ file: (name: string, path: string, init?: RequestInit) => Promise<string>
1138
+ list: () => Promise<{ items: InstalledPack[]; }>
1139
+ records: PackRecordsResource
1140
+ reset: () => Promise<PackProfile>
1141
+ save: (manifest: PackManifest, files?: Record<string, string>) => Promise<PackProfile>
1142
+ sessionByTag: (name: string, tag: string, init?: RequestInit) => Promise<{ session_id: string; }>
1143
+ ```
1144
+
1022
1145
  ## `PaginatedSessionsResult` (interface)
1023
1146
 
1024
1147
  ```ts
@@ -1149,6 +1272,25 @@ reasoningLevel: "max" | "off" | "minimal" | "low" | "medium" | "high" | "xhigh"
1149
1272
  thinkingOverride: boolean | undefined
1150
1273
  ```
1151
1274
 
1275
+ ## `ProfileComponent` (interface)
1276
+
1277
+ ```ts
1278
+ entry: string | undefined
1279
+ id: string
1280
+ kind: "iframe" | undefined
1281
+ pack: string | undefined
1282
+ regions: string[]
1283
+ reserved: boolean | undefined
1284
+ title: string
1285
+ ```
1286
+
1287
+ ## `ProfileResource` (class)
1288
+
1289
+ ```ts
1290
+ get: (init?: RequestInit) => Promise<PackProfile>
1291
+ onChanged: (listener: () => void) => () => void
1292
+ ```
1293
+
1152
1294
  ## `ProvidersResponse` (interface)
1153
1295
 
1154
1296
  ```ts
@@ -1182,6 +1324,7 @@ content: string
1182
1324
  created_at: string
1183
1325
  error: string | undefined
1184
1326
  id: string
1327
+ next_turn_only: boolean | undefined
1185
1328
  position: number
1186
1329
  status: QueuedMessageStatus
1187
1330
  target_run_id: string | undefined