Function abstio::download::download_bytes
source · [−]pub async fn download_bytes<I: AsRef<str>>(
url: I,
post_body: Option<String>,
progress: &mut Sender<String>
) -> Result<Vec<u8>>
Expand description
Downloads bytes from a URL. This must be called with a tokio runtime somewhere. The caller creates an mpsc channel pair and provides the sender. Progress will be described through it.