@arcadeai/arcadejs 1.0.0-rc.1 → 1.0.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/CHANGELOG.md +5 -2
- package/README.md +1 -1
- package/index.d.mts +5 -5
- package/index.d.ts +5 -5
- package/index.d.ts.map +1 -1
- package/index.js +3 -3
- package/index.js.map +1 -1
- package/index.mjs +4 -4
- package/index.mjs.map +1 -1
- package/package.json +2 -2
- package/resources/auth.d.ts +4 -4
- package/resources/auth.d.ts.map +1 -1
- package/resources/auth.js.map +1 -1
- package/resources/auth.mjs.map +1 -1
- package/resources/chat/chat.d.ts +1 -1
- package/resources/chat/chat.d.ts.map +1 -1
- package/resources/index.d.ts +1 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +2 -2
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/shared.d.ts +3 -3
- package/resources/shared.d.ts.map +1 -1
- package/resources/tools/index.d.ts +1 -1
- package/resources/tools/index.d.ts.map +1 -1
- package/resources/tools/index.js +2 -2
- package/resources/tools/index.js.map +1 -1
- package/resources/tools/index.mjs +1 -1
- package/resources/tools/index.mjs.map +1 -1
- package/resources/tools/tools.d.ts +50 -99
- package/resources/tools/tools.d.ts.map +1 -1
- package/resources/tools/tools.js +5 -5
- package/resources/tools/tools.js.map +1 -1
- package/resources/tools/tools.mjs +3 -3
- package/resources/tools/tools.mjs.map +1 -1
- package/src/index.ts +9 -11
- package/src/resources/auth.ts +7 -7
- package/src/resources/chat/chat.ts +1 -1
- package/src/resources/index.ts +2 -3
- package/src/resources/shared.ts +3 -3
- package/src/resources/tools/index.ts +2 -3
- package/src/resources/tools/tools.ts +60 -135
- package/src/version.ts +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
|
@@ -29,16 +29,16 @@ export class Tools extends APIResource {
|
|
|
29
29
|
list(
|
|
30
30
|
query?: ToolListParams,
|
|
31
31
|
options?: Core.RequestOptions,
|
|
32
|
-
): Core.PagePromise<
|
|
33
|
-
list(options?: Core.RequestOptions): Core.PagePromise<
|
|
32
|
+
): Core.PagePromise<ToolDefinitionsOffsetPage, ToolDefinition>;
|
|
33
|
+
list(options?: Core.RequestOptions): Core.PagePromise<ToolDefinitionsOffsetPage, ToolDefinition>;
|
|
34
34
|
list(
|
|
35
35
|
query: ToolListParams | Core.RequestOptions = {},
|
|
36
36
|
options?: Core.RequestOptions,
|
|
37
|
-
): Core.PagePromise<
|
|
37
|
+
): Core.PagePromise<ToolDefinitionsOffsetPage, ToolDefinition> {
|
|
38
38
|
if (isRequestOptions(query)) {
|
|
39
39
|
return this.list({}, query);
|
|
40
40
|
}
|
|
41
|
-
return this._client.getAPIList('/v1/tools',
|
|
41
|
+
return this._client.getAPIList('/v1/tools', ToolDefinitionsOffsetPage, { query, ...options });
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
/**
|
|
@@ -47,7 +47,7 @@ export class Tools extends APIResource {
|
|
|
47
47
|
authorize(
|
|
48
48
|
body: ToolAuthorizeParams,
|
|
49
49
|
options?: Core.RequestOptions,
|
|
50
|
-
): Core.APIPromise<Shared.
|
|
50
|
+
): Core.APIPromise<Shared.AuthorizationResponse> {
|
|
51
51
|
return this._client.post('/v1/tools/authorize', { body, ...options });
|
|
52
52
|
}
|
|
53
53
|
|
|
@@ -61,12 +61,12 @@ export class Tools extends APIResource {
|
|
|
61
61
|
/**
|
|
62
62
|
* Returns the arcade tool specification for a specific tool
|
|
63
63
|
*/
|
|
64
|
-
get(name: string, options?: Core.RequestOptions): Core.APIPromise<
|
|
64
|
+
get(name: string, options?: Core.RequestOptions): Core.APIPromise<ToolDefinition> {
|
|
65
65
|
return this._client.get(`/v1/tools/${name}`, options);
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
68
|
|
|
69
|
-
export class
|
|
69
|
+
export class ToolDefinitionsOffsetPage extends OffsetPage<ToolDefinition> {}
|
|
70
70
|
|
|
71
71
|
export class ToolExecutionsOffsetPage extends OffsetPage<ToolExecution> {}
|
|
72
72
|
|
|
@@ -133,7 +133,7 @@ export interface ExecuteToolResponse {
|
|
|
133
133
|
|
|
134
134
|
export namespace ExecuteToolResponse {
|
|
135
135
|
export interface Output {
|
|
136
|
-
authorization?: Shared.
|
|
136
|
+
authorization?: Shared.AuthorizationResponse;
|
|
137
137
|
|
|
138
138
|
error?: Output.Error;
|
|
139
139
|
|
|
@@ -155,95 +155,23 @@ export namespace ExecuteToolResponse {
|
|
|
155
155
|
}
|
|
156
156
|
}
|
|
157
157
|
|
|
158
|
-
export interface
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
created_at?: string;
|
|
162
|
-
|
|
163
|
-
execution_status?: string;
|
|
164
|
-
|
|
165
|
-
execution_type?: string;
|
|
166
|
-
|
|
167
|
-
finished_at?: string;
|
|
168
|
-
|
|
169
|
-
run_at?: string;
|
|
170
|
-
|
|
171
|
-
started_at?: string;
|
|
172
|
-
|
|
173
|
-
tool_name?: string;
|
|
174
|
-
|
|
175
|
-
toolkit_name?: string;
|
|
176
|
-
|
|
177
|
-
toolkit_version?: string;
|
|
178
|
-
|
|
179
|
-
updated_at?: string;
|
|
180
|
-
|
|
181
|
-
user_id?: string;
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
export interface ToolExecutionAttempt {
|
|
185
|
-
id?: string;
|
|
186
|
-
|
|
187
|
-
finished_at?: string;
|
|
188
|
-
|
|
189
|
-
output?: ToolExecutionAttempt.Output;
|
|
190
|
-
|
|
191
|
-
started_at?: string;
|
|
192
|
-
|
|
193
|
-
success?: boolean;
|
|
194
|
-
|
|
195
|
-
system_error_message?: string;
|
|
196
|
-
}
|
|
197
|
-
|
|
198
|
-
export namespace ToolExecutionAttempt {
|
|
199
|
-
export interface Output {
|
|
200
|
-
authorization?: Shared.AuthAuthorizationResponse;
|
|
201
|
-
|
|
202
|
-
error?: Output.Error;
|
|
203
|
-
|
|
204
|
-
value?: unknown;
|
|
205
|
-
}
|
|
206
|
-
|
|
207
|
-
export namespace Output {
|
|
208
|
-
export interface Error {
|
|
209
|
-
message: string;
|
|
210
|
-
|
|
211
|
-
additional_prompt_content?: string;
|
|
212
|
-
|
|
213
|
-
can_retry?: boolean;
|
|
214
|
-
|
|
215
|
-
developer_message?: string;
|
|
216
|
-
|
|
217
|
-
retry_after_ms?: number;
|
|
218
|
-
}
|
|
219
|
-
}
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
export interface ValueSchema {
|
|
223
|
-
val_type: string;
|
|
224
|
-
|
|
225
|
-
enum?: Array<string>;
|
|
226
|
-
|
|
227
|
-
inner_val_type?: string;
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
export interface ToolListResponse {
|
|
231
|
-
input: ToolListResponse.Input;
|
|
158
|
+
export interface ToolDefinition {
|
|
159
|
+
input: ToolDefinition.Input;
|
|
232
160
|
|
|
233
161
|
name: string;
|
|
234
162
|
|
|
235
|
-
toolkit:
|
|
163
|
+
toolkit: ToolDefinition.Toolkit;
|
|
236
164
|
|
|
237
165
|
description?: string;
|
|
238
166
|
|
|
239
167
|
fully_qualified_name?: string;
|
|
240
168
|
|
|
241
|
-
output?:
|
|
169
|
+
output?: ToolDefinition.Output;
|
|
242
170
|
|
|
243
|
-
requirements?:
|
|
171
|
+
requirements?: ToolDefinition.Requirements;
|
|
244
172
|
}
|
|
245
173
|
|
|
246
|
-
export namespace
|
|
174
|
+
export namespace ToolDefinition {
|
|
247
175
|
export interface Input {
|
|
248
176
|
parameters?: Array<Input.Parameter>;
|
|
249
177
|
}
|
|
@@ -301,80 +229,78 @@ export namespace ToolListResponse {
|
|
|
301
229
|
}
|
|
302
230
|
}
|
|
303
231
|
|
|
304
|
-
export interface
|
|
305
|
-
|
|
232
|
+
export interface ToolExecution {
|
|
233
|
+
id?: string;
|
|
306
234
|
|
|
307
|
-
|
|
235
|
+
created_at?: string;
|
|
236
|
+
|
|
237
|
+
execution_status?: string;
|
|
308
238
|
|
|
309
|
-
|
|
239
|
+
execution_type?: string;
|
|
310
240
|
|
|
311
|
-
|
|
241
|
+
finished_at?: string;
|
|
312
242
|
|
|
313
|
-
|
|
243
|
+
run_at?: string;
|
|
314
244
|
|
|
315
|
-
|
|
245
|
+
started_at?: string;
|
|
316
246
|
|
|
317
|
-
|
|
318
|
-
}
|
|
247
|
+
tool_name?: string;
|
|
319
248
|
|
|
320
|
-
|
|
321
|
-
export interface Input {
|
|
322
|
-
parameters?: Array<Input.Parameter>;
|
|
323
|
-
}
|
|
249
|
+
toolkit_name?: string;
|
|
324
250
|
|
|
325
|
-
|
|
326
|
-
export interface Parameter {
|
|
327
|
-
name: string;
|
|
251
|
+
toolkit_version?: string;
|
|
328
252
|
|
|
329
|
-
|
|
253
|
+
updated_at?: string;
|
|
330
254
|
|
|
331
|
-
|
|
255
|
+
user_id?: string;
|
|
256
|
+
}
|
|
332
257
|
|
|
333
|
-
|
|
258
|
+
export interface ToolExecutionAttempt {
|
|
259
|
+
id?: string;
|
|
334
260
|
|
|
335
|
-
|
|
336
|
-
}
|
|
337
|
-
}
|
|
261
|
+
finished_at?: string;
|
|
338
262
|
|
|
339
|
-
|
|
340
|
-
name: string;
|
|
263
|
+
output?: ToolExecutionAttempt.Output;
|
|
341
264
|
|
|
342
|
-
|
|
265
|
+
started_at?: string;
|
|
343
266
|
|
|
344
|
-
|
|
345
|
-
}
|
|
267
|
+
success?: boolean;
|
|
346
268
|
|
|
347
|
-
|
|
348
|
-
|
|
269
|
+
system_error_message?: string;
|
|
270
|
+
}
|
|
349
271
|
|
|
350
|
-
|
|
272
|
+
export namespace ToolExecutionAttempt {
|
|
273
|
+
export interface Output {
|
|
274
|
+
authorization?: Shared.AuthorizationResponse;
|
|
351
275
|
|
|
352
|
-
|
|
353
|
-
}
|
|
276
|
+
error?: Output.Error;
|
|
354
277
|
|
|
355
|
-
|
|
356
|
-
authorization?: Requirements.Authorization;
|
|
278
|
+
value?: unknown;
|
|
357
279
|
}
|
|
358
280
|
|
|
359
|
-
export namespace
|
|
360
|
-
export interface
|
|
361
|
-
|
|
281
|
+
export namespace Output {
|
|
282
|
+
export interface Error {
|
|
283
|
+
message: string;
|
|
362
284
|
|
|
363
|
-
|
|
285
|
+
additional_prompt_content?: string;
|
|
364
286
|
|
|
365
|
-
|
|
287
|
+
can_retry?: boolean;
|
|
366
288
|
|
|
367
|
-
|
|
368
|
-
}
|
|
289
|
+
developer_message?: string;
|
|
369
290
|
|
|
370
|
-
|
|
371
|
-
export interface Oauth2 {
|
|
372
|
-
scopes?: Array<string>;
|
|
373
|
-
}
|
|
291
|
+
retry_after_ms?: number;
|
|
374
292
|
}
|
|
375
293
|
}
|
|
376
294
|
}
|
|
377
295
|
|
|
296
|
+
export interface ValueSchema {
|
|
297
|
+
val_type: string;
|
|
298
|
+
|
|
299
|
+
enum?: Array<string>;
|
|
300
|
+
|
|
301
|
+
inner_val_type?: string;
|
|
302
|
+
}
|
|
303
|
+
|
|
378
304
|
export interface ToolListParams extends OffsetPageParams {
|
|
379
305
|
/**
|
|
380
306
|
* Toolkit name
|
|
@@ -418,7 +344,7 @@ export interface ToolExecuteParams {
|
|
|
418
344
|
user_id?: string;
|
|
419
345
|
}
|
|
420
346
|
|
|
421
|
-
Tools.
|
|
347
|
+
Tools.ToolDefinitionsOffsetPage = ToolDefinitionsOffsetPage;
|
|
422
348
|
Tools.Scheduled = Scheduled;
|
|
423
349
|
Tools.Formatted = Formatted;
|
|
424
350
|
Tools.FormattedListResponsesOffsetPage = FormattedListResponsesOffsetPage;
|
|
@@ -428,12 +354,11 @@ export declare namespace Tools {
|
|
|
428
354
|
type AuthorizeToolRequest as AuthorizeToolRequest,
|
|
429
355
|
type ExecuteToolRequest as ExecuteToolRequest,
|
|
430
356
|
type ExecuteToolResponse as ExecuteToolResponse,
|
|
357
|
+
type ToolDefinition as ToolDefinition,
|
|
431
358
|
type ToolExecution as ToolExecution,
|
|
432
359
|
type ToolExecutionAttempt as ToolExecutionAttempt,
|
|
433
360
|
type ValueSchema as ValueSchema,
|
|
434
|
-
|
|
435
|
-
type ToolGetResponse as ToolGetResponse,
|
|
436
|
-
ToolListResponsesOffsetPage as ToolListResponsesOffsetPage,
|
|
361
|
+
ToolDefinitionsOffsetPage as ToolDefinitionsOffsetPage,
|
|
437
362
|
type ToolListParams as ToolListParams,
|
|
438
363
|
type ToolAuthorizeParams as ToolAuthorizeParams,
|
|
439
364
|
type ToolExecuteParams as ToolExecuteParams,
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '1.0.0
|
|
1
|
+
export const VERSION = '1.0.0'; // x-release-please-version
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "1.0.0
|
|
1
|
+
export declare const VERSION = "1.0.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.d.ts","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,
|
|
1
|
+
{"version":3,"file":"version.d.ts","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,UAAU,CAAC"}
|
package/version.js
CHANGED
package/version.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.js","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG,
|
|
1
|
+
{"version":3,"file":"version.js","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG,OAAO,CAAC,CAAC,2BAA2B"}
|
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '1.0.0
|
|
1
|
+
export const VERSION = '1.0.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|
package/version.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.mjs","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,OAAO,GAAG,
|
|
1
|
+
{"version":3,"file":"version.mjs","sourceRoot":"","sources":["src/version.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,OAAO,GAAG,OAAO,CAAC,CAAC,2BAA2B"}
|