MCPcopy Index your code

hub / github.com/TrueLayer/reqwest-middleware / functions

Functions111 in github.com/TrueLayer/reqwest-middleware

↓ 31 callersMethodbuild
Returns a `ClientWithMiddleware` using this builder configuration.
reqwest-middleware/src/client.rs:84
↓ 20 callersMethodclone
(&self)
reqwest-tracing/src/middleware.rs:22
↓ 19 callersMethodwith
Convenience method to attach middleware. If you need to keep a reference to the middleware after attaching, use [`with_arc`]. [`with_arc`]: Self::wi
reqwest-middleware/src/client.rs:48
↓ 12 callersMethodset_inner
(&mut self, key: &str, value: String)
reqwest-tracing/src/otel.rs:112
↓ 6 callersMethodrequest
Start building a `Request` with the `Method` and `Url`. Returns a `RequestBuilder`, which will allow setting headers and the request body before send
reqwest-middleware/src/client.rs:178
↓ 5 callersMethodget
Convenience method to make a `GET` request to a URL. # Errors This method fails whenever the supplied `Url` cannot be parsed.
reqwest-middleware/src/client.rs:121
↓ 5 callersFunctionremove_credentials
Removes the username and/or password parts of the url, if present.
reqwest-tracing/src/reqwest_otel_span_builder.rs:351
↓ 5 callersMethodrun
( mut self, req: Request, extensions: &'a mut Extensions, )
reqwest-middleware/src/middleware.rs:94
↓ 5 callersMethodsend
Constructs the Request and sends it to the target URL, returning a future Response. # Errors This method fails if there was an error while sending r
reqwest-middleware/src/client.rs:581
↓ 5 callersMethodstatus
Returns the status code, if the error was generated from a response.
reqwest-middleware/src/error.rs:135
↓ 4 callersMethodtimeout
(self, timeout: std::time::Duration)
reqwest-middleware/src/client.rs:426
↓ 4 callersMethoduri
Returns the uri in which the server is listening to.
reqwest-retry/tests/all/helpers/simple_server.rs:69
↓ 3 callersMethodstart
Starts the TcpListener and handles the requests.
reqwest-retry/tests/all/helpers/simple_server.rs:74
↓ 2 callersFunctiondefault_on_request_end
(span: &Span, outcome: &Result<Response>)
reqwest-tracing/src/reqwest_otel_span_builder.rs:74
↓ 2 callersFunctiondefault_span_name
(req: &'a Request, ext: &'a Extensions)
reqwest-tracing/src/reqwest_otel_span_builder.rs:127
↓ 2 callersMethodexecute_with_extensions
Executes a `Request` with initial [`Extensions`]. A `Request` can be built manually with `Request::new()` or obtained from a RequestBuilder with `Req
reqwest-middleware/src/client.rs:219
↓ 2 callersFunctionget_header_value
(key: &str, headers: &reqwest::header::HeaderMap)
reqwest-tracing/src/reqwest_otel_span_builder.rs:82
↓ 2 callersMethodhandle
( &self, req: Request, extensions: &mut Extensions, next: Next<'_>, )
reqwest-retry/src/middleware.rs:115
↓ 2 callersFunctionmake_echo_request_in_otel_context
(client: ClientWithMiddleware)
reqwest-tracing/src/otel.rs:215
↓ 2 callersMethodset_custom_handler
( &mut self, custom_handler: impl Fn(TcpStream) -> BoxFuture<'static, Result<(), Box<dyn std::
reqwest-retry/tests/all/helpers/simple_server.rs:57
↓ 2 callersMethodurl
Returns a possible URL related to this error.
reqwest-middleware/src/error.rs:25
↓ 1 callersMethodbuild_split
Build a `Request`, which can be inspected, modified and executed with `ClientWithMiddleware::execute()`. This is similar to [`RequestBuilder::build()
reqwest-middleware/src/client.rs:533
↓ 1 callersFunctionclassify_io_error
(error: &std::io::Error)
reqwest-retry/src/retryable_strategy.rs:189
↓ 1 callersFunctiondefault_on_request_failure
Default request failure retry strategy. Will only retry if the request failed due to a network error
reqwest-retry/src/retryable_strategy.rs:134
↓ 1 callersFunctiondefault_on_request_failure
(span: &Span, e: &Error)
reqwest-tracing/src/reqwest_otel_span_builder.rs:105
↓ 1 callersFunctiondefault_on_request_success
Default request success retry strategy. Will only retry if: The status was 5XX (server error) The status was 408 (request timeout) or 429 (too many r
reqwest-retry/src/retryable_strategy.rs:113
↓ 1 callersFunctiondefault_on_request_success
(span: &Span, response: &Response)
reqwest-tracing/src/reqwest_otel_span_builder.rs:89
↓ 1 callersMethodexecute
Executes a `Request`. A `Request` can be built manually with `Request::new()` or obtained from a RequestBuilder with `RequestBuilder::build()`. You
reqwest-middleware/src/client.rs:202
↓ 1 callersMethodexecute_with_retry
This function will try to execute the request, if it fails with an error classified as transient it will call itself to retry the request.
reqwest-retry/src/middleware.rs:137
↓ 1 callersMethodextensions
Returns a mutable reference to the internal set of extensions for this request
reqwest-middleware/src/client.rs:556
↓ 1 callersMethodfind
Find the templated path from the actual path. Returns the templated path if a match is found. ``` # use reqwest_tracing::OtelPathNames; let path_nam
reqwest-tracing/src/reqwest_otel_span_builder.rs:310
↓ 1 callersMethodget_bad_request_response
Returns the raw HTTP response in case of a 400 Bad Request.
reqwest-retry/tests/all/helpers/simple_server.rs:157
↓ 1 callersMethodget_response
Returns the response to use based on the calls counter. It uses a round-robin mechanism.
reqwest-retry/tests/all/helpers/simple_server.rs:147
↓ 1 callersFunctionget_span_status
HTTP Mapping <https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/trace/semantic_conventions/http.md#status> Maps t
reqwest-tracing/src/reqwest_otel_span_builder.rs:185
↓ 1 callersMethodhandle
( &self, req: Request, extensions: &mut Extensions, next: Next<'_>, )
reqwest-middleware/src/middleware.rs:60
↓ 1 callersMethodhandle_connection
Asyncrounously reads from the buffer and handle the request. It first checks that the format is correct, then returns the response. Returns a 400 if
reqwest-retry/tests/all/helpers/simple_server.rs:97
↓ 1 callersMethodheaders
Add a set of Headers to the existing ones on this Request. The headers will be merged in to any already set.
reqwest-middleware/src/client.rs:361
↓ 1 callersMethodinit
(&self, req: RequestBuilder)
reqwest-middleware/src/req_init.rs:30
↓ 1 callersFunctioninject_opentelemetry_context_into_request
Injects the given OpenTelemetry Context into a reqwest::Request headers to allow propagation downstream.
reqwest-tracing/src/otel.rs:7
↓ 1 callersMethodis_body
Returns true if the error is related to the request or response body.
reqwest-middleware/src/error.rs:119
↓ 1 callersMethodis_builder
Returns true if the error is from a type `Builder`.
reqwest-middleware/src/error.rs:70
↓ 1 callersMethodis_connect
Returns true if the error is related to connect.
reqwest-middleware/src/error.rs:111
↓ 1 callersMethodis_decode
Returns true if the error is related to decoding the response's body.
reqwest-middleware/src/error.rs:127
↓ 1 callersMethodis_redirect
Returns true if the error is from a `RedirectPolicy`.
reqwest-middleware/src/error.rs:78
↓ 1 callersMethodis_request
Returns true if the error is related to the request.
reqwest-middleware/src/error.rs:102
↓ 1 callersMethodis_timeout
Returns true if the error is related to a timeout.
reqwest-middleware/src/error.rs:94
↓ 1 callersMethodtry_clone
Attempt to clone the RequestBuilder. `None` is returned if the RequestBuilder can not be cloned, i.e. if the request body is a stream. # Examples `
reqwest-middleware/src/client.rs:606
↓ 1 callersMethodwith_arc
Add middleware to the chain. [`with`] is more ergonomic if you don't need the `Arc`. [`with`]: Self::with
reqwest-middleware/src/client.rs:58
↓ 1 callersMethodwith_arc_init
Add a request initialiser to the chain. [`with_init`] is more ergonomic if you don't need the `Arc`. [`with_init`]: Self::with_init
reqwest-middleware/src/client.rs:78
↓ 1 callersMethodwith_extension
Inserts the extension into this request builder
reqwest-middleware/src/client.rs:550
↓ 1 callersMethodwith_init
Convenience method to attach a request initialiser. If you need to keep a reference to the initialiser after attaching, use [`with_arc_init`]. [`wit
reqwest-middleware/src/client.rs:68
Functionassert_retry_on_connection_reset_by_peer
()
reqwest-retry/tests/all/retry.rs:318
Functionassert_retry_on_hyper_canceled
()
reqwest-retry/tests/all/retry.rs:267
Functionassert_retry_on_incomplete_message
()
reqwest-retry/tests/all/retry.rs:212
Functionassert_retry_on_request_timeout
()
reqwest-retry/tests/all/retry.rs:177
Methodbasic_auth
Enable HTTP basic authentication. ```rust # use anyhow::Error; # async fn run() -> Result<(), Error> { let client = reqwest_middleware::ClientWithMi
reqwest-middleware/src/client.rs:390
Methodbearer_auth
Enable HTTP bearer authentication.
reqwest-middleware/src/client.rs:402
Methodbody
Set the request body.
reqwest-middleware/src/client.rs:413
Methodcall
(&mut self, req: Request)
reqwest-middleware/src/client.rs:287
Functioncontext_no_propagated
()
reqwest-tracing/src/otel.rs:489
Methoddefault
()
reqwest-tracing/src/middleware.rs:28
Methoddelete
Convenience method to make a `DELETE` request to a URL. # Errors This method fails whenever the supplied `Url` cannot be parsed.
reqwest-middleware/src/client.rs:157
Methodfmt
(&self, f: &mut fmt::Formatter<'_>)
reqwest-retry/tests/all/helpers/simple_server.rs:29
Methodfmt
(&self, f: &mut fmt::Formatter)
reqwest-middleware/src/client.rs:241
Methodform
Send a form body. Sets the body to the url encoded serialization of the passed value, and also sets the `Content-Type: application/x-www-form-urlenco
reqwest-middleware/src/client.rs:496
Methodfrom
(_status: &reqwest::Error)
reqwest-retry/src/retryable.rs:24
Methodfrom
(client: Client)
reqwest-middleware/src/client.rs:231
Methodfrom_client
This method allows creating a ClientBuilder from an existing ClientWithMiddleware instance
reqwest-middleware/src/client.rs:35
Methodfrom_parts
Assemble a builder starting from an existing `Client` and a `Request`.
reqwest-middleware/src/client.rs:334
Methodfrom_reqwest_response
Try to map a `reqwest` response into `Retryable`. Returns `None` if the response object does not contain any errors.
reqwest-retry/src/retryable.rs:18
Functionget_header_value_for_span_attribute
()
reqwest-tracing/src/reqwest_otel_span_builder.rs:377
Functionget_source_error_type
( err: &dyn std::error::Error, )
reqwest-retry/src/retryable_strategy.rs:200
Methodhandle
(&self, res: &Result<reqwest::Response, Error>)
reqwest-retry/src/retryable_strategy.rs:98
Methodhandle
( &self, req: Request, extensions: &mut Extensions, next: Next<'_>, )
reqwest-tracing/src/middleware.rs:39
Methodhead
Convenience method to make a `HEAD` request to a URL. # Errors This method fails whenever the supplied `Url` cannot be parsed.
reqwest-middleware/src/client.rs:166
Methodheader
Add a `Header` to this Request.
reqwest-middleware/src/client.rs:345
Methodis_middleware
Returns true if the error is from any middleware.
reqwest-middleware/src/error.rs:62
Methodis_status
Returns true if the error is from `Response::error_for_status`.
reqwest-middleware/src/error.rs:86
Methodjson
(self, json: &T)
reqwest-middleware/src/client.rs:515
Methodknown_paths
Create a new [`OtelPathNames`] from a set of known paths. Paths in this set will be found with `find`. Paths can have different parameters: - Named
reqwest-tracing/src/reqwest_otel_span_builder.rs:286
Methodmiddleware
(err: E)
reqwest-middleware/src/error.rs:17
Methodmultipart
(self, multipart: multipart::Form)
reqwest-middleware/src/client.rs:435
Methodnew
(retries: u32, status_code: u16)
reqwest-retry/tests/all/retry.rs:21
Methodnew
Creates an instance of a [`SimpleServer`] If [`port`] is None os Some(0), it gets randomly chosen between the available ones.
reqwest-retry/tests/all/helpers/simple_server.rs:37
Methodnew
(client: &'a Client, middlewares: &'a [Arc<dyn Middleware>])
reqwest-middleware/src/middleware.rs:87
Methodnew
(client: Client)
reqwest-middleware/src/client.rs:25
Methodnew
()
reqwest-tracing/src/middleware.rs:14
Methodnew
(request: &'a mut Request)
reqwest-tracing/src/otel.rs:106
Methodnew_with_policy
Construct `RetryTransientMiddleware` with a [retry_policy][RetryPolicy].
reqwest-retry/src/middleware.rs:79
Methodnew_with_policy_and_strategy
Construct `RetryTransientMiddleware` with a [retry_policy][RetryPolicy] and [retryable_strategy](RetryableStrategy).
reqwest-retry/src/middleware.rs:98
Methodon_request_end
(span: &Span, outcome: &Result<Response>, _: &mut Extensions)
reqwest-tracing/src/reqwest_otel_span_builder.rs:155
Methodon_request_start
(req: &Request, ext: &mut Extensions)
reqwest-tracing/src/reqwest_otel_span_builder.rs:150
Methodparse_request_line
Parses the request line and checks that it contains the method, uri and http_version parts. It does not check if the content of the checked parts is c
reqwest-retry/tests/all/helpers/simple_server.rs:129
Methodpatch
Convenience method to make a `PATCH` request to a URL. # Errors This method fails whenever the supplied `Url` cannot be parsed.
reqwest-middleware/src/client.rs:148
Methodpoll
(mut self: Pin<&mut Self>, cx: &mut Context<'_>)
reqwest-middleware/src/client.rs:273
Methodpoll_ready
(&mut self, cx: &mut Context<'_>)
reqwest-middleware/src/client.rs:283
Methodpost
Convenience method to make a `POST` request to a URL. # Errors This method fails whenever the supplied `Url` cannot be parsed.
reqwest-middleware/src/client.rs:130
Methodput
Convenience method to make a `PUT` request to a URL. # Errors This method fails whenever the supplied `Url` cannot be parsed.
reqwest-middleware/src/client.rs:139
Methodquery
Modify the query string of the URL. Modifies the URL of this request, adding the parameters provided. This method appends and does not overwrite. Thi
reqwest-middleware/src/client.rs:461
Functionremove_credentials_from_url_without_credentials_is_noop
()
reqwest-tracing/src/reqwest_otel_span_builder.rs:387
next →1–100 of 111, ranked by callers