Crates.io | reqwest-retry-after |
lib.rs | reqwest-retry-after |
version | 0.1.2 |
source | src |
created_at | 2022-08-07 00:10:22.80656 |
updated_at | 2024-01-06 20:03:13.770281 |
description | Retry-After header support for reqwest |
homepage | |
repository | https://github.com/melotic/reqwest-retry-after |
max_upload_size | |
id | 640045 |
size | 11,459 |
reqwest-retry-after
is a library that adds support for the Retry-After
header in reqwest, using reqwest_middleware.
Simply pass RetryAfterMiddleware
to the ClientWithMiddleware
builder.
use reqwest_middleware::{ClientBuilder, ClientWithMiddleware};
use reqwest_retry_after::RetryAfterMiddleware;
let client = ClientBuilder::new(reqwest::Client::new())
.with(RetryAfterMiddleware::new())
.build();