From 92e1e43da2fa6fc1c47d706efa496a9f9f8397a8 Mon Sep 17 00:00:00 2001 From: dhanabalan Date: Tue, 15 Sep 2026 08:42:46 +0530 Subject: [PATCH] Added sftp file service --- app/Services/SftpFileService.php | 35 ++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 app/Services/SftpFileService.php diff --git a/app/Services/SftpFileService.php b/app/Services/SftpFileService.php new file mode 100644 index 0000000..b3d8276 --- /dev/null +++ b/app/Services/SftpFileService.php @@ -0,0 +1,35 @@ +disk = Storage::disk('ftp'); + } + + public function getFiles(): array + { + return $this->disk->files(); + } + + public function getFileContent(string $file): string + { + return $this->disk->get($file); + } + + public function moveFile(string $file, string $destination): bool + { + return $this->disk->move($file, $destination); + } + + // public function deleteFile(string $file): bool + // { + // return $this->disk->delete($file); + // } +} -- 2.49.1