@transai/connector-runner-file 0.18.0 → 0.19.1

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.
@@ -1,12 +1,13 @@
1
1
  import { FilesSDKInterface, LoggerSDKInterface } from '@transai/connector-runtime-sdk';
2
2
  import { FileAction } from '../types';
3
3
  type ActionParams = {
4
- remotePath: string;
4
+ remotePath?: string;
5
+ localPath?: string;
5
6
  };
6
7
  export declare class ActionDeleteFile implements FileAction<ActionParams, void> {
7
8
  #private;
8
9
  static readonly TYPE = "delete";
9
- constructor(fileHandler: FilesSDKInterface, logger?: LoggerSDKInterface);
10
+ constructor(fileHandler: FilesSDKInterface, localFileSDKInterface: FilesSDKInterface, logger?: LoggerSDKInterface);
10
11
  execute(params: ActionParams): Promise<void>;
11
12
  }
12
13
  export {};
@@ -0,0 +1,17 @@
1
+ import { FilesSDKInterface, LoggerSDKInterface } from '@transai/connector-runtime-sdk';
2
+ import { FileAction } from '../types';
3
+ type ActionParams = {
4
+ localPath?: string;
5
+ };
6
+ type ActionResult = {
7
+ files: Array<string>;
8
+ directories: Array<string>;
9
+ outputPath: string;
10
+ };
11
+ export declare class ActionExtractArchive implements FileAction<ActionParams, ActionResult> {
12
+ #private;
13
+ static readonly TYPE = "extract-archive";
14
+ constructor(localFileSDKInterface: FilesSDKInterface, logger?: LoggerSDKInterface);
15
+ execute(params: ActionParams): Promise<ActionResult>;
16
+ }
17
+ export {};
@@ -0,0 +1,17 @@
1
+ import { FilesSDKInterface, LoggerSDKInterface } from '@transai/connector-runtime-sdk';
2
+ import { FileAction } from '../types';
3
+ type ActionParams = {
4
+ localPath?: string;
5
+ remotePath?: string;
6
+ };
7
+ type ActionResult = {
8
+ files: Array<string>;
9
+ directories: Array<string>;
10
+ };
11
+ export declare class ActionListDirectory implements FileAction<ActionParams, ActionResult> {
12
+ #private;
13
+ static readonly TYPE = "list-directory";
14
+ constructor(fileHandler: FilesSDKInterface, localFileSDKInterface: FilesSDKInterface, logger?: LoggerSDKInterface);
15
+ execute(params: ActionParams): Promise<ActionResult>;
16
+ }
17
+ export {};
@@ -0,0 +1,2 @@
1
+ import { FilesSDKInterface } from '@transai/connector-runtime-sdk';
2
+ export declare function parseLocalPath(fileSdk: FilesSDKInterface, localPath: string): string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@transai/connector-runner-file",
3
- "version": "0.18.0",
3
+ "version": "0.19.1",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -10,6 +10,9 @@
10
10
  "email": "samen@transai.com",
11
11
  "url": "https://transai.com"
12
12
  },
13
+ "dependencies": {
14
+ "unzipper": "^0.12.3"
15
+ },
13
16
  "type": "commonjs",
14
17
  "main": "./index.cjs",
15
18
  "typings": "./index.d.ts"