Skip to content

Accessing FileRise via curl (WebDAV)

Ryan edited this page Apr 21, 2025 · 1 revision

📡 Accessing FileRise via curl (WebDAV)

FileRise supports WebDAV natively, so you can upload, download, list, and manage files entirely from the command‑line with curl, which is available on Linux, macOS, and Windows.

This page shows quick, copy‑paste examples.


🔽 Download a file

curl -u username:password -O "http://your‑server/webdav.php/uploads/path/to/file.txt"
  • -u supplies your FileRise username and password.
  • -O saves the file with its original name.

Example — download report.pdf:

curl -u demo:demo -O "http://192.168.1.134/webdav.php/uploads/demo/report.pdf"

🔼 Upload a file

curl -u username:password -T "localfile.txt" "http://your‑server/webdav.php/uploads/path/"
  • -T is the local file you want to upload.
  • End folder URLs with a slash / when uploading.

Example — upload backup.zip to uploads/demo/:

curl -u demo:demo -T "backup.zip" "http://192.168.1.134/webdav.php/uploads/demo/"

📁 List directory contents

curl -u username:password -X PROPFIND -H "Depth: 1" "http://your‑server/webdav.php/uploads/demo/"
  • -X PROPFIND triggers a WebDAV list request.
  • -H "Depth: 1" lists immediate children only (non‑recursive).

Example:

curl -u demo:demo -X PROPFIND -H "Depth: 1" "http://192.168.1.134/webdav.php/uploads/demo/"

Returns an XML listing of files and sub‑folders.


⚡ Tips

  • URL encoding – replace spaces with %20 (My%20Folder).
  • Trailing slashes – folders should end with /.
  • HTTPS recommended – use https://… in production.
  • Windows curl – Windows 10/11 include curl; watch quoting and backslashes.

🛠 Example script snippet

Automated daily backup upload:

curl -u demo:demo -T "/path/to/daily_backup.zip" "http://your‑server/webdav.php/uploads/backups/"

Place this in a shell script or Windows batch file and schedule it with cron or Task Scheduler.


🎯 Summary

With WebDAV + curl, FileRise integrates seamlessly into scripts, cron jobs, CI pipelines, or quick one‑off commands — perfect for power users who want more than the web UI.


🧩 See also

Clone this wiki locally