zen_query
Extract multiple fields from every element matching a CSS selector, avoiding per-element calls. Supports default fields (text, href, src) and custom attributes, bounds, or HTML.
Instructions
Extract multiple fields from every element matching a CSS selector.
Much faster and cheaper than calling zen_js per element. The default
fields cover the common ones (text, href, value, src, alt, id, name);
pass fields=["text","data-foo","bounds","attrs"] to get arbitrary
attributes or bounds/attrs/html extras.
Args: selector: CSS selector. fields: Field names to extract per element. Defaults to a useful set. limit: Max elements to return (capped at 500). tab_id: Optional tab; defaults to active.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| selector | Yes | ||
| fields | No | ||
| limit | No | ||
| tab_id | No |