# screenshot

> Save the settled screen as a JPEG and print its path and size.

Source: https://zeptap.com/docs/cli/commands/screenshot



## Usage [#usage]

```sh
zeptap screenshot [-o <path>] [--if-changed] [--annotate]
```

## Options [#options]

| Option             | Description                                                                                                |
| ------------------ | ---------------------------------------------------------------------------------------------------------- |
| `-o, --out <path>` | Save to this path. A `.png` path saves a PNG                                                               |
| `--if-changed`     | If the screen hasn't changed since the last screenshot, print that file's path instead of saving a new one |
| `--annotate`       | Draw each text line's box and its `@t` number on the image, and print the lines                            |

Also takes the [global options](https://zeptap.com/docs/cli#global-options).

## Details [#details]

* The screenshot is taken after the screen stops moving (up to `--settle-ms`, default 3000).
* Files go to `./.zeptap/shots/`, numbered and limited to the last 50. See [Screenshots](https://zeptap.com/docs/cli/output#screenshots).
* Coordinates for touch commands are pixels in this image, origin top-left. Send the numbers you read; don't rescale them.
* `--if-changed` saves tokens in a polling loop: the agent opens the file only when the path changes.
* `--annotate` also refreshes the `@t` refs, so the numbers on the image work with `tap`.

## Examples [#examples]

```sh
$ zeptap screenshot -l 7
screenshot: /Users/you/project/.zeptap/shots/0043.jpg (591x1280 px; tap coordinates are pixels in it)

$ zeptap screenshot -l 7 -o ~/Desktop/home.png
$ zeptap screenshot -l 7 --annotate
$ zeptap screenshot -l 7 --if-changed
```

## MCP tool [#mcp-tool]

[`screenshot`](https://zeptap.com/docs/agents/tools#screenshot).
