14 releases

0.1.14 Oct 28, 2024
0.1.13 Jul 31, 2024
0.1.11 Apr 27, 2024
0.1.9 Jan 31, 2024
0.1.1 Sep 9, 2022

#54 in HTTP client

Download history 1219/week @ 2024-09-21 1357/week @ 2024-09-28 1313/week @ 2024-10-05 1182/week @ 2024-10-12 1501/week @ 2024-10-19 1750/week @ 2024-10-26 596/week @ 2024-11-02 1039/week @ 2024-11-09 606/week @ 2024-11-16 1301/week @ 2024-11-23 1126/week @ 2024-11-30 918/week @ 2024-12-07 551/week @ 2024-12-14 472/week @ 2024-12-21 756/week @ 2024-12-28 989/week @ 2025-01-04

2,865 downloads per month
Used in opentalk-nextcloud-client

MIT/Apache

50KB
1K SLoC

Reqwest dav

crates.io Documentation MIT/Apache-2 licensed CI

An async webdav client for rust with tokio and reqwest

Features

  • Authentication
    • Basic
    • Digest
  • Files management
    • Get
    • Put
    • Mv
    • Cp
    • Delete
    • Mkcol
    • List

Examples

use crate::{Auth, ClientBuilder, Depth, Error};

#[tokio::test]
async fn it_works() -> Result<(), Error> {
  
    // build a client
    let client = ClientBuilder::new()
        .set_host("http://server/remote.php/dav/files/username/".to_string())
        .set_auth(Auth::Basic("username".to_owned(), "password".to_owned()))
        .build()?;

    // list files
    println!(
        "{}",
        serde_json::to_string(&client.list("", Depth::Infinity).await?).unwrap()
    );
  
    // delete a file
    client.delete("1.txt").await.unwrap();

    Ok(())
}

Dependencies

~8–20MB
~269K SLoC