scrapy-poet integration, if enabled during the initial setup, allows obtaining the following inputs from web-poet and zyte-common-items through Zyte API:

Additional inputs and input annotations are also provided:

Built-in inputs

class scrapy_zyte_api.Actions(results: List[_ActionResult] | None)[source]

A page input that specifies browser actions and contains their results.

The actions must be specified with an annotation using actions().

results: List[_ActionResult] | None

Results of actions.

class scrapy_zyte_api.Geolocation[source]

A page input that forces a given geolocation for all other page inputs.

The target geolocation must be specified with an annotation.

class scrapy_zyte_api.Screenshot(body: bytes)[source]

A container for holding the screenshot of a webpage.

body: bytes


Built-in input annotations

enum scrapy_zyte_api.ExtractFrom(value)[source]

Annotation to specify the extraction source of an automatic extraction input, such as Product or Article.

See Dependency annotations.

Member Type:


Valid values are as follows:

httpResponseBody: str = <ExtractFrom.httpResponseBody: 'httpResponseBody'>
browserHtml: str = <ExtractFrom.browserHtml: 'browserHtml'>
scrapy_zyte_api.actions(value: Iterable[Action])[source]

Convert an iterable of Action dicts into a hashable value.