@blazingagents/sdk 0.2.2 → 0.4.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/README.md +38 -5
- package/dist/client.d.ts +3 -1
- package/dist/client.js +1 -1
- package/dist/contracts/entities/sessions.d.ts +32 -0
- package/dist/contracts/entities/sessions.js +10 -1
- package/dist/contracts/index.d.ts +1 -1
- package/dist/contracts/index.js +1 -1
- package/dist/direct-chat-transport.js +1 -1
- package/dist/generation.js +3 -3
- package/dist/index.d.ts +1 -1
- package/dist/relay.js +2 -2
- package/dist/resources/agents.js +33 -23
- package/dist/resources/artifacts.js +8 -7
- package/dist/resources/mcp-connections.js +19 -15
- package/dist/resources/memories.js +10 -10
- package/dist/resources/prompts.js +10 -7
- package/dist/resources/providers.js +16 -13
- package/dist/resources/sessions.js +24 -13
- package/dist/resources/skills.js +21 -17
- package/dist/resources/tasks.js +19 -16
- package/dist/resources/tenant.js +4 -3
- package/dist/resources/usage.js +4 -4
- package/dist/resources/workspaces.js +10 -9
- package/dist/types.d.ts +232 -106
- package/package.json +1 -1
package/dist/types.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ import type { CreateMcpConnectionBody, McpAttachmentResponse, McpAttachmentsResp
|
|
|
7
7
|
import type { CreateMemoryBody, MemoriesListResponse, MemoryResponse, UpdateMemoryBody } from "./contracts/entities/memories.ts";
|
|
8
8
|
import type { CreatePromptBody, PromptResponse, PromptsResponse, UpdatePromptBody } from "./contracts/entities/prompts.ts";
|
|
9
9
|
import type { CreateProviderBody, DeleteProviderOptions, ProviderModelsResponse, ProviderResponse, ProvidersResponse, ThinkingLevelsResponse, UpdateProviderBody } from "./contracts/entities/providers.ts";
|
|
10
|
-
import type { DecideToolApprovalBody, SessionMessagesResponse, SessionsListResponse, ToolApprovalDecisionResponse, ToolApprovalsResponse } from "./contracts/entities/sessions.ts";
|
|
10
|
+
import type { DecideToolApprovalBody, LatestSessionsListResponse, SessionMessagesResponse, SessionsListResponse, ToolApprovalDecisionResponse, ToolApprovalsResponse } from "./contracts/entities/sessions.ts";
|
|
11
11
|
import type { CreateSkillBody, SkillArchiveType, SkillCopyResults, SkillDetail, SkillsListResponse } from "./contracts/entities/skills.ts";
|
|
12
12
|
import type { CreateTaskBody, CreateTaskResponse, CreateTaskRunBody, CreateTaskRunResponse, TaskResponse, TaskRunMessagesResponse, TaskRunResponse, TaskRunsListResponse, TasksListResponse, UpdateTaskBody } from "./contracts/entities/tasks.ts";
|
|
13
13
|
import type { TenantSettingsResponse, UpdateTenantSettingsBody } from "./contracts/entities/tenants.ts";
|
|
@@ -99,19 +99,19 @@ interface ExistingSessionInput {
|
|
|
99
99
|
}
|
|
100
100
|
type ChatSessionInput = NewSessionInput | ExistingSessionInput;
|
|
101
101
|
interface ChatMessageContentInput extends AttributionInput, CorrelatedRequestInput {
|
|
102
|
+
abortSignal?: AbortSignal;
|
|
102
103
|
agentId: string;
|
|
103
104
|
message: UIMessage;
|
|
104
105
|
messageId?: string;
|
|
105
106
|
promptId?: never;
|
|
106
|
-
signal?: AbortSignal;
|
|
107
107
|
variables?: never;
|
|
108
108
|
}
|
|
109
109
|
interface ChatPromptContentInput extends AttributionInput, CorrelatedRequestInput {
|
|
110
|
+
abortSignal?: AbortSignal;
|
|
110
111
|
agentId: string;
|
|
111
112
|
message?: never;
|
|
112
113
|
messageId?: string;
|
|
113
114
|
promptId: string;
|
|
114
|
-
signal?: AbortSignal;
|
|
115
115
|
variables?: Record<string, string>;
|
|
116
116
|
}
|
|
117
117
|
export type ChatMessageInput = ChatMessageContentInput & ChatSessionInput;
|
|
@@ -140,19 +140,19 @@ interface StatelessGenerationInput extends AttributionInput, CorrelatedRequestIn
|
|
|
140
140
|
version?: number;
|
|
141
141
|
}
|
|
142
142
|
export interface CompletionPromptInput extends StatelessGenerationInput {
|
|
143
|
+
abortSignal?: AbortSignal;
|
|
143
144
|
agentId: string;
|
|
144
145
|
prompt: string;
|
|
145
146
|
promptId?: never;
|
|
146
147
|
schema?: never;
|
|
147
|
-
signal?: AbortSignal;
|
|
148
148
|
variables?: never;
|
|
149
149
|
}
|
|
150
150
|
export interface CompletionPromptIdInput extends StatelessGenerationInput {
|
|
151
|
+
abortSignal?: AbortSignal;
|
|
151
152
|
agentId: string;
|
|
152
153
|
prompt?: never;
|
|
153
154
|
promptId: string;
|
|
154
155
|
schema?: never;
|
|
155
|
-
signal?: AbortSignal;
|
|
156
156
|
variables?: Record<string, string>;
|
|
157
157
|
}
|
|
158
158
|
export type CompletionInput = CompletionPromptInput | CompletionPromptIdInput;
|
|
@@ -163,19 +163,19 @@ export interface CompletionResult {
|
|
|
163
163
|
toResponse: () => Response;
|
|
164
164
|
}
|
|
165
165
|
export interface ObjectPromptInput extends StatelessGenerationInput {
|
|
166
|
+
abortSignal?: AbortSignal;
|
|
166
167
|
agentId: string;
|
|
167
168
|
prompt: string;
|
|
168
169
|
promptId?: never;
|
|
169
170
|
schema: Record<string, unknown>;
|
|
170
|
-
signal?: AbortSignal;
|
|
171
171
|
variables?: never;
|
|
172
172
|
}
|
|
173
173
|
export interface ObjectPromptIdInput extends StatelessGenerationInput {
|
|
174
|
+
abortSignal?: AbortSignal;
|
|
174
175
|
agentId: string;
|
|
175
176
|
prompt?: never;
|
|
176
177
|
promptId: string;
|
|
177
178
|
schema: Record<string, unknown>;
|
|
178
|
-
signal?: AbortSignal;
|
|
179
179
|
variables?: Record<string, string>;
|
|
180
180
|
}
|
|
181
181
|
export type ObjectInput = ObjectPromptInput | ObjectPromptIdInput;
|
|
@@ -185,130 +185,235 @@ export interface ObjectResult {
|
|
|
185
185
|
requestId?: string;
|
|
186
186
|
toResponse: () => Response;
|
|
187
187
|
}
|
|
188
|
-
export
|
|
188
|
+
export interface ResourceRequestOptions {
|
|
189
|
+
abortSignal?: AbortSignal;
|
|
190
|
+
}
|
|
189
191
|
export interface AgentsResource {
|
|
190
192
|
/** Omitting `workspaceId` attaches a default Workspace with a lazy runtime. */
|
|
191
|
-
create(
|
|
193
|
+
create(input: CreateAgentBody & ResourceRequestOptions): Promise<Agent>;
|
|
192
194
|
/** Deletes the Agent while preserving its attached Workspace. */
|
|
193
|
-
delete(
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
195
|
+
delete(input: {
|
|
196
|
+
agentId: string;
|
|
197
|
+
includeArtifacts: boolean;
|
|
198
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
199
|
+
disable(input: {
|
|
200
|
+
agentId: string;
|
|
201
|
+
} & ResourceRequestOptions): Promise<Agent>;
|
|
202
|
+
enable(input: {
|
|
203
|
+
agentId: string;
|
|
204
|
+
} & ResourceRequestOptions): Promise<Agent>;
|
|
205
|
+
get(input: {
|
|
206
|
+
agentId: string;
|
|
207
|
+
} & ResourceRequestOptions): Promise<Agent>;
|
|
208
|
+
getVersion(input: {
|
|
209
|
+
agentId: string;
|
|
210
|
+
version: number;
|
|
211
|
+
} & ResourceRequestOptions): Promise<AgentVersion>;
|
|
212
|
+
list(input?: AgentsListOptions): Promise<AgentsResponse>;
|
|
213
|
+
listMcpAttachments(input: {
|
|
214
|
+
agentId: string;
|
|
215
|
+
} & ResourceRequestOptions): Promise<McpAttachmentsResponse>;
|
|
216
|
+
listVersions(input: {
|
|
217
|
+
agentId: string;
|
|
218
|
+
} & AgentVersionsListOptions): Promise<AgentVersionsResponse>;
|
|
219
|
+
removeAvatar(input: {
|
|
220
|
+
agentId: string;
|
|
221
|
+
} & ResourceRequestOptions): Promise<Agent>;
|
|
222
|
+
/** Copies an immutable Version into the Agent, creating a new latest Version. */
|
|
223
|
+
restoreVersion(input: {
|
|
224
|
+
agentId: string;
|
|
225
|
+
version: number;
|
|
226
|
+
} & ResourceRequestOptions): Promise<Agent>;
|
|
207
227
|
/** A concrete `workspaceId` switches the Agent; detachment is unsupported. */
|
|
208
|
-
update(
|
|
209
|
-
|
|
210
|
-
|
|
228
|
+
update(input: UpdateAgentBody & {
|
|
229
|
+
agentId: string;
|
|
230
|
+
} & ResourceRequestOptions): Promise<Agent>;
|
|
231
|
+
updateMcpAttachment(input: UpdateMcpAttachmentBody & {
|
|
232
|
+
agentId: string;
|
|
233
|
+
mcpConnectionId: string;
|
|
234
|
+
} & ResourceRequestOptions): Promise<McpAttachmentResponse>;
|
|
235
|
+
uploadAvatar(input: {
|
|
236
|
+
agentId: string;
|
|
237
|
+
file: File;
|
|
238
|
+
} & ResourceRequestOptions): Promise<Agent>;
|
|
211
239
|
}
|
|
212
240
|
export interface AgentClient {
|
|
213
241
|
readonly skills: AgentSkillsResource;
|
|
214
242
|
}
|
|
215
|
-
export interface AgentsListOptions extends
|
|
243
|
+
export interface AgentsListOptions extends ResourceRequestOptions {
|
|
216
244
|
userId?: string;
|
|
217
245
|
workspaceId?: string;
|
|
218
246
|
}
|
|
219
247
|
export interface WorkspacesResource {
|
|
220
|
-
create(
|
|
248
|
+
create(input?: CreateWorkspaceBody & ResourceRequestOptions): Promise<Workspace>;
|
|
221
249
|
delete(input: {
|
|
222
250
|
workspaceId: string;
|
|
223
|
-
}): Promise<"completed" | "pending">;
|
|
251
|
+
} & ResourceRequestOptions): Promise<"completed" | "pending">;
|
|
224
252
|
get(input: {
|
|
225
253
|
workspaceId: string;
|
|
226
|
-
}
|
|
227
|
-
list(
|
|
254
|
+
} & ResourceRequestOptions): Promise<Workspace>;
|
|
255
|
+
list(input?: WorkspacesListOptions): Promise<WorkspacesListResponse>;
|
|
228
256
|
update(input: UpdateWorkspaceBody & {
|
|
229
257
|
workspaceId: string;
|
|
230
|
-
}): Promise<Workspace>;
|
|
258
|
+
} & ResourceRequestOptions): Promise<Workspace>;
|
|
231
259
|
}
|
|
232
|
-
export interface WorkspacesListOptions extends
|
|
260
|
+
export interface WorkspacesListOptions extends ResourceRequestOptions {
|
|
233
261
|
cursor?: string;
|
|
234
262
|
limit?: number;
|
|
235
263
|
userId?: string;
|
|
236
264
|
}
|
|
237
|
-
export interface AgentVersionsListOptions extends
|
|
265
|
+
export interface AgentVersionsListOptions extends ResourceRequestOptions {
|
|
238
266
|
cursor?: string;
|
|
239
267
|
limit?: number;
|
|
240
268
|
}
|
|
241
|
-
export interface ArtifactsListOptions extends
|
|
269
|
+
export interface ArtifactsListOptions extends ResourceRequestOptions {
|
|
242
270
|
agentId?: string;
|
|
243
271
|
cursor?: string;
|
|
244
272
|
sessionId?: string;
|
|
245
273
|
}
|
|
246
274
|
export interface ArtifactsResource {
|
|
247
|
-
createDownloadUrl(
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
275
|
+
createDownloadUrl(input: {
|
|
276
|
+
artifactId: string;
|
|
277
|
+
} & ResourceRequestOptions): Promise<ArtifactDownloadUrlResponse>;
|
|
278
|
+
delete(input: {
|
|
279
|
+
artifactId: string;
|
|
280
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
281
|
+
get(input: {
|
|
282
|
+
artifactId: string;
|
|
283
|
+
} & ResourceRequestOptions): Promise<ArtifactListItem>;
|
|
284
|
+
list(input?: ArtifactsListOptions): Promise<ArtifactsListResponse>;
|
|
251
285
|
}
|
|
252
286
|
export interface MemoriesResource {
|
|
253
|
-
create(
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
287
|
+
create(input: CreateMemoryBody & {
|
|
288
|
+
agentId: string;
|
|
289
|
+
} & ResourceRequestOptions): Promise<MemoryResponse>;
|
|
290
|
+
delete(input: {
|
|
291
|
+
agentId: string;
|
|
292
|
+
memoryId: string;
|
|
293
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
294
|
+
get(input: {
|
|
295
|
+
agentId: string;
|
|
296
|
+
memoryId: string;
|
|
297
|
+
} & ResourceRequestOptions): Promise<MemoryResponse>;
|
|
298
|
+
list(input: {
|
|
299
|
+
agentId: string;
|
|
300
|
+
} & MemoriesListOptions): Promise<MemoriesListResponse>;
|
|
301
|
+
update(input: UpdateMemoryBody & {
|
|
302
|
+
agentId: string;
|
|
303
|
+
memoryId: string;
|
|
304
|
+
} & ResourceRequestOptions): Promise<MemoryResponse>;
|
|
305
|
+
}
|
|
306
|
+
export interface MemoriesListOptions extends ResourceRequestOptions {
|
|
260
307
|
cursor?: string;
|
|
261
308
|
limit?: number;
|
|
262
309
|
search?: string;
|
|
263
310
|
userId?: string;
|
|
264
311
|
}
|
|
265
312
|
export interface PromptsResource {
|
|
266
|
-
create(
|
|
267
|
-
delete(
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
313
|
+
create(input: CreatePromptBody & ResourceRequestOptions): Promise<PromptResponse>;
|
|
314
|
+
delete(input: {
|
|
315
|
+
promptId: string;
|
|
316
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
317
|
+
get(input: {
|
|
318
|
+
promptId: string;
|
|
319
|
+
} & ResourceRequestOptions): Promise<PromptResponse>;
|
|
320
|
+
list(input?: {
|
|
321
|
+
userId?: string;
|
|
322
|
+
} & ResourceRequestOptions): Promise<PromptsResponse>;
|
|
323
|
+
update(input: UpdatePromptBody & {
|
|
324
|
+
promptId: string;
|
|
325
|
+
} & ResourceRequestOptions): Promise<PromptResponse>;
|
|
271
326
|
}
|
|
272
327
|
export interface ProvidersResource {
|
|
273
|
-
create(
|
|
274
|
-
delete(
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
328
|
+
create(input: CreateProviderBody & ResourceRequestOptions): Promise<ProviderResponse>;
|
|
329
|
+
delete(input: DeleteProviderOptions & {
|
|
330
|
+
providerId: string;
|
|
331
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
332
|
+
get(input: {
|
|
333
|
+
providerId: string;
|
|
334
|
+
} & ResourceRequestOptions): Promise<ProviderResponse>;
|
|
335
|
+
getThinkingLevels(input: {
|
|
336
|
+
providerId: string;
|
|
337
|
+
model: string;
|
|
338
|
+
} & ResourceRequestOptions): Promise<ThinkingLevelsResponse>;
|
|
339
|
+
list(input?: ResourceRequestOptions): Promise<ProvidersResponse>;
|
|
340
|
+
listModels(input: {
|
|
341
|
+
providerId: string;
|
|
342
|
+
} & ResourceRequestOptions): Promise<ProviderModelsResponse>;
|
|
343
|
+
update(input: UpdateProviderBody & {
|
|
344
|
+
providerId: string;
|
|
345
|
+
} & ResourceRequestOptions): Promise<ProviderResponse>;
|
|
280
346
|
}
|
|
281
347
|
export interface McpConnectionsResource {
|
|
282
|
-
connect(
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
348
|
+
connect(input: {
|
|
349
|
+
mcpConnectionId: string;
|
|
350
|
+
} & ResourceRequestOptions): Promise<McpConnectionOauthConnectResponse>;
|
|
351
|
+
create(input: CreateMcpConnectionBody & ResourceRequestOptions): Promise<McpConnectionResponse>;
|
|
352
|
+
delete(input: {
|
|
353
|
+
mcpConnectionId: string;
|
|
354
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
355
|
+
get(input: {
|
|
356
|
+
mcpConnectionId: string;
|
|
357
|
+
} & ResourceRequestOptions): Promise<McpConnectionResponse>;
|
|
358
|
+
list(input?: ResourceRequestOptions): Promise<McpConnectionsResponse>;
|
|
359
|
+
reconnect(input: ReconnectMcpConnectionBody & {
|
|
360
|
+
mcpConnectionId: string;
|
|
361
|
+
} & ResourceRequestOptions): Promise<McpConnectionReconnectResult>;
|
|
362
|
+
test(input: {
|
|
363
|
+
mcpConnectionId: string;
|
|
364
|
+
} & ResourceRequestOptions): Promise<McpConnectionTestResponse>;
|
|
365
|
+
update(input: UpdateMcpConnectionBody & {
|
|
366
|
+
mcpConnectionId: string;
|
|
367
|
+
} & ResourceRequestOptions): Promise<McpConnectionResponse>;
|
|
368
|
+
}
|
|
369
|
+
export interface SessionsListOptions extends ResourceRequestOptions {
|
|
292
370
|
cursor?: string;
|
|
293
371
|
limit?: number;
|
|
294
372
|
userId?: string;
|
|
295
373
|
}
|
|
296
|
-
export interface
|
|
374
|
+
export interface LatestSessionsListOptions extends ResourceRequestOptions {
|
|
375
|
+
cursor?: string;
|
|
376
|
+
limit?: number;
|
|
377
|
+
userId?: string;
|
|
378
|
+
}
|
|
379
|
+
export interface SessionMessagesOptions extends ResourceRequestOptions {
|
|
297
380
|
after?: string;
|
|
298
381
|
cursor?: string;
|
|
299
382
|
limit?: number;
|
|
300
383
|
}
|
|
301
384
|
export interface SessionsResource {
|
|
302
|
-
decideToolApproval(
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
385
|
+
decideToolApproval(input: DecideToolApprovalBody & {
|
|
386
|
+
agentId: string;
|
|
387
|
+
sessionId: string;
|
|
388
|
+
approvalId: string;
|
|
389
|
+
} & ResourceRequestOptions): Promise<ToolApprovalDecisionResponse>;
|
|
390
|
+
delete(input: {
|
|
391
|
+
agentId: string;
|
|
392
|
+
sessionId: string;
|
|
393
|
+
deleteArtifacts: boolean;
|
|
394
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
395
|
+
joinToolApprovalContinuation(input: {
|
|
396
|
+
agentId: string;
|
|
397
|
+
sessionId: string;
|
|
398
|
+
continuationId: string;
|
|
399
|
+
} & ResourceRequestOptions): Promise<TerminalStreamResult>;
|
|
400
|
+
list(input: {
|
|
401
|
+
agentId: string;
|
|
402
|
+
} & SessionsListOptions): Promise<SessionsListResponse>;
|
|
403
|
+
/**
|
|
404
|
+
* `GET /v1/sessions/latest` — each Agent's most recently updated Session
|
|
405
|
+
* across the Tenant, one item per Agent, newest first. `userId` narrows
|
|
406
|
+
* the candidate Sessions to one end user's before picking the latest.
|
|
407
|
+
*/
|
|
408
|
+
listLatest(input?: LatestSessionsListOptions): Promise<LatestSessionsListResponse>;
|
|
409
|
+
messages(input: {
|
|
410
|
+
agentId: string;
|
|
411
|
+
sessionId: string;
|
|
412
|
+
} & SessionMessagesOptions): Promise<SessionMessagesResponse>;
|
|
413
|
+
toolApprovals(input: {
|
|
414
|
+
agentId: string;
|
|
415
|
+
sessionId: string;
|
|
416
|
+
} & ResourceRequestOptions): Promise<ToolApprovalsResponse>;
|
|
312
417
|
}
|
|
313
418
|
export interface AgentSkillsResource {
|
|
314
419
|
copy(input: {
|
|
@@ -316,72 +421,93 @@ export interface AgentSkillsResource {
|
|
|
316
421
|
to: {
|
|
317
422
|
agentIds: string[];
|
|
318
423
|
};
|
|
319
|
-
}): Promise<SkillCopyResults>;
|
|
320
|
-
create(input: CreateSkillBody): Promise<SkillDetail>;
|
|
424
|
+
} & ResourceRequestOptions): Promise<SkillCopyResults>;
|
|
425
|
+
create(input: CreateSkillBody & ResourceRequestOptions): Promise<SkillDetail>;
|
|
321
426
|
delete(input: {
|
|
322
427
|
skillId: string;
|
|
323
|
-
}): Promise<void>;
|
|
428
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
324
429
|
deleteFile(input: {
|
|
325
430
|
path: string;
|
|
326
431
|
skillId: string;
|
|
327
|
-
}): Promise<SkillDetail>;
|
|
432
|
+
} & ResourceRequestOptions): Promise<SkillDetail>;
|
|
328
433
|
get(input: {
|
|
329
434
|
skillId: string;
|
|
330
|
-
}
|
|
435
|
+
} & ResourceRequestOptions): Promise<SkillDetail>;
|
|
331
436
|
getFile(input: {
|
|
332
437
|
path: string;
|
|
333
438
|
skillId: string;
|
|
334
|
-
}
|
|
335
|
-
list(
|
|
439
|
+
} & ResourceRequestOptions): Promise<Uint8Array>;
|
|
440
|
+
list(input?: SkillsListOptions): Promise<SkillsListResponse>;
|
|
336
441
|
putFile(input: {
|
|
337
442
|
content: Blob | string | Uint8Array;
|
|
338
443
|
path: string;
|
|
339
444
|
skillId: string;
|
|
340
|
-
}): Promise<SkillDetail>;
|
|
445
|
+
} & ResourceRequestOptions): Promise<SkillDetail>;
|
|
341
446
|
upload(input: {
|
|
342
447
|
source: {
|
|
343
448
|
file: Blob | Uint8Array;
|
|
344
449
|
type: SkillArchiveType;
|
|
345
450
|
};
|
|
346
|
-
}): Promise<SkillDetail>;
|
|
451
|
+
} & ResourceRequestOptions): Promise<SkillDetail>;
|
|
347
452
|
}
|
|
348
|
-
export interface SkillsListOptions extends
|
|
453
|
+
export interface SkillsListOptions extends ResourceRequestOptions {
|
|
349
454
|
cursor?: string;
|
|
350
455
|
limit?: number;
|
|
351
456
|
}
|
|
352
|
-
export interface TasksListOptions extends
|
|
457
|
+
export interface TasksListOptions extends ResourceRequestOptions {
|
|
353
458
|
agentId?: string;
|
|
354
459
|
cursor?: string;
|
|
355
460
|
limit?: number;
|
|
356
461
|
userId?: string;
|
|
357
462
|
}
|
|
358
|
-
export interface TaskRunsListOptions extends
|
|
463
|
+
export interface TaskRunsListOptions extends ResourceRequestOptions {
|
|
359
464
|
cursor?: string;
|
|
360
465
|
limit?: number;
|
|
361
466
|
}
|
|
362
|
-
export interface TaskRunMessagesOptions extends
|
|
467
|
+
export interface TaskRunMessagesOptions extends ResourceRequestOptions {
|
|
363
468
|
after?: string;
|
|
364
469
|
cursor?: string;
|
|
365
470
|
limit?: number;
|
|
366
471
|
}
|
|
367
472
|
export interface TasksResource {
|
|
368
|
-
cancelRun(
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
473
|
+
cancelRun(input: {
|
|
474
|
+
taskId: string;
|
|
475
|
+
runId: string;
|
|
476
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
477
|
+
create(input: CreateTaskBody & ResourceRequestOptions): Promise<CreateTaskResponse>;
|
|
478
|
+
createRun(input: CreateTaskRunBody & {
|
|
479
|
+
taskId: string;
|
|
480
|
+
} & ResourceRequestOptions): Promise<CreateTaskRunResponse>;
|
|
481
|
+
delete(input: {
|
|
482
|
+
taskId: string;
|
|
483
|
+
} & ResourceRequestOptions): Promise<void>;
|
|
484
|
+
get(input: {
|
|
485
|
+
taskId: string;
|
|
486
|
+
} & ResourceRequestOptions): Promise<TaskResponse>;
|
|
487
|
+
getRun(input: {
|
|
488
|
+
taskId: string;
|
|
489
|
+
runId: string;
|
|
490
|
+
} & ResourceRequestOptions): Promise<TaskRunResponse>;
|
|
491
|
+
list(input?: TasksListOptions): Promise<TasksListResponse>;
|
|
492
|
+
listRuns(input: {
|
|
493
|
+
taskId: string;
|
|
494
|
+
} & TaskRunsListOptions): Promise<TaskRunsListResponse>;
|
|
495
|
+
runMessages(input: {
|
|
496
|
+
taskId: string;
|
|
497
|
+
runId: string;
|
|
498
|
+
} & TaskRunMessagesOptions): Promise<TaskRunMessagesResponse>;
|
|
499
|
+
update(input: UpdateTaskBody & {
|
|
500
|
+
taskId: string;
|
|
501
|
+
} & ResourceRequestOptions): Promise<TaskResponse>;
|
|
378
502
|
}
|
|
379
503
|
export interface TenantResource {
|
|
380
|
-
get(
|
|
381
|
-
patch(
|
|
504
|
+
get(input?: ResourceRequestOptions): Promise<TenantSettingsResponse>;
|
|
505
|
+
patch(input: UpdateTenantSettingsBody & ResourceRequestOptions): Promise<TenantSettingsResponse>;
|
|
382
506
|
}
|
|
383
507
|
export interface UsageResource {
|
|
384
|
-
get(
|
|
385
|
-
getForAgent(
|
|
508
|
+
get(input?: Partial<UsageQuery> & ResourceRequestOptions): Promise<UsageResponse>;
|
|
509
|
+
getForAgent(input: Partial<UsageQuery> & {
|
|
510
|
+
agentId: string;
|
|
511
|
+
} & ResourceRequestOptions): Promise<UsageResponse>;
|
|
386
512
|
}
|
|
387
513
|
export {};
|