---
title: "Capture screenshot"
method: GET
path: "/api/v1/ui/screenshot"
tags: ["ui"]
---

# Capture screenshot

`GET /api/v1/ui/screenshot`

Captures a screenshot of the entire screen or a specific element. Element IDs may identify MAUI visual elements or native elements advertised by the visual tree.

## Query parameters

- `elementId` string
- `maxWidth` integer
- `scale` 'native' | 'auto'
- `format` 'png' | 'jpeg'
- `captureEpoch` integer
- `registryGeneration` integer

## Response `200`

Screenshot image.

## Other responses

- `404` — Element not found.
- `409` — Capture is stale or a UI/native mutation or probe is temporarily busy. Retry after obtaining a fresh capture.
- `500` — Internal server error.
- `501` — Capability not implemented by the connected backend.

---

[API](https://skmtc.dev/dotnet/apis/devflow-agent-protocol.md) · [All operations](https://skmtc.dev/dotnet/apis/devflow-agent-protocol/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/dotnet/devflow-agent-protocol/revisions/31dec8eed3de/schema)
