BaseRequestData
crawlee._request.BaseRequestData
Index
Methods
from_url
Create a new
BaseRequestData
instance from a URL. SeeRequest.from_url
for more details.Parameters
url: str
method: HttpMethod = 'GET'keyword-only
payload: HttpPayload | None = Nonekeyword-only
label: str | None = Nonekeyword-only
unique_key: str | None = Nonekeyword-only
id: str | None = Nonekeyword-only
keep_url_fragment: bool = Falsekeyword-only
use_extended_unique_key: bool = Falsekeyword-only
kwargs: Any
Returns Self
get_query_param_from_url
Get the value of a specific query parameter from the URL.
Parameters
param: str
default: str | None = Nonekeyword-only
Returns str | None
Properties
data
handled_at
headers
HTTP request headers.
loaded_url
method
HTTP request method.
model_config
no_retry
payload
query_params
URL query parameters.
retry_count
unique_key
A unique key identifying the request. Two requests with the same unique_key
are considered as pointing
to the same URL.
If unique_key
is not provided, then it is automatically generated by normalizing the URL.
For example, the URL of HTTP://www.EXAMPLE.com/something/
will produce the unique_key
of http://www.example.com/something
.
Pass an arbitrary non-empty text value to the unique_key
property
to override the default behavior and specify which URLs shall be considered equal.
url
URL of the web page to crawl
user_data
Custom user data assigned to the request. Use this to save any request related data to the request's scope, keeping them accessible on retries, failures etc.
Data needed to create a new crawling request.