canonical: https://jentic.com/apis/applitools.com/applitools

# Applitools Eyes API

Jentic publishes the only available OpenAPI specification for Applitools Eyes API, keeping it validated and agent-ready. The Applitools Eyes Server REST API exposes management operations on top of Applitools' visual testing platform - read batch results and statistics, set or update batch properties, post discussion comments on visual diffs, set SCM commit statuses for visual review checks, and validate API keys. The eight endpoints are designed for CI integration and dashboard automation, not for executing the visual checks themselves (which run through Applitools SDKs).

## For AI agents

Read visual test batch results, manage batch properties, comment on visual diffs, and set SCM commit checks for visual review pipelines.

## Scope

Does not run visual checks, drive browsers, or capture screenshots - use the Applitools SDK for execution and this API for batch management, comments, and SCM status only.

## Capabilities

- Fetch the result and aggregated statistics of a visual test batch by batchId
- Update batch metadata such as name, branch, and accessibility properties
- Post discussion comments and reactions on a visual diff to coordinate review
- Set a commit status on a connected SCM provider so PR checks reflect visual review state
- Validate an Applitools API key before bootstrapping a CI run
- Filter batches by status - passed, failed, unresolved - for dashboards and alerting

## Use cases

### CI Visual Review Gate

After a CI run executes Applitools visual checks via the SDK, the same pipeline calls `/scm/commits/{sha}/set-status` to mark the GitHub or GitLab commit as success or failure based on the batch outcome. This blocks merges on unresolved visual diffs without requiring developers to log into the Applitools dashboard. The full status round-trip uses two endpoints - read the batch, set the commit status.

Example prompt: Read GET `/batches/{batchId}`, then POST `/scm/commits/{sha}/set-status` with status=failure if unresolved>0

### Visual Diff Review Bot

A review bot watches Applitools batches in a target branch, posts discussion comments via `/discuss/{discussionId}` when a visual diff awaits human review, and resolves or escalates threads as engineers respond. The bot uses `/batches/{batchId}/properties` to tag batches with the responsible team so notifications route correctly.

Example prompt: POST a comment on `/discuss/{discussionId}` mentioning the design owner team and tag batch with property 'team:checkout'

### Visual QA Dashboard

An internal dashboard polls /batches and `/batches/{batchId}/properties` to render a live view of visual test health across branches, surfacing the count of unresolved diffs, the dominant failing baseline, and trend over time. The dashboard validates each user's API key through `/auth/api-key-validation` before scoping queries to their team.

Example prompt: Validate API key with GET `/auth/api-key-validation`, then list the last 50 batches and aggregate unresolvedCount per branch

### AI Agent Visual Triage

An AI agent uses Jentic to triage failed Applitools batches - reading batch results, summarizing the diff regions, posting a contextual discussion comment, and updating the SCM commit status. Jentic securely stores the Applitools API key and the agent only sees the X-Eyes-Api-Key header value at execution time.

Example prompt: Search Jentic for 'get applitools batch results', call GET `/batches/{batchId}`, summarise unresolved diffs, and POST a discussion comment with the summary

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | `/batches/{batchId}` | Get the result and metadata of a visual test batch |
| GET | `/batches` | List visual test batches |
| GET | `/batches/{batchId}/properties` | Read batch properties such as name, branch, and tags |
| POST | `/discuss/{discussionId}` | Post a discussion comment on a visual diff |
| POST | `/scm/commits/{sha}/set-status` | Set a commit status on a linked SCM repository |
| GET | `/auth/api-key-validation` | Validate an Applitools API key |

## Key resources

- **batches** — Read batch results, statistics, and properties for visual test runs
- **discuss** — Post and read discussion comments on visual diffs
- **scm** — Set SCM commit statuses for visual review checks
- **auth** — Validate Applitools API keys

## Why Jentic

- **Setup:** Wiring Applitools Eyes by hand means learning its Eyes API-key header scheme and threading batch and discussion ids through its management paths yourself. Through Jentic you install once, import the Applitools Eyes API from the API Directory, store the key once, and your agent calls it.
- **Permission scoping:** Applitools puts the batch id in the URL path (`/batches/{batchId}`, `/batches/{batchId}/properties`), so a rule can pin your agent to reading a specific batch and its properties. You choose the operations it may call, so writes like posting discussions or setting SCM commit status are not included unless you add them.
- **Credential handling:** Your Applitools API key is stored once, encrypted, by your own Jentic One instance and attached to the Eyes key header at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'get Applitools batch results' or 'set commit status for visual review', and Jentic returns the matching operation with its parameter and response schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Percy API** — Visual review platform with a similar batch-and-comment model
- **BrowserStack API** — Cross-browser test execution that pairs with Applitools for the visual layer
- **GitHub REST API** — Read PR context and post review comments alongside Applitools commit statuses

## FAQ

### Why is there no official OpenAPI spec for Applitools Eyes API?

Applitools does not publish an OpenAPI specification. Jentic generates and maintains this spec so that AI agents and developers can call Applitools Eyes API via structured tooling. It is validated against the live API and kept up to date. Get started with Jentic One, the self-hosted execution layer.

### What authentication does the Applitools Eyes API use?

The API uses an API key in the X-Eyes-Api-Key header. You generate the key from the Applitools dashboard. Through Jentic the key is stored encrypted in your Jentic One instance and injected at execution time, so the raw key never enters the agent's context.

### Can I run a visual check through this API?

No - visual checks themselves are executed by the Applitools SDK in your test runner (Cypress, Playwright, Selenium, etc.). This REST API exposes management operations on top of completed batches: reading results, posting comments, and setting commit statuses.

### How do I block a pull request on unresolved visual diffs?

Read GET `/batches/{batchId}` to get unresolvedCount, then POST `/scm/commits/{sha}/set-status` with status=failure when unresolvedCount > 0. The connected GitHub or GitLab repository will reflect the failed check on the PR.

### How do I read Applitools batch results through Jentic?

Run pip install jentic, search 'get applitools batch results', and call GET `/batches/{batchId}` with the batchId returned by your test run. Jentic injects the X-Eyes-Api-Key automatically and returns the batch JSON for your agent to consume.

### Are there rate limits on the Applitools Eyes API?

Applitools enforces per-account rate limits that are not published in the spec. In practice the management endpoints are tolerant of CI burst patterns; if you exceed the limit the API returns 429. Cache batch reads where possible and avoid polling the same batch more than once per few seconds.

### Can I limit what my agent is allowed to do with the Applitools Eyes API?

Yes. Because you run Jentic One yourself, your own rules decide which operations and credentials the agent may use, and you pick exactly which endpoints it can call. Applitools carries the batch id in the URL path, such as GET `/batches/{batchId}` and GET `/batches/{batchId}/properties`, so a rule can pin the agent to reading one specific batch and its properties. Write operations like posting a discussion comment on a visual diff or setting an SCM commit status are not included unless you add them.
