@blazingagents/sdk 0.20.0 → 0.21.0
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/approvals.d.ts +4 -0
- package/dist/approvals.js +4 -0
- package/dist/chat-transport.d.ts +18 -1
- package/dist/chat-transport.js +16 -0
- package/dist/client.d.ts +24 -1
- package/dist/client.js +33 -1
- package/dist/contracts/api.d.ts +34 -0
- package/dist/contracts/api.js +28 -0
- package/dist/contracts/entities/agent-tools.d.ts +5 -2
- package/dist/contracts/entities/agent-tools.js +5 -2
- package/dist/contracts/entities/agents.d.ts +4 -0
- package/dist/contracts/entities/agents.js +9 -0
- package/dist/contracts/entities/chat.d.ts +3 -0
- package/dist/contracts/entities/chat.js +6 -0
- package/dist/contracts/entities/mcp-connections.d.ts +3 -1
- package/dist/contracts/entities/mcp-connections.js +3 -1
- package/dist/contracts/entities/prompts.d.ts +13 -0
- package/dist/contracts/entities/prompts.js +13 -0
- package/dist/contracts/entities/session-inputs.js +3 -1
- package/dist/contracts/entities/sessions.d.ts +11 -0
- package/dist/contracts/entities/sessions.js +11 -1
- package/dist/contracts/entities/skills.d.ts +3 -0
- package/dist/contracts/entities/skills.js +3 -0
- package/dist/contracts/entities/tasks.d.ts +1 -0
- package/dist/contracts/entities/usage.d.ts +4 -1
- package/dist/contracts/entities/usage.js +7 -1
- package/dist/contracts/entities/workspaces.d.ts +17 -6
- package/dist/contracts/entities/workspaces.js +3 -7
- package/dist/contracts/ids.d.ts +31 -0
- package/dist/contracts/ids.js +34 -0
- package/dist/contracts/index.d.ts +4 -3
- package/dist/contracts/index.js +2 -2
- package/dist/contracts/utils.d.ts +10 -0
- package/dist/contracts/utils.js +10 -0
- package/dist/direct-chat-transport.d.ts +27 -1
- package/dist/direct-chat-transport.js +26 -0
- package/dist/errors.d.ts +9 -0
- package/dist/errors.js +9 -0
- package/dist/functions.d.ts +35 -2
- package/dist/functions.js +60 -4
- package/dist/generation.d.ts +32 -0
- package/dist/generation.js +83 -0
- package/dist/http.d.ts +26 -0
- package/dist/http.js +43 -0
- package/dist/index.d.ts +2 -2
- package/dist/relay.d.ts +23 -0
- package/dist/relay.js +16 -0
- package/dist/resources/agents.d.ts +5 -0
- package/dist/resources/agents.js +38 -0
- package/dist/resources/artifacts.d.ts +2 -0
- package/dist/resources/artifacts.js +14 -0
- package/dist/resources/chat-connections.d.ts +5 -0
- package/dist/resources/chat-connections.js +32 -0
- package/dist/resources/chat-deliveries.d.ts +2 -0
- package/dist/resources/chat-deliveries.js +5 -0
- package/dist/resources/mcp-connections.d.ts +5 -0
- package/dist/resources/mcp-connections.js +26 -0
- package/dist/resources/memories.d.ts +2 -0
- package/dist/resources/memories.js +17 -0
- package/dist/resources/merchant-bindings.d.ts +2 -0
- package/dist/resources/merchant-bindings.js +11 -0
- package/dist/resources/merchant-connection.d.ts +2 -0
- package/dist/resources/merchant-connection.js +14 -0
- package/dist/resources/merchant-usage-events.d.ts +2 -0
- package/dist/resources/merchant-usage-events.js +20 -0
- package/dist/resources/prompts.d.ts +5 -0
- package/dist/resources/prompts.js +20 -0
- package/dist/resources/providers.d.ts +2 -0
- package/dist/resources/providers.js +23 -0
- package/dist/resources/sessions.d.ts +2 -0
- package/dist/resources/sessions.js +40 -0
- package/dist/resources/skills.d.ts +5 -0
- package/dist/resources/skills.js +35 -0
- package/dist/resources/tasks.d.ts +2 -0
- package/dist/resources/tasks.js +32 -0
- package/dist/resources/tenant.d.ts +2 -0
- package/dist/resources/tenant.js +8 -0
- package/dist/resources/usage.d.ts +2 -0
- package/dist/resources/usage.js +14 -0
- package/dist/resources/workspaces.d.ts +5 -0
- package/dist/resources/workspaces.js +20 -0
- package/dist/types.d.ts +679 -10
- package/package.json +1 -1
package/dist/types.d.ts
CHANGED
|
@@ -61,20 +61,50 @@ export interface BlazingAgentsRequestOptions {
|
|
|
61
61
|
clientRequestId: string;
|
|
62
62
|
}
|
|
63
63
|
export interface UserClient {
|
|
64
|
+
/**
|
|
65
|
+
* Returns the Skill operations for the selected Agent.
|
|
66
|
+
* @param input - `agentId`.
|
|
67
|
+
* @returns The selected Agent Skill client.
|
|
68
|
+
*/
|
|
64
69
|
agent(input: {
|
|
65
70
|
agentId: string;
|
|
66
71
|
}): AgentClient;
|
|
67
72
|
readonly agents: AgentsResource;
|
|
68
73
|
readonly artifacts: ArtifactsResource;
|
|
74
|
+
/**
|
|
75
|
+
* Creates or resumes a Session and returns its SSE stream and Session ID.
|
|
76
|
+
* @param input - Agent, message or stored Prompt, and optional existing Session.
|
|
77
|
+
* @returns The Session ID promise and single-owner SSE accessors.
|
|
78
|
+
*/
|
|
69
79
|
chat(input: ChatInput): Promise<ChatResult>;
|
|
80
|
+
/**
|
|
81
|
+
* Starts stateless text generation with independent final, incremental, and response outputs.
|
|
82
|
+
* @param input - Agent and literal prompt or stored Prompt reference.
|
|
83
|
+
* @returns Independent text stream, final text promise, and response relay.
|
|
84
|
+
*/
|
|
70
85
|
completion(input: CompletionInput): Promise<CompletionResult>;
|
|
86
|
+
/**
|
|
87
|
+
* Submits a complete Tool approval round and streams its continuation.
|
|
88
|
+
* @param input - Agent, Session, and decisions for the complete approval round.
|
|
89
|
+
* @returns The Session ID promise and continuation SSE accessors.
|
|
90
|
+
*/
|
|
71
91
|
continueChat(input: ContinueChatInput): Promise<ChatResult>;
|
|
72
92
|
readonly memories: MemoriesResource;
|
|
93
|
+
/**
|
|
94
|
+
* Starts stateless JSON generation with partial objects and a final parsed value.
|
|
95
|
+
* @param input - Agent, prompt source, and JSON output schema.
|
|
96
|
+
* @returns Partial JSON objects, a final JSON promise, and a text response relay.
|
|
97
|
+
*/
|
|
73
98
|
object(input: ObjectInput): Promise<ObjectResult>;
|
|
74
99
|
readonly prompts: PromptsResource;
|
|
75
100
|
readonly sessions: SessionsResource;
|
|
76
101
|
readonly tasks: TasksResource;
|
|
77
102
|
readonly usage: Pick<UsageResource, "get" | "sessions">;
|
|
103
|
+
/**
|
|
104
|
+
* Creates a client view with the supplied request correlation ID.
|
|
105
|
+
* @param options - Caller-owned request correlation ID for subsequent calls.
|
|
106
|
+
* @returns A new client carrying the supplied correlation ID.
|
|
107
|
+
*/
|
|
78
108
|
withOptions(options: BlazingAgentsRequestOptions): UserClient;
|
|
79
109
|
readonly workspaces: WorkspacesResource;
|
|
80
110
|
}
|
|
@@ -156,14 +186,32 @@ export interface ChatResult {
|
|
|
156
186
|
* resume.
|
|
157
187
|
*/
|
|
158
188
|
sessionId: Promise<string>;
|
|
189
|
+
/**
|
|
190
|
+
* Claims the response relay once and returns its HTTP response.
|
|
191
|
+
* @returns The response relay.
|
|
192
|
+
* @throws BlazingAgentsError - If the response body has already been claimed.
|
|
193
|
+
*/
|
|
159
194
|
toResponse: () => Response;
|
|
160
|
-
/**
|
|
195
|
+
/**
|
|
196
|
+
* Claims the SSE bytes once, without constructing a Response. Shares ownership with toResponse().
|
|
197
|
+
* @returns The SSE byte stream.
|
|
198
|
+
* @throws BlazingAgentsError - If the response body has already been claimed.
|
|
199
|
+
*/
|
|
161
200
|
toStream: () => ReadableStream<Uint8Array>;
|
|
162
201
|
}
|
|
163
202
|
export interface TerminalStreamResult {
|
|
164
203
|
requestId?: string;
|
|
204
|
+
/**
|
|
205
|
+
* Claims the response relay once and returns its HTTP response.
|
|
206
|
+
* @returns The response relay.
|
|
207
|
+
* @throws BlazingAgentsError - If the response body has already been claimed.
|
|
208
|
+
*/
|
|
165
209
|
toResponse: () => Response;
|
|
166
|
-
/**
|
|
210
|
+
/**
|
|
211
|
+
* Claims the SSE bytes once, without constructing a Response. Shares ownership with toResponse().
|
|
212
|
+
* @returns The SSE byte stream.
|
|
213
|
+
* @throws BlazingAgentsError - If the response body has already been claimed.
|
|
214
|
+
*/
|
|
167
215
|
toStream: () => ReadableStream<Uint8Array>;
|
|
168
216
|
}
|
|
169
217
|
type StatelessGenerationInput = AttributionInput & CorrelatedRequestInput;
|
|
@@ -188,6 +236,11 @@ export interface CompletionResult {
|
|
|
188
236
|
requestId?: string;
|
|
189
237
|
text: Promise<string>;
|
|
190
238
|
textStream: AsyncIterable<string>;
|
|
239
|
+
/**
|
|
240
|
+
* Claims the response relay once and returns its HTTP response.
|
|
241
|
+
* @returns The response relay.
|
|
242
|
+
* @throws BlazingAgentsError - If the response body has already been claimed.
|
|
243
|
+
*/
|
|
191
244
|
toResponse: () => Response;
|
|
192
245
|
}
|
|
193
246
|
export interface ObjectPromptInput extends StatelessGenerationInput {
|
|
@@ -211,43 +264,111 @@ export interface ObjectResult {
|
|
|
211
264
|
object: Promise<unknown>;
|
|
212
265
|
partialObjectStream: AsyncIterable<unknown>;
|
|
213
266
|
requestId?: string;
|
|
267
|
+
/**
|
|
268
|
+
* Claims the response relay once and returns its HTTP response.
|
|
269
|
+
* @returns The response relay.
|
|
270
|
+
* @throws BlazingAgentsError - If the response body has already been claimed.
|
|
271
|
+
*/
|
|
214
272
|
toResponse: () => Response;
|
|
215
273
|
}
|
|
216
274
|
export interface ResourceRequestOptions {
|
|
217
275
|
abortSignal?: AbortSignal;
|
|
218
276
|
}
|
|
219
277
|
export interface AgentsResource {
|
|
220
|
-
/**
|
|
278
|
+
/**
|
|
279
|
+
* Creates the Agent. Omitting `workspaceId` creates a Core Workspace by default. `workspaceTier` selects its immutable tier and conflicts with `workspaceId`.
|
|
280
|
+
* @param input - creation fields; optional abortSignal.
|
|
281
|
+
* @returns The agent.
|
|
282
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
283
|
+
*/
|
|
221
284
|
create(input: CreateAgentBody & ResourceRequestOptions): Promise<Agent>;
|
|
222
|
-
/**
|
|
285
|
+
/**
|
|
286
|
+
* Deletes the Agent while preserving its attached Workspace.
|
|
287
|
+
* @param input - `agentId`; optional abortSignal; includeArtifacts controls Artifact deletion.
|
|
288
|
+
* @returns Resolves when the operation completes.
|
|
289
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
290
|
+
*/
|
|
223
291
|
delete(input: {
|
|
224
292
|
agentId: string;
|
|
225
293
|
includeArtifacts: boolean;
|
|
226
294
|
} & ResourceRequestOptions): Promise<void>;
|
|
295
|
+
/**
|
|
296
|
+
* Disables the Agent.
|
|
297
|
+
* @param input - `agentId`; optional abortSignal.
|
|
298
|
+
* @returns The agent.
|
|
299
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
300
|
+
*/
|
|
227
301
|
disable(input: {
|
|
228
302
|
agentId: string;
|
|
229
303
|
} & ResourceRequestOptions): Promise<Agent>;
|
|
304
|
+
/**
|
|
305
|
+
* Enables the Agent.
|
|
306
|
+
* @param input - `agentId`; optional abortSignal.
|
|
307
|
+
* @returns The agent.
|
|
308
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
309
|
+
*/
|
|
230
310
|
enable(input: {
|
|
231
311
|
agentId: string;
|
|
232
312
|
} & ResourceRequestOptions): Promise<Agent>;
|
|
313
|
+
/**
|
|
314
|
+
* Retrieves the Agent.
|
|
315
|
+
* @param input - `agentId`; optional abortSignal.
|
|
316
|
+
* @returns The agent.
|
|
317
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
318
|
+
*/
|
|
233
319
|
get(input: {
|
|
234
320
|
agentId: string;
|
|
235
321
|
} & ResourceRequestOptions): Promise<Agent>;
|
|
322
|
+
/**
|
|
323
|
+
* Lists available Agent records.
|
|
324
|
+
* @param input - filters and pagination options.
|
|
325
|
+
* @returns Matching Agents. This response has no pagination cursor.
|
|
326
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
327
|
+
*/
|
|
236
328
|
list(input?: AgentsListOptions): Promise<AgentsResponse>;
|
|
329
|
+
/**
|
|
330
|
+
* Lists the Agent MCP attachments.
|
|
331
|
+
* @param input - `agentId`; optional abortSignal.
|
|
332
|
+
* @returns The mcp attachments response.
|
|
333
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
334
|
+
*/
|
|
237
335
|
listMcpAttachments(input: {
|
|
238
336
|
agentId: string;
|
|
239
337
|
} & ResourceRequestOptions): Promise<McpAttachmentsResponse>;
|
|
338
|
+
/**
|
|
339
|
+
* Removes the Agent avatar.
|
|
340
|
+
* @param input - `agentId`; optional abortSignal.
|
|
341
|
+
* @returns The agent.
|
|
342
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
343
|
+
*/
|
|
240
344
|
removeAvatar(input: {
|
|
241
345
|
agentId: string;
|
|
242
346
|
} & ResourceRequestOptions): Promise<Agent>;
|
|
243
|
-
/**
|
|
347
|
+
/**
|
|
348
|
+
* Updates the Agent. A concrete `workspaceId` switches the Agent; detachment is unsupported.
|
|
349
|
+
* @param input - `agentId`; fields to change; optional abortSignal.
|
|
350
|
+
* @returns The agent.
|
|
351
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
352
|
+
*/
|
|
244
353
|
update(input: UpdateAgentBody & {
|
|
245
354
|
agentId: string;
|
|
246
355
|
} & ResourceRequestOptions): Promise<Agent>;
|
|
356
|
+
/**
|
|
357
|
+
* Updates one Agent MCP attachment.
|
|
358
|
+
* @param input - `agentId`, `mcpConnectionId`; fields to change; optional abortSignal.
|
|
359
|
+
* @returns The mcp attachment response.
|
|
360
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
361
|
+
*/
|
|
247
362
|
updateMcpAttachment(input: UpdateMcpAttachmentBody & {
|
|
248
363
|
agentId: string;
|
|
249
364
|
mcpConnectionId: string;
|
|
250
365
|
} & ResourceRequestOptions): Promise<McpAttachmentResponse>;
|
|
366
|
+
/**
|
|
367
|
+
* Uploads an Agent avatar as multipart form data.
|
|
368
|
+
* @param input - Target `agentId`, image `file`, and optional abortSignal.
|
|
369
|
+
* @returns The agent.
|
|
370
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
371
|
+
*/
|
|
251
372
|
uploadAvatar(input: {
|
|
252
373
|
agentId: string;
|
|
253
374
|
file: File;
|
|
@@ -263,14 +384,44 @@ export interface AgentsListOptions extends ResourceRequestOptions {
|
|
|
263
384
|
workspaceId?: string;
|
|
264
385
|
}
|
|
265
386
|
export interface WorkspacesResource {
|
|
387
|
+
/**
|
|
388
|
+
* Creates the Workspace.
|
|
389
|
+
* @param input - creation fields; optional abortSignal.
|
|
390
|
+
* @returns The workspace.
|
|
391
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
392
|
+
*/
|
|
266
393
|
create(input?: CreateWorkspaceBody & ResourceRequestOptions): Promise<Workspace>;
|
|
394
|
+
/**
|
|
395
|
+
* Deletes the Workspace.
|
|
396
|
+
* @param input - `workspaceId`; optional abortSignal.
|
|
397
|
+
* @returns "pending" while deletion is underway, otherwise "completed".
|
|
398
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
399
|
+
*/
|
|
267
400
|
delete(input: {
|
|
268
401
|
workspaceId: string;
|
|
269
402
|
} & ResourceRequestOptions): Promise<"completed" | "pending">;
|
|
403
|
+
/**
|
|
404
|
+
* Retrieves the Workspace.
|
|
405
|
+
* @param input - `workspaceId`; optional abortSignal.
|
|
406
|
+
* @returns The workspace.
|
|
407
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
408
|
+
*/
|
|
270
409
|
get(input: {
|
|
271
410
|
workspaceId: string;
|
|
272
411
|
} & ResourceRequestOptions): Promise<Workspace>;
|
|
412
|
+
/**
|
|
413
|
+
* Lists one page of Workspace records.
|
|
414
|
+
* @param input - filters and pagination options.
|
|
415
|
+
* @returns The workspaces list response.
|
|
416
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
417
|
+
*/
|
|
273
418
|
list(input?: WorkspacesListOptions): Promise<WorkspacesListResponse>;
|
|
419
|
+
/**
|
|
420
|
+
* Updates the Workspace.
|
|
421
|
+
* @param input - `workspaceId`; fields to change; optional abortSignal.
|
|
422
|
+
* @returns The workspace.
|
|
423
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
424
|
+
*/
|
|
274
425
|
update(input: UpdateWorkspaceBody & {
|
|
275
426
|
workspaceId: string;
|
|
276
427
|
} & ResourceRequestOptions): Promise<Workspace>;
|
|
@@ -286,32 +437,85 @@ export interface ArtifactsListOptions extends ResourceRequestOptions {
|
|
|
286
437
|
sessionId?: string;
|
|
287
438
|
}
|
|
288
439
|
export interface ArtifactsResource {
|
|
440
|
+
/**
|
|
441
|
+
* Creates a temporary Artifact download URL.
|
|
442
|
+
* @param input - `artifactId`; optional abortSignal.
|
|
443
|
+
* @returns The artifact download url response.
|
|
444
|
+
*/
|
|
289
445
|
createDownloadUrl(input: {
|
|
290
446
|
artifactId: string;
|
|
291
447
|
} & ResourceRequestOptions): Promise<ArtifactDownloadUrlResponse>;
|
|
448
|
+
/**
|
|
449
|
+
* Deletes the Artifact.
|
|
450
|
+
* @param input - `artifactId`; optional abortSignal.
|
|
451
|
+
* @returns Resolves when the operation completes.
|
|
452
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
453
|
+
*/
|
|
292
454
|
delete(input: {
|
|
293
455
|
artifactId: string;
|
|
294
456
|
} & ResourceRequestOptions): Promise<void>;
|
|
457
|
+
/**
|
|
458
|
+
* Retrieves the Artifact.
|
|
459
|
+
* @param input - `artifactId`; optional abortSignal.
|
|
460
|
+
* @returns The artifact list item.
|
|
461
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
462
|
+
*/
|
|
295
463
|
get(input: {
|
|
296
464
|
artifactId: string;
|
|
297
465
|
} & ResourceRequestOptions): Promise<ArtifactListItem>;
|
|
466
|
+
/**
|
|
467
|
+
* Lists one page of Artifact records.
|
|
468
|
+
* @param input - filters and pagination options.
|
|
469
|
+
* @returns The artifacts list response.
|
|
470
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
471
|
+
*/
|
|
298
472
|
list(input?: ArtifactsListOptions): Promise<ArtifactsListResponse>;
|
|
299
473
|
}
|
|
300
474
|
export interface MemoriesResource {
|
|
475
|
+
/**
|
|
476
|
+
* Creates the Memory.
|
|
477
|
+
* @param input - `agentId`; creation fields; optional abortSignal.
|
|
478
|
+
* @returns The memory response.
|
|
479
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
480
|
+
*/
|
|
301
481
|
create(input: CreateMemoryBody & {
|
|
302
482
|
agentId: string;
|
|
303
483
|
} & ResourceRequestOptions): Promise<MemoryResponse>;
|
|
484
|
+
/**
|
|
485
|
+
* Deletes the Memory.
|
|
486
|
+
* @param input - `agentId`, `memoryId`; optional abortSignal.
|
|
487
|
+
* @returns Resolves when the operation completes.
|
|
488
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
489
|
+
*/
|
|
304
490
|
delete(input: {
|
|
305
491
|
agentId: string;
|
|
306
492
|
memoryId: string;
|
|
307
493
|
} & ResourceRequestOptions): Promise<void>;
|
|
494
|
+
/**
|
|
495
|
+
* Retrieves the Memory.
|
|
496
|
+
* @param input - `agentId`, `memoryId`; optional abortSignal.
|
|
497
|
+
* @returns The memory response.
|
|
498
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
499
|
+
*/
|
|
308
500
|
get(input: {
|
|
309
501
|
agentId: string;
|
|
310
502
|
memoryId: string;
|
|
311
503
|
} & ResourceRequestOptions): Promise<MemoryResponse>;
|
|
504
|
+
/**
|
|
505
|
+
* Lists one page of Memory records.
|
|
506
|
+
* @param input - `agentId`; filters and pagination options.
|
|
507
|
+
* @returns The memories list response.
|
|
508
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
509
|
+
*/
|
|
312
510
|
list(input: {
|
|
313
511
|
agentId: string;
|
|
314
512
|
} & MemoriesListOptions): Promise<MemoriesListResponse>;
|
|
513
|
+
/**
|
|
514
|
+
* Updates the Memory.
|
|
515
|
+
* @param input - `agentId`, `memoryId`; fields to change; optional abortSignal.
|
|
516
|
+
* @returns The memory response.
|
|
517
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
518
|
+
*/
|
|
315
519
|
update(input: UpdateMemoryBody & {
|
|
316
520
|
agentId: string;
|
|
317
521
|
memoryId: string;
|
|
@@ -324,61 +528,181 @@ export interface MemoriesListOptions extends ResourceRequestOptions {
|
|
|
324
528
|
userId?: string;
|
|
325
529
|
}
|
|
326
530
|
export interface PromptsResource {
|
|
531
|
+
/**
|
|
532
|
+
* Creates the Prompt.
|
|
533
|
+
* @param input - creation fields; optional abortSignal.
|
|
534
|
+
* @returns The prompt response.
|
|
535
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
536
|
+
*/
|
|
327
537
|
create(input: CreatePromptBody & ResourceRequestOptions): Promise<PromptResponse>;
|
|
538
|
+
/**
|
|
539
|
+
* Deletes the Prompt.
|
|
540
|
+
* @param input - `promptId`; optional abortSignal.
|
|
541
|
+
* @returns Resolves when the operation completes.
|
|
542
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
543
|
+
*/
|
|
328
544
|
delete(input: {
|
|
329
545
|
promptId: string;
|
|
330
546
|
} & ResourceRequestOptions): Promise<void>;
|
|
547
|
+
/**
|
|
548
|
+
* Retrieves the Prompt.
|
|
549
|
+
* @param input - `promptId`; optional abortSignal.
|
|
550
|
+
* @returns The prompt response.
|
|
551
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
552
|
+
*/
|
|
331
553
|
get(input: {
|
|
332
554
|
promptId: string;
|
|
333
555
|
} & ResourceRequestOptions): Promise<PromptResponse>;
|
|
556
|
+
/**
|
|
557
|
+
* Lists one page of Prompt records.
|
|
558
|
+
* @param input - `userId`, `agentId`; filters and pagination options; optional abortSignal.
|
|
559
|
+
* @returns The prompts response.
|
|
560
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
561
|
+
*/
|
|
334
562
|
list(input?: {
|
|
335
563
|
userId?: string;
|
|
336
564
|
agentId?: string;
|
|
337
565
|
cursor?: string;
|
|
338
566
|
limit?: number;
|
|
339
567
|
} & ResourceRequestOptions): Promise<PromptsResponse>;
|
|
568
|
+
/**
|
|
569
|
+
* Updates the Prompt.
|
|
570
|
+
* @param input - `promptId`; fields to change; optional abortSignal.
|
|
571
|
+
* @returns The prompt response.
|
|
572
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
573
|
+
*/
|
|
340
574
|
update(input: UpdatePromptBody & {
|
|
341
575
|
promptId: string;
|
|
342
576
|
} & ResourceRequestOptions): Promise<PromptResponse>;
|
|
343
577
|
}
|
|
344
578
|
export interface ProvidersResource {
|
|
579
|
+
/**
|
|
580
|
+
* Creates the Provider.
|
|
581
|
+
* @param input - creation fields; optional abortSignal.
|
|
582
|
+
* @returns The provider response.
|
|
583
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
584
|
+
*/
|
|
345
585
|
create(input: CreateProviderBody & ResourceRequestOptions): Promise<ProviderResponse>;
|
|
586
|
+
/**
|
|
587
|
+
* Deletes the Provider.
|
|
588
|
+
* @param input - `providerId`; optional abortSignal.
|
|
589
|
+
* @returns Resolves when the operation completes.
|
|
590
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
591
|
+
*/
|
|
346
592
|
delete(input: DeleteProviderOptions & {
|
|
347
593
|
providerId: string;
|
|
348
594
|
} & ResourceRequestOptions): Promise<void>;
|
|
595
|
+
/**
|
|
596
|
+
* Retrieves the Provider.
|
|
597
|
+
* @param input - `providerId`; optional abortSignal.
|
|
598
|
+
* @returns The provider response.
|
|
599
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
600
|
+
*/
|
|
349
601
|
get(input: {
|
|
350
602
|
providerId: string;
|
|
351
603
|
} & ResourceRequestOptions): Promise<ProviderResponse>;
|
|
604
|
+
/**
|
|
605
|
+
* Retrieves supported thinking levels for a Provider model.
|
|
606
|
+
* @param input - `providerId`, provider-specific `model` name, and optional abortSignal.
|
|
607
|
+
* @returns The thinking levels response.
|
|
608
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
609
|
+
*/
|
|
352
610
|
getThinkingLevels(input: {
|
|
353
611
|
providerId: string;
|
|
354
612
|
model: string;
|
|
355
613
|
} & ResourceRequestOptions): Promise<ThinkingLevelsResponse>;
|
|
614
|
+
/**
|
|
615
|
+
* Lists available Provider records.
|
|
616
|
+
* @param input - optional abortSignal.
|
|
617
|
+
* @returns The providers response.
|
|
618
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
619
|
+
*/
|
|
356
620
|
list(input?: ResourceRequestOptions): Promise<ProvidersResponse>;
|
|
621
|
+
/**
|
|
622
|
+
* Lists models exposed by the Provider.
|
|
623
|
+
* @param input - `providerId`; optional abortSignal.
|
|
624
|
+
* @returns The provider models response.
|
|
625
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
626
|
+
*/
|
|
357
627
|
listModels(input: {
|
|
358
628
|
providerId: string;
|
|
359
629
|
} & ResourceRequestOptions): Promise<ProviderModelsResponse>;
|
|
630
|
+
/**
|
|
631
|
+
* Updates the Provider.
|
|
632
|
+
* @param input - `providerId`; fields to change; optional abortSignal.
|
|
633
|
+
* @returns The provider response.
|
|
634
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
635
|
+
*/
|
|
360
636
|
update(input: UpdateProviderBody & {
|
|
361
637
|
providerId: string;
|
|
362
638
|
} & ResourceRequestOptions): Promise<ProviderResponse>;
|
|
363
639
|
}
|
|
364
640
|
export interface McpConnectionsResource {
|
|
641
|
+
/**
|
|
642
|
+
* Starts OAuth authorization for the MCP Connection.
|
|
643
|
+
* @param input - `mcpConnectionId`; optional abortSignal.
|
|
644
|
+
* @returns The mcp connection oauth connect response.
|
|
645
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
646
|
+
*/
|
|
365
647
|
connect(input: {
|
|
366
648
|
mcpConnectionId: string;
|
|
367
649
|
} & ResourceRequestOptions): Promise<McpConnectionOauthConnectResponse>;
|
|
650
|
+
/**
|
|
651
|
+
* Creates the MCP Connection.
|
|
652
|
+
* @param input - creation fields; optional abortSignal.
|
|
653
|
+
* @returns The mcp connection response.
|
|
654
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
655
|
+
*/
|
|
368
656
|
create(input: CreateMcpConnectionBody & ResourceRequestOptions): Promise<McpConnectionResponse>;
|
|
657
|
+
/**
|
|
658
|
+
* Deletes the MCP Connection.
|
|
659
|
+
* @param input - `mcpConnectionId`; optional abortSignal.
|
|
660
|
+
* @returns Resolves when the operation completes.
|
|
661
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
662
|
+
*/
|
|
369
663
|
delete(input: {
|
|
370
664
|
mcpConnectionId: string;
|
|
371
665
|
} & ResourceRequestOptions): Promise<void>;
|
|
666
|
+
/**
|
|
667
|
+
* Retrieves the MCP Connection.
|
|
668
|
+
* @param input - `mcpConnectionId`; optional abortSignal.
|
|
669
|
+
* @returns The mcp connection response.
|
|
670
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
671
|
+
*/
|
|
372
672
|
get(input: {
|
|
373
673
|
mcpConnectionId: string;
|
|
374
674
|
} & ResourceRequestOptions): Promise<McpConnectionResponse>;
|
|
675
|
+
/**
|
|
676
|
+
* Lists available MCP Connection records.
|
|
677
|
+
* @param input - optional abortSignal.
|
|
678
|
+
* @returns The mcp connections response.
|
|
679
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
680
|
+
*/
|
|
375
681
|
list(input?: ResourceRequestOptions): Promise<McpConnectionsResponse>;
|
|
682
|
+
/**
|
|
683
|
+
* Reconnects the MCP Connection.
|
|
684
|
+
* @param input - `mcpConnectionId`; fields to change; optional abortSignal.
|
|
685
|
+
* @returns The mcp connection reconnect result.
|
|
686
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
687
|
+
*/
|
|
376
688
|
reconnect(input: ReconnectMcpConnectionBody & {
|
|
377
689
|
mcpConnectionId: string;
|
|
378
690
|
} & ResourceRequestOptions): Promise<McpConnectionReconnectResult>;
|
|
691
|
+
/**
|
|
692
|
+
* Tests the MCP Connection.
|
|
693
|
+
* @param input - `mcpConnectionId`; optional abortSignal.
|
|
694
|
+
* @returns The mcp connection test response.
|
|
695
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
696
|
+
*/
|
|
379
697
|
test(input: {
|
|
380
698
|
mcpConnectionId: string;
|
|
381
699
|
} & ResourceRequestOptions): Promise<McpConnectionTestResponse>;
|
|
700
|
+
/**
|
|
701
|
+
* Updates the MCP Connection.
|
|
702
|
+
* @param input - `mcpConnectionId`; fields to change; optional abortSignal.
|
|
703
|
+
* @returns The mcp connection response.
|
|
704
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
705
|
+
*/
|
|
382
706
|
update(input: UpdateMcpConnectionBody & {
|
|
383
707
|
mcpConnectionId: string;
|
|
384
708
|
} & ResourceRequestOptions): Promise<McpConnectionResponse>;
|
|
@@ -400,20 +724,55 @@ export interface SessionMessagesOptions extends ResourceRequestOptions {
|
|
|
400
724
|
limit?: number;
|
|
401
725
|
}
|
|
402
726
|
export interface SessionsResource {
|
|
727
|
+
/**
|
|
728
|
+
* Deletes the Session.
|
|
729
|
+
* @param input - `agentId`, `sessionId`; optional abortSignal; deleteArtifacts controls Artifact deletion.
|
|
730
|
+
* @returns Resolves when the operation completes.
|
|
731
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
732
|
+
*/
|
|
403
733
|
delete(input: {
|
|
404
734
|
agentId: string;
|
|
405
735
|
sessionId: string;
|
|
406
736
|
deleteArtifacts: boolean;
|
|
407
737
|
} & ResourceRequestOptions): Promise<void>;
|
|
738
|
+
/**
|
|
739
|
+
* Retry an uncertain acknowledgement with the same explicit idempotencyKey.
|
|
740
|
+
* @param input - `agentId`, `sessionId`, `messageId`; optional abortSignal.
|
|
741
|
+
* @returns The session response.
|
|
742
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
743
|
+
*/
|
|
744
|
+
fork(input: {
|
|
745
|
+
agentId: string;
|
|
746
|
+
sessionId: string;
|
|
747
|
+
messageId: string;
|
|
748
|
+
idempotencyKey: string;
|
|
749
|
+
} & ResourceRequestOptions): Promise<SessionResponse>;
|
|
750
|
+
/**
|
|
751
|
+
* Retrieves the Session.
|
|
752
|
+
* @param input - `agentId`, `sessionId`; optional abortSignal.
|
|
753
|
+
* @returns The session response.
|
|
754
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
755
|
+
*/
|
|
408
756
|
get(input: {
|
|
409
757
|
agentId: string;
|
|
410
758
|
sessionId: string;
|
|
411
759
|
} & ResourceRequestOptions): Promise<SessionResponse>;
|
|
412
|
-
/**
|
|
760
|
+
/**
|
|
761
|
+
* Poll from the first page for state changes; cursor only paginates receipts.
|
|
762
|
+
* @param input - `agentId`, `sessionId`; query filters; optional abortSignal.
|
|
763
|
+
* @returns The session inputs response.
|
|
764
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
765
|
+
*/
|
|
413
766
|
inputs(input: {
|
|
414
767
|
agentId: string;
|
|
415
768
|
sessionId: string;
|
|
416
769
|
} & SessionInputsQuery & ResourceRequestOptions): Promise<SessionInputsResponse>;
|
|
770
|
+
/**
|
|
771
|
+
* Lists one page of Session records.
|
|
772
|
+
* @param input - `agentId`; filters and pagination options.
|
|
773
|
+
* @returns The sessions list response.
|
|
774
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
775
|
+
*/
|
|
417
776
|
list(input: {
|
|
418
777
|
agentId: string;
|
|
419
778
|
} & SessionsListOptions): Promise<SessionsListResponse>;
|
|
@@ -421,56 +780,135 @@ export interface SessionsResource {
|
|
|
421
780
|
* `GET /v1/sessions/latest` — the Tenant's most recently updated Sessions,
|
|
422
781
|
* newest first. Set `byAgent` to return at most one Session per Agent.
|
|
423
782
|
* `userId` narrows the candidate Sessions to one end user's.
|
|
783
|
+
* @param input - filters and pagination options.
|
|
784
|
+
* @returns The latest sessions list response.
|
|
785
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
424
786
|
*/
|
|
425
787
|
listLatest(input?: LatestSessionsListOptions): Promise<LatestSessionsListResponse>;
|
|
788
|
+
/**
|
|
789
|
+
* Lists one page of Session messages.
|
|
790
|
+
* @param input - `agentId`, `sessionId`.
|
|
791
|
+
* @returns The session messages response.
|
|
792
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
793
|
+
*/
|
|
426
794
|
messages(input: {
|
|
427
795
|
agentId: string;
|
|
428
796
|
sessionId: string;
|
|
429
797
|
} & SessionMessagesOptions): Promise<SessionMessagesResponse>;
|
|
430
|
-
/**
|
|
798
|
+
/**
|
|
799
|
+
* Records cancellation for the named Turn without waiting for settlement.
|
|
800
|
+
* @param input - `agentId`, `sessionId`; fields to change; optional abortSignal.
|
|
801
|
+
* @returns The stop session response.
|
|
802
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
803
|
+
*/
|
|
431
804
|
stop(input: {
|
|
432
805
|
agentId: string;
|
|
433
806
|
sessionId: string;
|
|
434
807
|
} & StopSessionBody & ResourceRequestOptions): Promise<StopSessionResponse>;
|
|
435
|
-
/**
|
|
808
|
+
/**
|
|
809
|
+
* Retry an uncertain acknowledgement with the same requestId and payload.
|
|
810
|
+
* @param input - `agentId`, `sessionId`; fields to change; optional abortSignal.
|
|
811
|
+
* @returns The session input response.
|
|
812
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
813
|
+
*/
|
|
436
814
|
submitInput(input: Omit<SubmitSessionInputBody, "message"> & {
|
|
437
815
|
agentId: string;
|
|
438
816
|
sessionId: string;
|
|
439
817
|
message: UIMessage;
|
|
440
818
|
} & ResourceRequestOptions): Promise<SessionInputResponse>;
|
|
819
|
+
/**
|
|
820
|
+
* Retrieves the pending Tool approval round.
|
|
821
|
+
* @param input - `agentId`, `sessionId`; optional abortSignal.
|
|
822
|
+
* @returns The tool approvals response.
|
|
823
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
824
|
+
*/
|
|
441
825
|
toolApprovals(input: {
|
|
442
826
|
agentId: string;
|
|
443
827
|
sessionId: string;
|
|
444
828
|
} & ResourceRequestOptions): Promise<ToolApprovalsResponse>;
|
|
445
829
|
}
|
|
446
830
|
export interface AgentSkillsResource {
|
|
831
|
+
/**
|
|
832
|
+
* Copies the Skill to the selected Agents.
|
|
833
|
+
* @param input - Source `skillId`, destination `to.agentIds`, and optional abortSignal.
|
|
834
|
+
* @returns The skill copy results.
|
|
835
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
836
|
+
*/
|
|
447
837
|
copy(input: {
|
|
448
838
|
skillId: string;
|
|
449
839
|
to: {
|
|
450
840
|
agentIds: string[];
|
|
451
841
|
};
|
|
452
842
|
} & ResourceRequestOptions): Promise<SkillCopyResults>;
|
|
843
|
+
/**
|
|
844
|
+
* Creates the Skill.
|
|
845
|
+
* @param input - creation fields; optional abortSignal.
|
|
846
|
+
* @returns The skill detail.
|
|
847
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
848
|
+
*/
|
|
453
849
|
create(input: CreateSkillBody & ResourceRequestOptions): Promise<SkillDetail>;
|
|
850
|
+
/**
|
|
851
|
+
* Deletes the Skill.
|
|
852
|
+
* @param input - `skillId`; optional abortSignal.
|
|
853
|
+
* @returns Resolves when the operation completes.
|
|
854
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
855
|
+
*/
|
|
454
856
|
delete(input: {
|
|
455
857
|
skillId: string;
|
|
456
858
|
} & ResourceRequestOptions): Promise<void>;
|
|
859
|
+
/**
|
|
860
|
+
* Deletes a Skill file.
|
|
861
|
+
* @param input - `skillId`, relative file `path`, and optional abortSignal.
|
|
862
|
+
* @returns The skill detail.
|
|
863
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
864
|
+
*/
|
|
457
865
|
deleteFile(input: {
|
|
458
866
|
path: string;
|
|
459
867
|
skillId: string;
|
|
460
868
|
} & ResourceRequestOptions): Promise<SkillDetail>;
|
|
869
|
+
/**
|
|
870
|
+
* Retrieves the Skill.
|
|
871
|
+
* @param input - `skillId`; optional abortSignal.
|
|
872
|
+
* @returns The skill detail.
|
|
873
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
874
|
+
*/
|
|
461
875
|
get(input: {
|
|
462
876
|
skillId: string;
|
|
463
877
|
} & ResourceRequestOptions): Promise<SkillDetail>;
|
|
878
|
+
/**
|
|
879
|
+
* Reads Skill file bytes.
|
|
880
|
+
* @param input - `skillId`, relative file `path`, and optional abortSignal.
|
|
881
|
+
* @returns The requested file bytes.
|
|
882
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
883
|
+
*/
|
|
464
884
|
getFile(input: {
|
|
465
885
|
path: string;
|
|
466
886
|
skillId: string;
|
|
467
887
|
} & ResourceRequestOptions): Promise<Uint8Array>;
|
|
888
|
+
/**
|
|
889
|
+
* Lists one page of Skill records.
|
|
890
|
+
* @param input - filters and pagination options.
|
|
891
|
+
* @returns The skills list response.
|
|
892
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
893
|
+
*/
|
|
468
894
|
list(input?: SkillsListOptions): Promise<SkillsListResponse>;
|
|
895
|
+
/**
|
|
896
|
+
* Replaces a Skill file with the supplied content.
|
|
897
|
+
* @param input - `skillId`, relative `path`, replacement `content`, and optional abortSignal.
|
|
898
|
+
* @returns The skill detail.
|
|
899
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
900
|
+
*/
|
|
469
901
|
putFile(input: {
|
|
470
902
|
content: Blob | string | Uint8Array;
|
|
471
903
|
path: string;
|
|
472
904
|
skillId: string;
|
|
473
905
|
} & ResourceRequestOptions): Promise<SkillDetail>;
|
|
906
|
+
/**
|
|
907
|
+
* Uploads a Skill archive as multipart form data.
|
|
908
|
+
* @param input - Archive bytes in `source.file`, archive format in `source.type`, and optional abortSignal.
|
|
909
|
+
* @returns The skill detail.
|
|
910
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
911
|
+
*/
|
|
474
912
|
upload(input: {
|
|
475
913
|
source: {
|
|
476
914
|
file: Blob | Uint8Array;
|
|
@@ -498,47 +936,141 @@ export interface TaskRunMessagesOptions extends ResourceRequestOptions {
|
|
|
498
936
|
limit?: number;
|
|
499
937
|
}
|
|
500
938
|
export interface TasksResource {
|
|
939
|
+
/**
|
|
940
|
+
* Requests cancellation of a Task run.
|
|
941
|
+
* @param input - `taskId`, `runId`; optional abortSignal.
|
|
942
|
+
* @returns Resolves when the operation completes.
|
|
943
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
944
|
+
*/
|
|
501
945
|
cancelRun(input: {
|
|
502
946
|
taskId: string;
|
|
503
947
|
runId: string;
|
|
504
948
|
} & ResourceRequestOptions): Promise<void>;
|
|
949
|
+
/**
|
|
950
|
+
* Creates the Task.
|
|
951
|
+
* @param input - creation fields; optional abortSignal.
|
|
952
|
+
* @returns The create task response.
|
|
953
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
954
|
+
*/
|
|
505
955
|
create(input: CreateTaskBody & ResourceRequestOptions): Promise<CreateTaskResponse>;
|
|
956
|
+
/**
|
|
957
|
+
* Creates a Task run.
|
|
958
|
+
* @param input - `taskId`; creation fields; optional abortSignal.
|
|
959
|
+
* @returns The create task run response.
|
|
960
|
+
*/
|
|
506
961
|
createRun(input: CreateTaskRunBody & {
|
|
507
962
|
taskId: string;
|
|
508
963
|
} & ResourceRequestOptions): Promise<CreateTaskRunResponse>;
|
|
964
|
+
/**
|
|
965
|
+
* Deletes the Task.
|
|
966
|
+
* @param input - `taskId`; optional abortSignal.
|
|
967
|
+
* @returns Resolves when the operation completes.
|
|
968
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
969
|
+
*/
|
|
509
970
|
delete(input: {
|
|
510
971
|
taskId: string;
|
|
511
972
|
} & ResourceRequestOptions): Promise<void>;
|
|
973
|
+
/**
|
|
974
|
+
* Retrieves the Task.
|
|
975
|
+
* @param input - `taskId`; optional abortSignal.
|
|
976
|
+
* @returns The task response.
|
|
977
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
978
|
+
*/
|
|
512
979
|
get(input: {
|
|
513
980
|
taskId: string;
|
|
514
981
|
} & ResourceRequestOptions): Promise<TaskResponse>;
|
|
982
|
+
/**
|
|
983
|
+
* Retrieves a Task run.
|
|
984
|
+
* @param input - `taskId`, `runId`; optional abortSignal.
|
|
985
|
+
* @returns The task run response.
|
|
986
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
987
|
+
*/
|
|
515
988
|
getRun(input: {
|
|
516
989
|
taskId: string;
|
|
517
990
|
runId: string;
|
|
518
991
|
} & ResourceRequestOptions): Promise<TaskRunResponse>;
|
|
992
|
+
/**
|
|
993
|
+
* Lists one page of Task records.
|
|
994
|
+
* @param input - filters and pagination options.
|
|
995
|
+
* @returns The tasks list response.
|
|
996
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
997
|
+
*/
|
|
519
998
|
list(input?: TasksListOptions): Promise<TasksListResponse>;
|
|
999
|
+
/**
|
|
1000
|
+
* Lists one page of Task runs.
|
|
1001
|
+
* @param input - `taskId`; filters and pagination options.
|
|
1002
|
+
* @returns The task runs list response.
|
|
1003
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1004
|
+
*/
|
|
520
1005
|
listRuns(input: {
|
|
521
1006
|
taskId: string;
|
|
522
1007
|
} & TaskRunsListOptions): Promise<TaskRunsListResponse>;
|
|
1008
|
+
/**
|
|
1009
|
+
* Lists one page of Task run messages.
|
|
1010
|
+
* @param input - `taskId`, `runId`.
|
|
1011
|
+
* @returns The task run messages response.
|
|
1012
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1013
|
+
*/
|
|
523
1014
|
runMessages(input: {
|
|
524
1015
|
taskId: string;
|
|
525
1016
|
runId: string;
|
|
526
1017
|
} & TaskRunMessagesOptions): Promise<TaskRunMessagesResponse>;
|
|
1018
|
+
/**
|
|
1019
|
+
* Updates the Task.
|
|
1020
|
+
* @param input - `taskId`; fields to change; optional abortSignal.
|
|
1021
|
+
* @returns The task response.
|
|
1022
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1023
|
+
*/
|
|
527
1024
|
update(input: UpdateTaskBody & {
|
|
528
1025
|
taskId: string;
|
|
529
1026
|
} & ResourceRequestOptions): Promise<TaskResponse>;
|
|
530
1027
|
}
|
|
531
1028
|
export interface TenantResource {
|
|
1029
|
+
/**
|
|
1030
|
+
* Retrieves Tenant settings.
|
|
1031
|
+
* @param input - optional abortSignal.
|
|
1032
|
+
* @returns The tenant settings response.
|
|
1033
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1034
|
+
*/
|
|
532
1035
|
get(input?: ResourceRequestOptions): Promise<TenantSettingsResponse>;
|
|
1036
|
+
/**
|
|
1037
|
+
* Updates Tenant settings.
|
|
1038
|
+
* @param input - fields to change; optional abortSignal.
|
|
1039
|
+
* @returns The tenant settings response.
|
|
1040
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1041
|
+
*/
|
|
533
1042
|
patch(input: UpdateTenantSettingsBody & ResourceRequestOptions): Promise<TenantSettingsResponse>;
|
|
534
1043
|
}
|
|
535
1044
|
export interface UsageResource {
|
|
1045
|
+
/**
|
|
1046
|
+
* Retrieves usage totals.
|
|
1047
|
+
* @param input - query filters; optional abortSignal.
|
|
1048
|
+
* @returns The usage response.
|
|
1049
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1050
|
+
*/
|
|
536
1051
|
get(input?: Partial<UsageQuery> & ResourceRequestOptions): Promise<UsageResponse>;
|
|
1052
|
+
/**
|
|
1053
|
+
* Retrieves usage for one Agent.
|
|
1054
|
+
* @param input - `agentId`; query filters; optional abortSignal.
|
|
1055
|
+
* @returns The usage response.
|
|
1056
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1057
|
+
*/
|
|
537
1058
|
getForAgent(input: Partial<UsageQuery> & {
|
|
538
1059
|
agentId: string;
|
|
539
1060
|
} & ResourceRequestOptions): Promise<UsageResponse>;
|
|
540
|
-
/**
|
|
1061
|
+
/**
|
|
1062
|
+
* Returns totals, daily usage, and bounded Agent, user, and model rankings.
|
|
1063
|
+
* @param input - query filters; optional abortSignal.
|
|
1064
|
+
* @returns The usage overview response.
|
|
1065
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1066
|
+
*/
|
|
541
1067
|
overview(input?: Partial<UsageOverviewQuery> & ResourceRequestOptions): Promise<UsageOverviewResponse>;
|
|
1068
|
+
/**
|
|
1069
|
+
* Retrieves usage grouped by Session.
|
|
1070
|
+
* @param input - query filters; optional abortSignal.
|
|
1071
|
+
* @returns The session usage response.
|
|
1072
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1073
|
+
*/
|
|
542
1074
|
sessions(input: SessionUsageQuery & ResourceRequestOptions): Promise<SessionUsageResponse>;
|
|
543
1075
|
}
|
|
544
1076
|
/**
|
|
@@ -547,10 +1079,33 @@ export interface UsageResource {
|
|
|
547
1079
|
* `keyFragment`.
|
|
548
1080
|
*/
|
|
549
1081
|
export interface MerchantConnectionResource {
|
|
1082
|
+
/**
|
|
1083
|
+
* Creates the merchant connection.
|
|
1084
|
+
* @param input - creation fields; optional abortSignal.
|
|
1085
|
+
* @returns The merchant connection response.
|
|
1086
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1087
|
+
*/
|
|
550
1088
|
create(input: CreateMerchantConnectionBody & ResourceRequestOptions): Promise<MerchantConnectionResponse>;
|
|
1089
|
+
/**
|
|
1090
|
+
* Retrieves the merchant connection.
|
|
1091
|
+
* @param input - optional abortSignal.
|
|
1092
|
+
* @returns The merchant connection response.
|
|
1093
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1094
|
+
*/
|
|
551
1095
|
get(input?: ResourceRequestOptions): Promise<MerchantConnectionResponse>;
|
|
552
|
-
/**
|
|
1096
|
+
/**
|
|
1097
|
+
* Retires the merchant connection and stops deliveries.
|
|
1098
|
+
* @param input - optional abortSignal.
|
|
1099
|
+
* @returns Resolves when the operation completes.
|
|
1100
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1101
|
+
*/
|
|
553
1102
|
retire(input?: ResourceRequestOptions): Promise<void>;
|
|
1103
|
+
/**
|
|
1104
|
+
* Updates the merchant connection.
|
|
1105
|
+
* @param input - fields to change; optional abortSignal.
|
|
1106
|
+
* @returns The merchant connection response.
|
|
1107
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1108
|
+
*/
|
|
554
1109
|
update(input: UpdateMerchantConnectionBody & ResourceRequestOptions): Promise<MerchantConnectionResponse>;
|
|
555
1110
|
}
|
|
556
1111
|
export interface MerchantBindingsListOptions extends ResourceRequestOptions {
|
|
@@ -564,10 +1119,28 @@ export interface MerchantBindingsListOptions extends ResourceRequestOptions {
|
|
|
564
1119
|
* the provider.
|
|
565
1120
|
*/
|
|
566
1121
|
export interface MerchantBindingsResource {
|
|
1122
|
+
/**
|
|
1123
|
+
* Deletes the end-user merchant binding.
|
|
1124
|
+
* @param input - `userId`; optional abortSignal.
|
|
1125
|
+
* @returns Resolves when the operation completes.
|
|
1126
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1127
|
+
*/
|
|
567
1128
|
delete(input: {
|
|
568
1129
|
userId: string;
|
|
569
1130
|
} & ResourceRequestOptions): Promise<void>;
|
|
1131
|
+
/**
|
|
1132
|
+
* Lists one page of end-user merchant binding records.
|
|
1133
|
+
* @param input - filters and pagination options.
|
|
1134
|
+
* @returns The merchant bindings response.
|
|
1135
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1136
|
+
*/
|
|
570
1137
|
list(input?: MerchantBindingsListOptions): Promise<MerchantBindingsResponse>;
|
|
1138
|
+
/**
|
|
1139
|
+
* Validates and saves the end-user merchant binding.
|
|
1140
|
+
* @param input - `userId`; fields to change; optional abortSignal.
|
|
1141
|
+
* @returns The merchant binding response.
|
|
1142
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1143
|
+
*/
|
|
571
1144
|
put(input: UpsertMerchantBindingBody & {
|
|
572
1145
|
userId: string;
|
|
573
1146
|
} & ResourceRequestOptions): Promise<MerchantBindingResponse>;
|
|
@@ -583,44 +1156,134 @@ export interface MerchantUsageEventsListOptions extends ResourceRequestOptions {
|
|
|
583
1156
|
* operator actions on unresolved events.
|
|
584
1157
|
*/
|
|
585
1158
|
export interface MerchantUsageEventsResource {
|
|
1159
|
+
/**
|
|
1160
|
+
* Discards the merchant usage event.
|
|
1161
|
+
* @param input - `eventId`; optional abortSignal.
|
|
1162
|
+
* @returns The merchant usage event response.
|
|
1163
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1164
|
+
*/
|
|
586
1165
|
discard(input: {
|
|
587
1166
|
eventId: string;
|
|
588
1167
|
} & ResourceRequestOptions): Promise<MerchantUsageEventResponse>;
|
|
1168
|
+
/**
|
|
1169
|
+
* Retrieves the merchant usage event.
|
|
1170
|
+
* @param input - `eventId`; optional abortSignal.
|
|
1171
|
+
* @returns The merchant usage event response.
|
|
1172
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1173
|
+
*/
|
|
589
1174
|
get(input: {
|
|
590
1175
|
eventId: string;
|
|
591
1176
|
} & ResourceRequestOptions): Promise<MerchantUsageEventResponse>;
|
|
1177
|
+
/**
|
|
1178
|
+
* Lists one page of merchant usage event records.
|
|
1179
|
+
* @param input - filters and pagination options.
|
|
1180
|
+
* @returns The merchant usage events response.
|
|
1181
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1182
|
+
*/
|
|
592
1183
|
list(input?: MerchantUsageEventsListOptions): Promise<MerchantUsageEventsResponse>;
|
|
1184
|
+
/**
|
|
1185
|
+
* Releases the merchant usage event.
|
|
1186
|
+
* @param input - `eventId`; optional abortSignal.
|
|
1187
|
+
* @returns The merchant usage event response.
|
|
1188
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1189
|
+
*/
|
|
593
1190
|
release(input: {
|
|
594
1191
|
eventId: string;
|
|
595
1192
|
} & ResourceRequestOptions): Promise<MerchantUsageEventResponse>;
|
|
1193
|
+
/**
|
|
1194
|
+
* Retries delivery of the merchant usage event.
|
|
1195
|
+
* @param input - `eventId`; optional abortSignal.
|
|
1196
|
+
* @returns The merchant usage event response.
|
|
1197
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1198
|
+
*/
|
|
596
1199
|
retry(input: {
|
|
597
1200
|
eventId: string;
|
|
598
1201
|
} & ResourceRequestOptions): Promise<MerchantUsageEventResponse>;
|
|
1202
|
+
/**
|
|
1203
|
+
* Retrieves merchant usage delivery totals for the selected day range.
|
|
1204
|
+
* @param input - Lookback window in `days` and optional abortSignal.
|
|
1205
|
+
* @returns The merchant usage summary response.
|
|
1206
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1207
|
+
*/
|
|
599
1208
|
summary(input?: {
|
|
600
1209
|
days?: number;
|
|
601
1210
|
} & ResourceRequestOptions): Promise<MerchantUsageSummaryResponse>;
|
|
602
1211
|
}
|
|
603
1212
|
export interface ChatConnectionsResource {
|
|
1213
|
+
/**
|
|
1214
|
+
* Checks the Chat Connection health.
|
|
1215
|
+
* @param input - `chatConnectionId`; optional abortSignal.
|
|
1216
|
+
* @returns The chat connection.
|
|
1217
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1218
|
+
*/
|
|
604
1219
|
checkHealth(input: {
|
|
605
1220
|
chatConnectionId: string;
|
|
606
1221
|
} & ResourceRequestOptions): Promise<ChatConnection>;
|
|
1222
|
+
/**
|
|
1223
|
+
* Creates the Chat Connection.
|
|
1224
|
+
* @param input - creation fields; optional abortSignal.
|
|
1225
|
+
* @returns The chat connection.
|
|
1226
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1227
|
+
*/
|
|
607
1228
|
create(input: CreateChatConnectionBody & ResourceRequestOptions): Promise<ChatConnection>;
|
|
1229
|
+
/**
|
|
1230
|
+
* Deletes the Chat Connection.
|
|
1231
|
+
* @param input - `chatConnectionId`; optional abortSignal.
|
|
1232
|
+
* @returns Resolves when the operation completes.
|
|
1233
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1234
|
+
*/
|
|
608
1235
|
delete(input: {
|
|
609
1236
|
chatConnectionId: string;
|
|
610
1237
|
} & ResourceRequestOptions): Promise<void>;
|
|
1238
|
+
/**
|
|
1239
|
+
* Disables the Chat Connection.
|
|
1240
|
+
* @param input - `chatConnectionId`; optional abortSignal.
|
|
1241
|
+
* @returns The chat connection.
|
|
1242
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1243
|
+
*/
|
|
611
1244
|
disable(input: {
|
|
612
1245
|
chatConnectionId: string;
|
|
613
1246
|
} & ResourceRequestOptions): Promise<ChatConnection>;
|
|
1247
|
+
/**
|
|
1248
|
+
* Enables the Chat Connection.
|
|
1249
|
+
* @param input - `chatConnectionId`; optional abortSignal.
|
|
1250
|
+
* @returns The chat connection.
|
|
1251
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1252
|
+
*/
|
|
614
1253
|
enable(input: {
|
|
615
1254
|
chatConnectionId: string;
|
|
616
1255
|
} & ResourceRequestOptions): Promise<ChatConnection>;
|
|
1256
|
+
/**
|
|
1257
|
+
* Retrieves the Chat Connection.
|
|
1258
|
+
* @param input - `chatConnectionId`; optional abortSignal.
|
|
1259
|
+
* @returns The chat connection.
|
|
1260
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1261
|
+
*/
|
|
617
1262
|
get(input: {
|
|
618
1263
|
chatConnectionId: string;
|
|
619
1264
|
} & ResourceRequestOptions): Promise<ChatConnection>;
|
|
1265
|
+
/**
|
|
1266
|
+
* Lists available Chat Connection records.
|
|
1267
|
+
* @param input - optional abortSignal.
|
|
1268
|
+
* @returns The chat connections response.
|
|
1269
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1270
|
+
*/
|
|
620
1271
|
list(input?: ResourceRequestOptions): Promise<ChatConnectionsResponse>;
|
|
1272
|
+
/**
|
|
1273
|
+
* Replaces the Chat Connection credentials.
|
|
1274
|
+
* @param input - `chatConnectionId`; fields to change; optional abortSignal.
|
|
1275
|
+
* @returns The chat connection.
|
|
1276
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1277
|
+
*/
|
|
621
1278
|
rotateCredentials(input: RotateChatConnectionBody & {
|
|
622
1279
|
chatConnectionId: string;
|
|
623
1280
|
} & ResourceRequestOptions): Promise<ChatConnection>;
|
|
1281
|
+
/**
|
|
1282
|
+
* Updates the Chat Connection.
|
|
1283
|
+
* @param input - `chatConnectionId`; fields to change; optional abortSignal.
|
|
1284
|
+
* @returns The chat connection.
|
|
1285
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1286
|
+
*/
|
|
624
1287
|
update(input: UpdateChatConnectionBody & {
|
|
625
1288
|
chatConnectionId: string;
|
|
626
1289
|
} & ResourceRequestOptions): Promise<ChatConnection>;
|
|
@@ -638,6 +1301,12 @@ export interface ChatDeliveriesListOptions extends ResourceRequestOptions {
|
|
|
638
1301
|
* Connections behind `GET /v1/chat-deliveries`, newest first.
|
|
639
1302
|
*/
|
|
640
1303
|
export interface ChatDeliveriesResource {
|
|
1304
|
+
/**
|
|
1305
|
+
* Lists one page of Chat delivery records.
|
|
1306
|
+
* @param input - filters and pagination options.
|
|
1307
|
+
* @returns The chat deliveries response.
|
|
1308
|
+
* @throws BlazingAgentsError - If the request fails, is aborted, or returns an invalid response.
|
|
1309
|
+
*/
|
|
641
1310
|
list(input?: ChatDeliveriesListOptions): Promise<ChatDeliveriesResponse>;
|
|
642
1311
|
}
|
|
643
1312
|
export {};
|