Docs.rs
  • actix-http-3.11.0
    • actix-http 3.11.0
    • Docs.rs crate page
    • MIT OR Apache-2.0
    • Links
    • Homepage
    • Repository
    • crates.io
    • Source
    • Owners
    • fafhrd91
    • github:actix:core
    • Dependencies
      • actix-codec ^0.5 normal
      • actix-rt ^2.2 normal
      • actix-service ^2 normal
      • actix-tls ^3.4 normal optional
      • actix-utils ^3 normal
      • base64 ^0.22 normal optional
      • bitflags ^2 normal
      • brotli ^8 normal optional
      • bytes ^1 normal
      • bytestring ^1 normal
      • derive_more ^2 normal
      • encoding_rs ^0.8 normal
      • flate2 ^1.0.13 normal optional
      • foldhash ^0.1 normal
      • futures-core ^0.3.17 normal
      • h2 ^0.3.26 normal optional
      • http ^0.2.7 normal
      • httparse ^1.5.1 normal
      • httpdate ^1.0.1 normal
      • itoa ^1 normal
      • language-tags ^0.3 normal
      • local-channel ^0.1 normal optional
      • mime ^0.3.4 normal
      • percent-encoding ^2.1 normal
      • pin-project-lite ^0.2 normal
      • rand ^0.9 normal optional
      • sha1 ^0.10 normal optional
      • smallvec ^1.6.1 normal
      • tokio ^1.38.2 normal
      • tokio-util ^0.7 normal
      • tracing ^0.1.30 normal
      • zstd ^0.13 normal optional
      • actix-http-test ^3 dev
      • actix-server ^2 dev
      • actix-tls ^3.4 dev
      • actix-web ^4 dev
      • async-stream ^0.3 dev
      • criterion ^0.5 dev
      • divan ^0.1.8 dev
      • env_logger ^0.11 dev
      • futures-util ^0.3.17 dev
      • memchr ^2.4 dev
      • once_cell ^1.21 dev
      • rcgen ^0.13 dev
      • regex ^1.3 dev
      • rustls-pemfile ^2 dev
      • rustversion ^1 dev
      • serde ^1 dev
      • serde_json ^1.0 dev
      • static_assertions ^1 dev
      • openssl ^0.10.55 dev
      • rustls ^0.23 dev
      • tokio ^1.38.2 dev
    • Versions
    • 85.06% of the crate is documented
  • Platform
    • x86_64-unknown-linux-gnu
  • Feature flags
  • docs.rs
    • About docs.rs
    • Privacy policy
  • Rust
    • Rust website
    • The Book
    • Standard Library API Reference
    • Rust by Example
    • The Cargo Guide
    • Clippy Documentation

Crate actix_http

logo

actix_http3.11.0

  • All Items

Sections

  • Crate Features

Crate Items

  • Re-exports
  • Modules
  • Structs
  • Enums
  • Traits
  • Type Aliases

Crates

  • actix_http

Crate actix_http

Source
Expand description

HTTP types and services for the Actix ecosystem.

§Crate Features

FeatureFunctionality
http2HTTP/2 support via h2.
opensslTLS support via OpenSSL.
rustls-0_20TLS support via rustls 0.20.
rustls-0_21TLS support via rustls 0.21.
rustls-0_22TLS support via rustls 0.22.
rustls-0_23TLS support via rustls 0.23.
compress-brotliPayload compression support: Brotli.
compress-gzipPayload compression support: Deflate, Gzip.
compress-zstdPayload compression support: Zstd.
trust-dnsUse trust-dns as the client DNS resolver.

Re-exports§

pub use self::error::Error;
pub use self::header::ContentEncoding;

Modules§

body
Traits and structures to aid consuming and writing HTTP payloads.
encoding__compress
Content-Encoding support.
error
Error and Result module
h1
HTTP/1 protocol implementation.
h2http2
HTTP/2 protocol.
header
Pre-defined HeaderNames, traits for parsing and conversion, and other header utility methods.
test
Various testing helpers for use in internal and app tests.
uri
URI component of request and response lines
wsws
WebSocket protocol implementation.

Structs§

Extensions
A type map for request extensions.
HttpService
A ServiceFactory for HTTP/1.1 and HTTP/2 connections.
HttpServiceBuilder
An HTTP service builder.
Message
Method
The Request Method (VERB)
Request
An HTTP request.
RequestHead
Response
An HTTP response.
ResponseBuilder
An HTTP response builder.
ResponseHead
ServiceConfig
HTTP service configuration.
StatusCode
An HTTP status code (status-code in RFC 7230 et al.).
TlsAcceptorConfig__tls
Configuration options used when accepting TLS connection.
Uri
The URI component of a request.
Version
Represents a version of the HTTP spec.

Enums§

ConnectionType
Represents various types of connection
KeepAlive
Connection keep-alive config.
Payload
A streaming payload.
Protocol
A major HTTP protocol version.
RequestHeadType

Traits§

HttpMessage
Trait that implements general purpose operations on HTTP messages.

Type Aliases§

BoxedPayloadStream
A boxed payload stream.

Results

Settings
Help
    struct
    actix_http::Request
    An HTTP request.
    struct
    actix_http::RequestHead
    assoc const
    actix_http::StatusCode::REQUEST_TIMEOUT
    408 Request Timeout [RFC7231, Section 6.5.7]
    enum
    actix_http::RequestHeadType
    assoc const
    actix_http::StatusCode::REQUEST_HEADER_FIELDS_TOO_LARGE
    431 Request Header Fields Too Large [RFC6585]
    method
    actix_http::Response::bad_request
    Constructs a new response with status 400 Bad Request.
    assoc const
    actix_http::StatusCode::BAD_REQUEST
    400 Bad Request [RFC7231, Section 6.5.1]
    struct
    actix_http::test::TestRequest
    Test Request builder.
    enum variant
    actix_http::error::DispatchError::SlowRequestTimeout
    The first request did not complete within the specified …
    method
    actix_http::HttpServiceBuilder::client_request_timeout
    Set client request timeout (for first request).
    method
    actix_http::ServiceConfig::client_request_deadline
    Creates a time object representing the deadline for the …
    assoc const
    actix_http::StatusCode::TOO_MANY_REQUESTS
    429 Too Many Requests [RFC6585]
    assoc const
    actix_http::StatusCode::MISDIRECTED_REQUEST
    421 Misdirected Request RFC7540, Section 9.1.2
    constant
    actix_http::header::ACCESS_CONTROL_REQUEST_METHOD
    Informs the server know which HTTP method will be used …
    constant
    actix_http::header::ACCESS_CONTROL_REQUEST_HEADERS
    Informs the server which HTTP headers will be used when an …
    constant
    actix_http::header::UPGRADE_INSECURE_REQUESTS
    Sends a signal to the server expressing the client’s …
    method
    actix_http::h1::ExpectHandler::call
    &ExpectHandler, Request -> Service::Future
    method
    actix_http::Request::upgrade
    &Request<P> -> bool
    Check if request requires connection upgrade
    method
    actix_http::Request::version
    &Request<P> -> Version
    Read the Request Version.
    method
    actix_http::Request::uri
    &Request<P> -> &Uri
    Request’s uri.
    method
    actix_http::Request::head
    &Request<P> -> &RequestHead
    Http message part of the request
    method
    actix_http::Request::path
    &Request<P> -> &str
    The target path of this Request.
    method
    actix_http::Request::method
    &Request<P> -> &Method
    Read the Request method.
    method
    actix_http::Request::headers
    &Request<P> -> &HeaderMap
    method
    actix_http::Request::peer_addr
    &Request<P> -> Option<SocketAddr>
    Peer socket address.
    method
    actix_http::Request::extensions
    &Request<P> -> Ref<Extensions>
    method
    actix_http::Request::take_req_data
    &mut Request<P> -> Extensions
    Returns the request-local data/extensions container, …
    method
    actix_http::Request::extensions_mut
    &Request<P> -> RefMut<Extensions>
    method
    actix_http::Request::conn_data
    &Request<P> -> Option<&T>
    Returns a reference a piece of connection data set in an …
    method
    actix_http::Request::take_payload
    &mut Request<P> -> Payload<P>
    Get request’s payload
    method
    actix_http::Request::fmt
    &Request<P>, &mut Formatter -> Result
    method
    actix_http::Request::uri_mut
    &mut Request<P> -> &mut Uri
    Mutable reference to the request’s uri.
    method
    actix_http::Request::into_parts
    Request<P> -> (Message<RequestHead>, Payload<P>)
    Split request into request head and payload
    method
    actix_http::Request::headers_mut
    &mut Request<P> -> &mut HeaderMap
    Mutable reference to the message’s headers.
    method
    actix_http::Request::take_conn_data
    &mut Request<P> -> Option<Rc<Extensions>>
    Returns the connection-level data/extensions container if …
    method
    actix_http::h1::UpgradeHandler::call
    &UpgradeHandler, (Request, Framed<T, Codec>) -> Service::Future
    method
    actix_http::Request::payload
    &mut Request<P> -> &mut Payload<P>
    Get request’s payload
    method
    actix_http::Request::replace_payload
    Request<P>, Payload<P1> -> (Request<P1>, Payload<P>)
    Create new Request instance
    method
    actix_http::Request::new
    -> Request<BoxedPayloadStream>
    Create new Request instance
    method
    actix_http::Request::from
    Message<RequestHead> -> Request<BoxedPayloadStream>
    method
    actix_http::test::TestRequest::finish
    &mut TestRequest -> Request
    Complete request creation and generate Request instance.
    method
    actix_http::Request::with_payload
    Payload<P> -> Request<P>
    Create new Request instance
    method
    actix_http::Request::replace_payload
    Request<P>, Payload<P1> -> (Request<P1>, Payload<P>)
    Create new Request instance