Google 应用程序脚本:如何上传文件 FTP

Google app script : how to upload a file an FTP

我正在使用脚本以 CSV 格式导出 google 电子表格,并使用此代码在同一文件夹中创建文件(感谢 Tanaike):

var folder = DriveApp.getFileById(ss.getId()).getParents().next();

是否可以同时将创建的文件(CSV)上传到FTP(或SFTP)服务器?

谢谢

答案:

Is it possible at the same time to upload the created file (CSV) in an FTP (or SFTP) server?

不幸的是,这是不可能的。 Google Apps 脚本仅支持 HTTP 请求[1].

功能请求:

但是,如果您确实希望将其添加到 Apps 脚本,您可以前往 Google 的 Issue Tracker 并提出包含所有相关信息的功能请求。

参考文献:

  1. Class UrlFetchApp | Apps Script