get_list
Extract structured records from repeating elements on a webpage by specifying a container selector and field selectors, aligning data from each card or div reliably.
Instructions
Extract one record per element matching container_selector (e.g. a
product card in a grid), pulling fields out of each one. This is the
div/card equivalent of get_table for sites that don't use markup.
fields maps an output field name to a CSS selector relative to each
container, e.g. {"title": ".product-title a", "price": "[data-a-color='base']"}.
Use "" to target the container itself, or append "@attr" to read an
attribute instead of text, e.g. "link": "a@href" or "image": "img@src".
Because each field is looked up independently within its own container, results never get misaligned the way separate get_page_content calls + manual zipping do when some cards are missing a field (e.g. a strikethrough "was" price only some products have). Not sure of the right selectors? Call find_repeating_elements first.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"container_selector": "<container_selector>",
"fields": "<fields>"
},
"name": "get_list"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fields | Yes | ||
| container_selector | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |