aiohttp API reference
251 public APIs from aiohttp (aio-libs/aiohttp) — 105 classes, 18 functions, 128 methods. Signatures extracted by static analysis of the actual source.
Repository: aio-libs/aiohttp
| Kind | Count |
|---|---|
| Classes | 105 |
| Functions | 18 |
| Methods | 128 |
API list
func
aiohttp._cookie_helpers.parse_cookie_header(header:str) -> list[tuple[str, Morsel[str]]]Parse a Cookie header according to RFC 6265 Section 5.4.
class
aiohttp._websocket.models.WSHandshakeErrorWebSocket protocol handshake error.
method
aiohttp._websocket.models.WSMessageTextBytes.json(*loads:Callable[[bytes], Any]=json.loads) -> AnyReturn parsed JSON data.
class
aiohttp._websocket.models.WebSocketErrorWebSocket protocol parser error.
class
aiohttp._websocket.writer.WebSocketWriterWebSocket writer.
method
aiohttp._websocket.writer.WebSocketWriter.close(code:int=1000, message:bytes | str=b'') -> NoneClose the websocket, sending the specified code and message.
method
aiohttp._websocket.writer.WebSocketWriter.send_frame(message:bytes, opcode:int, compress:int | None=None) -> NoneSend a frame over the websocket with message as its payload.
class
aiohttp.abc.AbstractAccessLoggerAbstract writer to access log.
method
aiohttp.abc.AbstractAccessLogger.enabled() -> boolCheck if logger is enabled.
method
aiohttp.abc.AbstractAccessLogger.log(request:BaseRequest, response:StreamResponse, time:float) -> NoneEmit log to logger.
class
aiohttp.abc.AbstractAsyncAccessLoggerAbstract asynchronous writer to access log.
method
aiohttp.abc.AbstractAsyncAccessLogger.enabled() -> boolCheck if logger is enabled.
method
aiohttp.abc.AbstractAsyncAccessLogger.log(request:BaseRequest, response:StreamResponse, request_start:float) -> NoneEmit log to logger.
class
aiohttp.abc.AbstractCookieJarAbstract Cookie Jar.
method
aiohttp.abc.AbstractCookieJar.clear(predicate:ClearCookiePredicate | None=None) -> NoneClear all cookies if no predicate is passed.
method
aiohttp.abc.AbstractCookieJar.clear_domain(domain:str) -> NoneClear all cookies for domain and all subdomains.
method
aiohttp.abc.AbstractCookieJar.cookies() -> MappingProxyType[tuple[str, str], SimpleCookie]Return the cookies stored in this jar.
method
aiohttp.abc.AbstractCookieJar.filter_cookies(request_url:URL) -> BaseCookie[str]Return the jar's cookies filtered by their attributes.
method
aiohttp.abc.AbstractCookieJar.host_only_cookies() -> frozenset[tuple[str, str]]Return the host-only cookies stored in this jar.
method
aiohttp.abc.AbstractCookieJar.quote_cookie() -> boolReturn True if cookies should be quoted.
method
aiohttp.abc.AbstractCookieJar.unsafe() -> boolReturn True if cookies can be used with IP addresses.
method
aiohttp.abc.AbstractCookieJar.update_cookies(cookies:LooseCookies, response_url:URL=URL()) -> NoneUpdate cookies.
method
aiohttp.abc.AbstractCookieJar.update_cookies_from_headers(headers:Sequence[str], response_url:URL) -> NoneUpdate cookies from raw Set-Cookie headers.
class
aiohttp.abc.AbstractResolverAbstract DNS resolver.
method
aiohttp.abc.AbstractResolver.close() -> NoneRelease resolver
method
aiohttp.abc.AbstractResolver.resolve(host:str, port:int=0, family:socket.AddressFamily=socket.AF_INET) -> list[ResolveResult]Return IP address for given hostname
class
aiohttp.abc.AbstractStreamWriterAbstract stream writer.
method
aiohttp.abc.AbstractStreamWriter.drain() -> NoneFlush the write buffer.
method
aiohttp.abc.AbstractStreamWriter.enable_chunking() -> NoneEnable HTTP chunked mode
method
aiohttp.abc.AbstractStreamWriter.enable_compression(encoding:str='deflate', strategy:int | None=None) -> NoneEnable HTTP body compression
method
aiohttp.abc.AbstractStreamWriter.send_headers() -> NoneForce sending buffered headers if not already sent.
method
aiohttp.abc.AbstractStreamWriter.write(chunk:'bytes | bytearray | memoryview[int] | memoryview[bytes]') -> NoneWrite chunk into stream.
method
aiohttp.abc.AbstractStreamWriter.write_eof(chunk:bytes=b'') -> NoneWrite last chunk.
method
aiohttp.abc.AbstractStreamWriter.write_headers(status_line:str, headers:CIMultiDict[str]) -> NoneWrite HTTP headers
class
aiohttp.abc.AbstractViewAbstract class based view.
method
aiohttp.abc.AbstractView.request() -> RequestRequest instance.
class
aiohttp.abc.ResolveResultResolve result.
method
aiohttp.base_protocol.BaseProtocol.connected() -> boolReturn True if the connection is open.
class
aiohttp.client.ClientSessionFirst-class interface for making HTTP requests.
method
aiohttp.client.ClientSession.auto_decompress() -> boolShould the body response be automatically decompressed.
method
aiohttp.client.ClientSession.close() -> NoneClose underlying connector.
method
aiohttp.client.ClientSession.closed() -> boolIs client session closed.
method
aiohttp.client.ClientSession.connector() -> BaseConnector | NoneConnector instance used for the session.
method
aiohttp.client.ClientSession.connector_owner() -> boolShould connector be closed on session closing
method
aiohttp.client.ClientSession.cookie_jar() -> AbstractCookieJarThe session cookies.
method
aiohttp.client.ClientSession.detach() -> NoneDetach connector from session without closing the former.
method
aiohttp.client.ClientSession.headers() -> 'CIMultiDict[str]'The default headers of the client session.
method
aiohttp.client.ClientSession.json_serialize() -> JSONEncoderJson serializer callable
method
aiohttp.client.ClientSession.requote_redirect_url() -> boolDo URL requoting on redirection handling.
method
aiohttp.client.ClientSession.skip_auto_headers() -> frozenset[istr]Headers for which autogeneration should be skipped
method
aiohttp.client.ClientSession.timeout() -> ClientTimeoutTimeout for the session.
method
aiohttp.client.ClientSession.version() -> tuple[int, int]The session HTTP protocol version.
class
aiohttp.client_exceptions.ClientConnectionErrorBase class for client socket errors.
class
aiohttp.client_exceptions.ClientConnectionResetErrorConnectionResetError
class
aiohttp.client_exceptions.ClientConnectorCertificateErrorResponse certificate error.
class
aiohttp.client_exceptions.ClientConnectorDNSErrorDNS resolution failed during client connection.
class
aiohttp.client_exceptions.ClientConnectorErrorClient connector error.
class
aiohttp.client_exceptions.ClientConnectorSSLErrorResponse ssl error.
class
aiohttp.client_exceptions.ClientErrorBase class for client connection errors.
class
aiohttp.client_exceptions.ClientHttpProxyErrorHTTP proxy error.
class
aiohttp.client_exceptions.ClientOSErrorOSError error.
class
aiohttp.client_exceptions.ClientPayloadErrorResponse payload error.
class
aiohttp.client_exceptions.ClientProxyConnectionErrorProxy connection error.
class
aiohttp.client_exceptions.ClientResponseErrorBase class for exceptions that occur after getting a response.
class
aiohttp.client_exceptions.ClientSSLErrorBase error for ssl.*Errors.
class
aiohttp.client_exceptions.ConnectionTimeoutErrorConnection timeout error.
class
aiohttp.client_exceptions.ContentTypeErrorContentType found is not valid.
class
aiohttp.client_exceptions.InvalidURLInvalid URL.
class
aiohttp.client_exceptions.InvalidUrlClientErrorInvalid URL client error.
class
aiohttp.client_exceptions.InvalidUrlRedirectClientErrorInvalid URL redirect client error.
class
aiohttp.client_exceptions.NonHttpUrlClientErrorNon http URL client error.
class
aiohttp.client_exceptions.NonHttpUrlRedirectClientErrorNon http URL redirect client error.
class
aiohttp.client_exceptions.RedirectClientErrorClient redirect error.
class
aiohttp.client_exceptions.ServerConnectionErrorServer connection errors.
class
aiohttp.client_exceptions.ServerDisconnectedErrorServer disconnected.
class
aiohttp.client_exceptions.ServerFingerprintMismatchSSL certificate does not match expected fingerprint.
class
aiohttp.client_exceptions.ServerTimeoutErrorServer timeout error.
class
aiohttp.client_exceptions.SocketTimeoutErrorSocket timeout error.
class
aiohttp.client_exceptions.TooManyRedirectsClient was redirected too many times.
class
aiohttp.client_exceptions.UnixClientConnectorErrorUnix connector error.
class
aiohttp.client_exceptions.WSMessageTypeErrorWebSocket message type is not valid.
class
aiohttp.client_exceptions.WSServerHandshakeErrorwebsocket server handshake error.
func
aiohttp.client_middleware_digest_auth.DigestAuthMiddleware.H(x:bytes) -> bytesRFC 7616 Section 3: Hash function H(data) = hex(hash(data)).
func
aiohttp.client_middleware_digest_auth.escape_quotes(value:str) -> strEscape backslashes and double quotes for HTTP quoted-strings.
func
aiohttp.client_middleware_digest_auth.unescape_quotes(value:str) -> strUnescape backslashes and double quotes in HTTP quoted-strings.
func
aiohttp.client_middlewares.build_client_middlewares(handler:ClientHandlerType, middlewares:tuple[ClientMiddlewareType, ...]) -> ClientHandlerTypeApply middlewares to request handler.
class
aiohttp.client_proto.ResponseHandlerHelper class to adapt between Protocol and StreamReader.
method
aiohttp.client_proto.ResponseHandler.closed() -> None | asyncio.Future[None]Future that is set when the connection is closed.
class
aiohttp.client_reqrep.ClientRequestBaseAn internal class for proxy requests.
class
aiohttp.connector.BaseConnectorBase connector class.
method
aiohttp.connector.BaseConnector.close(*abort_ssl:bool=False) -> NoneClose all opened transports.
method
aiohttp.connector.BaseConnector.closed() -> boolIs connector closed.
method
aiohttp.connector.BaseConnector.connect(req:ClientRequest, traces:list['Trace'], timeout:'ClientTimeout') -> ConnectionGet from pool or create new connection.
method
aiohttp.connector.BaseConnector.force_close() -> boolUltimately close connection on releasing if True.
method
aiohttp.connector.BaseConnector.limit() -> intThe total number for simultaneous connections.
class
aiohttp.connector.ConnectionRepresents a single connection.
class
aiohttp.connector.NamedPipeConnectorNamed pipe connector.
method
aiohttp.connector.NamedPipeConnector.path() -> strPath to the named pipe.
class
aiohttp.connector.TCPConnectorTCP connector.
method
aiohttp.connector.TCPConnector.clear_dns_cache(host:str | None=None, port:int | None=None) -> NoneRemove specified host/port or clear all dns local cache.
method
aiohttp.connector.TCPConnector.close(*abort_ssl:bool=False) -> NoneClose all opened transports.
method
aiohttp.connector.TCPConnector.family() -> intSocket family like AF_INET.
method
aiohttp.connector.TCPConnector.use_dns_cache() -> boolTrue if local DNS caching is enabled.
class
aiohttp.connector.UnixConnectorUnix socket connector.
method
aiohttp.connector.UnixConnector.path() -> strPath to unix socket.
class
aiohttp.cookiejar.CookieJarImplements cookie storage adhering to RFC 6265.
method
aiohttp.cookiejar.CookieJar.cookies() -> MappingProxyType[tuple[str, str], SimpleCookie]Return the cookies stored in this jar.
method
aiohttp.cookiejar.CookieJar.filter_cookies(request_url:URL) -> 'BaseCookie[str]'Returns this jar's cookies filtered by their attributes.
method
aiohttp.cookiejar.CookieJar.host_only_cookies() -> frozenset[tuple[str, str]]Return the host-only cookies stored in this jar.
method
aiohttp.cookiejar.CookieJar.load(file_path:PathLike) -> NoneLoad cookies from a JSON file.
method
aiohttp.cookiejar.CookieJar.save(file_path:PathLike) -> NoneSave cookies to a file using JSON format.
method
aiohttp.cookiejar.CookieJar.update_cookies(cookies:LooseCookies, response_url:URL=URL()) -> NoneUpdate cookies.
class
aiohttp.cookiejar.DummyCookieJarImplements a dummy cookie storage.
method
aiohttp.cookiejar.DummyCookieJar.cookies() -> MappingProxyType[tuple[str, str], SimpleCookie]Return an empty mapping.
method
aiohttp.cookiejar.DummyCookieJar.host_only_cookies() -> frozenset[tuple[str, str]]Return an empty frozenset.
class
aiohttp.formdata.FormDataHelper class for form body generation.
class
aiohttp.helpers.AppKeyKeys for static typing support in Application.
class
aiohttp.helpers.BaseKeyBase for concrete context storage key classes.
class
aiohttp.helpers.CookieMixinMixin for handling cookies.
method
aiohttp.helpers.CookieMixin.del_cookie(name:str, *domain:str | None=None, *path:str='/', *secure:bool | None=None, *httponly:bool | None=None, *samesite:str | None=None) -> NoneDelete cookie.
class
aiohttp.helpers.HeadersMixinMixin for handling headers.
method
aiohttp.helpers.HeadersMixin.charset() -> str | NoneThe value of charset part for Content-Type HTTP header.
method
aiohttp.helpers.HeadersMixin.content_length() -> int | NoneThe value of Content-Length HTTP header.
method
aiohttp.helpers.HeadersMixin.content_type() -> strThe value of content part for Content-Type HTTP header.
class
aiohttp.helpers.RequestKeyKeys for static typing support in Request.
class
aiohttp.helpers.ResponseKeyKeys for static typing support in Response.
class
aiohttp.helpers.TimeoutHandleTimeout handle
class
aiohttp.helpers.TimerContextLow resolution timeout context manager
method
aiohttp.helpers.TimerContext.assert_timeout() -> NoneRaise TimeoutError if timer has already been cancelled.
func
aiohttp.helpers.calculate_timeout_when(loop_time:float, timeout:float, timeout_ceiling_threshold:float) -> floatCalculate when to execute a timeout.
func
aiohttp.helpers.content_disposition_header(disptype:str, quote_fields:bool=True, _charset:str='utf-8', params:dict[str, str] | None=None) -> strSets ``Content-Disposition`` header for MIME.
func
aiohttp.helpers.get_env_proxy_for_url(url:URL) -> tuple[URL, str | None]Get a permitted proxy for the given URL from the env.
func
aiohttp.helpers.is_canonical_ipv4_address(host:str) -> boolCheck if host is a canonical dotted-quad IPv4 address.
func
aiohttp.helpers.is_ip_address(host:str | None) -> boolCheck if host looks like an IP Address.
func
aiohttp.helpers.must_be_empty_body(method:str, code:int) -> boolCheck if a request must return an empty body.
func
aiohttp.helpers.netrc_from_env() -> netrc.netrc | NoneLoad netrc from file.
func
aiohttp.helpers.parse_content_type(raw:str) -> tuple[str, MappingProxyType[str, str]]Parse Content-Type header.
func
aiohttp.helpers.parse_http_date(date_str:str | None) -> datetime.datetime | NoneProcess a date string, return a datetime object
func
aiohttp.helpers.parse_mimetype(mimetype:str) -> MimeTypeParses a MIME type into its components.
func
aiohttp.helpers.quoted_string(content:str) -> strReturn 7-bit content as quoted-string.
func
aiohttp.helpers.set_exception(fut:Union['asyncio.Future[_T]', ErrorableProtocol], exc:type[BaseException] | BaseException, exc_cause:BaseException=_EXC_SENTINEL) -> NoneSet future exception.
func
aiohttp.helpers.should_remove_content_length(method:str, code:int) -> boolCheck if a Content-Length header should be removed.
class
aiohttp.http_exceptions.BadHttpMethodInvalid HTTP method in status line.
class
aiohttp.http_exceptions.ContentEncodingErrorContent encoding error.
class
aiohttp.http_exceptions.ContentLengthErrorNot enough data to satisfy content length header.
class
aiohttp.http_exceptions.HttpProcessingErrorHTTP error.
class
aiohttp.http_exceptions.PayloadEncodingErrorBase class for payload errors
class
aiohttp.http_exceptions.TransferEncodingErrortransfer encoding error.
class
aiohttp.http_parser.HttpRequestParserRead request status line.
class
aiohttp.http_parser.HttpResponseParserRead response status line and headers.
method
aiohttp.http_writer.StreamWriter.drain() -> NoneFlush the write buffer.
method
aiohttp.http_writer.StreamWriter.send_headers() -> NoneForce sending buffered headers if not already sent.
method
aiohttp.http_writer.StreamWriter.set_eof() -> NoneIndicate that the message is complete.
method
aiohttp.http_writer.StreamWriter.write(chunk:Union[bytes, bytearray, 'memoryview[int]', 'memoryview[bytes]'], *drain:bool=True, *LIMIT:int=65536) -> NoneWrites chunk of data to a stream.
method
aiohttp.http_writer.StreamWriter.write_headers(status_line:str, headers:'CIMultiDict[str]') -> NoneWrite headers to the stream.
class
aiohttp.multipart.BodyPartReaderMultipart reader for single body part.
method
aiohttp.multipart.BodyPartReader.decode(data:bytes) -> bytesDecodes data synchronously.
method
aiohttp.multipart.BodyPartReader.decode_iter(data:bytes) -> AsyncIterator[bytes]Async generator that yields decoded data chunks.
method
aiohttp.multipart.BodyPartReader.get_charset(default:str) -> strReturns charset parameter from Content-Type header or default.
method
aiohttp.multipart.BodyPartReader.json(*encoding:str | None=None) -> dict[str, Any] | NoneLike read(), but assumes that body parts contains JSON data.
method
aiohttp.multipart.BodyPartReader.name() -> str | NoneReturns name specified in Content-Disposition header.
method
aiohttp.multipart.BodyPartReader.read(*decode:bool=False) -> bytesReads body part data.
method
aiohttp.multipart.BodyPartReader.read_chunk(size:int=chunk_size) -> bytesReads body part content chunk of the specified size.
method
aiohttp.multipart.BodyPartReader.readline() -> bytesReads body part by line by line.
method
aiohttp.multipart.BodyPartReader.release() -> NoneLike read(), but reads all the data to the void.
method
aiohttp.multipart.BodyPartReader.text(*encoding:str | None=None) -> strLike read(), but assumes that body part contains text data.
class
aiohttp.multipart.MultipartReaderMultipart body reader.
method
aiohttp.multipart.MultipartReader.fetch_next_part() -> Union['MultipartReader', BodyPartReader]Returns the next body part reader.
method
aiohttp.multipart.MultipartReader.from_response(response:'ClientResponse') -> MultipartResponseWrapperConstructs reader instance from HTTP response.
method
aiohttp.multipart.MultipartReader.next() -> Union['MultipartReader', BodyPartReader] | NoneEmits the next multipart body part.
class
aiohttp.multipart.MultipartResponseWrapperWrapper around the MultipartReader.
method
aiohttp.multipart.MultipartResponseWrapper.at_eof() -> boolReturns True when all response data had been read.
method
aiohttp.multipart.MultipartResponseWrapper.next() -> Union['MultipartReader', 'BodyPartReader'] | NoneEmits next multipart reader object.
method
aiohttp.multipart.MultipartResponseWrapper.release() -> NoneRelease the connection gracefully.
class
aiohttp.multipart.MultipartWriterMultipart body writer.
method
aiohttp.multipart.MultipartWriter.append_form(obj:Sequence[tuple[str, str]] | Mapping[str, str], headers:Mapping[str, str] | None=None) -> PayloadHelper to append form urlencoded part.
method
aiohttp.multipart.MultipartWriter.append_json(obj:Any, headers:Mapping[str, str] | None=None) -> PayloadHelper to append JSON part.
method
aiohttp.multipart.MultipartWriter.append_payload(payload:Payload) -> PayloadAdds a new body part to multipart writer.
method
aiohttp.multipart.MultipartWriter.as_bytes(encoding:str='utf-8', errors:str='strict') -> bytesReturn bytes representation of the multipart data.
method
aiohttp.multipart.MultipartWriter.close() -> NoneClose all part payloads that need explicit closing.
method
aiohttp.multipart.MultipartWriter.decode(encoding:str='utf-8', errors:str='strict') -> strReturn string representation of the multipart data.
method
aiohttp.multipart.MultipartWriter.size() -> int | NoneSize of the payload.
method
aiohttp.multipart.MultipartWriter.write(writer:AbstractStreamWriter, close_boundary:bool=True) -> NoneWrite body.
class
aiohttp.payload.JsonBytesPayloadJSON payload for encoders that return bytes directly.
class
aiohttp.payload.LookupErrorRaised when no payload factory is found for the given data type.
method
aiohttp.payload.Payload.as_bytes(encoding:str='utf-8', errors:str='strict') -> bytesReturn bytes representation of the value.
method
aiohttp.payload.Payload.autoclose() -> boolWhether the payload can close itself automatically.
method
aiohttp.payload.Payload.close() -> NoneClose the payload if it holds any resources.
method
aiohttp.payload.Payload.consumed() -> boolWhether the payload has been consumed and cannot be reused.
method
aiohttp.payload.Payload.content_type() -> strContent type
method
aiohttp.payload.Payload.decode(encoding:str='utf-8', errors:str='strict') -> strReturn string representation of the value.
method
aiohttp.payload.Payload.encoding() -> str | NonePayload encoding
method
aiohttp.payload.Payload.filename() -> str | NoneFilename of the payload.
method
aiohttp.payload.Payload.headers() -> CIMultiDict[str]Custom item headers
method
aiohttp.payload.Payload.set_content_disposition(disptype:str, quote_fields:bool=True, _charset:str='utf-8', **params:str) -> NoneSets ``Content-Disposition`` header.
method
aiohttp.payload.Payload.size() -> int | NoneSize of the payload in bytes.
method
aiohttp.payload.Payload.write(writer:AbstractStreamWriter) -> NoneWrite payload to the writer stream.
method
aiohttp.payload.Payload.write_with_length(writer:AbstractStreamWriter, content_length:int | None) -> NoneWrite payload with a specific content length constraint.
class
aiohttp.payload.PayloadRegistryPayload registry.
class
aiohttp.resolver.AsyncResolverUse the `aiodns` package to make asynchronous DNS lookups
class
aiohttp.resolver.ThreadedResolverThreaded resolver.
class
aiohttp.streams.DataQueueDataQueue is a general-purpose blocking queue with one reader.
class
aiohttp.streams.EofStreameof stream indication.
class
aiohttp.streams.StreamReaderAn enhancement of asyncio.StreamReader.
method
aiohttp.streams.StreamReader.is_eof() -> boolReturn True if 'feed_eof' was called.
method
aiohttp.streams.StreamReader.iter_any() -> AsyncStreamIterator[bytes]Yield all available data as soon as it is received.
method
aiohttp.streams.StreamReader.iter_chunked(n:int) -> AsyncStreamIterator[bytes]Returns an asynchronous iterator that yields chunks of size n.
method
aiohttp.streams.StreamReader.readchunk() -> tuple[bytes, bool]Returns a tuple of (data, end_of_http_chunk).
method
aiohttp.streams.StreamReader.set_read_chunk_size(n:int) -> NoneRaise buffer limits to match the consumer's chunk size.
method
aiohttp.streams.StreamReader.unread_data(data:bytes) -> Nonerollback reading some data from stream, inserting it to buffer head.
class
aiohttp.tracing.TraceInternal dependency holder class.
class
aiohttp.tracing.TraceConnectionCreateEndParamsParameters sent by the `on_connection_create_end` signal
class
aiohttp.tracing.TraceConnectionQueuedEndParamsParameters sent by the `on_connection_queued_end` signal
class
aiohttp.tracing.TraceConnectionReuseconnParamsParameters sent by the `on_connection_reuseconn` signal
class
aiohttp.tracing.TraceDnsCacheHitParamsParameters sent by the `on_dns_cache_hit` signal
class
aiohttp.tracing.TraceDnsCacheMissParamsParameters sent by the `on_dns_cache_miss` signal
class
aiohttp.tracing.TraceDnsResolveHostEndParamsParameters sent by the `on_dns_resolvehost_end` signal
class
aiohttp.tracing.TraceDnsResolveHostStartParamsParameters sent by the `on_dns_resolvehost_start` signal
class
aiohttp.tracing.TraceRequestChunkSentParamsParameters sent by the `on_request_chunk_sent` signal
class
aiohttp.tracing.TraceRequestEndParamsParameters sent by the `on_request_end` signal
class
aiohttp.tracing.TraceRequestExceptionParamsParameters sent by the `on_request_exception` signal
class
aiohttp.tracing.TraceRequestHeadersSentParamsParameters sent by the `on_request_headers_sent` signal
class
aiohttp.tracing.TraceRequestRedirectParamsParameters sent by the `on_request_redirect` signal
class
aiohttp.tracing.TraceRequestStartParamsParameters sent by the `on_request_start` signal
method
aiohttp.web_app.Application.cleanup() -> NoneCauses on_cleanup signal Should be called after shutdown()
method
aiohttp.web_app.Application.shutdown() -> NoneCauses on_shutdown signal Should be called before cleanup()
class
aiohttp.web_exceptions.HTTPRedirectionBase class for exceptions with status codes in the 300s.
class
aiohttp.web_exceptions.HTTPSuccessfulBase class for exceptions with status codes in the 200s.
class
aiohttp.web_exceptions.NotAppKeyWarningWarning when not using AppKey in Application.
class
aiohttp.web_fileresponse.FileResponseA response object can be used to send files.
class
aiohttp.web_log.AccessLoggerHelper object to log access.
method
aiohttp.web_log.AccessLogger.enabled() -> boolCheck if logger is enabled.
class
aiohttp.web_protocol.PayloadAccessErrorPayload was accessed after response was sent.
class
aiohttp.web_protocol.RequestHandlerHTTP protocol implementation.
method
aiohttp.web_protocol.RequestHandler.close() -> NoneClose connection.
method
aiohttp.web_protocol.RequestHandler.force_close() -> NoneForcefully close connection.
method
aiohttp.web_protocol.RequestHandler.handle_error(request:BaseRequest, status:int=500, exc:BaseException | None=None, message:str | None=None) -> StreamResponseHandle errors.
method
aiohttp.web_protocol.RequestHandler.keep_alive(val:bool) -> NoneSet keep-alive connection mode.
method
aiohttp.web_protocol.RequestHandler.peername() -> str | tuple[str, int, int, int] | tuple[str, int] | NoneReturn peername if available.
method
aiohttp.web_protocol.RequestHandler.shutdown(timeout:float | None=15.0) -> NoneDo worker process exit preparations.
method
aiohttp.web_protocol.RequestHandler.sockname() -> str | tuple[str, int, int, int] | tuple[str, int] | NoneReturn sockname if available.
method
aiohttp.web_protocol.RequestHandler.ssl_context() -> Optional['ssl.SSLContext']Return SSLContext if available.
method
aiohttp.web_protocol.RequestHandler.start() -> NoneProcess incoming request.
class
aiohttp.web_protocol.RequestPayloadErrorPayload parsing error.
method
aiohttp.web_request.Request.app() -> 'Application'Application instance.
method
aiohttp.web_request.Request.match_info() -> 'UrlMappingMatchInfo'Result of route resolving.
class
aiohttp.web_routedef.RouteTableDefRoute definition table
class
aiohttp.web_runner.AppRunnerWeb Application runner
class
aiohttp.web_runner.ServerRunnerLow-level web server runner
class
aiohttp.web_urldispatcher.ResourceRouteA route with resource
method
aiohttp.web_urldispatcher.ResourceRoute.url_for(*args:str, **kwargs:str) -> URLConstruct url for route with additional params.
About this data
These signatures were extracted from the public source of aio-libs/aiohttp
using Python's ast module. Argument names, default values,
type annotations and return types are taken verbatim from the code.
Implementation bodies are never stored. See
how it works for details.