diff --git a/src/client/file-client.ts b/src/client/file-client.ts index 30d2767..e045890 100644 --- a/src/client/file-client.ts +++ b/src/client/file-client.ts @@ -25,7 +25,7 @@ export class FileClient { this.apiKey = options.apiKey; this.client = new HttpClient({ baseUrl: this.host, - apiKey: this.apiKey, + apiKey: options.apiKey, timeout: options.timeout || 60000, }); } @@ -96,6 +96,13 @@ export class FileClient { return this.uploadFile(text, destinationPath, fileName); } + async createDirectory(path: string): Promise { + const response = await this.client.post('/api/file/create_directory', null, { + params: { path }, + }); + return response.data; + } + async downloadTrajectory(conversationId: string): Promise { const response = await this.client.get( `/api/file/download-trajectory/${encodeURIComponent(conversationId)}`,