Screenshot Capture
screenshot_captureCaptures a single frame of a display, window, or region to a PNG. Returns {path, resolution (PIXELS), scale_factor, display_id} — scale_factor is the backing scale of the display that was ACTUALLY captured (the same value list_displays reports for that display_id, by construction: both read one function), so pixels = points x scale_factor when converting a coordinate from the image to ui_click. If the display could not be determined you get scale_factor_unknown instead of a guess; resolution is always there, so you can derive the ratio yourself. Requires Screen Recording permission; without it returns an explicit permission_required, never a blank image.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| target | Yes | ||
| output_path | No | Where to write the PNG (default: temp file). Missing parent folders are created. |