How I can include all the files in a folder in the $sftp->put?

here is my code:

<?php

require_once('vendor/autoload.php');

use phpseclib3NetSFTP;

$sftp = new SFTP($ftp_server);
$sftp_login = $sftp->login($ftp_user_name, $ftp_user_pass);

$remote_file_path = "remote_folder/";
$local_file_path = "local_folder/";

$sftp->put($remote_file_path, $local_file_path, SFTP::SOURCE_LOCAL_FILE); 

?>

I’m trying to push all the files inside a local folder to be pushed to a remote server.

With this, I’m able to put one file only but not all.
Tried to use a foreach loop but it didn’t work.

Please guide. Thanks!