asteroid-odyssey 1.0.7 → 1.0.8

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.
@@ -3,7 +3,7 @@ export { CancelablePromise, CancelError } from './core/CancelablePromise';
3
3
  export { OpenAPI } from './core/OpenAPI';
4
4
  export type { OpenAPIConfig } from './core/OpenAPI';
5
5
  export type { Agent } from './models/Agent';
6
- export type { CreateWorkflowRequest } from './models/CreateWorkflowRequest';
6
+ export { CreateWorkflowRequest } from './models/CreateWorkflowRequest';
7
7
  export type { Execution } from './models/Execution';
8
8
  export type { OptimisationRequest } from './models/OptimisationRequest';
9
9
  export type { Workflow } from './models/Workflow';
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.WorkflowService = exports.OptimiserService = exports.DefaultService = exports.ApiService = exports.AgentService = exports.OpenAPI = exports.CancelError = exports.CancelablePromise = exports.ApiError = void 0;
3
+ exports.WorkflowService = exports.OptimiserService = exports.DefaultService = exports.ApiService = exports.AgentService = exports.CreateWorkflowRequest = exports.OpenAPI = exports.CancelError = exports.CancelablePromise = exports.ApiError = void 0;
4
4
  /* generated using openapi-typescript-codegen -- do not edit */
5
5
  /* istanbul ignore file */
6
6
  /* tslint:disable */
@@ -12,6 +12,8 @@ Object.defineProperty(exports, "CancelablePromise", { enumerable: true, get: fun
12
12
  Object.defineProperty(exports, "CancelError", { enumerable: true, get: function () { return CancelablePromise_1.CancelError; } });
13
13
  var OpenAPI_1 = require("./core/OpenAPI");
14
14
  Object.defineProperty(exports, "OpenAPI", { enumerable: true, get: function () { return OpenAPI_1.OpenAPI; } });
15
+ var CreateWorkflowRequest_1 = require("./models/CreateWorkflowRequest");
16
+ Object.defineProperty(exports, "CreateWorkflowRequest", { enumerable: true, get: function () { return CreateWorkflowRequest_1.CreateWorkflowRequest; } });
15
17
  var AgentService_1 = require("./services/AgentService");
16
18
  Object.defineProperty(exports, "AgentService", { enumerable: true, get: function () { return AgentService_1.AgentService; } });
17
19
  var ApiService_1 = require("./services/ApiService");
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.OpenAPI = void 0;
4
4
  exports.OpenAPI = {
5
- BASE: 'https://api.asteroid.ai/api/v1',
5
+ BASE: '/api/v1',
6
6
  VERSION: '1.0.0',
7
7
  WITH_CREDENTIALS: false,
8
8
  CREDENTIALS: 'include',
@@ -20,6 +20,7 @@ export { FailureCategory } from './models/FailureCategory';
20
20
  export { FailureReport } from './models/FailureReport';
21
21
  export type { Feedback } from './models/Feedback';
22
22
  export type { FeedbackRequest } from './models/FeedbackRequest';
23
+ export type { FileURL } from './models/FileURL';
23
24
  export type { HubStats } from './models/HubStats';
24
25
  export { MessageRole } from './models/MessageRole';
25
26
  export { MessageType } from './models/MessageType';
@@ -0,0 +1,4 @@
1
+ export type FileURL = {
2
+ url?: string;
3
+ name?: string;
4
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,6 +1,7 @@
1
1
  import type { AsteroidChat } from '../models/AsteroidChat';
2
2
  import type { AsteroidMessage } from '../models/AsteroidMessage';
3
3
  import type { ChatIds } from '../models/ChatIds';
4
+ import type { FileURL } from '../models/FileURL';
4
5
  import type { Run } from '../models/Run';
5
6
  import type { Status } from '../models/Status';
6
7
  import type { CancelablePromise } from '../core/CancelablePromise';
@@ -85,6 +86,23 @@ export declare class RunService {
85
86
  * @throws ApiError
86
87
  */
87
88
  static createNewChat(runId: string, requestBody: AsteroidChat): CancelablePromise<ChatIds>;
89
+ /**
90
+ * Get a signed URL to create a file for a run
91
+ * @param runId
92
+ * @param requestBody
93
+ * @returns string File created
94
+ * @throws ApiError
95
+ */
96
+ static getCreateFileUrl(runId: string, requestBody: {
97
+ file_name?: string;
98
+ }): CancelablePromise<string>;
99
+ /**
100
+ * Get a signed URL to fetch a file for a run
101
+ * @param runId
102
+ * @returns FileURL An array of signed URLs to fetch files for a run
103
+ * @throws ApiError
104
+ */
105
+ static getFetchFileUrLs(runId: string): CancelablePromise<Array<FileURL>>;
88
106
  /**
89
107
  * Get the messages for a run
90
108
  * @param runId
@@ -188,6 +188,39 @@ class RunService {
188
188
  },
189
189
  });
190
190
  }
191
+ /**
192
+ * Get a signed URL to create a file for a run
193
+ * @param runId
194
+ * @param requestBody
195
+ * @returns string File created
196
+ * @throws ApiError
197
+ */
198
+ static getCreateFileUrl(runId, requestBody) {
199
+ return (0, request_1.request)(OpenAPI_1.OpenAPI, {
200
+ method: 'POST',
201
+ url: '/run/{run_id}/get_create_file_url',
202
+ path: {
203
+ 'run_id': runId,
204
+ },
205
+ body: requestBody,
206
+ mediaType: 'application/json',
207
+ });
208
+ }
209
+ /**
210
+ * Get a signed URL to fetch a file for a run
211
+ * @param runId
212
+ * @returns FileURL An array of signed URLs to fetch files for a run
213
+ * @throws ApiError
214
+ */
215
+ static getFetchFileUrLs(runId) {
216
+ return (0, request_1.request)(OpenAPI_1.OpenAPI, {
217
+ method: 'GET',
218
+ url: '/run/{run_id}/get_fetch_file_urls',
219
+ path: {
220
+ 'run_id': runId,
221
+ },
222
+ });
223
+ }
191
224
  /**
192
225
  * Get the messages for a run
193
226
  * @param runId
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "asteroid-odyssey",
3
- "version": "v1.0.7",
3
+ "version": "v1.0.8",
4
4
  "description": "SDK for interacting with Asteroid Agents API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",