> For the complete documentation index, see [llms.txt](https://help.autify.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.autify.com/nocode-web/en/faq/faq-test-result/faq-screenshot/screenshot-timing-based-on-step-type.md). Agents can also search and read this documentation through its [MCP server](https://help.autify.com/~gitbook/mcp).

# Screenshot timing based on step type

## 1. Introduction

This guide provides detailed insights into the timing and management of screenshots within our workflow, covering best practices and common pitfalls.

## 2. Screenshot Timing

### 2.1 Overview

Screenshots are essential for documenting and validating steps. Accurate timing ensures they reflect the actions performed.

### 2.2 Step Timings

**Middle Step Capture:** Screenshots taken during the action. Use techniques like long-press clicks to keep the target element visible.

**Pre-Step Capture:** Screenshots taken before the action begins, documenting the state before any changes.

**Post Step Capture:** Screenshots taken after actions such as "Switch Window", "Go To", and "Execute JS Script", capturing the state post-execution.

### 2.3 Considerations and Best Practices

* Post-action screenshots may not always capture the target element if it disappears quickly.
* Use the Step Name or Memo section on the Scenario Details page for clarification if the element is not visible.
* For click actions, long-press clicks can help keep the element visible for the screenshot.

## 3. Common Issues and Solutions

* **Element Disappearance:** If an element disappears quickly after an action, the screenshot may not capture it. Use descriptive names and memos to provide context.
* **Timing Mismatch:** Screenshots might slightly lag behind the actual action. Ensuring a longer action duration can mitigate this issue.

## 4. Examples

<table data-search="false"><thead><tr><th>Step</th><th>Screenshot Timing</th></tr></thead><tbody><tr><td>Click Element</td><td>Middle</td></tr><tr><td>Close Window</td><td>Pre</td></tr><tr><td>Execute JS Script</td><td>Post</td></tr><tr><td>Go To</td><td>Post</td></tr><tr><td>Key Press</td><td>Middle</td></tr><tr><td>Set Input Value</td><td>Post</td></tr><tr><td>Switch Window</td><td>Post</td></tr><tr><td>Sleep</td><td>Post</td></tr></tbody></table>

## 5. Conclusion

Effective screenshot timing is crucial for accurate documentation and validation of actions. By following the guidelines and best practices outlined in this document, you can ensure that your screenshots effectively represent the steps taken.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.autify.com/nocode-web/en/faq/faq-test-result/faq-screenshot/screenshot-timing-based-on-step-type.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
