RequestHistory Class

A container for an attempted request and the applicable response.

This is used to document requests/responses that resulted in redirected/retried requests.

Inheritance
builtins.object
RequestHistory

Constructor

RequestHistory(http_request: HTTPRequestType, http_response: Optional[HTTPResponseType] = None, error: Optional[Exception] = None, context: Optional[Dict[str, Any]] = None)

Parameters

http_request
HttpRequest
Required

The request.

http_response
HttpResponse
default value: None

The HTTP response.

error
Exception
default value: None

An error encountered during the request, or None if the response was received successfully.

context
dict
default value: None

The pipeline context.